Commit Graph

6846 Commits

Author SHA1 Message Date
James Vega
a453f56284 ShrinkUrl: Use tinyurl's api-create page to avoid screen-scraping.
Set snarfThrottle to 0 while testing since we know there's nothing other than
the test input that could be causing us to snarf.  Fixes some intermittent
test failures due to fast snarf responses.

Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-11-04 22:37:53 -05:00
James Vega
eda8ce3aa0 Remove supybot-wizard's direct import of sets.
This is deprecated in 2.6 and supybot.utils already handles adding sets.Set to
__builtins__ if we're running with Python < 2.4.

Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-11-02 19:11:58 -05:00
James Vega
082ee59d32 Change a couple tests so they fail for real reasons instead of fake.
Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-11-01 19:08:34 -05:00
James Vega
8a98653d3b Allow Banmask.makeBanmask to work when dynamic.channel is None.
This gives back the ability to generate a banmask based on the global banmask
settings instead of per-channel settings.

Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-11-01 10:26:08 -05:00
James Vega
acaa9b1fd6 Rename Owner.log to Owner.logmark
Since every plugin has a log method (to do actual logging), the log command
was conflicting with that.  The attempted workaround was overly complicated
and broken.  Simply renaming the command to logmark simplifies everything.

Closes Sf #2889709

Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-10-31 18:22:14 -04:00
James Vega
213d304e54 ChannelStats: Add tracking of max users for a channel.
Closes Sf #1032038

Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-10-27 19:28:34 -04:00
James Vega
e393ea5917 Remove supybot-plugin-package from the set of installed files.
Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-10-25 09:20:45 -04:00
James Vega
899391e4dc Remove supybot-plugin-package.
It was never fully fleshed out.  If someone wants to finish it, they can
rewrite it or dig it out of the history and finish it.

Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-10-23 20:09:54 -04:00
James Vega
96aaf159f6 Use '2x' to reference Python version in README.
Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-10-23 20:07:48 -04:00
James Vega
dc3cdbd849 Re-word the private message FAQ since +E UMODE is no longer default.
Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-10-23 20:05:55 -04:00
James Vega
342ab23af8 Bump the minimum supported Python version to 2.4.
Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-10-23 19:35:24 -04:00
James Vega
56ba12aa4b Add support for UltimateIRCd's ! (protected) user mode.
Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-10-23 19:20:02 -04:00
James Vega
927c8c963a Use the correct URLs for the PySqlite website.
Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-10-21 22:48:04 -04:00
James Vega
f475525237 Update references to PySqlite URL
Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-10-21 22:43:26 -04:00
James Vega
4c9efc044b Replace Factoids.factoidPrefix with Factoids.format
Factoids.format makes use of registry.TemplatedString so the user can specify
excactly how they want the factoid reply to be formed.

Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-10-15 22:37:59 -04:00
James Vega
5af38453a8 Update Topic to use registry.TemplatedString
Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-10-15 22:35:17 -04:00
James Vega
035a9f2459 Add registry.TemplatedString for config variables which use string.Template 2009-10-15 22:17:36 -04:00
James Vega
25fc2de643 utils.web: Provide access to the raw httpUrlRe/urlRe strings
Using the compiled regexps for a PluginRegexp method's __doc__ doesn't work.

Closes Sourceforge #2879862

Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-10-15 22:16:38 -04:00
James Vega
f7cedae9ad Update ircutils.standardSubstitute to use string.Template
In the process, deprecate utils.str.perlVariableSubstitute.

Since string.Template doesn't support callable values though, we also
sub-class IrcDict and override __getitem__ to call the value if it is
callable.

Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-10-15 22:16:29 -04:00
James Vega
c4de386d8f ShrinkUrl: Remove our 'lazy biotch' message and length check.
If someone wants to specifically request that a URL, which can't possibly be
made shorter using a specific service, be shrunk, we should abide their
request.
2009-10-08 23:14:42 -04:00
James Vega
de4218b26e ShrinkUrl: Add support for x0.no 2009-10-08 22:58:57 -04:00
James Vega
d8c13c1f21 Rewrite ShrinkUrl's tests to ease testing of new services.
Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-10-08 22:28:02 -04:00
James Vega
924b57eca3 ShrinkUrl: Lower snarfThrottle to .5 second while testing.
Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-10-04 23:30:08 -04:00
James Vega
9d66399420 ShrinkUrl: Add support for xrl.us
Closes one part of Debian #539858

Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-10-04 23:30:02 -04:00
James Vega
200f716011 ShrinkUrl: Uniformly handle errors while shrinking via ShrinkError.
Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-10-04 22:08:55 -04:00
James Vega
c055b16ea8 ShrinkUrl: Use getattr() to simplify use of the growing number of services.
Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-10-04 21:54:20 -04:00
James Vega
ca917d3528 Use utils.web.httpUrlRe for the Web/ShrinkUrl snarfer regexes.
Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-10-04 21:41:05 -04:00
James Vega
22b3ccfbde ShrinkUrl: Generalize CdbShrunkenUrlDB's support for the different dbs.
Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-09-29 20:11:47 -04:00
James Vega
c5896ff6cb utils.web: Import urllib's urlencode into our namespace.
Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-09-29 19:54:07 -04:00
James Vega
56fbbe9f36 commands.py: Explain the odd userHostmask check in getOtherUser
Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-09-23 18:29:49 -04:00
Benjamin P. Burhans
6418b3d8c3 Check for empty word list in BadWords plugin before filtering.
Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-09-16 01:20:52 -04:00
James Vega
de79e679f4 Add a data kwarg to getUrl(Fd) a la urllib2.Request.
This allows plugins to easily make POST requests using our getUrl(Fd)
functions.

Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-09-16 01:17:33 -04:00
James Vega
e9a896c736 Clarify databases.types.cdb.maximumModifications' help and use a proper type.
The code expects a float between 0 and 1 inclusive but was simply using
registry.Float.  registry.Probability matches the behavior we want.

Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-09-11 18:09:38 -04:00
James Vega
28b4b4742e Correct Unix.fortune.offensive's description to use -a.
Closes deb#545780

Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-09-09 07:49:17 -04:00
James Vega
459bc616b1 Reply with an error when getBanmask doesn't have a valid channel.
Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-09-02 07:40:33 -04:00
James Vega
260570bd4f Ensure getBanmask has a channel variable as per makeBanmask's requirement
Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-09-01 23:29:42 -04:00
James Vega
eff20402ac Change canonize => normalize
Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-08-27 16:41:34 -04:00
Štěpán Němec
e922918564 QuoteGrabs plugin: Add an `ungrab' command.
Also add a missing error check in the `list' db method.

Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-08-27 14:47:09 -04:00
Štěpán Němec
a66034f852 Fix some typos/wordings.
Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-08-26 16:34:12 -04:00
Štěpán Němec
2242b26025 scripts/supybot: Unify the `os.linesep' vs '\n' usage.
Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-08-26 16:15:50 -04:00
Štěpán Němec
a693162059 Note plugin: Fix erroneous use of __contributors__.
Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-08-26 15:43:10 -04:00
Štěpán Němec
53cac5b078 callbacks.py: Remove duplicated getRealIrc() definition
NestedCommandsIrcProxy inherits the method from ReplyIrcProxy.
(Also fix some typos.)

Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-08-20 11:23:12 -04:00
Štěpán Němec
2fa0f6dedc commands.py: Sort the items of the wrappers dictionary
(just to make it readable)

Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-08-20 11:20:48 -04:00
James Vega
169aee3bc0 ChannelStats.rank now starts from 1 instead of 0
Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-08-20 10:48:41 -04:00
James Vega
aa9db7ba23 Escape '-' where necessary in supybot.1
Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-07-25 15:12:30 +02:00
James Vega
c376b8e796 Channel: Allow kick to accept multiple nicks.
Closes: Sf patch #1813467

Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-07-20 18:08:21 -04:00
Ricky Zhou
aa2337791a Account for negative times in timeElapsed.
Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-07-20 16:07:51 -04:00
James Vega
cbf68e53e3 QuoteGrabs: QuoteGrabsRecord at arg needs to be an int.
Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-07-18 20:27:45 -04:00
James Vega
dcb247494e User: getHostmasks should always return a string
Since it was calling irc.reply() in one case, we had both that irc.reply being
sent and the irc.reply() of what getHostmasks returned (None in that case).
Bad!

Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-07-16 11:39:20 -04:00
James Vega
9dccada152 User: Fix hostmask.list to show the user's name not the repr user object
Signed-off-by: James Vega <jamessan@users.sourceforge.net>
2009-07-16 11:28:43 -04:00