[Zope-dev] Using views for exceptions in Zope 2.12?
Chris Withers
chris at simplistix.co.uk
Fri May 8 04:01:21 EDT 2009
Hi All,
Given that the source of bug #372632 appears to be code related to
allowing views on exceptions in Zope 2, I thought I'd try use this method.
I tried this, without much joy:
<browser:defaultView
for="exceptions.Exception"
name="error"
/>
<browser:page
for="exceptions.Exception"
template="html/error.html"
name="error"
permission="zope2.Public"
/>
So, how should I be wiring in views for exceptions?
Also, is there a base view class for exceptions anywhere that provides
the following or their equivalents?
kwargs = {'error_type': error_name,
'error_value': error_value,
'error_tb': error_tb,
'error_traceback': error_tb,
'error_message': error_message,
'error_log_url': error_log_url}
Finally, when a view is used to render and exception, is the userthe
current logged in user (as is the case with standard_error_message) or
Anonymous (as has annoyingly been the case with Unauthorized exceptions
in the past)
cheers,
Chris
--
Simplistix - Content Management, Zope & Python Consulting
- http://www.simplistix.co.uk
More information about the Zope-Dev
mailing list