FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

gh-134381: Improve thread safety in _PyThread_AfterFork by preserving not-started handles by zangjiucheng · Pull Request #134514 · python/cpython · GitHub

Repository navigation

gh-134381: Improve thread safety in _PyThread_AfterFork by preserving not-started handles - #134514

Merged
colesbury merged 8 commits into
python:mainfrom
zangjiucheng:gh-134381-main
May 23, 2025
Merged

colesbury merged 8 commits into
python:mainfrom
zangjiucheng:gh-134381-main

Conversation

zangjiucheng commented May 22, 2025 •
edited
Loading

Copy link
Copy Markdown
Contributor

python-cla-bot Bot commented May 22, 2025 •
edited
Loading

Copy link
Copy Markdown

All commit authors signed the Contributor License Agreement.

bedevere-app Bot commented May 22, 2025

Copy link
Copy Markdown

Most changes to Python require a NEWS entry. Add one using the blurb_it web app or the blurb command-line tool.

If this change has little impact on Python users, wait for a maintainer to apply the skip news label instead.

ZeroIntensity left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

Could you add a test for this? Something like the repro in the issue is probably fine.

Copy link
Copy Markdown
Contributor Author

Could you add a test for this? Something like the repro in the issue is probably fine.

I did add a similar test case, but not sure if that's good enough to cover the issue similar to the issue mentioned. Please take a review.

Comment thread Modules/_threadmodule.c Outdated
Comment thread Lib/test/test_thread.py Outdated
colesbury added needs backport to 3.13 only security fixes needs backport to 3.14 bugs and security fixes labels May 22, 2025

colesbury left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

Tests looks good. Some comments about how to structure it in the multiprocessing test suite below.

Comment thread Lib/test/_test_multiprocessing.py Outdated
Comment thread Lib/test/_test_multiprocessing.py Outdated
Comment thread Lib/test/_test_multiprocessing.py Outdated
Comment thread Lib/test/_test_multiprocessing.py Outdated

colesbury left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

Thanks for the fix, LGTM

colesbury added the 🔨 test-with-refleak-buildbots Test PR w/ refleak buildbots; report in status section label May 23, 2025

Copy link
Copy Markdown

🤖 New build scheduled with the buildbot fleet by @colesbury for commit ca06d61 🤖

Results will be shown at:

https://buildbot.python.org/all/#/grid?branch=refs%2Fpull%2F134514%2Fmerge

If you want to schedule another build, you need to add the 🔨 test-with-refleak-buildbots label again.

bedevere-bot removed the 🔨 test-with-refleak-buildbots Test PR w/ refleak buildbots; report in status section label May 23, 2025
colesbury self-assigned this May 23, 2025

ZeroIntensity left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

Tiny little formatting suggestion.

Comment thread Modules/_threadmodule.c Outdated
colesbury merged commit 9a2346d into python:main May 23, 2025

Copy link
Copy Markdown

Thanks @zangjiucheng for the PR, and @colesbury for merging it 🌮🎉.. I'm working now to backport this PR to: 3.13, 3.14.
🐍🍒⛏🤖

miss-islington pushed a commit to miss-islington/cpython that referenced this pull request May 23, 2025
…d after fork (pythongh-134514)

(cherry picked from commit 9a2346d)

Co-authored-by: Jiucheng(Oliver) <git.jiucheng@gmail.com>
miss-islington pushed a commit to miss-islington/cpython that referenced this pull request May 23, 2025
…d after fork (pythongh-134514)

(cherry picked from commit 9a2346d)

Co-authored-by: Jiucheng(Oliver) <git.jiucheng@gmail.com>

bedevere-app Bot commented May 23, 2025

Copy link
Copy Markdown

GH-134596 is a backport of this pull request to the 3.14 branch.

bedevere-app Bot removed the needs backport to 3.14 bugs and security fixes label May 23, 2025

bedevere-app Bot commented May 23, 2025

Copy link
Copy Markdown

GH-134597 is a backport of this pull request to the 3.13 branch.

bedevere-app Bot removed the needs backport to 3.13 only security fixes label May 23, 2025
colesbury pushed a commit that referenced this pull request May 23, 2025
…ad after fork (gh-134514) (gh-134597)

(cherry picked from commit 9a2346d)

Co-authored-by: Jiucheng(Oliver) <git.jiucheng@gmail.com>
colesbury pushed a commit that referenced this pull request May 23, 2025
…ad after fork (gh-134514) (gh-134596)

(cherry picked from commit 9a2346d)

Co-authored-by: Jiucheng(Oliver) <git.jiucheng@gmail.com>
Pranjal095 pushed a commit to Pranjal095/cpython that referenced this pull request Jul 12, 2025
taegyunkim pushed a commit to taegyunkim/cpython that referenced this pull request Aug 4, 2025
gostak-dd pushed a commit to gostak-dd/cpython that referenced this pull request Jun 2, 2026
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
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


Back | FazBrowse Home | New Git URL