Skip to content

Commit e9a5275

Browse files
committed
fix: Auto-detection of python version
1 parent 31e3127 commit e9a5275

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

.github/workflows/lintandformat.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ jobs:
1717
# Setup Python (faster than using Python container)
1818
- name: Setup Python
1919
uses: actions/setup-python@v5
20+
id: setup-python
2021
with:
2122
python-version: "3.11"
2223

@@ -25,8 +26,7 @@ jobs:
2526
uses: actions/cache@v4
2627
with:
2728
path: ~/.cache/uv
28-
# Replace 3.11 with ${{ matrix.python-version }} when ready
29-
key: ${{ runner.os }}-python-3.11-uv-${{ hashFiles('**/requirements.txt', '**/requirements-dev.txt') }}
29+
key: ${{ runner.os }}-python-${{ steps.setup-python.outputs.python-version }}-uv-${{ hashFiles('**/requirements.txt', '**/requirements-dev.txt') }}
3030

3131
- name: Install uv
3232
run: curl -LsSf https://astral.sh/uv/install.sh | sh

.github/workflows/test.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ jobs:
3838
# Setup Python (faster than using Python container)
3939
- name: Setup Python
4040
uses: actions/setup-python@v5
41+
id: setup-python
4142
with:
4243
python-version: "3.11"
4344

@@ -47,7 +48,7 @@ jobs:
4748
with:
4849
path: ~/.cache/uv
4950
# Replace 3.11 with ${{ matrix.python-version }} when ready
50-
key: ${{ runner.os }}-python-3.11-uv-${{ hashFiles('**/requirements.txt', '**/requirements-dev.txt') }}
51+
key: ${{ runner.os }}-python-${{ steps.setup-python.outputs.python-version }}-uv-${{ hashFiles('**/requirements.txt', '**/requirements-dev.txt') }}
5152

5253
- name: Install uv
5354
run: curl -LsSf https://astral.sh/uv/install.sh | sh

0 commit comments

Comments
 (0)