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.
master
W. Trevor King 2012-09-29 07:12:59 -04:00
parent 6e44dc1ff5
commit 409f9341d1
1 changed files with 2 additions and 2 deletions

View File

@ -312,8 +312,8 @@ class IkiWikiProcedureProxy(object):
except Exception as e: except Exception as e:
import traceback import traceback
self.error('uncaught exception: {}\n{}'.format( tb = traceback.format_exc()
e, traceback.format_exc(sys.exc_info()[2]))) self.error('uncaught exception: {}\n{}'.format(e, tb))
return return
def _importme(self): def _importme(self):