Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit71f3a64

Browse files
committed
✅ Introduce a gate/check GHA job
This adds a GHA job that reliably determines if all the requireddependencies have succeeded or not.It also allows to reduce the list of required branch protection CIstatuses to just one — `check`. This reduces the maintenance burdenby a lot and have been battle-tested across a small bunch of projectsin its action form and in-house implementations of other people.This action is now in use in aiohttp (and other aio-libs projects),CherryPy, conda, coveragepy, Open edX, Towncrier some of the Ansiblerepositories, pip-tools, all of the jaraco's projects (like`setuptools`, `importlib_metadata`), some of hynek's projects (like`attrs`, `structlog`), some PyCQA, PyCA, PyPA and pytest projects, afew AWS Labs projects. Admittedly, I maintain a few of these but itseems to address some of the pain folks have:jaraco/skeleton#55 (comment).I figured, this might be useful for CPython too, which is why I'msubmitting this patch.The story behind this is explained in more detail athttps://github.com/marketplace/actions/alls-green#why.
1 parent5432803 commit71f3a64

File tree

1 file changed

+48
-0
lines changed

1 file changed

+48
-0
lines changed

‎.github/workflows/build.yml

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -362,3 +362,51 @@ jobs:
362362
run:make pythoninfo
363363
-name:Tests
364364
run:xvfb-run make buildbottest TESTOPTS="-j4 -uall,-cpu"
365+
366+
all-required-green:# This job does nothing and is only used for the branch protection
367+
name:✅ All required checks pass
368+
if:always()
369+
370+
needs:
371+
-check_source# Transitive dependency, needed to access `run_tests` value
372+
-check-docs
373+
-check_generated_files
374+
-build_win32
375+
-build_win_amd64
376+
-build_macos
377+
-build_ubuntu
378+
-build_ubuntu_ssltests
379+
-build_asan
380+
381+
runs-on:ubuntu-latest
382+
383+
steps:
384+
-name:Decide whether the needed jobs succeeded or failed
385+
uses:re-actors/alls-green@05ac9388f0aebcb5727afa17fcccfecd6f8ec5fe
386+
with:
387+
allowed-failures:>-
388+
build_macos,
389+
build_ubuntu_ssltests,
390+
build_win32,
391+
allowed-skips:>-
392+
${{
393+
fromJSON(needs.check_source.outputs.run-docs)
394+
&& '
395+
check-docs,
396+
'
397+
|| ''
398+
}}
399+
${{
400+
needs.check_source.outputs.run_tests == 'true'
401+
&& '
402+
check_generated_files,
403+
build_win32,
404+
build_win_amd64,
405+
build_macos,
406+
build_ubuntu,
407+
build_ubuntu_ssltests,
408+
build_asan,
409+
'
410+
|| ''
411+
}}
412+
jobs:${{ toJSON(needs) }}

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp