Message118141
There's an issue with the documentation on the atexit module[1]. It states:
"Note: the functions registered via this module are not called when the program is killed by a signal, when a Python fatal internal error is detected, or when os._exit() is called."
This isn't necessarily true. For instance, if I start the following script:
from atexit import register
from time import sleep
@register
def end():
print 'atexit'
while True:
sleep(1)
...and then do a "kill -SIGINT <pid>", the atexit function gets called. It would be helpful to have a more detailed description of the rules on how this works.
[1] http://docs.python.org/library/atexit.html#module-atexit |
|
Date |
User |
Action |
Args |
2010-10-07 21:34:55 | Jason.Baker | set | recipients:
+ Jason.Baker, docs@python |
2010-10-07 21:34:55 | Jason.Baker | set | messageid: <1286487295.44.0.431847380909.issue10046@psf.upfronthosting.co.za> |
2010-10-07 21:34:53 | Jason.Baker | link | issue10046 messages |
2010-10-07 21:34:52 | Jason.Baker | create | |
|