Repository navigation
e2e: size the four shards by measured cost - #1893
Merged
Merged
Conversation
Run 4783 measured the shards at 30.3, about 22.9, 27.1 and 26.5 min: with equal test counts, shard 1 also ends in a run of cheap ai-* specs. Sixty tests instead of seventy-nine puts about 200s on shard 2 instead, which brings the slowest shard from 30.3 to about 27 min. Playwright's PWTEST_SHARD_WEIGHTS takes one weight per shard separated by colons; only a shard count with an entry is weighted.
The first weighted run (4790) showed shard 2 heavier than estimated, because its own timings were not available when the first weights were set. With every shard's per-file seconds, 62:90:84:79 puts all four shards within 2252 to 2279 s of that run.
joepio
marked this pull request as ready for review
September 29, 2026 18:58
joepio
added a commit
that referenced
this pull request
Sep 29, 2026
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.
Before: the four e2e shards are cut by test count. On run 4783 (the timing-summary run, all green) they took 30.3, about 22.9, 27.1 and 26.5 min, so CI waits for shard 1.
After:
PWTEST_SHARD_WEIGHTS=60:98:79:78for the four-shard profile. Shard 1 ends in a run of cheap ai-* specs (about 8 s per test), so sixty tests instead of seventy-nine sheds about 200 s onto shard 2. Estimated shards: about 26.7, 26.3, 26.9 and 26.3 min, so the slowest drops from 30.3 to about 27 min.How: weights are proportions, so a growing suite keeps the split; only a shard count with an entry in
E2E_SHARD_WEIGHTSis weighted (Playwright wants one weight per shard, separated by colons). Estimates come from the per-fileE2E-TIMINGlines of run 4783 for shards 1, 3 and 4; shard 2's own log fell outside the fetchable tail, so its 22.9 min is from run 4774, and that is the one number to check on the first run with this change. Set membership was checked withplaywright --list --shardat the new weights.Generated by Claude Code