Commit 6a1e382
ci: red the Test Core shard when its predicted time stops matching the measured one (#16220)
* wip(devx): partition-test-shards gains --check-drift (predicted vs measured)
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Vbw3RPgdtqesx4azk9SbW8
* wip(devx): wire --check-drift into the Test Core shard job
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Vbw3RPgdtqesx4azk9SbW8
* feat(devx): red the Test Core shard when its predicted time stops matching the measured one
scripts/test-shard-timings.json is generated and nothing re-measured it, so it
rots in one direction only: suites get slower, the file stays put, and the shard
that drifted heavy reads as perfectly balanced right up until the 30-minute wall
kills it. Measured on run 34009395649: @objectstack/cli predicted 458.15s, ran
1231.52s (2.69x) while the split's own banner read max/mean 1.00x.
partition-test-shards.mjs gains --check-drift, and every Test Core shard now runs
it over the summary --summarize has just written. It reuses the generator's
samplesFromSummary so a cache replay cannot be read as a fast suite, compares
only the intersection of measured-and-predicted packages, and reports NOT
MEASURED as its own verdict rather than as a pass.
The bound is 1.5x, where the populations separate on green merge_group build
34013842594: five healthy shards at 0.69-1.18x, the drifted one at 1.74x.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Vbw3RPgdtqesx4azk9SbW8
* feat(devx): shard @objectstack/cli below package granularity as file-level slice items
The partitioner's own pin 3 names this remedy: no split at any shard count can
bin a package that exceeds 1.3x the mean, and @objectstack/cli measured 1231.52s
against a 800.7s post-refresh mean. A shard item is now a package OR a k/n slice
of one; the slice count is derived from that measurement rather than picked, and
the balancing pins bin the sliced items so the pending dataset refresh lands
instead of reding them.
The generator gains the other half: turbo records a run's passthrough argv per
task as `cliArguments`, so a package's slices are reassembled (summed) into one
whole-package weight before the median rule sees it. Without that, the next
refresh would record the heaviest suite at 1/n of its real cost.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Vbw3RPgdtqesx4azk9SbW8
* feat(devx): ci.yml and the completeness join understand a file-level shard item
A shard item is now a package or a package plus a k/n slice. turbo applies a
passthrough run-wide, so a slice cannot share an invocation with packages that
own fewer test files than n -- the whole packages keep one turbo run and each
slice gets its own, filtered to the one package it slices. Each leg tees to its
own log because run-with-stall-guard truncates, and the legs are concatenated
even when one failed, which is when the completeness guard earns its keep.
The scheduled join folds items to package names (an unfolded one reaches
describe() as a package the turbo ls document never listed, and the guard
refuses the whole shard over it), and parseRunCompleted folds every roster line
rather than the last, so a completed second invocation cannot vouch for a first
that stopped early.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Vbw3RPgdtqesx4azk9SbW8
* fix(devx): assembling the shard log must not replace the suite's exit status
A leg whose stall guard never got far enough to open its log would make `cat`
non-zero, and under `set -e` that becomes the step's exit code -- the step would
report the wrong reason for its own red, on exactly the failure path this job
exists to describe.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Vbw3RPgdtqesx4azk9SbW8
* fix(devx): --check-drift predicts from the slice the SUMMARY records, not the config
A package's slice count for the drift comparison now comes from the run's own
`cliArguments`, so a package the summaries show running WHOLE is charged the
whole dataset entry. FILE_SHARDED_PACKAGES stays the default for callers with no
run in hand. The two agree on a Test Core shard; only the observed one is right
anywhere else -- a developer running the CLI suite locally runs it whole, and
charging that a half-sized prediction reported a ~2x drift that was purely this
function's arithmetic.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Vbw3RPgdtqesx4azk9SbW8
* docs(devx): the log-assembly comment names the construct that is actually there
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Vbw3RPgdtqesx4azk9SbW8
* ci(devx): hold the drift step's CI wiring until the dataset refresh lands with it
The --check-drift mode, its self-tests and its ablation stay on the branch; only
this one invocation waits. With scripts/test-shard-timings.json still stale for
@objectstack/cli, wiring it today reds the shard carrying a CLI slice on every
PR -- a true reading that blocks everything until the refresh.
The file-level split already removes the urgent hazard on its own: the worst
shard goes from ~1445s (80% of the 30-minute wall) to ~1059s (59%) with the
dataset untouched, because the CLI is halved across two runners instead of
falling on one. The refresh and this step land together in the follow-up, and
the comment left in place says so rather than leaving the mode looking forgotten.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Vbw3RPgdtqesx4azk9SbW8
* docs(devx): separate the withheld-drift-step note from the completeness guard's
The two comment blocks ran together, so the completeness guard's rationale read
as part of the drift note.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Vbw3RPgdtqesx4azk9SbW8
---------
Co-authored-by: Claude <noreply@anthropic.com>1 parent 8adb9e8 commit 6a1e382
4 files changed
Lines changed: 1175 additions & 30 deletions
File tree
- .github/workflows
- scripts
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
539 | 539 | | |
540 | 540 | | |
541 | 541 | | |
542 | | - | |
| 542 | + | |
543 | 543 | | |
544 | 544 | | |
545 | 545 | | |
| |||
587 | 587 | | |
588 | 588 | | |
589 | 589 | | |
590 | | - | |
591 | 590 | | |
592 | | - | |
593 | | - | |
594 | | - | |
| 591 | + | |
| 592 | + | |
| 593 | + | |
| 594 | + | |
| 595 | + | |
| 596 | + | |
| 597 | + | |
| 598 | + | |
| 599 | + | |
| 600 | + | |
| 601 | + | |
| 602 | + | |
| 603 | + | |
| 604 | + | |
| 605 | + | |
| 606 | + | |
| 607 | + | |
| 608 | + | |
| 609 | + | |
| 610 | + | |
| 611 | + | |
| 612 | + | |
| 613 | + | |
| 614 | + | |
| 615 | + | |
| 616 | + | |
| 617 | + | |
| 618 | + | |
| 619 | + | |
| 620 | + | |
| 621 | + | |
| 622 | + | |
| 623 | + | |
| 624 | + | |
| 625 | + | |
| 626 | + | |
| 627 | + | |
| 628 | + | |
| 629 | + | |
| 630 | + | |
| 631 | + | |
| 632 | + | |
| 633 | + | |
| 634 | + | |
| 635 | + | |
| 636 | + | |
| 637 | + | |
| 638 | + | |
| 639 | + | |
| 640 | + | |
| 641 | + | |
| 642 | + | |
| 643 | + | |
| 644 | + | |
| 645 | + | |
| 646 | + | |
| 647 | + | |
| 648 | + | |
| 649 | + | |
| 650 | + | |
| 651 | + | |
| 652 | + | |
595 | 653 | | |
596 | 654 | | |
597 | 655 | | |
| |||
635 | 693 | | |
636 | 694 | | |
637 | 695 | | |
| 696 | + | |
| 697 | + | |
| 698 | + | |
| 699 | + | |
| 700 | + | |
| 701 | + | |
| 702 | + | |
| 703 | + | |
| 704 | + | |
| 705 | + | |
| 706 | + | |
| 707 | + | |
| 708 | + | |
| 709 | + | |
| 710 | + | |
| 711 | + | |
| 712 | + | |
| 713 | + | |
| 714 | + | |
| 715 | + | |
| 716 | + | |
| 717 | + | |
| 718 | + | |
| 719 | + | |
| 720 | + | |
638 | 721 | | |
639 | 722 | | |
640 | 723 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
144 | 144 | | |
145 | 145 | | |
146 | 146 | | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
147 | 153 | | |
148 | 154 | | |
149 | 155 | | |
| |||
298 | 304 | | |
299 | 305 | | |
300 | 306 | | |
| 307 | + | |
| 308 | + | |
| 309 | + | |
| 310 | + | |
| 311 | + | |
| 312 | + | |
| 313 | + | |
| 314 | + | |
| 315 | + | |
| 316 | + | |
| 317 | + | |
| 318 | + | |
| 319 | + | |
| 320 | + | |
| 321 | + | |
| 322 | + | |
| 323 | + | |
| 324 | + | |
| 325 | + | |
| 326 | + | |
| 327 | + | |
| 328 | + | |
| 329 | + | |
| 330 | + | |
| 331 | + | |
301 | 332 | | |
302 | 333 | | |
303 | 334 | | |
| 335 | + | |
| 336 | + | |
| 337 | + | |
| 338 | + | |
| 339 | + | |
| 340 | + | |
| 341 | + | |
| 342 | + | |
304 | 343 | | |
305 | 344 | | |
306 | 345 | | |
307 | 346 | | |
308 | | - | |
| 347 | + | |
| 348 | + | |
| 349 | + | |
309 | 350 | | |
310 | 351 | | |
311 | 352 | | |
| |||
596 | 637 | | |
597 | 638 | | |
598 | 639 | | |
599 | | - | |
| 640 | + | |
600 | 641 | | |
601 | 642 | | |
602 | 643 | | |
| |||
956 | 997 | | |
957 | 998 | | |
958 | 999 | | |
| 1000 | + | |
| 1001 | + | |
| 1002 | + | |
| 1003 | + | |
| 1004 | + | |
| 1005 | + | |
| 1006 | + | |
| 1007 | + | |
| 1008 | + | |
| 1009 | + | |
| 1010 | + | |
| 1011 | + | |
| 1012 | + | |
| 1013 | + | |
| 1014 | + | |
| 1015 | + | |
| 1016 | + | |
| 1017 | + | |
| 1018 | + | |
| 1019 | + | |
| 1020 | + | |
| 1021 | + | |
| 1022 | + | |
| 1023 | + | |
| 1024 | + | |
| 1025 | + | |
| 1026 | + | |
| 1027 | + | |
| 1028 | + | |
| 1029 | + | |
| 1030 | + | |
| 1031 | + | |
| 1032 | + | |
| 1033 | + | |
| 1034 | + | |
| 1035 | + | |
| 1036 | + | |
| 1037 | + | |
| 1038 | + | |
| 1039 | + | |
| 1040 | + | |
| 1041 | + | |
| 1042 | + | |
| 1043 | + | |
| 1044 | + | |
| 1045 | + | |
| 1046 | + | |
| 1047 | + | |
| 1048 | + | |
| 1049 | + | |
| 1050 | + | |
| 1051 | + | |
| 1052 | + | |
| 1053 | + | |
| 1054 | + | |
| 1055 | + | |
| 1056 | + | |
959 | 1057 | | |
960 | 1058 | | |
961 | 1059 | | |
| |||
1059 | 1157 | | |
1060 | 1158 | | |
1061 | 1159 | | |
1062 | | - | |
1063 | | - | |
1064 | | - | |
1065 | | - | |
| 1160 | + | |
| 1161 | + | |
| 1162 | + | |
| 1163 | + | |
| 1164 | + | |
| 1165 | + | |
1066 | 1166 | | |
1067 | 1167 | | |
1068 | 1168 | | |
| |||
0 commit comments