Nick Coghlan <ncogh...@gmail.com> added the comment:

No, the context must always be included unless explicitly suppressed. The 
interpreter can't reliably tell the difference between a raise statement in the 
current exception handler and one buried somewhere inside a nested function 
call. The whole point is to give developers a hint as to how to trigger the 
broken error handling code, which only works if the default behaviour is to 
provide the additional information.

Being able to suppress the context *is* a valid feature request, but one that 
will now need to wait until Python 3.3. In the meantime, sys.excepthook + the 
traceback module + PYTHONSTARTUP allows individual users to modify the 
interactive prompt to exhibit whatever exception display behaviour they like, 
and applications can do the same thing in their __main__module (likely via a 
context manager retrieved from a utility module).

----------
keywords: +after moratorium
versions: +Python 3.3 -Python 3.2

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue6210>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to