4343if :fromJSON(needs.build-context.outputs.run-docs)
4444uses :./.github/workflows/reusable-docs.yml
4545
46- check_autoconf_regen :
46+ check-autoconf-regen :
4747name :' Check if Autoconf files are up to date'
4848# Don't use ubuntu-latest but a specific version to make the job
4949# reproducible: to get the same tools versions (autoconf, aclocal, ...)
6262with :
6363fetch-depth :1
6464persist-credentials :false
65- -name :Runner image version
66- run :echo "IMAGE_VERSION=${ImageVersion}" >> "$GITHUB_ENV"
6765 -name :Check Autoconf and aclocal versions
6866run :|
6967 grep "Generated by GNU Autoconf 2.72" configure
8886 exit 1
8987 fi
9088
91- check_generated_files :
89+ check-generated-files :
9290name :' Check if generated files are up to date'
9391# Don't use ubuntu-latest but a specific version to make the job
9492# reproducible: to get the same tools versions (autoconf, aclocal, ...)
@@ -104,14 +102,14 @@ jobs:
104102with :
105103python-version :' 3.x'
106104 -name :Runner image version
107- run :echo "IMAGE_VERSION= ${ImageVersion}" >> "$GITHUB_ENV"
105+ run :echo "IMAGE_OS_VERSION=${ImageOS}- ${ImageVersion}" >> "$GITHUB_ENV"
108106 -name :Restore config.cache
109107uses :actions/cache@v4
110108with :
111109path :config.cache
112110# Include env.pythonLocation in key to avoid changes in environment when setup-python updates Python
113- key :${{ github.job }}-${{runner.os }}-${{ env.IMAGE_VERSION }}-${{ needs.build-context.outputs.config-hash }}-${{ env.pythonLocation }}
114- -name :InstallDependencies
111+ key :${{ github.job }}-${{ env.IMAGE_OS_VERSION }}-${{ needs.build-context.outputs.config-hash }}-${{ env.pythonLocation }}
112+ -name :Installdependencies
115113run :sudo ./.github/workflows/posix-deps-apt.sh
116114 -name :Add ccache to PATH
117115run :echo "PATH=/usr/lib/ccache:$PATH" >> "$GITHUB_ENV"
@@ -149,7 +147,7 @@ jobs:
149147if :github.event_name == 'pull_request' # $GITHUB_EVENT_NAME
150148run :make check-c-globals
151149
152- build_windows :
150+ build-windows :
153151name :>-
154152 Windows
155153 ${{ fromJSON(matrix.free-threading) && '(free-threading)' || '' }}
@@ -181,12 +179,13 @@ jobs:
181179arch :${{ matrix.arch }}
182180free-threading :${{ matrix.free-threading }}
183181
184- build_windows_msi :
182+ build-windows-msi :
185183name :>-# ${{ '' } is a hack to nest jobs under the same sidebar category
186184 Windows MSI${{ '' }}
187185needs :build-context
188186if :fromJSON(needs.build-context.outputs.run-windows-msi)
189187strategy :
188+ fail-fast :false
190189matrix :
191190arch :
192191 -x86
@@ -196,7 +195,7 @@ jobs:
196195with :
197196arch :${{ matrix.arch }}
198197
199- build_macos :
198+ build-macos :
200199name :>-
201200 macOS
202201 ${{ fromJSON(matrix.free-threading) && '(free-threading)' || '' }}
@@ -230,14 +229,15 @@ jobs:
230229free-threading :${{ matrix.free-threading }}
231230os :${{ matrix.os }}
232231
233- build_ubuntu :
232+ build-ubuntu :
234233name :>-
235234 Ubuntu
236235 ${{ fromJSON(matrix.free-threading) && '(free-threading)' || '' }}
237236 ${{ fromJSON(matrix.bolt) && '(bolt)' || '' }}
238237needs :build-context
239238if :needs.build-context.outputs.run-tests == 'true'
240239strategy :
240+ fail-fast :false
241241matrix :
242242bolt :
243243 -false
@@ -247,13 +247,13 @@ jobs:
247247 -true
248248os :
249249 -ubuntu-24.04
250- -ubuntu-22 .04-arm
250+ -ubuntu-24 .04-arm
251251exclude :
252252# Do not test BOLT with free-threading, to conserve resources
253253 -bolt :true
254254free-threading :true
255255# BOLT currently crashes during instrumentation on aarch64
256- -os :ubuntu-22 .04-arm
256+ -os :ubuntu-24 .04-arm
257257bolt :true
258258uses :./.github/workflows/reusable-ubuntu.yml
259259with :
@@ -262,7 +262,7 @@ jobs:
262262free-threading :${{ matrix.free-threading }}
263263os :${{ matrix.os }}
264264
265- build_ubuntu_ssltests :
265+ build-ubuntu-ssltests :
266266name :' Ubuntu SSL tests with OpenSSL'
267267runs-on :${{ matrix.os }}
268268timeout-minutes :60
@@ -284,15 +284,15 @@ jobs:
284284with :
285285persist-credentials :false
286286 -name :Runner image version
287- run :echo "IMAGE_VERSION= ${ImageVersion}" >> "$GITHUB_ENV"
287+ run :echo "IMAGE_OS_VERSION=${ImageOS}- ${ImageVersion}" >> "$GITHUB_ENV"
288288 -name :Restore config.cache
289289uses :actions/cache@v4
290290with :
291291path :config.cache
292- key :${{ github.job }}-${{runner.os }}-${{ env.IMAGE_VERSION }}-${{ needs.build-context.outputs.config-hash }}
292+ key :${{ github.job }}-${{ env.IMAGE_OS_VERSION }}-${{ needs.build-context.outputs.config-hash }}
293293 -name :Register gcc problem matcher
294294run :echo "::add-matcher::.github/problem-matchers/gcc.json"
295- -name :InstallDependencies
295+ -name :Installdependencies
296296run :sudo ./.github/workflows/posix-deps-apt.sh
297297 -name :Configure OpenSSL env vars
298298run :|
@@ -324,15 +324,15 @@ jobs:
324324 -name :SSL tests
325325run :./python Lib/test/ssltests.py
326326
327- build_wasi :
327+ build-wasi :
328328name :' WASI'
329329needs :build-context
330330if :needs.build-context.outputs.run-tests == 'true'
331331uses :./.github/workflows/reusable-wasi.yml
332332with :
333333config_hash :${{ needs.build-context.outputs.config-hash }}
334334
335- test_hypothesis :
335+ test-hypothesis :
336336name :" Hypothesis tests on Ubuntu"
337337runs-on :ubuntu-24.04
338338timeout-minutes :60
@@ -347,7 +347,7 @@ jobs:
347347persist-credentials :false
348348 -name :Register gcc problem matcher
349349run :echo "::add-matcher::.github/problem-matchers/gcc.json"
350- -name :InstallDependencies
350+ -name :Installdependencies
351351run :sudo ./.github/workflows/posix-deps-apt.sh
352352 -name :Configure OpenSSL env vars
353353run :|
@@ -379,12 +379,12 @@ jobs:
379379 -name :Bind mount sources read-only
380380run :sudo mount --bind -o ro "$GITHUB_WORKSPACE" "$CPYTHON_RO_SRCDIR"
381381 -name :Runner image version
382- run :echo "IMAGE_VERSION= ${ImageVersion}" >> "$GITHUB_ENV"
382+ run :echo "IMAGE_OS_VERSION=${ImageOS}- ${ImageVersion}" >> "$GITHUB_ENV"
383383 -name :Restore config.cache
384384uses :actions/cache@v4
385385with :
386386path :${{ env.CPYTHON_BUILDDIR }}/config.cache
387- key :${{ github.job }}-${{runner.os }}-${{ env.IMAGE_VERSION }}-${{ needs.build-context.outputs.config-hash }}
387+ key :${{ github.job }}-${{ env.IMAGE_OS_VERSION }}-${{ needs.build-context.outputs.config-hash }}
388388 -name :Configure CPython out-of-tree
389389working-directory :${{ env.CPYTHON_BUILDDIR }}
390390run :|
@@ -447,14 +447,14 @@ jobs:
447447name :hypothesis-example-db
448448path :${{ env.CPYTHON_BUILDDIR }}/.hypothesis/examples/
449449
450-
451- build_asan :
450+ build-asan :
452451name :' Address sanitizer'
453452runs-on :${{ matrix.os }}
454453timeout-minutes :60
455454needs :build-context
456455if :needs.build-context.outputs.run-tests == 'true'
457456strategy :
457+ fail-fast :false
458458matrix :
459459os :[ubuntu-24.04]
460460env :
@@ -466,15 +466,15 @@ jobs:
466466with :
467467persist-credentials :false
468468 -name :Runner image version
469- run :echo "IMAGE_VERSION= ${ImageVersion}" >> "$GITHUB_ENV"
469+ run :echo "IMAGE_OS_VERSION=${ImageOS}- ${ImageVersion}" >> "$GITHUB_ENV"
470470 -name :Restore config.cache
471471uses :actions/cache@v4
472472with :
473473path :config.cache
474- key :${{ github.job }}-${{runner.os }}-${{ env.IMAGE_VERSION }}-${{ needs.build-context.outputs.config-hash }}
474+ key :${{ github.job }}-${{ env.IMAGE_OS_VERSION }}-${{ needs.build-context.outputs.config-hash }}
475475 -name :Register gcc problem matcher
476476run :echo "::add-matcher::.github/problem-matchers/gcc.json"
477- -name :InstallDependencies
477+ -name :Installdependencies
478478run :sudo ./.github/workflows/posix-deps-apt.sh
479479 -name :Set up GCC-10 for ASAN
480480uses :egor-tensin/setup-gcc@v1
@@ -511,13 +511,14 @@ jobs:
511511 -name :Tests
512512run :xvfb-run make ci
513513
514- build_tsan :
514+ build-tsan :
515515name :>-
516516 Thread sanitizer
517517 ${{ fromJSON(matrix.free-threading) && '(free-threading)' || '' }}
518518needs :build-context
519519if :needs.build-context.outputs.run-tests == 'true'
520520strategy :
521+ fail-fast :false
521522matrix :
522523free-threading :
523524 -false
@@ -530,26 +531,27 @@ jobs:
530531cross-build-linux :
531532name :Cross build Linux
532533runs-on :ubuntu-latest
534+ timeout-minutes :60
533535needs :build-context
534536if :needs.build-context.outputs.run-tests == 'true'
535537steps :
536538 -uses :actions/checkout@v4
537539with :
538540persist-credentials :false
539541 -name :Runner image version
540- run :echo "IMAGE_VERSION= ${ImageVersion}" >> "$GITHUB_ENV"
542+ run :echo "IMAGE_OS_VERSION=${ImageOS}- ${ImageVersion}" >> "$GITHUB_ENV"
541543 -name :Restore config.cache
542544uses :actions/cache@v4
543545with :
544546path :config.cache
545- key :${{ github.job }}-${{runner.os }}-${{ env.IMAGE_VERSION }}-${{ needs.build-context.outputs.config-hash }}
547+ key :${{ github.job }}-${{ env.IMAGE_OS_VERSION }}-${{ needs.build-context.outputs.config-hash }}
546548 -name :Register gcc problem matcher
547549run :echo "::add-matcher::.github/problem-matchers/gcc.json"
548550 -name :Set build dir
549551run :
550552# an absolute path outside of the working directoy
551553echo "BUILD_DIR=$(realpath ${{ github.workspace }}/../build)" >> "$GITHUB_ENV"
552- -name :InstallDependencies
554+ -name :Installdependencies
553555run :sudo ./.github/workflows/posix-deps-apt.sh
554556 -name :Configure host build
555557run :./configure --prefix="$BUILD_DIR/host-python"
@@ -594,8 +596,8 @@ jobs:
594596output-sarif :true
595597sanitizer :${{ matrix.sanitizer }}
596598 -name :Upload crash
597- uses :actions/upload-artifact@v4
598599if :failure() && steps.build.outcome == 'success'
600+ uses :actions/upload-artifact@v4
599601with :
600602name :${{ matrix.sanitizer }}-artifacts
601603path :./out/artifacts
@@ -608,35 +610,35 @@ jobs:
608610
609611all-required-green :# This job does nothing and is only used for the branch protection
610612name :All required checks pass
611- if : always()
612-
613+ runs-on : ubuntu-latest
614+ timeout-minutes : 5
613615needs :
614616 -build-context # Transitive dependency, needed to access `run-tests` value
615617 -check-docs
616- -check_autoconf_regen
617- -check_generated_files
618- -build_macos
619- -build_ubuntu
620- -build_ubuntu_ssltests
621- -build_wasi
622- -build_windows
623- -build_windows_msi
624- -test_hypothesis
625- -build_asan
626- -build_tsan
618+ -check-autoconf-regen
619+ -check-generated-files
620+ -build-windows
621+ -build-windows-msi
622+ -build-macos
623+ -build-ubuntu
624+ -build-ubuntu-ssltests
625+ -build-wasi
626+ -test-hypothesis
627+ -build-asan
628+ -build-tsan
629+ -cross-build-linux
627630 -cifuzz
628-
629- runs-on :ubuntu-latest
631+ if :always()
630632
631633steps :
632634 -name :Check whether the needed jobs succeeded or failed
633635uses :re-actors/alls-green@05ac9388f0aebcb5727afa17fcccfecd6f8ec5fe
634636with :
635637allowed-failures :>-
636- build_ubuntu_ssltests,
637- build_windows_msi,
638+ build-windows-msi,
639+ build-ubuntu-ssltests,
640+ test-hypothesis,
638641 cifuzz,
639- test_hypothesis,
640642allowed-skips :>-
641643 ${{
642644 !fromJSON(needs.build-context.outputs.run-docs)
@@ -648,22 +650,23 @@ jobs:
648650 ${{
649651 needs.build-context.outputs.run-tests != 'true'
650652 && '
651- check_autoconf_regen,
652- check_generated_files,
653- build_macos,
654- build_ubuntu,
655- build_ubuntu_ssltests,
656- build_wasi,
657- build_asan,
658- build_tsan,
659- test_hypothesis,
653+ check-autoconf-regen,
654+ check-generated-files,
655+ build-macos,
656+ build-ubuntu,
657+ build-ubuntu-ssltests,
658+ build-wasi,
659+ test-hypothesis,
660+ build-asan,
661+ build-tsan,
662+ cross-build-linux,
660663 '
661664 || ''
662665 }}
663666 ${{
664667 !fromJSON(needs.build-context.outputs.run-windows-tests)
665668 && '
666- build_windows ,
669+ build-windows ,
667670 '
668671 || ''
669672 }}