Used cgitb instead of the default exception printing.

This commit is contained in:
Jeremy Fincher 2003-12-02 00:01:49 +00:00
parent 9264b635e2
commit 17d9a59845

View File

@ -35,6 +35,7 @@ import fix
import os
import sys
import cgitb
import atexit
import logging
@ -61,8 +62,7 @@ class Formatter(logging.Formatter):
for exn in deadlyExceptions:
if issubclass(e.__class__, exn):
raise
### TODO: formatException should use cgitb.
return logging.Formatter.formatException(self, (E, e, tb))
return cgitb.text((E, e, tb)).rstrip('\r\n')
class DailyRotatingHandler(logging.FileHandler):