-----Original Message----- From: Chris Withers [mailto:chrisw@nipltd.com] Sent: 29 May 2000 14:01 To: Martijn Pieters Cc: Patrick J.M. Keane; zope@zope.org Subject: Re: [Zope] Traceback?
Martijn Pieters wrote:
If you switch debug mode off, tracebacks will be included in error messages as HTML comments, thus rendering them invisible from the unsuspecting site visitor.
Is that true even if you override standard_error_message?
I believe so, and empiracally this appears to be the case. From HTTPResponse.py: def _traceback(self,t,v,tb): tb=self.format_exception(t,v,tb,200) tb=join(tb,'\n') tb=self.quoteHTML(tb) if self.debug_mode: _tbopen, _tbclose = '<PRE>', '</PRE>' else: _tbopen, _tbclose = '<!--', '-->' return "\n%s\n%s\n%s" % (_tbopen, tb, _tbclose) which is appended to the body of the error message when an exception occurs. hth, -- Marcus