[issue45210] tp_dealloc docs should mention error indicator may be set

2022-04-06 Thread STINNER Victor
STINNER Victor added the comment: I wrote GH-32357 to check in debug mode that tp_dealloc functions leave the current exception unchanged. You can use attached unicode_dealloc_bug.patch to inject a bug to test my PR. Example ("make" is enough to trigger the bug): --- Fatal Python error: _Py_D

[issue45210] tp_dealloc docs should mention error indicator may be set

2022-04-06 Thread STINNER Victor
Change by STINNER Victor : -- pull_requests: +30407 pull_request: https://github.com/python/cpython/pull/32357 ___ Python tracker ___ __

[issue45210] tp_dealloc docs should mention error indicator may be set

2021-09-16 Thread STINNER Victor
STINNER Victor added the comment: I'm not sure that it's a feature. Maybe we should modify to never call tp_dealloc with an exception set. -- nosy: +vstinner ___ Python tracker _

[issue45210] tp_dealloc docs should mention error indicator may be set

2021-09-15 Thread Roundup Robot
Change by Roundup Robot : -- keywords: +patch nosy: +python-dev nosy_count: 2.0 -> 3.0 pull_requests: +26772 stage: -> patch review pull_request: https://github.com/python/cpython/pull/28358 ___ Python tracker _

[issue45210] tp_dealloc docs should mention error indicator may be set

2021-09-15 Thread Edward Yang
New submission from Edward Yang : The fact that the error indicator may be set during tp_dealloc is somewhat well known (https://github.com/posborne/dbus-python/blob/fef4bccfc535c6c2819e3f15384600d7bc198bc5/_dbus_bindings/conn.c#L387) but it's not documented in the official manual. We should