This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author petr.viktorin
Recipients ncoghlan, petr.viktorin
Date 2015-06-04.08:53:10
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
tp_traverse is completely orthogonal to tp_dealloc, it's needed to detect (and then break) reference cycles like:
    obj = xxlimited.Xxo() = obj

As for tp_finalize: yes, mentioning it in tp_dealloc docs would be good, but I'll need a bit more studying to understand the problem correctly. The cases fixed here are relatively simple; Antoine gives more complex ones in [0]. When I feel qualified to give advice, I'll change the docs. (And most likely, write a PEP to make things easier; some changes to classes will be needed anyway to make PEP 489 multi-phase init work nicely in all cases).
But, I plan to focus my CPython time on documenting PEP 489 before diving in here. I think issue 16690 is a good place to track tp_dealloc docs changes.

Date User Action Args
2015-06-04 08:53:10petr.viktorinsetrecipients: + petr.viktorin, ncoghlan
2015-06-04 08:53:10petr.viktorinsetmessageid: <>
2015-06-04 08:53:10petr.viktorinlinkissue24373 messages
2015-06-04 08:53:10petr.viktorincreate