-
Notifications
You must be signed in to change notification settings - Fork 4
64 lines (59 loc) · 2.36 KB
/
Copy pathpython-package.yml
File metadata and controls
64 lines (59 loc) · 2.36 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
# Workflow is based on the Astropy GitHub actions workflow, ci_workflows.yml
name: CI
on:
push:
branches:
- '*'
tags:
- '*'
pull_request:
# 2025-01-07
# NERSC has Python 3.10, Numpy 1.22.4, Scipy 1.8.1, matplotlib 3.8.4, astropy 6.0.1, healpy 1.16.6, PyYAML 6.0.1
# PyPI has Python 3.13, Numpy 2.2.1, Scipy 1.15.0, matplotlib 3.10.0, astropy 7.0.0, healpy 1.18.0, PyYAML 6.0.2
# Numpy 1.26.4 was the last pre-2.0 Numpy.
#
jobs:
tests:
name: Unit tests
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false # reset to true after Astropy 7 issues are resolved.
matrix:
include:
# Stable, yet close to bleeding-edge.
- os: ubuntu-latest
python-version: '3.13'
numpy-version: '<3.0'
- os: ubuntu-latest
python-version: '3.12'
numpy-version: '<2.2'
- os: ubuntu-latest
python-version: '3.11'
numpy-version: '<2.1'
# Similar to NERSC but more recent NumPy.
- os: ubuntu-latest
python-version: '3.10'
numpy-version: '<2.0'
steps:
- name: Install libraries
run: |
sudo apt install libopenblas-dev liblapack-dev liblapacke-dev
sudo apt install intel-mkl libmkl-dev
- name: Checkout code
uses: actions/checkout@v5
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v6
with:
python-version: ${{ matrix.python-version }}
- name: Install Python dependencies
run: |
python -m pip install --upgrade pip setuptools wheel
python -m pip install --upgrade --upgrade-strategy only-if-needed "numpy${{ matrix.numpy-version }}"
python -m pip install desiutil fitsio pytest
python -m pip install desitarget
python -m pip install git+https://github.com/desihub/desispec
- name: Install specex
run: |
python -m pip install --editable . --verbose
- name: Run the test
run: pytest