-
Notifications
You must be signed in to change notification settings - Fork 3
56 lines (52 loc) · 2.04 KB
/
python-package.yml
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
# Workflow is based on the Astropy GitHub actions workflow, ci_workflows.yml
name: CI
on:
push:
branches:
- '*'
tags:
- '*'
pull_request:
jobs:
tests:
name: Unit tests
runs-on: ${{ matrix.os }}
strategy:
fail-fast: true
matrix:
os: [ubuntu-latest]
python-version: ['3.9'] # fuji+guadalupe version
astropy-version: ['==5.0'] # fuji+guadalupe version
fitsio-version: ['==1.1.6'] # fuji+guadalupe version
numpy-version: ['<1.23'] # to keep asscalar, used by astropy
include:
- os: [ubuntu-latest]
python-version: '3.10'
astropy-version: '<7'
fitsio-version: '==1.2.4'
numpy-version: '2.1.3'
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: System packages
run: |
sudo apt install libbz2-dev
# needed for fitsio...
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install Python dependencies
run: |
python -m pip install --upgrade pip wheel
python -m pip install pytest
python -m pip install -r requirements.txt
python -m pip install -U 'numpy${{ matrix.numpy-version }}'
python -m pip install -U 'astropy${{ matrix.astropy-version }}'
python -m pip cache remove fitsio
python -m pip install --no-deps --force-reinstall --ignore-installed 'fitsio${{ matrix.fitsio-version }}'
python -m pip install git+https://github.com/desihub/[email protected]#egg=specter
- name: Run the test
run: pytest py/gpu_specter