Shutdown hook

Steve steve.morin at gmail.com
Tue Nov 15 17:45:27 EST 2005


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(this));




More information about the Python-list mailing list