James Y Knight wrote:
On Dec 9, 2008, at 4:09 AM, Gabriel Rossetti wrote:
Forget it, I monkey-patched defer.Deferred to add __del__ to see if it was called, and it was, so they are getting destroyed...

BTW, that is not a good way to tell if objects are being deleted. Simply the act of adding a __del__ to an object can *cause* it to be not collected, due to the way python's GC works. Luckily that was not the case here. :) A better method to tell if objects are being collected is to create a list of weakrefs (with callbacks to print a message, say) to the objects.

James

Thank you for the tip James!

Gabriel

_______________________________________________
Twisted-Python mailing list
[email protected]
http://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-python

Reply via email to