GeezerVison is showing github.com — TraceRefs build triggers assertion errors · Issue #107630 · python/cpython
TraceRefs build triggers assertion errors #107630DescriptionIn a --with-trace-refs --with-pydebug build of 3.12 and main, even a simple test like test_int triggers an assertion error in the refchain handling. I expect it's caused by @ericsnowcurrently's PR #107567.
cpython-tracerefs % ../../cpython/configure -C --with-trace-refs --with-pydebug
[...]
cpython-tracerefs % make
[...]
cpython-tracerefs % ./python -m test test_int
0:00:00 load avg: 2.79 Run tests sequentially
0:00:00 load avg: 2.79 [1/1] test_int
== Tests result: SUCCESS ==
1 test OK.
Total duration: 477 ms
Tests result: SUCCESS
../../cpython/Objects/object.c:2234: _Py_ForgetReference: Assertion failed: invalid object chain
Enable tracemalloc to get the memory block allocation traceback
object address : 0x7ff86d998050
object refcount : 0
object type : 0x55fbc49aba60
object type name: dict
object repr : <refcnt 0 at 0x7ff86d998050>
Fatal Python error: _PyObject_AssertFailed: _PyObject_AssertFailed
Python runtime state: finalizing (tstate=0x000055fbc4b27e88)
Current thread 0x00007ff86daec740 (most recent call first):
<no Python frame>
Aborted
Linked PRs
Reacted by Eric Snow and sunmy2019 ActivityYhg1s commented on Aug 4, 2023 FWIW, if the fix for this is too involved or too complicated, I'd rather roll back #107567 and leave tracerefs broken when using isolated subinterpreters than leaving tracerefs broken for everything. ericsnowcurrently commented on Aug 4, 2023 I'm okay with a revert on 3.12. You're right that the previous state of affairs was better.
FWIW, there's an object leaking between interpreters somewhere and tracking that down is a big pain. I don't know how long it will take, so reverting now makes sense. I would like to un-revert once I've tracked down the culprit though. sunmy2019 commented on Aug 6, 2023 Confirmed it is fixed on the 3.12 branch. The issue would remain open for the main branch. added 2 commits that reference this issue on Aug 7, 2023gh-107630: Fix Remaining Subinterpreters Crashes on Py_TRACE_REFS Bui… ericsnowcurrently commented on Aug 8, 2023
MetadataMetadataStatusShow more project fields
DevelopmentNo branches or pull requestsIssue actions
|