Crash report
What happened?
If you use any list comprehension inside a subinterpreter (either through _interpreters or through interpreters), an assertion fails in _PyCode_CheckNoExternalState:
import _interpreters
interp = _interpreters.create()
_interpreters.run_string(interp, "[None for _ in []]")
python: Objects/codeobject.c:1982: _PyCode_CheckNoExternalState: Assertion `counts->locals.hidden.total == 0' failed.
This was originally causing failures in #134606. I think that assertion can be removed, because _PyCode_CheckNoExternalState seems to have no need for the number of hidden locals being zero.
cc @ericsnowcurrently
CPython versions tested on:
CPython main branch
Operating systems tested on:
Linux
Output from running 'python -VV' on the command line:
No response
Linked PRs
Crash report
What happened?
If you use any list comprehension inside a subinterpreter (either through
_interpretersor throughinterpreters), an assertion fails in_PyCode_CheckNoExternalState:This was originally causing failures in #134606. I think that assertion can be removed, because
_PyCode_CheckNoExternalStateseems to have no need for the number of hidden locals being zero.cc @ericsnowcurrently
CPython versions tested on:
CPython main branch
Operating systems tested on:
Linux
Output from running 'python -VV' on the command line:
No response
Linked PRs
_PyCode_CheckNoExternalState#135466_PyCode_CheckNoExternalState(gh-135466) #135694