bpo-13487: Use sys.modules.copy() in inspect for thread safety by gpshead · Pull Request #18786 · python/cpython (original) (raw)
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 andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Conversation3 Commits1 Checks0 Files changed
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.Learn more about bidirectional Unicode characters
[ Show hidden characters]({{ revealButtonHref }})
…afety.
list(sys.modules.items())
was apparently not immune to "dictionary
changed size during iteration" errors.
gpshead changed the title
bpo-13487: Use sys.modules.copy() in inspect.getmodule() for thread s… bpo-13487: Use sys.modules.copy() in inspect for thread safety
Thanks @gpshead for the PR 🌮🎉.. I'm working now to backport this PR to: 3.7, 3.8.
🐍🍒⛏🤖
miss-islington pushed a commit to miss-islington/cpython that referenced this pull request
…afety. (pythonGH-18786)
list(sys.modules.items())
was apparently not immune to "dictionary
changed size during iteration" errors.
Tested internally using an integration test that has run into this a couple of times in the past two years. With this patch applied, the test is no longer flaky. (cherry picked from commit 85cf1d5)
Co-authored-by: Gregory P. Smith gps@google.com
gpshead deleted the inspect_getmodule_sys_modules_dict_copy branch
miss-islington pushed a commit to miss-islington/cpython that referenced this pull request
…afety. (pythonGH-18786)
list(sys.modules.items())
was apparently not immune to "dictionary
changed size during iteration" errors.
Tested internally using an integration test that has run into this a couple of times in the past two years. With this patch applied, the test is no longer flaky. (cherry picked from commit 85cf1d5)
Co-authored-by: Gregory P. Smith gps@google.com
miss-islington added a commit that referenced this pull request
…afety. (GH-18786)
list(sys.modules.items())
was apparently not immune to "dictionary
changed size during iteration" errors.
Tested internally using an integration test that has run into this a couple of times in the past two years. With this patch applied, the test is no longer flaky. (cherry picked from commit 85cf1d5)
Co-authored-by: Gregory P. Smith gps@google.com
miss-islington added a commit that referenced this pull request
…afety. (GH-18786)
list(sys.modules.items())
was apparently not immune to "dictionary
changed size during iteration" errors.
Tested internally using an integration test that has run into this a couple of times in the past two years. With this patch applied, the test is no longer flaky. (cherry picked from commit 85cf1d5)
Co-authored-by: Gregory P. Smith gps@google.com
ned-deily pushed a commit that referenced this pull request
…afety. (GH-18786)
list(sys.modules.items())
was apparently not immune to "dictionary
changed size during iteration" errors.
Tested internally using an integration test that has run into this a couple of times in the past two years. With this patch applied, the test is no longer flaky. (cherry picked from commit 85cf1d5)
Co-authored-by: Gregory P. Smith gps@google.com
Labels
An unexpected behavior, bug, or error