Message246491
| Author | petr.viktorin |
|---|---|
| Recipients | petr.viktorin |
| Date | 2015-07-09.13:31:32 |
| SpamBayes Score | -1.0 |
| Marked as misclassified | Yes |
| Message-id | <1436448692.77.0.0262276090845.issue24596@psf.upfronthosting.co.za> |
| In-reply-to |
| Content | |
|---|---|
When this program is invoked as a script (`python reproducer.py`), the __del__ is never called:
---
class ClassWithDel:
def __del__(self):
print('__del__ called')
a = ClassWithDel()
a.link = a
raise SystemExit(0)
---
Raising a different exception, moving the code to a function, importing the module, or invoking with -m (or even -c), causes __del__ to be called normally. |
|
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2015-07-09 13:31:32 | petr.viktorin | set | recipients: + petr.viktorin |
| 2015-07-09 13:31:32 | petr.viktorin | set | messageid: <1436448692.77.0.0262276090845.issue24596@psf.upfronthosting.co.za> |
| 2015-07-09 13:31:32 | petr.viktorin | link | issue24596 messages |
| 2015-07-09 13:31:32 | petr.viktorin | create | |