Why doesn't my finaliser run here?

Gregory Ewing greg.ewing at canterbury.ac.nz
Mon Sep 5 02:49:44 EDT 2016


Chris Angelico wrote:
> There's a reference here somewhere, though. My suspicion is it's in
> sys.exc_info / sys.last_traceback,

It's sys.last_traceback:

 >>> e = Eggs()
instance created successfully
('self definitely exists:', <__main__.Eggs object at 0x2b6670>)
Traceback (most recent call last):
   File "<stdin>", line 1, in <module>
   File "<stdin>", line 8, in __init__
Exception
 >>> sys.last_traceback = None
('deleting', '<__main__.Eggs object at 0x2b6670>')
 >>>

-- 
Greg
-- 
https://mail.python.org/mailman/listinfo/python-list




More information about the Python-list mailing list