@@ -24,14 +24,16 @@ permissions:
2424jobs :
2525 build_sdist :
2626 if : >-
27- github.event_name == 'push' ||
28- github.event_name == 'pull_request' && (
29- (
30- github.event.action == 'labeled' &&
31- github.event.label.name == 'CI: Run cibuildwheel'
32- ) ||
33- contains(github.event.pull_request.labels.*.name,
34- 'CI: Run cibuildwheel')
27+ github.repository == 'matplotlib/matplotlib' && (
28+ github.event_name == 'push' ||
29+ github.event_name == 'pull_request' && (
30+ (
31+ github.event.action == 'labeled' &&
32+ github.event.label.name == 'CI: Run cibuildwheel'
33+ ) ||
34+ contains(github.event.pull_request.labels.*.name,
35+ 'CI: Run cibuildwheel')
36+ )
3537 )
3638 name : Build sdist
3739 runs-on : ubuntu-latest
@@ -44,10 +46,10 @@ jobs:
4446 fetch-depth : 0
4547 persist-credentials : false
4648
47- - uses : actions/setup-python@42375524e23c412d93fb67b49958b491fce71c38 # v5.4 .0
49+ - uses : actions/setup-python@a26af69be951a213d495a4c3e4e4022e16d87065 # v5.6 .0
4850 name : Install Python
4951 with :
50- python-version : ' 3.10 '
52+ python-version : ' 3.11 '
5153
5254 # Something changed somewhere that prevents the downloaded-at-build-time
5355 # licenses from being included in built wheels, so pre-download them so
@@ -70,22 +72,24 @@ jobs:
7072 run : twine check dist/*
7173
7274 - name : Upload sdist result
73- uses : actions/upload-artifact@65c4c4a1ddee5b72f698fdd19549f0f0fb45cf08 # v4.6.0
75+ uses : actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
7476 with :
7577 name : cibw-sdist
7678 path : dist/*.tar.gz
7779 if-no-files-found : error
7880
7981 build_wheels :
8082 if : >-
81- github.event_name == 'push' ||
82- github.event_name == 'pull_request' && (
83- (
84- github.event.action == 'labeled' &&
85- github.event.label.name == 'CI: Run cibuildwheel'
86- ) ||
87- contains(github.event.pull_request.labels.*.name,
88- 'CI: Run cibuildwheel')
83+ github.repository == 'matplotlib/matplotlib' && (
84+ github.event_name == 'push' ||
85+ github.event_name == 'pull_request' && (
86+ (
87+ github.event.action == 'labeled' &&
88+ github.event.label.name == 'CI: Run cibuildwheel'
89+ ) ||
90+ contains(github.event.pull_request.labels.*.name,
91+ 'CI: Run cibuildwheel')
92+ )
8993 )
9094 needs : build_sdist
9195 name : Build wheels on ${{ matrix.os }} for ${{ matrix.cibw_archs }}
@@ -131,13 +135,13 @@ jobs:
131135
132136 steps :
133137 - name : Download sdist
134- uses : actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 # v4.1.8
138+ uses : actions/download-artifact@d3f86a106a0bac45b974a628896c90dbdf5c8093 # v4.3.0
135139 with :
136140 name : cibw-sdist
137141 path : dist/
138142
139143 - name : Build wheels for CPython 3.13
140- uses : pypa/cibuildwheel@ee63bf16da6cddfb925f542f2c7b59ad50e93969 # v2.22.0
144+ uses : pypa/cibuildwheel@faf86a6ed7efa889faf6996aa23820831055001a # v2.23.3
141145 with :
142146 package-dir : dist/${{ needs.build_sdist.outputs.SDIST_NAME }}
143147 env :
@@ -148,47 +152,42 @@ jobs:
148152 CIBW_ARCHS : ${{ matrix.cibw_archs }}
149153
150154 - name : Build wheels for CPython 3.12
151- uses : pypa/cibuildwheel@ee63bf16da6cddfb925f542f2c7b59ad50e93969 # v2.22.0
155+ uses : pypa/cibuildwheel@faf86a6ed7efa889faf6996aa23820831055001a # v2.23.3
152156 with :
153157 package-dir : dist/${{ needs.build_sdist.outputs.SDIST_NAME }}
154158 env :
155159 CIBW_BUILD : " cp312-*"
156160 CIBW_ARCHS : ${{ matrix.cibw_archs }}
157161
158162 - name : Build wheels for CPython 3.11
159- uses : pypa/cibuildwheel@ee63bf16da6cddfb925f542f2c7b59ad50e93969 # v2.22.0
163+ uses : pypa/cibuildwheel@faf86a6ed7efa889faf6996aa23820831055001a # v2.23.3
160164 with :
161165 package-dir : dist/${{ needs.build_sdist.outputs.SDIST_NAME }}
162166 env :
163167 CIBW_BUILD : " cp311-*"
164168 CIBW_ARCHS : ${{ matrix.cibw_archs }}
165169
166- - name : Build wheels for CPython 3.10
167- uses : pypa/cibuildwheel@ee63bf16da6cddfb925f542f2c7b59ad50e93969 # v2.22.0
168- with :
169- package-dir : dist/${{ needs.build_sdist.outputs.SDIST_NAME }}
170- env :
171- CIBW_BUILD : " cp310-*"
172- CIBW_ARCHS : ${{ matrix.cibw_archs }}
173170
174171 - name : Build wheels for PyPy
175- uses : pypa/cibuildwheel@ee63bf16da6cddfb925f542f2c7b59ad50e93969 # v2.22.0
172+ uses : pypa/cibuildwheel@faf86a6ed7efa889faf6996aa23820831055001a # v2.23.3
176173 with :
177174 package-dir : dist/${{ needs.build_sdist.outputs.SDIST_NAME }}
178175 env :
179- CIBW_BUILD : " pp310 -*"
176+ CIBW_BUILD : " pp311 -*"
180177 CIBW_ARCHS : ${{ matrix.cibw_archs }}
181178 CIBW_ENABLE : pypy
179+ # No wheels available for Pillow with pp311 yet.
180+ CIBW_TEST_SKIP : " pp311*"
182181 if : matrix.cibw_archs != 'aarch64' && matrix.os != 'windows-latest'
183182
184- - uses : actions/upload-artifact@65c4c4a1ddee5b72f698fdd19549f0f0fb45cf08 # v4.6.0
183+ - uses : actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
185184 with :
186185 name : cibw-wheels-${{ runner.os }}-${{ matrix.cibw_archs }}
187186 path : ./wheelhouse/*.whl
188187 if-no-files-found : error
189188
190189 publish :
191- if : github.event_name == 'push' && github.ref_type == 'tag'
190+ if : github.repository == 'matplotlib/matplotlib' && github. event_name == 'push' && github.ref_type == 'tag'
192191 name : Upload release to PyPI
193192 needs : [build_sdist, build_wheels]
194193 runs-on : ubuntu-latest
@@ -199,7 +198,7 @@ jobs:
199198 contents : read
200199 steps :
201200 - name : Download packages
202- uses : actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 # v4.1.8
201+ uses : actions/download-artifact@d3f86a106a0bac45b974a628896c90dbdf5c8093 # v4.3.0
203202 with :
204203 pattern : cibw-*
205204 path : dist
@@ -209,7 +208,7 @@ jobs:
209208 run : ls dist
210209
211210 - name : Generate artifact attestation for sdist and wheel
212- uses : actions/attest-build-provenance@520d128f165991a6c774bcb264f323e3d70747f4 # v2.2 .0
211+ uses : actions/attest-build-provenance@db473fddc028af60658334401dc6fa3ffd8669fd # v2.3 .0
213212 with :
214213 subject-path : dist/matplotlib-*
215214
0 commit comments