Skip to content

ci(web): run the webview tests in four shards instead of two - #22146

Closed
teamleaderleo wants to merge 1 commit into
feat-cmux-nextfrom
flk-ci-web-shards
Closed

teamleaderleo wants to merge 1 commit into
feat-cmux-nextfrom
flk-ci-web-shards

Conversation

@teamleaderleo

@teamleaderleo teamleaderleo commented Oct 19, 2026 •

Copy link
Copy Markdown
Collaborator

The webview test step sets how long react-apps-check takes, and nearly all of that step goes to the Vite dev server files. scripts/ci/run-webviews-tests.sh runs those CMUX_WEB_TEST_DEV_JOBS at a time, which is 2 on the 8 vCPU runner.

Measured on job 117948581151, react-apps-check (2) at two shards:

  • Test step: 1,058 s. Its 136 other files were all done 20 s in, and the remaining 1,037 s went to 65 dev server files.
  • The sibling shard took 777 s.

With four shards, each gets 28 to 34 dev server files instead of 58 to 64 (round robin over the git-index list, same split rule). The test step on the critical path should drop to about half, roughly 550 s, and the whole job from about 19.5 min to about 11 min. The per-shard fixed cost (about 110 s for setup, the bundle build and the engine install) now runs four times instead of twice on free Blacksmith runners.

Only the matrix changed. The aggregate react-apps-check gate, the per-file isolation, the warmers and the PR-scoped check on shard 1 are unchanged.

Observed / Not run

  • Measured the step timeline from the job log of 117948581151 and the per-shard split from git ls-files with the script's own dev-server pattern.
  • This PR's own run is the first four-shard timing. I'll add it here when it lands.

Changelog

none

🤖 Generated with Claude Code


View with [code]smith Autofix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need.


Summary by cubic

Runs the webview tests in four shards instead of two, roughly halving the react-apps-check critical path.

Nearly all of a shard's test step goes to its Vite dev server files, which run two at a time on the 8 vCPU runner: shard 2 in job 117948581151 spent 1,037 of its 1,058 s there while its other 136 files finished in 20 s. Four shards give each 28–34 dev server files instead of 58–64, so the test step should drop to about 550 s and the whole job from ~19.5 to ~11 min. The tradeoff is that per-shard setup, bundle build, and engine install now run four times instead of twice.

Only the workflow matrix changed; the aggregate gate, per-file isolation, warmers, and PR-scoped check on shard 1 are unchanged.

Written for commit 4272c69. Summary will update on new commits.

View guided diff Turn on auto-fix

Each react-apps-check shard spends nearly all of its test step on its Vite
dev server files, which run two at a time on the 8 vCPU runner. With two
shards, shard 2 spent 1,037 of its 1,058 s there (job 117948581151) and
its other 136 files took 20 s. Four shards give each one 28 to 34 dev
server files instead of 58 to 64.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@github-actions

github-actions Bot commented Oct 19, 2026 •

Copy link
Copy Markdown
Contributor

cmux status (one comment, edited in place; each line is updated by the job that owns it)

Review 4272c69: HQ feed card · gallery before/after runs · checks

App of this head (app.zip, kept 1 day)

gh workflow run reload-build.yml -R manaflow-ai/cmux --ref feat-cmux-next -f tag=pr22146 -f ref=flk-ci-web-shards -f platform=macos -f backend_mode=local

Unclear: web / react-apps-check (4) failed: no known signature; failed step: Check webviews (Oxlint, Oxfmt, type check).

CI failed on 4272c696ec (run 39324966063 attempt 1): 5 unknown.

Job Verdict Why
web / react-apps-check (4) unknown no known signature; failed step: Check webviews (Oxlint, Oxfmt, type check)
web / react-apps-check (2) unknown no known signature; failed step: Check webviews (Oxlint, Oxfmt, type check)
web / react-apps-check (1) unknown no known signature; failed step: Check webviews (Oxlint, Oxfmt, type check)
web / react-apps-check (3) unknown no known signature; failed step: Check webviews (Oxlint, Oxfmt, type check)
web / react-apps-check unknown no known signature; failed step: Check webview test shards

Not re-run automatically: web / react-apps-check (4), web / react-apps-check (2), web / react-apps-check (1), web / react-apps-check (3), web / react-apps-check are not machine failures.

Written by scripts/ci/classify_failures.py (ci-failure-attribution.yml); signatures are its SIGNATURES table. A machine verdict is the runner's fault, not this PR's; yours means the failing file is one this PR changes, also red on main that main's latest full suite fails the same way, seen on other PRs that it failed on another pull request's run lately.

red: web / Web status; do not merge until green; see lane-rules
red: web / react-apps-check; do not merge until green; see lane-rules
red: web / react-apps-check (1); do not merge until green; see lane-rules
red: web / react-apps-check (2); do not merge until green; see lane-rules
red: web / react-apps-check (3); do not merge until green; see lane-rules
red: web / react-apps-check (4); do not merge until green; see lane-rules

CI fast guards failed on 4272c696ec (https://github.com/manaflow-ai/cmux/actions/runs/39324966063). It does not block the merge; a red guard merged into main breaks it for every open PR.
The log named no failed step; see the run.

Agents: python3 scripts/ci/guard_attribution.py fix applies the mechanical fixes locally.

@blacksmith-sh

blacksmith-sh Bot commented Oct 19, 2026

Copy link
Copy Markdown

Found 1 test failure on Blacksmith runners:

Failure

Test View Logs
NEXT post-publication dependency contract/NEXT post-publication dependency contract View Logs

Fix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need.

@greptile-apps

greptile-apps Bot commented Oct 19, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerView in GreptileConfidence Score: 5/5

[Medium impact] The PR appears safe to merge.

Summary

Expands the webview test matrix from two shards to four.

  • Webview tests run across four shards.

Reviews (1) · Last reviewed commit: "ci(web): run the webview tests in four s..." · Reviewed by Greptile

@teamleaderleo

Copy link
Copy Markdown
Collaborator Author

Bead cx-7bb0x created for this PR by the cmux coordinator.

@teamleaderleo

Copy link
Copy Markdown
Collaborator Author

Superseded by #22237 (merged): react-apps-check already runs four shards on feat-cmux-next, on the 32 vCPU runner after the twelve-wide trial. Nothing left to land here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant