1- # This file is autogenerated by maturin v1.7.0
1+ # This file is autogenerated by maturin v1.9.6
22# To update, run
33#
4- # maturin generate-ci github
4+ # maturin generate-ci github --output .github/workflows/CI.yml
55#
66name : CI
77
1111 - main
1212 - master
1313 tags :
14- - " * "
14+ - ' * '
1515 pull_request :
1616 workflow_dispatch :
1717
@@ -24,18 +24,20 @@ jobs:
2424 strategy :
2525 matrix :
2626 platform :
27- - runner : ubuntu-latest
27+ - runner : ubuntu-22.04
2828 target : x86_64
29- - runner : ubuntu-latest
29+ - runner : ubuntu-22.04
3030 target : x86
31- - runner : ubuntu-latest
31+ - runner : ubuntu-22.04
3232 target : aarch64
33- - runner : ubuntu-latest
33+ - runner : ubuntu-22.04
3434 target : armv7
35- - runner : ubuntu-latest
35+ - runner : ubuntu-22.04
3636 target : s390x
37- - runner : ubuntu-latest
37+ - runner : ubuntu-22.04
3838 target : ppc64le
39+ env :
40+ CFLAGS_s390x_unknown_linux_gnu : -march=z10
3941 steps :
4042 - uses : actions/checkout@v4
4143 - uses : actions/setup-python@v5
4547 uses : PyO3/maturin-action@v1
4648 with :
4749 target : ${{ matrix.platform.target }}
48- args : --release --out dist --find-interpreter
49- sccache : " true"
50+ args : --release --out dist
51+ sccache : ${{ !startsWith(github.ref, 'refs/tags/') }}
52+ manylinux : auto
53+ - name : Build free-threaded wheels
54+ uses : PyO3/maturin-action@v1
55+ with :
56+ target : ${{ matrix.platform.target }}
57+ args : --release --out dist -i python3.13t
58+ sccache : ${{ !startsWith(github.ref, 'refs/tags/') }}
5059 manylinux : auto
5160 - name : Upload wheels
5261 uses : actions/upload-artifact@v4
@@ -59,13 +68,13 @@ jobs:
5968 strategy :
6069 matrix :
6170 platform :
62- - runner : ubuntu-latest
71+ - runner : ubuntu-22.04
6372 target : x86_64
64- - runner : ubuntu-latest
73+ - runner : ubuntu-22.04
6574 target : x86
66- - runner : ubuntu-latest
75+ - runner : ubuntu-22.04
6776 target : aarch64
68- - runner : ubuntu-latest
77+ - runner : ubuntu-22.04
6978 target : armv7
7079 steps :
7180 - uses : actions/checkout@v4
7685 uses : PyO3/maturin-action@v1
7786 with :
7887 target : ${{ matrix.platform.target }}
79- args : --release --out dist --find-interpreter
80- sccache : " true"
88+ args : --release --out dist
89+ sccache : ${{ !startsWith(github.ref, 'refs/tags/') }}
90+ manylinux : musllinux_1_2
91+ - name : Build free-threaded wheels
92+ uses : PyO3/maturin-action@v1
93+ with :
94+ target : ${{ matrix.platform.target }}
95+ args : --release --out dist -i python3.13t
96+ sccache : ${{ !startsWith(github.ref, 'refs/tags/') }}
8197 manylinux : musllinux_1_2
8298 - name : Upload wheels
8399 uses : actions/upload-artifact@v4
@@ -104,8 +120,18 @@ jobs:
104120 uses : PyO3/maturin-action@v1
105121 with :
106122 target : ${{ matrix.platform.target }}
107- args : --release --out dist --find-interpreter
108- sccache : " true"
123+ args : --release --out dist
124+ sccache : ${{ !startsWith(github.ref, 'refs/tags/') }}
125+ - uses : actions/setup-python@v5
126+ with :
127+ python-version : 3.13t
128+ architecture : ${{ matrix.platform.target }}
129+ - name : Build free-threaded wheels
130+ uses : PyO3/maturin-action@v1
131+ with :
132+ target : ${{ matrix.platform.target }}
133+ args : --release --out dist -i python3.13t
134+ sccache : ${{ !startsWith(github.ref, 'refs/tags/') }}
109135 - name : Upload wheels
110136 uses : actions/upload-artifact@v4
111137 with :
@@ -117,9 +143,9 @@ jobs:
117143 strategy :
118144 matrix :
119145 platform :
120- - runner : macos-latest
146+ - runner : macos-13
121147 target : x86_64
122- - runner : macos-latest
148+ - runner : macos-14
123149 target : aarch64
124150 steps :
125151 - uses : actions/checkout@v4
@@ -130,8 +156,14 @@ jobs:
130156 uses : PyO3/maturin-action@v1
131157 with :
132158 target : ${{ matrix.platform.target }}
133- args : --release --out dist --find-interpreter
134- sccache : " true"
159+ args : --release --out dist
160+ sccache : ${{ !startsWith(github.ref, 'refs/tags/') }}
161+ - name : Build free-threaded wheels
162+ uses : PyO3/maturin-action@v1
163+ with :
164+ target : ${{ matrix.platform.target }}
165+ args : --release --out dist -i python3.13t
166+ sccache : ${{ !startsWith(github.ref, 'refs/tags/') }}
135167 - name : Upload wheels
136168 uses : actions/upload-artifact@v4
137169 with :
@@ -156,11 +188,23 @@ jobs:
156188 release :
157189 name : Release
158190 runs-on : ubuntu-latest
159- if : startsWith(github.ref, 'refs/tags/')
191+ if : ${{ startsWith(github.ref, 'refs/tags/') || github.event_name == 'workflow_dispatch' }}
160192 needs : [linux, musllinux, windows, macos, sdist]
193+ permissions :
194+ # Use to sign the release artifacts
195+ id-token : write
196+ # Used to upload release artifacts
197+ contents : write
198+ # Used to generate artifact attestation
199+ attestations : write
161200 steps :
162201 - uses : actions/download-artifact@v4
202+ - name : Generate artifact attestation
203+ uses : actions/attest-build-provenance@v2
204+ with :
205+ subject-path : ' wheels-*/*'
163206 - name : Publish to PyPI
207+ if : ${{ startsWith(github.ref, 'refs/tags/') }}
164208 uses : PyO3/maturin-action@v1
165209 env :
166210 MATURIN_PYPI_TOKEN : ${{ secrets.PYPI_API_TOKEN }}
0 commit comments