Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Add Cython flag to signal free-threading compatibility #113

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

lysnikolaou
Copy link

These are the necessary changes for imagecodecs to signify that it's compatible with the Python 3.13 free-threaded build. I've run some tests and everything seems to be running fine with it, apart from the issue described in #112.

@cgohlke cgohlke added the build label Oct 3, 2024
@cgohlke
Copy link
Owner

cgohlke commented Oct 3, 2024

Thanks. I'll reconsider this when ready to test free-threading. It's probably better to enable freethreading_compatible per module after individual review and testing. The criteria for freethreading_compatible must be stricter than passing existing tests without crash, no?

@lysnikolaou
Copy link
Author

A thing to note is that the GIL is dynamically enabled for the whole process even if there's just one extension module that does not set the freethreading_compatible flag. That's why we've been pretty aggressive in enabling the freethreading_compatible flag, since that enables testing for bigger codebases that include many dependencies.

Also, I'm happy to spend more time on this and do any testing you'd like to see. Apart from running the tests, I did a manual skim through the code as well, but that's always going to miss some stuff.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants