9
9
pull_request :
10
10
branches :
11
11
- " *"
12
+ release :
13
+ types :
14
+ - published
12
15
schedule :
13
16
# Daily at 05:47
14
17
- cron : ' 47 5 * * *'
21
24
PIP_NO_PYTHON_VERSION_WARNING : 1
22
25
23
26
jobs :
27
+ build :
28
+ name : Build
29
+ runs-on : ubuntu-latest
30
+ container : docker://python:3.11-buster
31
+ steps :
32
+ - uses : actions/checkout@v4
33
+ - name : Build
34
+ run : |
35
+ python -m venv venv
36
+ venv/bin/pip install --upgrade pip
37
+ venv/bin/pip install build
38
+ venv/bin/python -m build --outdir dist/
39
+ - uses : actions/upload-artifact@v4
40
+ if : always()
41
+ with :
42
+ name : dist
43
+ path : dist/*
44
+ if-no-files-found : error
45
+
24
46
test :
25
47
name : ${{ matrix.os.name }} ${{ matrix.python.name }} ${{ matrix.reactor.name }}
48
+ needs : build
26
49
runs-on : ${{ matrix.os.runs-on }}
27
50
container : ${{ matrix.os.container[matrix.python.docker] }}
28
51
strategy :
@@ -35,16 +58,18 @@ jobs:
35
58
container :
36
59
" 2.7 " : docker://python:2.7-buster
37
60
" 3.5 " : docker://python:3.5-buster
38
- " 3.6 " : docker://python:3.6-buster
39
- " 3.7 " : docker://python:3.7-buster
40
- " 3.8 " : docker://python:3.8-buster
41
- " 3.9 " : docker://python:3.9-buster
42
- " 3.10 " : docker://python:3.10-buster
43
- " 3.11 " : docker://python:3.11-buster
44
- " pypy2.7 " : docker://pypy:2.7-buster
45
- " pypy3.7 " : docker://pypy:3.7-buster
46
- " pypy3.8 " : docker://pypy:3.8-buster
47
- " pypy3.9 " : docker://pypy:3.9-buster
61
+ " 3.6 " : docker://python:3.6-bullseye
62
+ " 3.7 " : docker://python:3.7-bookworm
63
+ " 3.8 " : docker://python:3.8-bookworm
64
+ " 3.9 " : docker://python:3.9-bookworm
65
+ " 3.10 " : docker://python:3.10-bookworm
66
+ " 3.11 " : docker://python:3.11-bookworm
67
+ " 3.12 " : docker://python:3.12-bookworm
68
+ " pypy2.7 " : docker://pypy:2.7-bookworm
69
+ " pypy3.7 " : docker://pypy:3.7-bullseye
70
+ " pypy3.8 " : docker://pypy:3.8-bookworm
71
+ " pypy3.9 " : docker://pypy:3.9-bookworm
72
+ " pypy3.10 " : docker://pypy:3.10-bookworm
48
73
- name : 🪟
49
74
runs-on : windows-latest
50
75
python_platform : win32
@@ -100,6 +125,12 @@ jobs:
100
125
docker : " 3.11"
101
126
implementation : cpython
102
127
major : 3
128
+ - name : CPython 3.12
129
+ tox : py312
130
+ action : " 3.12"
131
+ docker : " 3.12"
132
+ implementation : cpython
133
+ major : 3
103
134
# disabled due to installation failures
104
135
# https://github.com/pytest-dev/pytest-twisted/pull/157
105
136
# - name: PyPy 2.7
@@ -126,6 +157,12 @@ jobs:
126
157
docker : pypy3.9
127
158
implementation : pypy
128
159
major : 3
160
+ - name : PyPy 3.10
161
+ tox : pypy310
162
+ action : pypy-3.10
163
+ docker : pypy3.10
164
+ implementation : pypy
165
+ major : 3
129
166
reactor :
130
167
- name : default
131
168
tox : default
@@ -160,6 +197,10 @@ jobs:
160
197
action : " 3.11"
161
198
reactor :
162
199
tox : pyside2
200
+ - python :
201
+ action : " 3.12"
202
+ reactor :
203
+ tox : pyside2
163
204
- python :
164
205
major : 2
165
206
reactor :
@@ -173,13 +214,13 @@ jobs:
173
214
reactor :
174
215
tox : pyside2
175
216
steps :
176
- - uses : actions/checkout@v2
217
+ - uses : actions/checkout@v4
177
218
- name : Enable Problem Matchers
178
219
run : |
179
220
echo "::add-matcher::.github/local-problem-matchers.json"
180
221
- name : Set up ${{ matrix.python.name }}
181
222
if : ${{ job.container == '' }}
182
- uses : actions/setup-python@v2
223
+ uses : actions/setup-python@v5
183
224
with :
184
225
# This allows the matrix to specify just the major.minor version while still
185
226
# expanding it to get the latest patch version including alpha releases.
@@ -215,21 +256,27 @@ jobs:
215
256
- name : Install
216
257
run : |
217
258
pip install tox
259
+ - uses : actions/download-artifact@v4
260
+ with :
261
+ name : dist
262
+ path : dist/
218
263
- name : Test
264
+ shell : bash
219
265
run : |
220
- tox -v -e "${{ matrix.python.tox }}-${{ matrix.reactor.tox }}reactor"
266
+ tox --installpkg dist/*.whl -v -e "${{ matrix.python.tox }}-${{ matrix.reactor.tox }}reactor"
267
+
221
268
linting :
222
269
name : Linting
223
270
runs-on : ubuntu-latest
224
271
strategy :
225
272
matrix :
226
273
python :
227
- - short : 39
228
- dotted : 3.9
274
+ - short : 311
275
+ dotted : " 3.11 "
229
276
steps :
230
- - uses : actions/checkout@v2
277
+ - uses : actions/checkout@v4
231
278
- name : Set up Python ${{ matrix.python.dotted }}
232
- uses : actions/setup-python@v2
279
+ uses : actions/setup-python@v5
233
280
with :
234
281
python-version : ${{ matrix.python.dotted }}
235
282
architecture : x64
@@ -239,12 +286,33 @@ jobs:
239
286
- name : Test
240
287
run : |
241
288
tox -v -e linting
289
+
290
+ publish :
291
+ name : Publish
292
+ runs-on : ubuntu-latest
293
+ needs :
294
+ - build
295
+ - test
296
+ - linting
297
+ steps :
298
+ - uses : actions/download-artifact@v4
299
+ with :
300
+ name : dist
301
+ path : dist/
302
+ - uses : pypa/gh-action-pypi-publish@release/v1
303
+ if : github.event_name == 'release'
304
+ with :
305
+ packages-dir : dist/
306
+ skip-existing : true
307
+
242
308
all :
243
309
name : All
244
310
runs-on : ubuntu-latest
245
311
needs :
312
+ - build
246
313
- test
247
314
- linting
315
+ - publish
248
316
steps :
249
317
- name : This
250
318
shell : python
0 commit comments