Repository navigation
fix(free-ci-health): a split shard's overrun compares wall time with its per-job prediction (#3851) - #4051
fix(free-ci-health): a split shard's overrun compares wall time with its per-job prediction (#3851)#4051prascli wants to merge 2 commits into
Conversation
…its per-job prediction (garrytan#3851) The shard-overrun warning compared a shard's wall clock (`elapsedMs`) with the plan's `predictedMs`, which is the shard's serial seed sum. At `--shard-jobs k` the k sub-shards run in parallel, so a healthy shard finishes in about `predictedMs / k`: at k=4 the 1.5x factor only fired after roughly a 6x slowdown, and the signal was blind exactly where shard-splitting is used. `shardOverruns` now divides the prediction by the shard's k, `ciHealthSummary` passes the plan shard's `jobs` through, and the warning names the parallel job count so the number it prints is the wall time it compared. k=1 output is unchanged. `docs/TESTING_INTERNALS.md` states the wall-time rule. Tests cover a k=4 shard warning at 1.5x its 100 s wall prediction and staying quiet at 1.2x, and the `--ci-verify` summary carrying the plan's k.
|
Merging to
After your PR is submitted to the merge queue, this comment will be automatically updated with its status. If the PR fails, failure details will also be posted here |
…me with its per-job prediction)
|
Added What I could verify locally, on this branch cherry-picked onto
All eight workflows on 1d46e6f are still |
…rediction over jobs (GST-1653) (#4085) shardOverruns compared a shard's wall-clock elapsedMs with predictedMs, the shard's serial seed sum. free-tests.yml plans every shard at --shard-jobs 4, so the 1.5x warning only fired after about a 6x slowdown. The prediction is now divided by the plan shard's jobs, ciHealthSummary carries jobs through, and the warning names the parallel job count. k=1 output is unchanged. Rewritten on main from #4051, which fixes #3851. Co-authored-by: Indra Prasetya <[email protected]> Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
|
Thanks @indraoverflow, good catch: the shard-overrun warning was comparing wall time with a serial prediction, so on 4-job shards it was effectively off. We rebuilt it on current main in #4085, which merged as 115e245 with you credited as co-author. Closing this one as superseded; it also resolves #3851. |
|
Note for anyone landing here later: I renamed my GitHub account from For any future attribution of this work, the correct identity is: The fix itself landed in #4085. |
Closes the gap described in #3851.
What changed
--ci-verify's shard-overrun warning compared two different units.plan.shards[].predictedMsis the shard's serial seed sum (the packing load), whileoutcome.elapsedMsis the shard's wall clock. At--shard-jobs kthe k sub-shards run in parallel andmergeSubShardOutcomesrecords the group's wall time, so a healthy shard finishes in aboutpredictedMs / k. At k=4 the 1.5x factor therefore only fired after roughly a 6x slowdown, and the signal was blind exactly where shard splitting is used.shardOverrunstakes an optionaljobsand measureselapsedMsagainstpredictedMs / max(1, jobs).ciHealthSummarypasses the plan shard'sjobsthrough, so the--ci-verifyjob summary uses the same wall expectation.overrunWarningnames the parallel job count, so the number it prints is the wall time it compared. k=1 output is byte-identical.docs/TESTING_INTERNALS.mdstates the wall-time rule next to the 1.5x / 30 s thresholds.No behavior change when a plan has no
jobs(k=1), which is the default and every plan written before--shard-jobs.Verification
The new cases fix the reported failure mode: a 400 s serial seed over 4 parallel jobs that takes 160 s (1.6x its 100 s wall prediction) now warns, where before it needed 600 s.