Skip to content

gh-128421: Add locking to most frame object functions#131479

Merged
colesbury merged 6 commits intopython:mainfrom
colesbury:gh-128421-frame
Mar 21, 2025
Merged

gh-128421: Add locking to most frame object functions#131479
colesbury merged 6 commits intopython:mainfrom
colesbury:gh-128421-frame

Conversation

@colesbury
Copy link
Contributor

@colesbury colesbury commented Mar 19, 2025

This makes more operations on frame objects thread-safe in the free threaded build, which fixes some data races that occurred when passing exceptions between threads.

However, accessing local variables or the line number of a frame from another thread while its still executing is not thread-safe and may crash the interpreter.

Loading
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.

2 participants