Skip to content

Commit 7786368

Browse files
authored
Dev (#31)
* convert readme directions into checklist * add instructions for installing packages via conda for nox test * use mamba for creating environment in ci workflow * add api rst file
1 parent 6b30e1a commit 7786368

4 files changed

Lines changed: 154 additions & 112 deletions

File tree

.github/workflows/ci.yml

Lines changed: 22 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,10 @@ env:
1717
# for libraries that care about the value set.
1818
FORCE_COLOR: 3
1919

20+
defaults:
21+
run:
22+
shell: bash -el {0}
23+
2024
jobs:
2125
lint:
2226
name: Pylint
@@ -47,29 +51,35 @@ jobs:
4751
python-version: ["3.11", "3.12", "3.13"]
4852
runs-on: [ubuntu-latest, windows-latest, macos-14]
4953

50-
include:
51-
- python-version: "pypy-3.11"
52-
runs-on: ubuntu-latest
53-
5454
steps:
5555
- uses: actions/checkout@v5
5656
with:
5757
fetch-depth: 0
5858

59-
- uses: actions/setup-python@v5
60-
with:
61-
python-version: ${{ matrix.python-version }}
62-
allow-prereleases: true
59+
- name: Switch to Current Branch
60+
run: git checkout ${{ env.BRANCH }}
6361

64-
- uses: astral-sh/setup-uv@v6
62+
- name: Get current week number of year
63+
id: date
64+
run: echo "date=$(date +%Y-W%W)" >> $GITHUB_OUTPUT # e.g., 2024-W19
65+
66+
# Install Micromamba with conda-forge dependencies
67+
- name: Setup Micromamba
68+
uses: mamba-org/setup-micromamba@v2
69+
with:
70+
environment-file: environment.yml
71+
post-cleanup: "all"
72+
cache-downloads: false
73+
# environment cache is persistent for one week.
74+
cache-environment-key:
75+
micromamba-environment-${{ steps.date.outputs.date }}
6576

6677
- name: Install package
67-
run: uv sync
78+
run: pip install --no-deps -e .
6879

6980
- name: Run the tests
7081
run: >-
71-
uv run pytest -ra --cov --cov-report=xml --cov-report=term
72-
--durations=20
82+
pytest -ra --cov --cov-report=xml --cov-report=term --durations=20
7383
7484
- name: Upload coverage report
7585
uses: codecov/codecov-action@v5

0 commit comments

Comments
 (0)