Skip to content

Commit 0edf7a6

Browse files
Fix CI by installing Python versions with UV instead of GitHub's setup-python action (#58)
* Fix CI by installing Python versions with UV instead of GitHub's setup-python action * use 3.13 for slap * update list of python versions
1 parent 5c8ad82 commit 0edf7a6

1 file changed

Lines changed: 60 additions & 24 deletions

File tree

.github/workflows/python.yml

Lines changed: 60 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -9,17 +9,14 @@ on:
99

1010
jobs:
1111
test:
12-
runs-on: ubuntu-20.04
12+
runs-on: ubuntu-latest
1313
strategy:
1414
fail-fast: false
1515
matrix:
16-
# Generated with scripts/github_actions_get_python_versions.py
1716
python-version: [
18-
# NOTE: We do not check 3.8.0 because Flake8 does not run on it.
19-
"3.8.1",
17+
#$ uv python list --all-versions | awk '{print $1}' | sed -E 's/cpython-(3\.[0-9]+\.[0-9]+)-.*/"\1",/' | grep -v py | sort --version-sort | uniq
2018
"3.8.2",
2119
"3.8.3",
22-
"3.8.4",
2320
"3.8.5",
2421
"3.8.6",
2522
"3.8.7",
@@ -34,6 +31,8 @@ jobs:
3431
"3.8.16",
3532
"3.8.17",
3633
"3.8.18",
34+
"3.8.19",
35+
"3.8.20",
3736
"3.9.0",
3837
"3.9.1",
3938
"3.9.2",
@@ -42,8 +41,6 @@ jobs:
4241
"3.9.5",
4342
"3.9.6",
4443
"3.9.7",
45-
"3.9.8",
46-
"3.9.9",
4744
"3.9.10",
4845
"3.9.11",
4946
"3.9.12",
@@ -53,8 +50,13 @@ jobs:
5350
"3.9.16",
5451
"3.9.17",
5552
"3.9.18",
53+
"3.9.19",
54+
"3.9.20",
55+
"3.9.21",
56+
"3.9.22",
57+
"3.9.23",
58+
"3.9.24",
5659
"3.10.0",
57-
"3.10.1",
5860
"3.10.2",
5961
"3.10.3",
6062
"3.10.4",
@@ -63,35 +65,71 @@ jobs:
6365
"3.10.7",
6466
"3.10.8",
6567
"3.10.9",
66-
"3.10.10",
6768
"3.10.11",
6869
"3.10.12",
6970
"3.10.13",
70-
"3.11.0",
71+
"3.10.14",
72+
"3.10.15",
73+
"3.10.16",
74+
"3.10.17",
75+
"3.10.18",
76+
"3.10.19",
7177
"3.11.1",
72-
"3.11.2",
7378
"3.11.3",
7479
"3.11.4",
7580
"3.11.5",
7681
"3.11.6",
7782
"3.11.7",
7883
"3.11.8",
84+
"3.11.9",
85+
"3.11.10",
86+
"3.11.11",
87+
"3.11.12",
88+
"3.11.13",
89+
"3.11.14",
7990
"3.12.0",
8091
"3.12.1",
8192
"3.12.2",
82-
"3.x",
83-
"pypy-3.8", # "pypy-3.9", "pypy-3.10"
93+
"3.12.3",
94+
"3.12.4",
95+
"3.12.5",
96+
"3.12.6",
97+
"3.12.7",
98+
"3.12.8",
99+
"3.12.9",
100+
"3.12.10",
101+
"3.12.11",
102+
"3.12.12",
103+
"3.13.0",
104+
"3.13.1",
105+
"3.13.2",
106+
"3.13.3",
107+
"3.13.4",
108+
"3.13.5",
109+
"3.13.6",
110+
"3.13.7",
111+
"3.13.8",
112+
"3.13.9",
113+
114+
# manual additions
115+
"pypy-3.8",
116+
117+
# NOTE(@niklas): Mypy fails with a syntax error on `# type: ignore` on the first line for `utils_test.py`
118+
# only on these PyPy versions.. huh?
119+
# "pypy-3.9",
120+
# "pypy-3.10",
121+
# "pypy-3.11",
84122
]
85123
steps:
86124
- uses: actions/checkout@v4
87-
- uses: NiklasRosenstein/slap@gha/install/v1
125+
88126
- name: Install uv
89-
uses: astral-sh/setup-uv@v5
127+
uses: astral-sh/setup-uv@v6
90128
with:
91-
version: "0.5.25"
92-
- uses: actions/setup-python@v5
93-
with: { python-version: "${{ matrix.python-version }}" }
94-
- run: slap test
129+
version: "0.9.5"
130+
python-version: "${{ matrix.python-version }}"
131+
132+
- run: uvx --python 3.13 --from slap-cli slap test
95133

96134
publish:
97135
runs-on: ubuntu-latest
@@ -104,14 +142,12 @@ jobs:
104142
steps:
105143
- uses: actions/checkout@v4
106144

107-
- name: Set up Python 3.13
108-
uses: actions/setup-python@v5
145+
- name: Install uv
146+
uses: astral-sh/setup-uv@v6
109147
with:
148+
version: "0.9.5"
110149
python-version: "3.13"
111150

112-
- name: Install uv
113-
run: python -m pip install uv
114-
115151
- name: Build dist
116152
run: uv build
117153

0 commit comments

Comments
 (0)