aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorW. Trevor King <wking@tremily.us>2012-09-29 07:12:59 -0400
committerW. Trevor King <wking@tremily.us>2012-09-29 07:12:59 -0400
commit409f9341d17ba88685f08b561378d6c0c783b405 (patch)
treed778c65deb96d993207a77316108b49c82f0f885
parent6e44dc1ff5905ac59fe6428c5ea17cd3d179407b (diff)
downloadikiwiki-409f9341d17ba88685f08b561378d6c0c783b405.tar
ikiwiki-409f9341d17ba88685f08b561378d6c0c783b405.tar.gz
proxy: don't pass arguments to format_exc() in IkiWikiProcedureProxy.run()
This avoids: Traceback (most recent call last): File "./plugins/rst", line 86, in <module> proxy.run() File "/home/wking/src/ikiwiki/plugins/proxy.py", line 316, in run e, traceback.format_exc(sys.exc_info()[2]))) File "/usr/lib/python3.2/traceback.py", line 269, in format_exc ... TypeError: unorderable types: int() < traceback() The syntax for format_exc in Python 2.x is: traceback.format_exc([limit]) In Python 3.x, it is: traceback.format_exc(limit=None, chain=True) Neither of these need any information from sys.exc_info() passed in.
-rwxr-xr-xplugins/proxy.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/plugins/proxy.py b/plugins/proxy.py
index 60ea89967..656c9e5bd 100755
--- a/plugins/proxy.py
+++ b/plugins/proxy.py
@@ -312,8 +312,8 @@ class IkiWikiProcedureProxy(object):
except Exception as e:
import traceback
- self.error('uncaught exception: {}\n{}'.format(
- e, traceback.format_exc(sys.exc_info()[2])))
+ tb = traceback.format_exc()
+ self.error('uncaught exception: {}\n{}'.format(e, tb))
return
def _importme(self):