yarl
yarl copied to clipboard
📦 Start building wheels with free-threading
What do these changes do?
Fancy 3.13t stuff.
Are there changes in behavior for the user?
Being able to install from wheels under free-threaded Python builds.
Related issue number
N/A
Checklist
- [x] I think the code is well written
- [ ] Unit tests for the changes exist
- [ ] Documentation reflects the changes
Looks like this needs an unreleased Cython version from Git.
I think we need to wait for Cython 3.1+ to do this
https://docs.cython.org/en/latest/src/userguide/freethreading.html
Looks like 3.1 is getting closer https://github.com/cython/cython/milestone/65
Projects like numpy use a development version of cython to build wheels because the cython release might be far away.
This is fine, we're not in a hurry. It's always been like this.
The target cannot be solved by upgrading Cython version only.
IIRC the quoter uses pre-allocated memory buffer for small strings: https://github.com/aio-libs/yarl/blob/master/yarl/_quoting_c.pyx#L28
Now it's access is protected by GIL, gil-less solution requires some sort of explicit synchronization.
Closing as it's been implemented in #1456 already.