Skip to content

Commit

Permalink
github action: move to uv
Browse files Browse the repository at this point in the history
  • Loading branch information
jcmgray committed Oct 9, 2024
1 parent f5040e7 commit 4b8a047
Show file tree
Hide file tree
Showing 9 changed files with 76 additions and 93 deletions.
27 changes: 16 additions & 11 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
strategy:
matrix:
os: [ubuntu-latest]
python-version: ['3.9', '3.10', '3.11']
python-version: ['3.9', '3.12']
env: [base]
include:
- os: macos-latest
Expand All @@ -26,23 +26,28 @@ jobs:
env: win
- os: ubuntu-latest
python-version: '3.11'
env: no-oe
env: minimal

steps:
- uses: actions/checkout@v4

- name: Install micromamba
uses: mamba-org/setup-micromamba@v2
- name: Install uv
uses: astral-sh/setup-uv@v3
with:
environment-file: ci/requirements/py-${{ matrix.env }}.yml
environment-name: test-env
cache-environment: true
create-args: >-
python=${{ matrix.python-version }}
conda
version: "latest"
enable-cache: true

- name: Install python
run: uv python install ${{ matrix.python-version }}

- name: Install dependencies
run: uv pip install -r ci/requirements/${{ matrix.env }}.txt

- name: Install cotengra
run: uv pip install -e .

- name: Test with pytest
run: pytest --cov=cotengra tests/ --cov-report=xml tests
run: uv run pytest --cov=cotengra tests/ --cov-report=xml tests

- name: Report to codecov
uses: codecov/codecov-action@v4
Expand Down
15 changes: 15 additions & 0 deletions ci/requirements/base.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
autoray
cmaes>=0.10
cotengrust
coverage
kahypar
matplotlib
networkx
nevergrad
opt_einsum
optuna
pytest
pytest-cov
ray
seaborn
tqdm
15 changes: 15 additions & 0 deletions ci/requirements/mac.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
autoray
cmaes>=0.10
cotengrust
coverage
# kahypar
matplotlib
networkx
nevergrad
opt_einsum
optuna
pytest
pytest-cov
ray
seaborn
tqdm
15 changes: 15 additions & 0 deletions ci/requirements/minimal.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
autoray
cmaes>=0.10
# cotengrust
coverage
kahypar
matplotlib
networkx
nevergrad
# opt_einsum
optuna
pytest
pytest-cov
# ray
seaborn
tqdm
21 changes: 0 additions & 21 deletions ci/requirements/py-base.yml

This file was deleted.

20 changes: 0 additions & 20 deletions ci/requirements/py-mac.yml

This file was deleted.

20 changes: 0 additions & 20 deletions ci/requirements/py-no-oe.yml

This file was deleted.

21 changes: 0 additions & 21 deletions ci/requirements/py-win.yml

This file was deleted.

15 changes: 15 additions & 0 deletions ci/requirements/win.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
autoray
cmaes>=0.10
cotengrust
coverage
# kahypar
matplotlib
networkx
nevergrad
opt_einsum
optuna
pytest
pytest-cov
# ray
seaborn
tqdm

0 comments on commit 4b8a047

Please sign in to comment.