Feat: Add free-threaded Python support - #357
vchamarthi wants to merge 6 commits into
Conversation
There was a problem hiding this comment.
Pull request overview
This PR enables free-threaded (PEP 703) Python support for mkl_fft by marking the Cython extension as free-threading compatible, aligning build tooling requirements, and expanding CI/conda packaging to cover both CPython 3.14 (GIL) and 3.14t (free-threaded) variants.
Changes:
- Mark
mkl_fft/_pydfti.pyxasfreethreading_compatiblefor Cython and pin Cython to>=3.1.0across build/packaging. - Update conda recipes to require
cython >=3.1.0and removepython-gilpins. - Extend conda/pip CI matrices to build/test CPython 3.14
cp314andcp314tvariants and adjust cache/artifact naming accordingly.
Reviewed changes
Copilot reviewed 10 out of 10 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| pyproject.toml | Pins build-time Cython to >=3.1.0 for free-threading support features. |
| mkl_fft/_pydfti.pyx | Declares the extension as free-threading compatible via a Cython directive. |
| conda-recipe/meta.yaml | Aligns Intel-channel recipe with Cython >=3.1.0 and drops python-gil pins. |
| conda-recipe-cf/meta.yaml | Aligns conda-forge recipe with Cython >=3.1.0 and drops python-gil pins. |
| AGENTS.md | Updates documented build dependencies to reflect the Cython pin. |
| .github/workflows/conda-package.yml | Adds 3.14 cp314 and cp314t build/test coverage and distinguishes variants in cache/artifacts. |
| .github/workflows/conda-package-cf.yml | Mirrors conda-forge CI to build/test both 3.14 variants and adjust cache/artifacts. |
| .github/workflows/build-with-standard-clang.yml | Adds 3.14t to the Python matrix (currently incompatible with actions/setup-python). |
| .github/workflows/build-with-clang.yml | Adds 3.14t to the Python matrix (currently incompatible with actions/setup-python). |
| .github/workflows/build_pip.yml | Adds 3.14 cp314/cp314t variants via a python_spec matchspec approach. |
|
Testing this PR captured a few issues, which are being resolved in a separate PR. When above feedback is applied, I think this can go in. |
ndgrigorian
left a comment
There was a problem hiding this comment.
With previous comments resolved, LGTM
|
Thank you @ndgrigorian @antonwolfy |
…threaded-python-clean
|
This PR should be ready to have final look and merge. |
Summary
Enable free-threaded Python support for
mkl_fft.The Meson migration in #303 is now merged, so this PR contains only the
changes required for free-threaded support.
Depends on IntelPython/mkl-service#213 for a compatible free-threaded
mkl-servicepackage.