Skip to content
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

bpo-37421: Fix multiprocessing get_temp_dir() finalizer #14572

Merged
merged 2 commits into from
Jul 4, 2019
Merged

bpo-37421: Fix multiprocessing get_temp_dir() finalizer #14572

merged 2 commits into from
Jul 4, 2019

Conversation

vstinner
Copy link
Member

@vstinner vstinner commented Jul 3, 2019

Fix multiprocessing.util.get_temp_dir() finalizer: clear also the
'tempdir' configuration of the current process, so next call to
get_temp_dir() will create a new temporary directory, rather than
reusing the removed temporary directory.

https://bugs.python.org/issue37421

Fix multiprocessing.util.get_temp_dir() finalizer: clear also the
'tempdir' configuration of the current process, so next call to
get_temp_dir() will create a new temporary directory, rather than
reusing the removed temporary directory.
@vstinner
Copy link
Member Author

vstinner commented Jul 3, 2019

Oh, this fix is not enough to repair ./python -u -m test test_multiprocessing_spawn -R 3:3 regression, two other tests are still failing:

ERROR: test_context (test.test_multiprocessing_spawn.TestStartMethod)
ERROR: test_set_get (test.test_multiprocessing_spawn.TestStartMethod)

@vstinner vstinner merged commit 9d40554 into python:master Jul 4, 2019
@miss-islington
Copy link
Contributor

Thanks @vstinner for the PR 🌮🎉.. I'm working now to backport this PR to: 3.7, 3.8.
🐍🍒⛏🤖

@bedevere-bot
Copy link

GH-14585 is a backport of this pull request to the 3.8 branch.

@bedevere-bot bedevere-bot removed the needs backport to 3.8 only security fixes label Jul 4, 2019
@vstinner vstinner deleted the mp_remove_temp_dir branch July 4, 2019 10:29
@bedevere-bot
Copy link

GH-14586 is a backport of this pull request to the 3.7 branch.

miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Jul 4, 2019
Fix multiprocessing.util.get_temp_dir() finalizer: clear also the
'tempdir' configuration of the current process, so next call to
get_temp_dir() will create a new temporary directory, rather than
reusing the removed temporary directory.
(cherry picked from commit 9d40554)

Co-authored-by: Victor Stinner <vstinner@redhat.com>
miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Jul 4, 2019
Fix multiprocessing.util.get_temp_dir() finalizer: clear also the
'tempdir' configuration of the current process, so next call to
get_temp_dir() will create a new temporary directory, rather than
reusing the removed temporary directory.
(cherry picked from commit 9d40554)

Co-authored-by: Victor Stinner <vstinner@redhat.com>
miss-islington added a commit that referenced this pull request Jul 4, 2019
Fix multiprocessing.util.get_temp_dir() finalizer: clear also the
'tempdir' configuration of the current process, so next call to
get_temp_dir() will create a new temporary directory, rather than
reusing the removed temporary directory.
(cherry picked from commit 9d40554)

Co-authored-by: Victor Stinner <vstinner@redhat.com>
miss-islington added a commit that referenced this pull request Jul 4, 2019
Fix multiprocessing.util.get_temp_dir() finalizer: clear also the
'tempdir' configuration of the current process, so next call to
get_temp_dir() will create a new temporary directory, rather than
reusing the removed temporary directory.
(cherry picked from commit 9d40554)

Co-authored-by: Victor Stinner <vstinner@redhat.com>
lisroach pushed a commit to lisroach/cpython that referenced this pull request Sep 10, 2019
Fix multiprocessing.util.get_temp_dir() finalizer: clear also the
'tempdir' configuration of the current process, so next call to
get_temp_dir() will create a new temporary directory, rather than
reusing the removed temporary directory.
DinoV pushed a commit to DinoV/cpython that referenced this pull request Jan 14, 2020
Fix multiprocessing.util.get_temp_dir() finalizer: clear also the
'tempdir' configuration of the current process, so next call to
get_temp_dir() will create a new temporary directory, rather than
reusing the removed temporary directory.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants