I did a few tests with this script:

class byebye:

  def __del__(self):
    print 'Bye, bye...'


x = byebye()


x.del() gets executed if:
-I del x, then run gc.collect()
-simply exit the script
-get the script to abort on an exception

But if I kill it with the default signal TERM, the script dies, but I don't get the message, so I am assuming that python isn't taking the time to cleanup, even though that is (was) what TERM was intended for.

Has this been discussed before ? Is worth a suggestion (PEP) ?


--
Yves.
http://www.SollerS.ca
--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to