Skip to content

Commit 1b3362c

Browse files
committed
Use uv in Windows
1 parent 9bc7e38 commit 1b3362c

File tree

1 file changed

+12
-8
lines changed

1 file changed

+12
-8
lines changed

.github/workflows/windows-ci.yml

Lines changed: 12 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -30,22 +30,26 @@ jobs:
3030
python-version: ${{ matrix.python-version }}
3131

3232
- uses: actions/cache@v4
33+
env:
34+
UV_CACHE_DIR: ~\AppData\Local\uv\Cache
3335
with:
34-
path: ~\AppData\Local\pip\Cache
35-
key: ${{ runner.os }}-pip-${{ hashFiles('pyproject.toml') }}
36+
path: "${{ env.UV_CACHE_DIR }}"
37+
key: ${{ runner.os }}-uv-${{ hashFiles('pyproject.toml') }}
3638
restore-keys: |
37-
${{ runner.os }}-pip-
39+
${{ runner.os }}-uv-
3840
3941
- name: "Install dependencies"
42+
env:
43+
UV_CACHE_DIR: ~\AppData\Local\uv\Cache
4044
run: |
41-
python -m pip install --upgrade pip setuptools wheel
42-
# We use '--ignore-installed' to avoid GitHub's cache which can cause
43-
# issues - we have seen packages from this cache be cause trouble with
44-
# pip-extra-reqs.
45-
python -m pip install --ignore-installed --upgrade --editable .[dev]
45+
curl -LsSf https://astral.sh/uv/install.sh | sh
46+
uv venv ~\AppData\Local\.venv
47+
source ~\AppData\Local\.venv
48+
uv pip install --upgrade --editable ".[dev]"
4649
4750
- name: "Run tests"
4851
run: |
52+
source ~\AppData\Local\.venv
4953
# We run tests against "." and not the tests directory as we test the README
5054
# and documentation.
5155
pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests . --cov-report=xml

0 commit comments

Comments
 (0)