Skip to content

bpo-34651: Only allow the main interpreter to fork.#9279

Merged
ericsnowcurrently merged 6 commits into
python:masterfrom
ericsnowcurrently:fork-and-subinterpreters
Sep 14, 2018
Merged

bpo-34651: Only allow the main interpreter to fork.#9279
ericsnowcurrently merged 6 commits into
python:masterfrom
ericsnowcurrently:fork-and-subinterpreters

Conversation

@ericsnowcurrently

@ericsnowcurrently ericsnowcurrently commented Sep 13, 2018

Copy link
Copy Markdown
Member

When os.fork() is called (on platforms that support it) all threads but the current one are destroyed in the child process. Consequently we must ensure that all but the associated interpreter are likewise destroyed. The main interpreter is critical for runtime operation, so we must ensure that fork only happens in the main interpreter.

https://bugs.python.org/issue34651

@ericsnowcurrently ericsnowcurrently merged commit 5903296 into python:master Sep 14, 2018
@ericsnowcurrently ericsnowcurrently deleted the fork-and-subinterpreters branch September 14, 2018 21:17
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.

3 participants