File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 4848 uses : ./.github/workflows/_find_changes.yaml
4949 secrets : inherit
5050
51- build-wheels :
52- # For efficiency, skip this workflow if there were no code file changes.
53- if : >-
54- ${{needs.find-changes.outputs.code == 'true'
55- || github.event_name == 'workflow_dispatch'}}
56- name : ${{matrix.conf.os}}/${{matrix.conf.pyarch}}/py3${{matrix.conf.py}}
51+ build-library :
52+ name : Build for ${{matrix.conf.os}}/${{matrix.conf.pyarch}}/py3${{matrix.conf.py}}
5753 needs : find-changes
5854 runs-on : ${{matrix.conf.os}}
5955 timeout-minutes : 30
9086 # Must use explicit test for true so it works when inputs.debug is null.
9187 use-verbose : ${{github.event.inputs.debug == true}}
9288 steps :
89+ - if : >-
90+ ${{needs.find-changes.outputs.code == 'false'
91+ && github.event_name != 'workflow_dispatch'}}
92+ name: Exit early if there were no changes to code files
93+ run: exit 0
94+
9395 - name : Check out a copy of the git repository
9496 uses : actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
9597 with :
Original file line number Diff line number Diff line change 4848 uses : ./.github/workflows/_find_changes.yaml
4949 secrets : inherit
5050
51+ build-wheels-skip :
52+ if : >-
53+ ${{needs.find-changes.outputs.code == 'false'
54+ && github.event_name != 'workflow_dispatch'}}
55+ # Important: the name must be the same as that of the build-wheels job.
56+ name : Build & test wheels
57+ needs : find-changes
58+ runs-on : ubuntu-24.04
59+ timeout-minutes : 5
60+ steps :
61+ - name : Exit with success if there were no changes to code files
62+ run : exit 0
63+
5164 build-wheels :
52- # For efficiency, skip this workflow if there were no code file changes.
5365 if : >-
5466 ${{needs.find-changes.outputs.code == 'true'
5567 || github.event_name == 'workflow_dispatch'}}
Original file line number Diff line number Diff line change @@ -49,18 +49,20 @@ jobs:
4949 secrets : inherit
5050
5151 build-and-test :
52- # For efficiency, skip this workflow if there were no code file changes.
53- if : >-
54- ${{needs.find-changes.outputs.code == 'true'
55- || github.event_name == 'workflow_dispatch'}}
56- name : Build and test Docker images
52+ name : Build & test Docker images
5753 needs : find-changes
5854 runs-on : ubuntu-24.04
5955 timeout-minutes : 30
6056 env :
6157 # The next environment variable is used by Docker.
6258 BUILDKIT_PROGRESS : ${{inputs.debug && 'plain' || ''}}
6359 steps :
60+ - if : >-
61+ ${{needs.find-changes.outputs.code == 'false'
62+ && github.event_name != 'workflow_dispatch'}}
63+ name: Exit early if there were no changes to code files
64+ run: exit 0
65+
6466 - name : Check out a copy of the git repository
6567 uses : actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
6668 with :
Original file line number Diff line number Diff line change 4949 secrets : inherit
5050
5151 check-format :
52- # For efficiency, skip this workflow if there were no Python file changes.
53- if : >-
54- ${{needs.find-changes.outputs.python == 'true'
55- || github.event_name == 'workflow_dispatch'}}
5652 name : Python format check
5753 needs : find-changes
5854 runs-on : ubuntu-24.04
6157 # Add xtrace to SHELLOPTS for all Bash scripts when doing debug runs.
6258 SHELLOPTS : ${{inputs.debug && 'xtrace' || '' }}
6359 steps :
60+ - if : >-
61+ ${{needs.find-changes.outputs.python == 'false'
62+ && github.event_name != 'workflow_dispatch'}}
63+ name: Exit early if there were no changes to code files
64+ run: exit 0
65+
6466 - name : Check out a copy of the git repository
6567 uses : actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
6668 with :
Original file line number Diff line number Diff line change 4949 secrets : inherit
5050
5151 test-options :
52- # For efficiency, skip this workflow if there were no code file changes.
53- if : >-
54- ${{needs.find-changes.outputs.code == 'true'
55- || github.event_name == 'workflow_dispatch'}}
5652 name : Test ${{matrix.hardware_opt}} + ${{matrix.parallel_opt}}
5753 needs : find-changes
5854 runs-on : ubuntu-24.04
6763 # Must use explicit test for true so it works when inputs.debug is null.
6864 use-verbose : ${{github.event.inputs.debug == true}}
6965 steps :
66+ - if : >-
67+ ${{needs.find-changes.outputs.code == 'false'
68+ && github.event_name != 'workflow_dispatch'}}
69+ name: Exit early if there were no changes to code files
70+ run: exit 0
71+
7072 - name : Check out a copy of the git repository
7173 uses : actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
7274 with :
Original file line number Diff line number Diff line change 4949 secrets : inherit
5050
5151 sanitizer-tests :
52- # For efficiency, skip this workflow if there were no code file changes.
53- if : >-
54- ${{needs.find-changes.outputs.code == 'true'
55- || github.event_name == 'workflow_dispatch'}}
5652 name : Test with sanitizers
5753 needs : find-changes
5854 runs-on : ubuntu-24.04
6561 # Must use explicit test for true so it works when inputs.debug is null.
6662 use-verbose : ${{github.event.inputs.debug == true}}
6763 steps :
64+ - if : >-
65+ ${{needs.find-changes.outputs.code == 'false'
66+ && github.event_name != 'workflow_dispatch'}}
67+ name: Exit early if there were no changes to code files
68+ run: exit 0
69+
6870 - name : Check out a copy of the git repository
6971 uses : actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
7072 with :
Original file line number Diff line number Diff line change 4949 secrets : inherit
5050
5151 tcmalloc-test :
52- # For efficiency, skip this workflow if there were no code file changes.
53- if : >-
54- ${{needs.find-changes.outputs.code == 'true'
55- || github.event_name == 'workflow_dispatch'}}
5652 name : Test with TCMalloc
5753 needs : find-changes
5854 runs-on : ubuntu-24.04
6157 # Must use explicit test for true so it works when inputs.debug is null.
6258 use-verbose : ${{github.event.inputs.debug == true}}
6359 steps :
60+ - if : >-
61+ ${{needs.find-changes.outputs.code == 'false'
62+ && github.event_name != 'workflow_dispatch'}}
63+ name: Exit early if there were no changes to code files
64+ run: exit 0
65+
6466 - name : Check out a copy of the git repository
6567 uses : actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
6668 with :
You can’t perform that action at this time.
0 commit comments