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 shihai1991
Recipients aeros, alex-garel, corona10, eric.snow, erlendaasland, nw0, petr.viktorin, shihai1991, vstinner
Date 2021-09-06.05:17:55
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
> PyStructSequence_InitType2() is not compatible with subinterpreters: it uses static types. Moreover, it allocates tp_members memory which is not released when the type is destroyed. But I'm not sure that the type is ever destroyed, since this API is designed for static types.

IMO, I suggest to create a new function, PyStructSequence_FromModuleAndDesc(module, desc, flags) to create a heaptype and don't aloocates memory block for tp_members,something like 'PyType_FromModuleAndSpec()`.

I don't know there have any block issue to do this converting operation. But I can take a look.

@petr ping, Petr, do you have any better idea about this question :)
Date User Action Args
2021-09-06 05:17:55shihai1991setrecipients: + shihai1991, vstinner, petr.viktorin, eric.snow, corona10, alex-garel, aeros, erlendaasland, nw0
2021-09-06 05:17:55shihai1991setmessageid: <>
2021-09-06 05:17:55shihai1991linkissue40512 messages
2021-09-06 05:17:55shihai1991create