-
-
Notifications
You must be signed in to change notification settings - Fork 643
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
…21670) As part of [upgrading to PyO3 v0.23.x](#21671), access to`pyclass`-annotated types will no longer be implicitly synchronized against the Python GIL. Those `pyclass`-annotated types [must now be `Sync`](https://pyo3.rs/v0.23.1/class/thread-safety) and provide that synchronization explicitly. Several places in Pants use `RefCell` which is not Send/Sync by itself. This PR uses `pyo3::sync::GILProtected` to provide explicit synchronization against the GIL for those use cases. (Eventually, we may wish to not use `GILProtected` to enable use of the Python 3.13 "no GIL" free threaded build, but that day is not today.) [Migration guide](https://pyo3.rs/v0.23.1/migration.html#free-threaded-python-support)
- Loading branch information
Showing
2 changed files
with
130 additions
and
96 deletions.
There are no files selected for viewing
This file contains 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
Oops, something went wrong.