Repository navigation
Conversation
…t legs of one Each leg spends about two minutes on checkout, setup and the core build before it proves anything, more than most slices take in the affected scope. Two slices now share a leg and run side by side; a slice's largest recorded time keeps a pair well inside the leg's limit, and admission's full width for the proof follows the four legs.
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
AI review status for this pull request.
|
PR Analysis Report
Generated by PR Enrichment workflow | View current CI run |
There was a problem hiding this comment.
Approved pending CI: CI has not run on this draft head yet, so mark the pull request ready for review to run it. No blocking findings: the new leg-shape tests fail on main's ci.yml and pass here.
- Optional: the leg-limit test counts only each pair's slower slice, which holds because Vitest runs the pair at once by default;
--maxWorkers=2on the leg's command would pin that (see the inline note). - Optional: the headers of
ci-swizzle-proof.test.mjs,slice.mjsand eachswizzle-proof.<n>.test.mjsstill say one slice per leg.
Claims and files checked
Review mode: full; reason: no-earlier-review
- Claims:
- Leg n runs slices 2n−1 and 2n in one Node test call, is named
swizzle-proof (n/4), and its steps say "this leg's slices": verified (ci.yml:1573,:1603,:1613,:1617). - Vitest runs the pair side by side: verified (no worker limit in
vitest.config.ts; Vitest 4.1 defaults to one worker per CPU minus one). - Admission's full width for the proof is 4 and its tight width stays 2: verified (
ci.yml:208). - The scope job, the start condition, the watchdog, the 15-minute limit, the recorded-time check, the test join and the slice files are unchanged: verified (diff;
ci.yml:1530-1570,:1585,:1609-1612,:1619). - The record keeps each slice's largest time, 348 s for slice 1: verified (
scripts/lib/duration-split.mjs:160-168,scripts/vitest-node-durations.json:1393). - A leg takes about its slower slice plus setup, at most about 470 s: verified as arithmetic (348 s + 120 s), given the parallel run.
- A leg of four would approach the limit on a full-scope run: consistent with the record (four slices on three workers, about 613 s plus setup).
- The shape tests cover one leg per slice file, two per leg, the pair's limit, admission's width, the watchdog and the recorded-time check: verified (
ci-swizzle-proof.test.mjs:49-128). - 176 tests pass across the seven named test files: verified (103 plus 73).
- With
main'sci.ymlthe four new or changed cases fail: verified (4 failed, 3 passed). - Prettier passes: verified. Actionlint passes: not checked (not available to this review; Lint has not run on the draft).
- Four standard
ubuntu-latestrunners instead of eight, and four fewer jobs at full width: verified (ci.yml:1583-1584; the added full-width jobs drop from 6 to 2). - About 110 s of setup, 3.35 minutes a leg, 141 proving runs a day, about 7 runner-minutes and $4.6–6.6 a day saved: not checkable here (CI history); the arithmetic is consistent.
- Time to green stays about the same: consistent (the longest leg stays the slice-1 leg; at tight width the proof runs two waves instead of four).
- Only #8027 also changes
ci.yml, in its native jobs: #8027 verified (open, conflicting, its hunk at line 807); other open pull requests not enumerated.
- Leg n runs slices 2n−1 and 2n in one Node test call, is named
- Files:
.github/workflows/ci.yml: clear (optional: pin the pair's parallel run at line 1613)..github/scripts/ci-swizzle-proof.test.mjs: clear (optional: its header still says one slice per leg).
| export VITEST_SHARD_WATCHDOG_SECONDS | ||
| WATCHDOG=(--reporter=default --reporter=github-actions --reporter=./scripts/vitest-shard-watchdog.mjs) | ||
| pnpm test:node "${WATCHDOG[@]}" packages/cli/test/swizzle-proof/swizzle-proof.${{ matrix.slice }}.test.mjs | ||
| pnpm test:node "${WATCHDOG[@]}" packages/cli/test/swizzle-proof/swizzle-proof.$((2 * LEG - 1)).test.mjs packages/cli/test/swizzle-proof/swizzle-proof.$((2 * LEG)).test.mjs |
There was a problem hiding this comment.
Optional: the leg-limit test in ci-swizzle-proof.test.mjs ("holds a pair of slices inside the leg limit") counts only each pair's slower slice, which is right only while Vitest runs both files at once. Today that comes from Vitest's default of one worker per CPU minus one. Adding --maxWorkers=2 to this command would pin it, so leg 1 never runs its 348 s and 340 s slices one after the other against the watchdog. Pairing slowest with fastest (1+8, 2+7, 3+6, 4+5) would also keep a serial run inside the limit.
|
(Posted by Cindy's agent.) Closing: the swizzle proof no longer runs on pull requests by default (#12449), and on the release-check a slice proves its targets in about 137 s (slice 3: 21 targets, 34 s of it in the browser), so pairing two slices per leg saves no wall time and only a few runner-minutes a day. |
Who this helps
Authors waiting on CI, and CI's budget. A pull request whose change proves a swizzle target runs the swizzle proof in legs of its own, beside the Node legs. Each leg pays about two minutes of checkout, setup and core build before it proves anything, and in the affected scope most slices then prove only a few targets in 15–110 s. Eight legs a run spend about 15 minutes of runner time on setup alone. On 11/15 the proof ran on 141 pull-request runs, 8 legs each: about 3.35 min a leg and about $16.5 a day, roughly half of it setup.
What changes
.github/workflows/ci.yml, theswizzle-proofjob: four legs of two slices each instead of eight legs of one. Leg n runsswizzle-proof.<2n-1>.test.mjsandswizzle-proof.<2n>.test.mjsin onepnpm test:nodecall, so Vitest runs the pair side by side on the leg's runner. Its name isswizzle-proof (n/4), and the steps' names say "this leg's slices".Why a pair fits
The record keeps each slice's largest time; the largest is 348 s (
swizzle-proof.1). Two slices run in parallel, so a leg takes about its slower slice plus setup: at most about 470 s against the 14-minute watchdog. A leg of four would approach the limit on a full-scope run, so the pairing stops at two.Evidence
ci-swizzle-proof.test.mjs:ci-swizzle-proof,ci-admission,ci-test-join,ci-tooling-routing,vitest-shard-sequencer,vitest-node-legsandworkflow-paths. Withmain'sci.yml, the 4 new or changed cases fail.actionlintandprettierpass.CI impact: on a run whose change proves a target, the proof uses four standard
ubuntu-latestrunners instead of eight, and four fewer jobs run at full width. Per run that saves about 4 × 110 s of setup, about 7 runner-minutes. At about 141 such runs a day, that is an estimated $4.6–6.6 a day, depending on how much the paired slices overlap. Time to green: about the same; the slowest leg gains at most the time of its second slice, and fewer legs wait for a runner.Overlap check
Among open pull requests (also checked file by file on those with more than 100 files), only #8027 (native iOS screenshots, last updated 10/25 and already conflicting with
main) also changesci.yml, in its native jobs (around line 807), a different part of the file. No open pull request changesci-swizzle-proof.test.mjs.Overlap checked: #8027 (a different job in ci.yml: the native iOS screenshot jobs)
Owning session: noopbot (a61f66c2), under CI & Release (ca77f950). Land path: the shipper, through merge-guard.