Skip to content

[FR]: Support free-threaded Python (3.13t/3.14t) wheel resolution with uv #805

@mkanat

Description

@mkanat

What is the current behavior?

When using rules_python's free-threaded Python toolchain (--@rules_python//python/config_settings:py_freethreaded=yes), aspect_rules_py's uv extension installs regular cp314 wheels instead of cp314t wheels.

You can reproduce it by depending on any package with a C extension (e.g., regex) and then trying to build with that flag while using the uv support.

The uv wheel installer resolves and installs wheels for the regular ABI (cp314). For example, regex gets installed with:

_regex.cpython-314-x86_64-linux-gnu.so

But the free-threaded interpreter (python3.14t) expects:

_regex.cpython-314t-x86_64-linux-gnu.so

Pure-Python packages are unaffected since they have no ABI-specific files.

Describe the feature

Just recognize that --@rules_python//python/config_settings:py_freethreaded=yes got set and select the right wheel.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions