From efc30a4ed2bc37b09ffdffba60533152d71b7f31 Mon Sep 17 00:00:00 2001 From: Valentin Lorentz Date: Thu, 30 Jun 2011 00:55:09 +0200 Subject: [PATCH 1/2] Fix traceback when sending POST requests to the 404 error handler. --- src/utils/httpserver.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/utils/httpserver.py b/src/utils/httpserver.py index e0b986b2d..687c69ed5 100644 --- a/src/utils/httpserver.py +++ b/src/utils/httpserver.py @@ -132,7 +132,7 @@ class SupyHTTPServerCallback: message, it probably means you are developping a plugin, and you have neither overriden this message or defined an handler for this query.""") - def doGet(self, handler, path): + def doGet(self, handler, path, *args, **kwargs): handler.send_response(400) self.send_header('Content_type', 'text/plain') self.send_header('Content-Length', len(self.defaultResponse)) @@ -153,7 +153,7 @@ class Supy404(SupyHTTPServerCallback): if I don't know what to serve. What I'm saying is you just triggered a 404 Not Found, and I am not trained to help you in such a case.""") - def doGet(self, handler, path): + def doGet(self, handler, path, *args, **kwargs): handler.send_response(404) self.send_header('Content_type', 'text/plain') self.send_header('Content-Length', len(self.response)) From 3b5d2cb48b5bb9fbe2c29a7ce7c46d705fddbf94 Mon Sep 17 00:00:00 2001 From: Valentin Lorentz Date: Thu, 30 Jun 2011 03:04:12 +0200 Subject: [PATCH 2/2] Herald: fix name conflict (wqs using _ as a temporary variable) --- plugins/Herald/plugin.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/Herald/plugin.py b/plugins/Herald/plugin.py index 833208ae8..b398362d1 100644 --- a/plugins/Herald/plugin.py +++ b/plugins/Herald/plugin.py @@ -149,7 +149,7 @@ class Herald(callbacks.Plugin): """ if optlist and text: raise callbacks.ArgumentError - for (option, _) in optlist: + for (option, foo) in optlist: if option == 'remove': self.setRegistryValue('default', '', channel) irc.replySuccess()