Crash because of ownership assert in `PyObject_ClearManagedDict`
Aperta
@sobolevn ci sta già lavorando.
Dal 26/6/2026.
interpreter-core
type-crash
- Lingua principale
- Python
- Stelle
- 77.2k
- Fork
- 35.9k
- Metriche di merge delle PR
- Metriche PR in attesa
Descrizione
Crash report
Refs https://github.com/python/cpython/issues/151763
Original description: https://gist.github.com/devdanzin/99b84915b197ae0ade7face262b8af66
Repro:
from unittest.mock import MagicMock
from _testcapi import set_nomemory
set_nomemory(200) # fail allocations from the 200th onward (lands in shutdown GC)
(MagicMock(), undefined_name) # build a MagicMock (managed __dict__), then NameError abandons
# it into a traceback cycle -> survives to shutdown GC
I have a fix ready.
Linked PRs
- gh-152255
Guida per i contributori
Apri la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Valutazione
Questa issue non è ancora stata valutata.