55 runs-on : ubuntu-latest
66 strategy :
77 matrix :
8- python-version : ['3.9', '3.10', '3.11', '3.12']
9- numpy-version : ['1.21', '1.26', '2.0', 'dev']
10- exclude :
8+ include :
9+ - python-version : ' 3.10'
10+ numpy-version : ' 1.22'
11+ - python-version : ' 3.10'
12+ numpy-version : ' 1.26'
13+ - python-version : ' 3.10'
14+ numpy-version : ' latest'
1115 - python-version : ' 3.11'
12- numpy-version : ' 1.21 '
16+ numpy-version : ' dev '
1317 - python-version : ' 3.12'
14- numpy-version : ' 1.21'
15- fail-fast : true
18+ numpy-version : ' 1.22'
19+ - python-version : ' 3.12'
20+ numpy-version : ' 1.26'
21+ - python-version : ' 3.13'
22+ numpy-version : ' latest'
23+ - python-version : ' 3.13'
24+ numpy-version : ' dev'
25+
26+ fail-fast : false
1627 steps :
1728 - uses : actions/checkout@v4
1829 - uses : actions/setup-python@v5
@@ -22,21 +33,27 @@ jobs:
2233 run : |
2334 python -m pip install --upgrade pip
2435 if [ "${{ matrix.numpy-version }}" == "dev" ]; then
25- PIP_EXTRA='numpy --pre --extra-index-url https://pypi.anaconda.org/scientific-python-nightly-wheels/simple'
26- elif [ "${{ matrix.numpy-version }}" == "1.21" ]; then
27- PIP_EXTRA='numpy==1.21.*'
36+ python -m pip install pytest
37+ python -m pip install numpy --pre --extra-index-url https://pypi.anaconda.org/scientific-python-nightly-wheels/simple
38+ elif [ "${{ matrix.numpy-version }}" == "1.22" ]; then
39+ python -m pip install pytest numpy==1.22.*
40+ elif [ "${{ matrix.numpy-version }}" == "1.26" ]; then
41+ python -m pip install pytest numpy==1.26.*
2842 else
29- PIP_EXTRA='numpy==1.26.*'
43+ # Don't pip install .[dev] as it would pull in the whole torch cuda stack
44+ python -m pip install \
45+ array-api-strict \
46+ dask[array] \
47+ jax[cpu] \
48+ numpy \
49+ pytest \
50+ sparse \
51+ ndonnx \
52+ python -m -pip install torch --index-url https://download.pytorch.org/whl/cpu
3053 fi
3154
32- python -m pip install .[dev] $PIP_EXTRA
55+ - name : Test it installs
56+ run : python -m pip install .
3357
3458 - name : Run Tests
35- run : |
36- if [[ "${{ matrix.numpy-version }}" == "1.21" || "${{ matrix.numpy-version }}" == "dev" ]]; then
37- PYTEST_EXTRA=(-k "numpy and not jax and not torch and not dask and not sparse")
38- fi
39- pytest -v "${PYTEST_EXTRA[@]}"
40-
41- # Make sure it installs
42- python -m pip install .
59+ run : pytest -v
0 commit comments