@@ -88,14 +88,31 @@ jobs:
88
88
pyqt6-ver : ' !=6.6.0'
89
89
# https://bugreports.qt.io/projects/PYSIDE/issues/PYSIDE-2346
90
90
pyside6-ver : ' !=6.5.1'
91
- - os : macos-12 # This runnre is on Intel chips.
92
- python-version : 3.9
91
+ - os : ubuntu-22.04
92
+ python-version : ' 3.13'
93
+ # https://www.riverbankcomputing.com/pipermail/pyqt/2023-November/045606.html
94
+ pyqt6-ver : ' !=6.6.0'
95
+ # https://bugreports.qt.io/projects/PYSIDE/issues/PYSIDE-2346
96
+ pyside6-ver : ' !=6.5.1'
97
+ - name-suffix : " Free-threaded"
98
+ os : ubuntu-22.04
99
+ python-version : ' 3.13t'
100
+ # https://www.riverbankcomputing.com/pipermail/pyqt/2023-November/045606.html
101
+ pyqt6-ver : ' !=6.6.0'
102
+ # https://bugreports.qt.io/projects/PYSIDE/issues/PYSIDE-2346
103
+ pyside6-ver : ' !=6.5.1'
104
+ - os : macos-12 # This runner is on Intel chips.
105
+ python-version : ' 3.9'
93
106
# https://bugreports.qt.io/projects/PYSIDE/issues/PYSIDE-2346
94
107
pyside6-ver : ' !=6.5.1'
95
108
- os : macos-14 # This runner is on M1 (arm64) chips.
96
109
python-version : ' 3.12'
97
110
# https://bugreports.qt.io/projects/PYSIDE/issues/PYSIDE-2346
98
111
pyside6-ver : ' !=6.5.1'
112
+ - os : macos-14 # This runner is on M1 (arm64) chips.
113
+ python-version : ' 3.13'
114
+ # https://bugreports.qt.io/projects/PYSIDE/issues/PYSIDE-2346
115
+ pyside6-ver : ' !=6.5.1'
99
116
100
117
steps :
101
118
- uses : actions/checkout@v4
@@ -104,8 +121,17 @@ jobs:
104
121
105
122
- name : Set up Python ${{ matrix.python-version }}
106
123
uses : actions/setup-python@v5
124
+ if : matrix.python-version != '3.13t'
107
125
with :
108
126
python-version : ${{ matrix.python-version }}
127
+ allow-prereleases : true
128
+
129
+ - name : Set up Python ${{ matrix.python-version }}
130
+ uses : deadsnakes/action@6c8b9b82fe0b4344f4b98f2775fcc395df45e494 # v3.1.0
131
+ if : matrix.python-version == '3.13t'
132
+ with :
133
+ python-version : ' 3.13'
134
+ nogil : true
109
135
110
136
- name : Install OS dependencies
111
137
run : |
@@ -152,6 +178,11 @@ jobs:
152
178
texlive-luatex \
153
179
texlive-pictures \
154
180
texlive-xetex
181
+ if [[ "${{ matrix.python-version }}" = '3.13t' ]]; then
182
+ # TODO: Remove this once setup-python supports nogil distributions.
183
+ sudo apt-get install -yy --no-install-recommends \
184
+ python3.13-tk-nogil
185
+ fi
155
186
if [[ "${{ matrix.os }}" = ubuntu-20.04 ]]; then
156
187
sudo apt-get install -yy --no-install-recommends libopengl0
157
188
else # ubuntu-22.04
@@ -202,6 +233,15 @@ jobs:
202
233
4-${{ runner.os }}-py${{ matrix.python-version }}-mpl-${{ github.ref }}-
203
234
4-${{ runner.os }}-py${{ matrix.python-version }}-mpl-
204
235
236
+ - name : Install the nightly dependencies
237
+ if : matrix.python-version == '3.13t'
238
+ run : |
239
+ python -m pip install pytz tzdata python-dateutil # Must be installed for Pandas.
240
+ python -m pip install \
241
+ --pre \
242
+ --index-url https://pypi.anaconda.org/scientific-python-nightly-wheels/simple \
243
+ --upgrade --only-binary=:all: numpy pandas pillow contourpy
244
+
205
245
- name : Install Python dependencies
206
246
run : |
207
247
# Upgrade pip and setuptools and wheel to get as clean an install as
@@ -227,6 +267,7 @@ jobs:
227
267
# Sphinx is needed to run sphinxext tests
228
268
python -m pip install --upgrade sphinx!=6.1.2
229
269
270
+ if [[ "${{ matrix.python-version }}" != '3.13t' ]]; then
230
271
# GUI toolkits are pip-installable only for some versions of Python
231
272
# so don't fail if we can't install them. Make it easier to check
232
273
# whether the install was successful by trying to import the toolkit
@@ -246,11 +287,11 @@ jobs:
246
287
python -c 'import PyQt5.QtCore' &&
247
288
echo 'PyQt5 is available' ||
248
289
echo 'PyQt5 is not available'
249
- # Even though PySide2 wheels can be installed on Python 3.12, they are broken and since PySide2 is
290
+ # Even though PySide2 wheels can be installed on Python 3.12+ , they are broken and since PySide2 is
250
291
# deprecated, they are unlikely to be fixed. For the same deprecation reason, there are no wheels
251
292
# on M1 macOS, so don't bother there either.
252
293
if [[ "${{ matrix.os }}" != 'macos-14'
253
- && "${{ matrix.python-version }}" != '3.12' ]]; then
294
+ && "${{ matrix.python-version }}" != '3.12' && "${{ matrix.python-version }}" != '3.13' ]]; then
254
295
python -mpip install --upgrade pyside2${{ matrix.pyside2-ver }} &&
255
296
python -c 'import PySide2.QtCore' &&
256
297
echo 'PySide2 is available' ||
@@ -272,6 +313,8 @@ jobs:
272
313
echo 'wxPython is available' ||
273
314
echo 'wxPython is not available'
274
315
316
+ fi # Skip backends on Python 3.13t.
317
+
275
318
- name : Install the nightly dependencies
276
319
# Only install the nightly dependencies during the scheduled event
277
320
if : github.event_name == 'schedule' && matrix.name-suffix != '(Minimum Versions)'
@@ -310,6 +353,9 @@ jobs:
310
353
311
354
- name : Run pytest
312
355
run : |
356
+ if [[ "${{ matrix.python-version }}" == '3.13t' ]]; then
357
+ export PYTHON_GIL=0
358
+ fi
313
359
pytest -rfEsXR -n auto \
314
360
--maxfail=50 --timeout=300 --durations=25 \
315
361
--cov-report=xml --cov=lib --log-level=DEBUG --color=yes
0 commit comments