Skip to content

Commit aee0678

Browse files
committed
Drop Python 3.9 support after EoL
Update classifiers, python_requires, CI workflows, tox envs, and release notes to require Python 3.10+
1 parent c34c73a commit aee0678

File tree

5 files changed

+27
-30
lines changed

5 files changed

+27
-30
lines changed

.github/workflows/deploy-code.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ jobs:
2525
id-token: write
2626
strategy:
2727
matrix:
28-
python-version: [3.9]
28+
python-version: [3.10]
2929
steps:
3030
- uses: actions/checkout@v6
3131
- uses: actions/setup-python@v6

.github/workflows/main.yml

Lines changed: 18 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ jobs:
3535
strategy:
3636
matrix:
3737
os: [ubuntu-latest]
38-
python-version: [3.9]
38+
python-version: [3.10]
3939
steps:
4040
- name: Print Concurrency Group
4141
env:
@@ -112,15 +112,15 @@ jobs:
112112
fail-fast: false
113113
matrix:
114114
os: [ubuntu-latest]
115-
python-version: [3.9, '3.10', 3.11, 3.12, 3.13]
115+
python-version: [3.10, 3.11, 3.12, 3.13]
116116
include:
117117
# macos-latest is an Arm64 image
118118
- os: macos-latest
119-
python-version: 3.9
119+
python-version: 3.10
120120
- os: macos-latest
121121
python-version: 3.13
122122
- os: windows-latest
123-
python-version: 3.9
123+
python-version: 3.10
124124
- os: windows-latest
125125
python-version: 3.13
126126
steps:
@@ -161,7 +161,7 @@ jobs:
161161
run: |
162162
coverage3 combine
163163
mv .coverage ./ci-artifact-data/ml.dat
164-
if: ${{ matrix.os == 'ubuntu-latest' && matrix.python-version == 3.9 }}
164+
if: ${{ matrix.os == 'ubuntu-latest' && matrix.python-version == 3.10 }}
165165
shell: bash
166166
- uses: actions/upload-artifact@v5
167167
with:
@@ -184,7 +184,7 @@ jobs:
184184
fail-fast: false
185185
matrix:
186186
os: [ubuntu-latest]
187-
python-version: [3.9, 3.13]
187+
python-version: [3.10, 3.13]
188188
steps:
189189
- uses: actions/checkout@v6
190190
with:
@@ -247,30 +247,26 @@ jobs:
247247
cd docs/_build/html
248248
mkdir artifacts
249249
tar -zcvf artifacts/tutorials.tar.gz --exclude=./artifacts .
250-
if: ${{ matrix.python-version == 3.9 && !startsWith(github.ref, 'refs/heads/stable') && !startsWith(github.base_ref, 'stable/') }}
250+
if: ${{ matrix.python-version == 3.10 && !startsWith(github.ref, 'refs/heads/stable') && !startsWith(github.base_ref, 'stable/') }}
251251
shell: bash
252252
- name: Run upload stable tutorials
253253
uses: actions/upload-artifact@v5
254254
with:
255255
name: tutorials-stable${{ matrix.python-version }}
256256
path: docs/_build/html/artifacts/tutorials.tar.gz
257-
if: ${{ matrix.python-version == 3.9 && !startsWith(github.ref, 'refs/heads/stable') && !startsWith(github.base_ref, 'stable/') }}
257+
if: ${{ matrix.python-version == 3.10 && !startsWith(github.ref, 'refs/heads/stable') && !startsWith(github.base_ref, 'stable/') }}
258258
Deprecation_Messages_and_Coverage:
259259
needs: [Checks, MachineLearning, Tutorials]
260260
runs-on: ubuntu-latest
261261
strategy:
262262
matrix:
263-
python-version: [3.9]
263+
python-version: [3.10]
264264
steps:
265265
- uses: actions/checkout@v6
266266
- uses: actions/setup-python@v6
267267
with:
268268
python-version: ${{ matrix.python-version }}
269-
- uses: actions/download-artifact@v6
270-
with:
271-
name: ubuntu-latest-3.9
272-
path: /tmp/u39
273-
- uses: actions/download-artifact@v6
269+
- uses: actions/download-artifact@v6
274270
with:
275271
name: ubuntu-latest-3.10
276272
path: /tmp/u310
@@ -288,32 +284,28 @@ jobs:
288284
path: /tmp/u313
289285
- uses: actions/download-artifact@v6
290286
with:
291-
name: macos-latest-3.9
292-
path: /tmp/m39
287+
name: macos-latest-3.10
288+
path: /tmp/m310
293289
- uses: actions/download-artifact@v6
294290
with:
295291
name: macos-latest-3.13
296292
path: /tmp/m313
297293
- uses: actions/download-artifact@v6
298294
with:
299-
name: windows-latest-3.9
300-
path: /tmp/w39
295+
name: windows-latest-3.10
296+
path: /tmp/w310
301297
- uses: actions/download-artifact@v6
302298
with:
303299
name: windows-latest-3.13
304300
path: /tmp/w313
301+
305302
- name: Install Dependencies
306303
run: pip install -U coverage coveralls diff-cover
307304
shell: bash
308305
- name: Combined Deprecation Messages
309306
run: |
310-
sort -f -u /tmp/u39/ml.dep /tmp/u310/ml.dep /tmp/u311/ml.dep /tmp/u312/ml.dep /tmp/u313/ml.dep /tmp/m39/ml.dep /tmp/m313/ml.dep /tmp/w39/ml.dep /tmp/w313/ml.dep || true
307+
sort -f -u /tmp/u310/ml.dep /tmp/u311/ml.dep /tmp/u312/ml.dep /tmp/u313/ml.dep /tmp/m310/ml.dep /tmp/m313/ml.dep /tmp/w310/ml.dep /tmp/w313/ml.dep || true
311308
shell: bash
312309
- name: Coverage combine
313-
run: coverage3 combine /tmp/u39/ml.dat
314-
shell: bash
315-
- name: Upload to Coveralls
316-
env:
317-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
318-
run: coveralls --service=github
319-
shell: bash
310+
run: coverage3 combine /tmp/u310/ml.dat
311+
shell: bash
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
---
2+
upgrade:
3+
- |
4+
Qiskit Machine Learning no longer supports Python 3.9, following its
5+
EoL in October 2025. The minimum required Python
6+
version is now 3.10.

setup.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,6 @@
6161
"Operating System :: MacOS",
6262
"Operating System :: POSIX :: Linux",
6363
"Programming Language :: Python :: 3 :: Only",
64-
"Programming Language :: Python :: 3.9",
6564
"Programming Language :: Python :: 3.10",
6665
"Programming Language :: Python :: 3.11",
6766
"Programming Language :: Python :: 3.12",
@@ -74,7 +73,7 @@
7473
),
7574
install_requires=REQUIREMENTS,
7675
include_package_data=True,
77-
python_requires=">=3.9",
76+
python_requires=">=3.10",
7877
extras_require={
7978
"torch": ["torch"],
8079
"sparse": ["sparse"],

tox.ini

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
[tox]
22
# Sets this min.version because of differences with env_tmp_dir env.
33
minversion = 4.0.2
4-
envlist = py39, py310, py311, py312, py313, lint, gpu, gpu-amd
4+
envlist = py310, py311, py312, py313, lint, gpu, gpu-amd
55
skipsdist = True
66

77
[testenv]

0 commit comments

Comments
 (0)