-
-
Notifications
You must be signed in to change notification settings - Fork 30.9k
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
test_interpreters fails when running tests sequentially #115490
Labels
Comments
Yeah, I see what the problem is. |
gh-115493 should take care of it. (I double-checked locally and it fixed it for me.) |
Yhg1s
added a commit
that referenced
this issue
Feb 15, 2024
…g unloading (#115515) Work around test.support.interpreters.channels not handling unloading, which regrtest does when running tests sequentially, by explicitly skipping the unloading of test.support.interpreters and its submodules. This can be rolled back once test.support.interpreters.channels supports unloading, if we are keeping sequential runs in the same process around.
With the workaround, this is no longer a blocker. |
ericsnowcurrently
added a commit
to ericsnowcurrently/cpython
that referenced
this issue
Mar 4, 2024
…ls not handling unloading (python#115515)" This reverts commit b0e5c35.
ericsnowcurrently
added a commit
that referenced
this issue
Mar 4, 2024
…es Handle Reloading Properly (gh-115493) The problem manifested when the .py module got reloaded and the corresponding extension module didn't. The .py module registers types with the extension and the extension was not allowing that to happen more than once. The solution: let it happen more than once.
github-project-automation
bot
moved this from Todo
to Done
in Release and Deferred blockers 🚫
Mar 4, 2024
adorilson
pushed a commit
to adorilson/cpython
that referenced
this issue
Mar 25, 2024
… Modules Handle Reloading Properly (pythongh-115493) The problem manifested when the .py module got reloaded and the corresponding extension module didn't. The .py module registers types with the extension and the extension was not allowing that to happen more than once. The solution: let it happen more than once.
diegorusso
pushed a commit
to diegorusso/cpython
that referenced
this issue
Apr 17, 2024
… Modules Handle Reloading Properly (pythongh-115493) The problem manifested when the .py module got reloaded and the corresponding extension module didn't. The .py module registers types with the extension and the extension was not allowing that to happen more than once. The solution: let it happen more than once.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Bug report
Bug description:
test_interpreters fails when running tests sequentially (which we do as part of the release process). The easiest reproducer seems to be
python -m test test_interpreters test_interpreters.test_channels
:The cause is libregrtest's behaviour of unloading newly imported modules from
sys.modules
after each test run. Either test.support.interpreters.channels should support being imported multiple times (perhaps by not doing any setup at import time, but via deliberate calls?), or libregrtest should be taught to skip unloading test.support.interpreters modules.@ericsnowcurrently, since this seems to be your area, any opinion making test.support.interpreters do the right thing here?
CPython versions tested on:
CPython main branch
Operating systems tested on:
Linux
Linked PRs
The text was updated successfully, but these errors were encountered: