|
12 | 12 | # cron every week on monday |
13 | 13 | - cron: "0 0 * * 1" |
14 | 14 |
|
| 15 | +env: |
| 16 | + UV_SYSTEM_PYTHON: 1 |
| 17 | + |
15 | 18 | jobs: |
16 | 19 | test: |
17 | 20 | strategy: |
@@ -41,18 +44,16 @@ jobs: |
41 | 44 | uses: actions/setup-python@v5 |
42 | 45 | with: |
43 | 46 | python-version: ${{ matrix.python-version }} |
44 | | - # Issue ref: https://github.com/actions/setup-python/issues/436 |
45 | | - # cache: "pip" |
46 | | - # cache-dependency-path: pyproject.toml |
47 | | - - uses: actions/cache@v4 |
48 | | - if: ${{ runner.os != 'macOS' }} |
49 | | - id: cache |
| 47 | + - name: Setup uv |
| 48 | + uses: astral-sh/setup-uv@v3 |
50 | 49 | with: |
51 | | - path: ${{ env.pythonLocation }} |
52 | | - key: ${{ runner.os }}-python-${{ env.pythonLocation }}-${{ hashFiles('pyproject.toml', 'requirements-tests.txt') }} |
| 50 | + version: "0.4.15" |
| 51 | + enable-cache: true |
| 52 | + cache-dependency-glob: | |
| 53 | + requirements**.txt |
| 54 | + pyproject.toml |
53 | 55 | - name: Install Dependencies |
54 | | - if: steps.cache.outputs.cache-hit != 'true' |
55 | | - run: pip install -r requirements-tests.txt |
| 56 | + run: uv pip install -r requirements-tests.txt |
56 | 57 | - name: Lint |
57 | 58 | run: bash scripts/lint.sh |
58 | 59 | - run: mkdir coverage |
@@ -81,16 +82,22 @@ jobs: |
81 | 82 | - uses: actions/setup-python@v5 |
82 | 83 | with: |
83 | 84 | python-version: '3.8' |
84 | | - # Issue ref: https://github.com/actions/setup-python/issues/436 |
85 | | - # cache: "pip" |
86 | | - # cache-dependency-path: pyproject.toml |
| 85 | + - name: Setup uv |
| 86 | + uses: astral-sh/setup-uv@v3 |
| 87 | + with: |
| 88 | + version: "0.4.15" |
| 89 | + enable-cache: true |
| 90 | + cache-dependency-glob: | |
| 91 | + requirements**.txt |
| 92 | + pyproject.toml |
87 | 93 | - name: Get coverage files |
88 | 94 | uses: actions/download-artifact@v4 |
89 | 95 | with: |
90 | 96 | pattern: coverage-* |
91 | 97 | path: coverage |
92 | 98 | merge-multiple: true |
93 | | - - run: pip install coverage[toml] |
| 99 | + - name: Install Dependencies |
| 100 | + run: uv pip install -r requirements-tests.txt |
94 | 101 | - run: ls -la coverage |
95 | 102 | - run: coverage combine coverage |
96 | 103 | - run: coverage report |
|
0 commit comments