Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

Status of Conda ecosystem support #46

Open
3 tasks done
rgommers opened this issue Jul 23, 2024 · 5 comments
Open
3 tasks done

Status of Conda ecosystem support #46

rgommers opened this issue Jul 23, 2024 · 5 comments
Labels
status tracking Issue that tracks the status of compatibility and ongoing work in one or more open source projects

Comments

@rgommers
Copy link
Member

rgommers commented Jul 23, 2024

Currently (as of July 23rd, 2024) the recommended way to set up a conda dev environment for free-threaded CPython is to install python and pip from the ad-testing channel, and then install everything else from source or from nightly wheels.

@rgommers rgommers added the status tracking Issue that tracks the status of compatibility and ongoing work in one or more open source projects label Jul 23, 2024
@jjhelmus
Copy link

jjhelmus commented Sep 9, 2024

Conda-forge has a free-threading release of Python 3.13.0rc1: conda-forge/python-feedstock#679.

@lesteve
Copy link
Contributor

lesteve commented Sep 10, 2024

FWIW the conda-forge command to install a free-threaded CPython from conda-forge was added in #74 and is available in https://py-free-threading.github.io/installing_cpython/#conda-forge

@rgommers
Copy link
Member Author

rgommers commented Nov 27, 2024

Conda-forge has had packages for a month or so now for both Python itself and for some key packages like numpy and cython (thanks to work by @isuruf). The noarch issue was also resolved, and a migrator is waiting to get started with larger-scale rebuilding once more projects have done a free-threading compatible release: https://conda-forge.org/status/migration/?name=python313t. So we're all good here for now.

I did a bit of automation to set up a Pixi dev environment for SciPy, that should translate pretty well to other packages with compiled code. If anyone needs it (extracted and cleaned up a bit from https://github.com/rgommers/pixi-dev-scipystack/blob/main/scipy/pixi.toml):

[feature.free-threading]
channels = ["conda-forge/label/cython_dev", "conda-forge"]

[feature.free-threading.dependencies]
python-freethreading = ">=3.13.0,<3.14"
compilers = ">=1.7.0,<2"
pkg-config = ">=0.29.2,<0.30"
ninja = ">=1.12.1,<2"
ccache = ">=4.10.1,<5"
meson = ">=1.6.0,<2"
meson-python = ">=0.16.0"
cython = ">=3.1.0a0,<4"
pythran = ">=0.17.0"
python-build = "*"
pip = "*"
blas-devel = "*"
numpy = ">=2.1.3"
pybind11 = ">=2.13.1"
pytest = "*"
hypothesis = "*"
pytest-run-parallel = "*"

[feature.free-threading.tasks]
build-nogil = { cmd = "your-build-cmd", env = { CC = "ccache $CC", CXX = "ccache $CXX" } }
test-nogil = { cmd = "your-test-cmd" }

@lesteve
Copy link
Contributor

lesteve commented Nov 29, 2024

a migrator is waiting to get started with larger-scale rebuilding once more projects have done a free-threading

Just curious, do you have some kind of rough timeline for the conda-forge migration to start? Are there some key packages that you think should have a release with preliminary 1 free-threaded support before the migration is launched on conda-forge?

I have read conda-forge/conda-forge-pinning-feedstock#6673 and I can see there is a fine line to thread between making free-threaded available to users so they have a chance to test and report issues vs adding one more thing to do for busy conda-forge maintainers ...

Footnotes

  1. numpy 2.1 wording in their release notes which I used in scikit-learn changelog as well 😉)

@rgommers
Copy link
Member Author

@lesteve it's up to the conda-forge core team, but I'd wait at least for the widely used code generators (Cython 3.1, Cffi) and some key packages with say >5,000 direct dependencies according to https://deps.dev/ (e.g., SciPy, scikit-learn, Matplotlib, Cryptography, Pydantic, ...). And the counter at https://hugovk.github.io/free-threaded-wheels/ creeping quite a bit closer to 360 (now 328/360).

Probably end of Q1'25 is the earliest that can happen. In the meantime, packages can be built by hand if you know they're compatible, which can be helpful if you're just needing that one dev dependency to make your life easier:)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status tracking Issue that tracks the status of compatibility and ongoing work in one or more open source projects
Projects
None yet
Development

No branches or pull requests

3 participants