Skip to content

Commit bb2ee0c

Browse files
IvanIsCodingGohlub
authored andcommitted
Add Python 3.13 to CI and to release (Qiskit#1291)
* Add 3.13 support * Enable pillow for 3.13 tests * Fix stub tests * Bump cibuildwheel to build with candidate and not rc * Remove win32 builds * Add 3.13 to supported list * Re-introduce win32
1 parent 14655e2 commit bb2ee0c

File tree

6 files changed

+13
-13
lines changed

6 files changed

+13
-13
lines changed

.github/workflows/main.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ jobs:
5858
strategy:
5959
matrix:
6060
rust: [stable]
61-
python-version: [3.9, "3.10", "3.11", "3.12"]
61+
python-version: [3.9, "3.10", "3.11", "3.12", "3.13"]
6262
platform: [
6363
{ os: "macOS-13", python-architecture: "x64", rust-target: "x86_64-apple-darwin" },
6464
{ os: "macOS-14", python-architecture: "arm64", rust-target: "aarch64-apple-darwin" },
@@ -73,7 +73,7 @@ jobs:
7373
msrv: "MSRV"
7474
# Test future versions of Rust and Python
7575
- rust: beta
76-
python-version: "3.13-dev"
76+
python-version: "3.13" # upgrade to 3.14-dev when the release candidate is available
7777
platform: { os: "ubuntu-latest", python-architecture: "x64", rust-target: "x86_64-unknown-linux-gnu" }
7878
msrv: "Beta"
7979
# Exclude python 3.9 on arm64 until actions/setup-python#808 is resolved
@@ -107,7 +107,7 @@ jobs:
107107
runs-on: ubuntu-latest
108108
strategy:
109109
matrix:
110-
python-version: [3.9, "3.10", "3.11", "3.12"]
110+
python-version: [3.9, "3.10", "3.11", "3.12", "3.13"]
111111
steps:
112112
- uses: actions/checkout@v4
113113
- name: Set up Python ${{ matrix.python-version }}

.github/workflows/wheels.yml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ jobs:
5757
- uses: dtolnay/rust-toolchain@stable
5858
- name: Install cibuildwheel
5959
run: |
60-
python -m pip install cibuildwheel==2.17.0
60+
python -m pip install cibuildwheel==2.21.3
6161
- name: Build wheels
6262
run: |
6363
python -m cibuildwheel --output-dir wheelhouse
@@ -105,7 +105,7 @@ jobs:
105105
platforms: all
106106
- name: Install cibuildwheel
107107
run: |
108-
python -m pip install cibuildwheel==2.17.0
108+
python -m pip install cibuildwheel==2.21.3
109109
- name: Build wheels
110110
run: |
111111
python -m cibuildwheel --output-dir wheelhouse
@@ -143,7 +143,7 @@ jobs:
143143
platforms: all
144144
- name: Install cibuildwheel
145145
run: |
146-
python -m pip install cibuildwheel==2.17.0
146+
python -m pip install cibuildwheel==2.21.3
147147
- name: Build wheels
148148
run: |
149149
python -m cibuildwheel --output-dir wheelhouse
@@ -182,7 +182,7 @@ jobs:
182182
platforms: all
183183
- name: Install cibuildwheel
184184
run: |
185-
python -m pip install cibuildwheel==2.17.0
185+
python -m pip install cibuildwheel==2.21.3
186186
- name: Build wheels
187187
run: |
188188
python -m cibuildwheel --output-dir wheelhouse
@@ -220,7 +220,7 @@ jobs:
220220
platforms: all
221221
- name: Install cibuildwheel
222222
run: |
223-
python -m pip install cibuildwheel==2.17.0
223+
python -m pip install cibuildwheel==2.21.3
224224
- name: Build wheels
225225
run: |
226226
python -m cibuildwheel --output-dir wheelhouse
@@ -253,7 +253,7 @@ jobs:
253253
run: rustup default stable-i686-pc-windows-msvc
254254
- name: Install cibuildwheel
255255
run: |
256-
python -m pip install cibuildwheel==2.17.0
256+
python -m pip install cibuildwheel==2.21.3
257257
- name: Build wheels
258258
run: |
259259
python -m cibuildwheel --output-dir wheelhouse

constraints.txt

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,2 @@
1-
decorator==4.4.2
2-
pillow<10.0.0;python_version<'3.13'
1+
pillow>=10.1
32
lxml==5.1.1

noxfile.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424

2525
def install_rustworkx(session):
2626
session.install(*deps)
27-
session.install(".", "-c", "constraints.txt")
27+
session.install(".[all]", "-c", "constraints.txt")
2828

2929
# We define a common base such that -e test triggers a test with the current
3030
# Python version of the interpreter and -e test_with_version launches

rustworkx/visualization/graphviz.pyi

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ import typing
1010
from rustworkx.rustworkx import PyGraph, PyDiGraph
1111

1212
if typing.TYPE_CHECKING:
13-
from PIL import Image # type: ignore
13+
from PIL.Image import Image # type: ignore
1414

1515
_S = typing.TypeVar("_S")
1616
_T = typing.TypeVar("_T")

setup.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,7 @@ def readme():
7070
"Programming Language :: Python :: 3.10",
7171
"Programming Language :: Python :: 3.11",
7272
"Programming Language :: Python :: 3.12",
73+
"Programming Language :: Python :: 3.13",
7374
"Operating System :: MacOS :: MacOS X",
7475
"Operating System :: Microsoft :: Windows",
7576
"Operating System :: POSIX :: Linux",

0 commit comments

Comments
 (0)