Repository navigation
ci: split Control UI E2E into 13 shards so it stops setting the wall - #131257
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. |
|
Codex review: needs maintainer review before merge. Reviewed August 27, 2026, 8:01 PM ET / August 28, 2026, 00:01 UTC. ClawSweeper reviewWhat this changesThe PR raises hosted and hybrid Control UI E2E CI from 12 to 14 matrix rows (13 Control UI shards plus one browser-extension row), matching parallelism, tests, and CI documentation. Merge readinessNo introduced correctness defect was found: the planner, workflow cap, guard, and documentation now agree on 14 total rows. Keep this maintainer-owned PR open until its exact-head CI run completes. Priority: P3 Review scores
Verification
Live VerificationCommand: Result: FAIL (failed) — step 1 Assertions:
How this fits togetherCI preflight converts the selected runner profile into a browser-test matrix. The Control UI E2E job consumes that matrix, while workflow guards and CI documentation preserve its scheduling contract. flowchart LR
A[Runner profile] --> B[Preflight planner]
B --> C[14-row E2E matrix]
C --> D[Parallel Chromium jobs]
B --> E[Workflow guard tests]
B --> F[CI operations docs]
Before merge
Agent review detailsSecurityNone. PR surfaceTests +7, Docs +2, Config +5. Total +14 across 4 files. View PR surface stats
Review metrics
Merge-risk optionsMaintainer options:
Copy recommended automerge instructionTechnical reviewBest possible solution: Retain the aligned 14-row planner, concurrency cap, guard, and documentation contract once exact-head CI completes successfully. Do we have a high-confidence way to reproduce the issue? Not applicable: the relevant behavior is a generated CI matrix and its GitHub Actions execution, not an end-user defect reproduction. Is this the best way to solve the issue? Yes. Increasing the hosted/hybrid planner count while matching max-parallel directly reduces the tall serial Chromium shard; the existing weighted sequencer remains the canonical packing mechanism. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against e946d226f73c. LabelsLabel changes:
Label justifications:
EvidenceWhat I checked:
Likely related people:
Rank-up movesOptional improvements that raise the rating; they are not merge blockers.
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
HistoryReview history (1 earlier review cycle)
|
checks-ui-e2e is the tallest CI job on main (387s worst observed). Its shard imbalance is not a packing problem: measured across runs 33116963478, 33117411412, and 33117811987, control-UI shard bodies span 1.25-1.27x, and leave-one-run-out cross-validation shows hinting all 286 files gains ~13s at 11 shards and ~0-7s at 13-14, because per-file run-to-run noise (p50 16%, p90 40%) swamps the residual prediction error. What dominates is a fixed per-shard floor of 116s median / 143s p90 (checkout, pnpm install, Vitest transform) that no packing change can touch. That floor varies randomly per job rather than per shard, so the packer must not model it -- a constant added to every bucket never changes greedy LPT's choice -- but it does set the shard count. Raise the hosted/hybrid matrix from 12 to 14 rows (13 control-UI shards plus the browser-extension row) and match max-parallel so the extra rows do not queue. Replaying each run's real per-file times through the packer moves the tallest shard body from 229/218/219s to 179/183/179s, modelling the tallest row at 4:52 p50 and 5:20 p90 against 5:28/5:56. Two extra registrations per run against a 6000/5min operating target. Also correct the sequencer comment, which pointed the next maintainer at the hint refresh that measurably does not pay, and record the floor-based sizing rationale in docs/ci.md. Note: this takes checks-ui-e2e off the critical path but does not reach a 5:00 wall on its own -- checks-node-compact-small-11 (297-367s) and checks-ui (276-331s) set a 5:42-6:32 floor behind it.
The planner-descriptor paragraph still described the hosted and hybrid profiles as eleven Vitest shards plus one browser-extension shard, which was accurate for the previous 12-row matrix and contradicts the 14-row plan in the same document. Found by ClawSweeper review of #131257.
1659645 to
a15ea70
Compare
|
Thanks — the P2 was a real miss on my part, now fixed in [P2] Stale eleven-shard reference ( [P1] Exact-head CI — the previous head That run also confirms the change does what the PR body predicts, measured from its own job logs rather than modelled:
Matrix topology is as intended: 14 rows, Two honest notes on that run. The tallest row's wall was 345s rather than the modelled 292s, but that is not the sharding — checkout ran 54-56s on every row, at the top of the observed 16-59s range, the same run-wide slow-fetch condition seen in run 33117811987. Body is the apples-to-apples measure and it landed where predicted. And because this PR edits On the live-verification Owner decision on the fanout — accepted. Two extra rows against a live One scope caveat worth repeating, since the PR should not be read as claiming a 5:00 wall: excluding the aggregate gate, if |
|
Merged via squash.
|
…penclaw#131257) * ci: split Control UI E2E into 13 shards so it stops setting the wall checks-ui-e2e is the tallest CI job on main (387s worst observed). Its shard imbalance is not a packing problem: measured across runs 33116963478, 33117411412, and 33117811987, control-UI shard bodies span 1.25-1.27x, and leave-one-run-out cross-validation shows hinting all 286 files gains ~13s at 11 shards and ~0-7s at 13-14, because per-file run-to-run noise (p50 16%, p90 40%) swamps the residual prediction error. What dominates is a fixed per-shard floor of 116s median / 143s p90 (checkout, pnpm install, Vitest transform) that no packing change can touch. That floor varies randomly per job rather than per shard, so the packer must not model it -- a constant added to every bucket never changes greedy LPT's choice -- but it does set the shard count. Raise the hosted/hybrid matrix from 12 to 14 rows (13 control-UI shards plus the browser-extension row) and match max-parallel so the extra rows do not queue. Replaying each run's real per-file times through the packer moves the tallest shard body from 229/218/219s to 179/183/179s, modelling the tallest row at 4:52 p50 and 5:20 p90 against 5:28/5:56. Two extra registrations per run against a 6000/5min operating target. Also correct the sequencer comment, which pointed the next maintainer at the hint refresh that measurably does not pay, and record the floor-based sizing rationale in docs/ci.md. Note: this takes checks-ui-e2e off the critical path but does not reach a 5:00 wall on its own -- checks-node-compact-small-11 (297-367s) and checks-ui (276-331s) set a 5:42-6:32 floor behind it. * docs(ci): correct the remaining eleven-shard Control UI E2E reference The planner-descriptor paragraph still described the hosted and hybrid profiles as eleven Vitest shards plus one browser-extension shard, which was accurate for the previous 12-row matrix and contradicts the 14-row plan in the same document. Found by ClawSweeper review of openclaw#131257.
What Problem This Solves
checks-ui-e2eis the tallest job in OpenClaw's CI graph onmain, at 357-387s across the three runs measured below, and it sets the wall in two of the three. Its shards are visibly uneven, so the whole lane waits on whichever row drew the heaviest work.Why This Change Was Made
The imbalance is not a packing problem, and the existing duration-weighted sequencer is not what needs fixing.
Per-file medians were re-derived from the
checks-ui-e2ejob logs of runs 33116963478, 33117411412, and 33117811987 (2026-08-27): 286 control-UI files, ~2114s of body. Control-UI shard bodies span 1.25-1.27x within a run, not the 2.6x visible in job wall — that figure compares wall and includes the browser-extension row, which is a different workload at 133s.Expanding
UI_E2E_FILE_SECONDS_HINTSto cover the ~200 unhinted files does not pay. Under leave-one-run-out cross-validation (weights fit on two runs, shards scored on the held-out third), the tallest shard body is 222s with the shipped estimator, 209s with a full 286-file table, and 196s with an oracle that knows the run's exact times — and at 13-14 shards the full table gains 0-7s. Per-file run-to-run noise is p50 16% / p90 40%, which swamps the residual prediction error. Scoring a table against the medians it was fit on shows a perfect 1.00x spread, but that is overfitting, not a result. The slow-tail hints do still earn their keep: bytes-only lands at 259s, so they stay.What actually dominates is a fixed per-shard floor of 116s median, 143s p90, 159s max — checkout 16-59s, Node setup 34-83s (dominated by
pnpm install, which runs on every row because the hosted/hybrid profile setsdependency-cache: false), and ~27s of Vitest transform/import/fork. That floor varies randomly per job rather than per shard, so the packer must not model it: a constant added to every bucket never changes which bucket greedy LPT picks. It only sets the shard count.So the shard count is the lever. The hosted/hybrid matrix goes from 12 to 14 rows — 13 control-UI shards plus the browser-extension row — with
max-parallelraised to match, without which the extra rows would queue behind the first twelve and make the lane slower.User Impact
Maintainer- and contributor-facing CI latency only; no product or runtime behavior changes.
checks-ui-e2edrops off the critical path.This does not reach a 5:00 wall on its own, and the PR should not be read as claiming that. Excluding the aggregate gate, if
checks-ui-e2evanished entirely the wall on those three runs would land at 5:42 / 6:32 / 6:12 onchecks-node-compact-small-11(297-367s) andchecks-ui(276-331s). In run 33116963478checks-ui-e2ewas not even the tallest job. Those two lanes are the next work.Evidence
Replaying each run's real per-file times through the packer at both shard counts:
With the measured overhead distribution that models the tallest row at 4:52 p50 / 5:20 p90, against 5:28 / 5:56 today.
Capacity, checked against the runner-registration budget in
docs/ci.md: the liveactions_runner_registrationbucket reports 10,000 per 5 minutes against a 6,000 operating target, so two extra rows per run is negligible. Concurrency is proven ground — run 33116963478 peaked at 105 concurrent jobs, and its twelvechecks-ui-e2erows all started within 1s of each other, so nothing was queueing at 12.Local validation:
node scripts/run-vitest.mjs test/scripts/ci-workflow-guards.test.ts— 137 passed, 2 skippednode scripts/run-vitest.mjs test/vitest-ui-e2e-config.test.ts— 4 passednode --import tsx scripts/check-workflows.mts— passed (zizmor clean)node scripts/check-changed.mjs— exit 0node scripts/docs-list.js,oxfmt --check,git diff --check— cleanThis PR edits
.github/workflows/ci.yml, which is in the UI scope regex atscripts/ci-changed-scope.mjs:104, so its own CI run exercises the new 14-row matrix directly.