[issue6210] Exception Chaining missing method for suppressing context

Ethan Furman report at bugs.python.org
Wed Dec 29 18:29:58 CET 2010


Ethan Furman <ethan at stoneleaf.us> added the comment:

> I said the *except* block, not the *try* block ;)

Ah.  So you did.

Okay, if I'm understanding correctly, the scenario you are talking about involves the code in the except block calling some other function, and that other function is raising an exception...  seems unlikely that this would be a case of transforming one exception into another, therefore the raise should not suppress the context by default...  okay, I'll concede the point.

Looks like the best option, then, is Nick's idea of the .no_context() method on exceptions.

----------
versions: +Python 3.2 -Python 3.3

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue6210>
_______________________________________


More information about the Python-bugs-list mailing list