Skip to content

Commit ba5dc60

Browse files
committed
ci(e2e): name the PR path check e2e-needed
The job only decides whether a PR runs the E2E lane, so its name and its single output say that: needs.e2e-needed.outputs.run. Signed-off-by: Piotr Mlocek <pmlocek@nvidia.com>
1 parent d4fdadb commit ba5dc60

1 file changed

Lines changed: 8 additions & 7 deletions

File tree

‎.github/workflows/ci.yml‎

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -70,13 +70,14 @@ jobs:
7070
- name: Build, verify, and install the wheel and sdist
7171
run: mise run build
7272

73-
changes:
74-
name: changes
73+
# Decides whether a PR needs the E2E lane, from the files it changes.
74+
e2e-needed:
75+
name: e2e-needed
7576
if: github.event_name == 'pull_request'
7677
runs-on: ubuntu-latest
7778
timeout-minutes: 5
7879
outputs:
79-
e2e: ${{ steps.diff.outputs.e2e }}
80+
run: ${{ steps.diff.outputs.run }}
8081
steps:
8182
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
8283
with:
@@ -89,17 +90,17 @@ jobs:
8990
run: |
9091
set -euo pipefail
9192
if git diff --name-only "${BASE_SHA}...HEAD" | grep -qE '^(\.python-version$|mise\.toml$|pyproject\.toml$|uv\.lock$|src/|tests/e2e/|hack/automation/(start|stop)-gateway\.sh$|\.github/workflows/e2e\.yml$)'; then
92-
echo "e2e=true" >>"$GITHUB_OUTPUT"
93+
echo "run=true" >>"$GITHUB_OUTPUT"
9394
else
94-
echo "e2e=false" >>"$GITHUB_OUTPUT"
95+
echo "run=false" >>"$GITHUB_OUTPUT"
9596
fi
9697
9798
# Not part of the required `ci` check, as in sdk-go: PRs run it only when
9899
# the SDK, its pins or the E2E lane change; pushes to main always run it.
99100
e2e:
100101
name: e2e
101-
needs: changes
102-
if: ${{ !cancelled() && (github.event_name != 'pull_request' || needs.changes.outputs.e2e == 'true') }}
102+
needs: e2e-needed
103+
if: ${{ !cancelled() && (github.event_name != 'pull_request' || needs.e2e-needed.outputs.run == 'true') }}
103104
uses: ./.github/workflows/e2e.yml
104105

105106
# The one required status check. Its name matches ai-openshell/sdk-go, so

0 commit comments

Comments
 (0)