Skip to content

gh-132713: Fix typing.Union[index] race condition #132802

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

Merged
merged 8 commits into from
Apr 23, 2025

Conversation

vstinner
Copy link
Member

@vstinner vstinner commented Apr 22, 2025

Use a critical section in union_getitem() to initialize the 'parameters' member.

Use a critical section in union_getitem() to initialize the
'parameters' member.
@vstinner
Copy link
Member Author

Please review the updated PR.

@vstinner
Copy link
Member Author

"All required checks pass" CI didn't run. I updated my branch to try to fix the CI.

@vstinner vstinner merged commit dc3e963 into python:main Apr 23, 2025
41 checks passed
@vstinner vstinner deleted the union_getitem branch April 23, 2025 13:45
@vstinner
Copy link
Member Author

Merged, thanks for reviews.

@vstinner vstinner added the needs backport to 3.13 bugs and security fixes label Apr 23, 2025
@miss-islington-app
Copy link

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

miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Apr 23, 2025
)

Add union_init_parameters() helper function. Use a critical section
to initialize the 'parameters' member.
(cherry picked from commit dc3e963)

Co-authored-by: Victor Stinner <vstinner@python.org>
@bedevere-app
Copy link

bedevere-app bot commented Apr 23, 2025

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

@bedevere-app bedevere-app bot removed the needs backport to 3.13 bugs and security fixes label Apr 23, 2025
vstinner added a commit that referenced this pull request Apr 23, 2025
…132839)

gh-132713: Fix typing.Union[index] race condition (GH-132802)

Add union_init_parameters() helper function. Use a critical section
to initialize the 'parameters' member.
(cherry picked from commit dc3e963)

Co-authored-by: Victor Stinner <vstinner@python.org>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants