Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

[3.14] gh-118981: multiprocessing.popen_spawn_posix, fix potential hang (gh-118982)#138605

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
encukou merged 2 commits intopython:3.14frommiss-islington:backport-8ed5a2b-3.14
Oct 8, 2025

Conversation

@miss-islington
Copy link
Contributor

@miss-islingtonmiss-islington commentedSep 7, 2025
edited by bedevere-appbot
Loading

fix potential hang.

It can happen that the child crashes right in the beginning for whatever reason. In this case, the parent will hang when writing into the pipe, because the child fd is not closed yet.

The normal pattern is to close the child fds right after the child proc is forked/executed/spawned, so when the child dies, then also the pipes will be closed, and there will be no hang (the parent gets SIGPIPE instead).
(cherry picked from commit8ed5a2b)

Co-authored-by: Albert Zeyeralbzey@gmail.com

pythongh-118982)fix potential hang.It can happen that the child crashes right in the beginning for whatever reason. In this case, the parent will hang when writing into the pipe, because the child fd is not closed yet.The normal pattern is to close the child fds right after the child proc is forked/executed/spawned, so when the child dies, then also the pipes will be closed, and there will be no hang (the parent gets SIGPIPE instead).(cherry picked from commit8ed5a2b)Co-authored-by: Albert Zeyer <albzey@gmail.com>
@encukouencukou merged commit3013683 intopython:3.14Oct 8, 2025
46 checks passed
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

@gpsheadgpsheadgpshead approved these changes

+1 more reviewer

@auvipyauvipyauvipy approved these changes

Reviewers whose approvals may not affect merge requirements

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

5 participants

@miss-islington@gpshead@auvipy@encukou@albertz

[8]ページ先頭

©2009-2025 Movatter.jp