Repository navigation
ci(viewer): the viewer tests end with their legs, not with a job that waits for a runner to say so (#1457) - #1515
Merged
Merged
Conversation
… waits for a runner to say so (#1457) The legs passed job of viewer-test.yml took a runner after the legs to fail on a test job skipped for want of a leg. Its queue wait was a median 26 s and a p90 of 163 s over the last 20 full runs, 4.6 minutes on #1481's landing run, in a chain that CI passed then waited behind again. The call's own result already aggregates the legs, each of which fails when its build did not pass, and CI passed and Deploy viewer read that result, so nothing else needs the check's name. The one case the job covered, a legs list that yields no leg, is now checked by check-workflows.py in the env config job: the default legs and every caller's are a written-out, non-empty list of legs that run something. Refs #1457.
DrunkOnJava
marked this pull request as ready for review
November 9, 2026 01:16
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
The viewer tests no longer end with a roll-up job,
legs passed, that took a runner of its own after the legs. The call's result already says whether the legs passed, and the one case the job covered is now checked statically.Motivation
Griffin asked for the bottlenecks to be fixed. Over the last 200 minutes the account's 40 concurrent jobs were full about 70% of the time, and on #1481's landing run
legs passedandCI passedwaited 4.6 and 3.2 minutes of its 28.6 for a runner each.Changes
.github/workflows/viewer-test.yml: theresultjob (legs passed) is removed, and the header says why it is not needed. Why it existed:CI passedcounts a skipped job as a pass and a call whose jobs were all skipped is skipped; the legs (test) already run whenever the run is not cancelled and fail their first step whenbuilddid not pass, so every leg either runs its tests or fails the call, and the call's own result, whichCI passedand Deploy viewer read (needs: viewerinci.yml,needs: [build, tests, measure]indeploy-viewer.yml), aggregates them. The only caseresultadded was alegslist that yields no leg, which skipstest, and a call whosetestis skipped passes.tools/ci/check-workflows.py(the env config job, which runs on every pull request) now checks that case before it can happen: the defaultlegsofviewer-test.yml(both triggers) and thelegsof every job that calls it are a JSON list written out (not a${{ }}expression), non-empty, each leg with a name and either spec files ormeasure: true. Five failure-first tests of the two pure helpers intools/ci/test_check_workflows.py, for the mistakes that would let the call pass (a list that yields no leg, a computed list, a leg that runs nothing, and a caller's list being read), 86 tests in all.CI passedstays: it is the required check,full / CI passed(.github/rulesets/main-protection.json,arm.sh's "no full / CI passed on this head yet"). It already needs the reusableviewerjob directly, so nothing changes there. Nothing else reads the namelegs passed: notarm.sh,watch.py, the rulesets, Deploy viewer or itswait-for-check, nor the release preflight (git grepand the scripts under.claude/).Numbers
legs passed, queue wait (created to started) in the last 20 fullci-pr.ymlruns that ran it: median 26 s, p90 163 s, max 277 s; it ran 3 s.CI passedin the last 56 runs: median 26 s, p90 181 s, max 1,317 s. So the removed job saved a median of about 30 s and about 2.8 minutes at the 90th percentile of a landing run's chain, not the 4.6 minutes of #1481's run, which was above that percentile. A job that takes a runner also counts against the 40 concurrent jobs while it runs, about 3 s. The gain depends on the pool: a roll-up job is created when its legs finish, and the median wait for it is already short (26 s), so with the pool less loaded than in the last 200 minutes the gain tends toward that median of about 30 s, and only a saturated pool gives the minutes.Left alone
CI passedstill waits behind everything for a runner of its own; it cannot be removed, since the ruleset requires its name. A caller that computeslegsis now refused by the check instead of guarded at run time; none does.Testing
Unit tests are banned in this repository: do not add them. Show the change working end to end on real files instead.
tools/check-local.shpasses. N/A: CI-only change; no local compute on this lane.main's workflow).The workflow and
check-workflows.pyare those of9018d984; after it the test file was cut to the five new tests andmainmerged in, and 86 tests pass on the head that lands:actionlintexits 0.python3 tools/ci/check-workflows.py: 0 errors, 0 warnings, and the new lineviewer test legs: 4 lists(the two defaults, Deploy viewer's two calls).python3 tools/ci/test_check_workflows.py: 86 tests..github/changed, soviewer-pathsruns them): the run has thebuild the WASMjob and the threebrowser testslegs, nolegs passed, andfull / CI passedsucceeds on theviewerjob's result. Not yet measured on this head.mainthat touches the viewer, and can be dispatched on this branch, not done to spare the runners).Audit-honesty checklist
check-workflows.py's docstring)changelog.d/<section>/. N/A: CI only, as agreed for CI: where the minutes go, and what to change #1457.Legal and contribution hygiene
Breaking changes
None.
Screenshots or output samples
See Testing.
Related issues
Refs #1457