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 vstinner
Recipients pablogsal, vstinner
Date 2020-04-07.16:23:41
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1586276621.78.0.843757244355.issue40217@roundup.psfhosted.org>
In-reply-to
Content
The bpo-35810 modified the object allocate to hold a *strong* reference to the type in PyObject.ob_type, whereas PyObject.ob_type is a *borrowed* references if the type is statically allocated.

commit 364f0b0f19cc3f0d5e63f571ec9163cf41c62958
Author: Eddie Elizondo <eduardo.elizondorueda@gmail.com>
Date:   Wed Mar 27 07:52:18 2019 -0400

    bpo-35810: Incref heap-allocated types in PyObject_Init (GH-11661)
    
    * Incref heap-allocated types in PyObject_Init
    * Add documentation and porting notes to What's New


The problem is now in some corner cases, the GC fails to visit all referrer of a type and so considers that the type is still alive.

bpo-40149 is a concrete example of such bug.

I propose to modify the GC to take bpo-35810 in account.

... or maybe I just misunderstood bpo-40149 bug :-)
History
Date User Action Args
2020-04-07 16:23:41vstinnersetrecipients: + vstinner, pablogsal
2020-04-07 16:23:41vstinnersetmessageid: <1586276621.78.0.843757244355.issue40217@roundup.psfhosted.org>
2020-04-07 16:23:41vstinnerlinkissue40217 messages
2020-04-07 16:23:41vstinnercreate