10000 CI Use Cython 3.1 for free-threaded build (#31357) · scikit-learn/scikit-learn@efe3b63 · GitHub
[go: up one dir, main page]

Skip to content

Commit efe3b63

Browse files
authored
CI Use Cython 3.1 for free-threaded build (#31357)
1 parent 8c508c4 commit efe3b63

4 files changed

+8
-17
lines changed

build_tools/azure/install.sh

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -67,17 +67,7 @@ python_environment_install_and_activate() {
6767
fi
6868

6969
# Install additional packages on top of the lock-file in specific cases
70-
if [[ "$DISTRIB" == "conda-free-threaded" ]]; then
71-
# TODO: we install scipy with pip. When there is a conda-forge package,
72-
# we can update build_tools/update_environments_and_lock_files.py and
73-
# remove the line below
74-
pip install scipy --only-binary :all:
75-
# TODO: we install cython 3.1 alpha from pip. When there is a conda-forge package,
76-
# we can update build_tools/update_environments_and_lock_files.py and
77-
# remove the line below
78-
pip install --pre cython --only-binary :all:
79-
80-
elif [[ "$DISTRIB" == "conda-pip-scipy-dev" ]]; then
70+
if [[ "$DISTRIB" == "conda-pip-scipy-dev" ]]; then
8171
echo "Installing development dependency wheels"
8272
dev_anaconda_url=https://pypi.anaconda.org/scientific-python-nightly-wheels/simple
8373
dev_packages="numpy scipy pandas Cython"

build_tools/azure/pylatest_free_threaded_environment.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@ channels:
66
dependencies:
77
- python-freethreading
88
- numpy
9+
- scipy
10+
- cython
911
- joblib
1012
- threadpoolctl
1113
- pytest

build_tools/azure/pylatest_free_threaded_linux-64_conda.lock

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Generated by conda-lock.
22
# platform: linux-64
3-
# input_hash: c7db5547fb9ea583bb70736e98b526e9e435c63cb5f6f3c4f38e0f0925e28535
3+
# input_hash: b76364b5635e8c36a0fc0777955b5664a336ba94ac96f3ade7aad842ab7e15c5
44
@EXPLICIT
55
https://conda.anaconda.org/conda-forge/linux-64/_libgcc_mutex-0.1-conda_forge.tar.bz2#d7c89558ba9fa0495403155b64376d81
66
https://conda.anaconda.org/conda-forge/noarch/python_abi-3.13-7_cp313t.conda#df81edcc11a1176315e8226acab83eec
@@ -34,6 +34,7 @@ https://conda.anaconda.org/conda-forge/linux-64/libopenblas-0.3.29-pthreads_h94d
3434
https://conda.anaconda.org/conda-forge/linux-64/python-3.13.3-h4724d56_1_cp313t.conda#8193603fe48ace3d8801cfb246f44491
3535
https://conda.anaconda.org/conda-forge/noarch/colorama-0.4.6-pyhd8ed1ab_1.conda#962b9857ee8e7018c22f2776ffa0b2d7
3636
https://conda.anaconda.org/conda-forge/noarch/cpython-3.13.3-py313hd8ed1ab_1.conda#6ba9ba47b91b7758cb963d0f0eaf3422
37+
https://conda.anaconda.org/conda-forge/noarch/cython-3.1.0-pyh2c78169_100.conda#89943f37072ca254aa4b7de98c6d7f0a
3738
https://conda.anaconda.org/conda-forge/noarch/execnet-2.1.1-pyhd8ed1ab_1.conda#a71efeae2c160f6789900ba2631a2c90
3839
https://conda.anaconda.org/conda-forge/noarch/iniconfig-2.0.0-pyhd8ed1ab_1.conda#6837f3eff7dcea42ecd714ce1ac2b108
3940
https://conda.anaconda.org/conda-forge/linux-64/libblas-3.9.0-31_h59b9bed_openblas.conda#728dbebd0f7a20337218beacffd37916
@@ -57,3 +58,4 @@ https://conda.anaconda.org/conda-forge/noarch/meson-python-0.18.0-pyh70fd9c4_0.c
5758
https://conda.anaconda.org/conda-forge/linux-64/numpy-2.2.5-py313h103f029_0.conda#7dcbd568d6f8a4ffba5ace28915f1230
5859
https://conda.anaconda.org/conda-forge/noarch/pytest-8.3.5-pyhd8ed1ab_0.conda#c3c9316209dec74a705a36797970c6be
5960
https://conda.anaconda.org/conda-forge/noarch/pytest-xdist-3.6.1-pyhd8ed1ab_1.conda#59aad4fb37cabc0bacc73cf344612ddd
61+
https://conda.anaconda.org/conda-forge/linux-64/scipy-1.15.2-py313h7f7b39c_0.conda#65f0c403e4324062633e648933f20a2e

build_tools/update_environments_and_lock_files.py

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -271,11 +271,8 @@ def remove_from(alist, to_remove):
271271
"conda_dependencies": [
272272
"python-freethreading",
273273
"numpy",
274-
# TODO add cython and scipy when there are conda-forge packages for
275-
# them and remove dev version install in
276-
# build_tools/azure/install.sh. Note that for now conda-lock does
277-
# not deal with free-threaded wheels correctly, see
278-
# https://github.com/conda/conda-lock/issues/754.
274+
"scipy",
275+
"cython",
279276
"joblib",
280277
"threadpoolctl",
281278
"pytest",

0 commit comments

Comments
 (0)
0