http://123maza.com/65/orange458/
--
http://mail.python.org/mailman/listinfo/python-list
Lawrence Oluyede wrote:
Il 2005-11-15, Ben Finney [EMAIL PROTECTED] ha
scritto:
Steve [EMAIL PROTECTED] wrote:
Does any one know if python has the ability to run a shutdown hook.
When the Python runtime system wants to exit, it raises a SystemExit
exception.
Catch that exception
great.
It's a good idea.
--
http://mail.python.org/mailman/listinfo/python-list
On 15 Nov 2005 14:45:27 -0800, Steve [EMAIL PROTECTED] wrote:
Does any one know if python has the ability to run a shutdown hook.
Look at the atexit module.
barbet (~)$ pydoc atexit.register
Help on function register in atexit:
atexit.register = register(func, *targs, **kargs)
register
Does any one know if python has the ability to run a shutdown hook.
For example you set a method to run when the python process is shutting
down, like it recieved a kill signal?
Basically looking for an effect like the following java code.
Runtime.getRuntime().addShutdownHook(new Thread
Steve [EMAIL PROTECTED] wrote:
Does any one know if python has the ability to run a shutdown hook.
When the Python runtime system wants to exit, it raises a SystemExit
exception.
Catch that exception at the top level of your code, and do whatever
you like. (It might be polite to actually exit
Thanks do appreciate it
--
Lisp Programming - You don't know what your missing ...
==
Help Send Laurie to Veterinary School
http://www.sendlaurietovetschool.com
--
http://mail.python.org/mailman/listinfo/python-list
Il 2005-11-15, Ben Finney [EMAIL PROTECTED] ha scritto:
Steve [EMAIL PROTECTED] wrote:
Does any one know if python has the ability to run a shutdown hook.
When the Python runtime system wants to exit, it raises a SystemExit
exception.
Catch that exception at the top level of your code