New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Python segfaults when configured with --with-pydebug --with-trace-refs #82581
Comments
configure --with-pydebug --with-trace-refs && make Modules/gcmodule.c:378: visit_decref: Assertion "!_PyObject_IsFreed(op)" failed Current thread 0x00007f6e2863e740 (most recent call first): |
This is a regression introduced by: commit 6876257
|
Notes for myself. the visit_decref() has been updated to display repr() of the parent object, rather than display the "freed" object. Before: Current thread 0x00007f6e2863e740 (most recent call first): After: object address : 0x7fe2d1a52b40 Fatal Python error: _PyObject_AssertFailed Current thread 0x00007fe2dea35740 (most recent call first): The problem was that the None object was seen as "freed" because _ob_prev=_ob_next=NULL. This object doesn't seem to be part of the list of all objects, sys.getobjects(). I fixed Py_None, but then I got the same assertion error on a different (moduledef) object. I gave up, and Pablo and me fixed _PyObject_IsFreed() instead. |
Since https://bugs.python.org/issue38070 was backported to 3.8, shouldn't this as well? 3.8 is currently broken otherwise. |
Thanks for the catch, Elvis! |
Thanks for the lightning-fast turnaround, Pablo! |
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
bugs.python.org fields:
The text was updated successfully, but these errors were encountered: