Message145586
Submitting a patch proposing this format:
-----BEGIN UNRAISABLE EXCEPTION-----
Class: AttributeError
Instance: "'NoneType' object has no attribute 'someattr'"
Function: <bound method A.__del__ of <__main__.A object at 0x1007671d0>>
Traceback (most recent call last):
File "/tmp/bla.py", line 4, in __del__
None.someattr
-----END UNRAISABLE EXCEPTION-----
I've wrapped the exception information with header/footer differentiating it from a user's error handling code that also prints tracebacks (is it too much?).
I've considered using the warnings module, But I dislike the suppression of already warned messages. (2 instances will raise exception in __del__ but only one message will be printed)
This is my first patch submission so feel free giving me a hard time. |
|
Date |
User |
Action |
Args |
2011-10-15 11:05:44 | alonho | set | recipients:
+ alonho, amaury.forgeotdarc, pitrou, oddthinking |
2011-10-15 11:05:44 | alonho | set | messageid: <1318676744.4.0.642268850066.issue7317@psf.upfronthosting.co.za> |
2011-10-15 11:05:43 | alonho | link | issue7317 messages |
2011-10-15 11:05:43 | alonho | create | |
|