Dieter Maurer wrote:
I had a similar experience but solved it by modifying
"zLOG.EventLogger.log" in the following way:

# DM 2005-06-27: Zope style tracebacks
from zExceptions.ExceptionFormatter import format_exception
....
        # DM 2005-06-27: we now use Zope's traceback format because
        #  it is more informative
        #self.logger.log(level, msg, exc_info=(error is not None))
        exc_class = sys.exc_info()[0]
        if error and exc_class is not None: # Note: "error" is a boolean!
            msg += '\n' + ''.join(format_exception(*sys.exc_info()))
        self.logger.log(level, msg)

I like this one too :-)

That just leaves the traceback printed by pdb, anyone reckon they can get that to use the sensible formatter? ;-)

Maybe, code like this should move into the Zope core?

*shrugs* I'm quite happy with it as a product that I can add and remove as required...

cheers,

Chris

--
Simplistix - Content Management, Zope & Python Consulting
           - http://www.simplistix.co.uk

_______________________________________________
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - http://mail.zope.org/mailman/listinfo/zope-announce
http://mail.zope.org/mailman/listinfo/zope-dev )

Reply via email to