Skip to content

fix(sync): walk full origin/main + accept run-K-rated/ subdirs#38

Merged
FumingPower3925 merged 1 commit into
mainfrom
fix/index-sync-rated-subdirs
Jun 6, 2026
Merged

fix(sync): walk full origin/main + accept run-K-rated/ subdirs#38
FumingPower3925 merged 1 commit into
mainfrom
fix/index-sync-rated-subdirs

Conversation

@FumingPower3925

Copy link
Copy Markdown
Contributor

Companion to goceleris/probatorium#183 — two fixes to the docs ingest for the v1.4.15 baseline.

Fix 1: index-sync walked a truncated tree

The sync-benchmarks workflow's 'Sync committed cell to working tree' step ran git checkout $COMMIT -- results/, which REPLACED the local results/ with the single commit's delta. So when the publisher pushed a single new cell (run-K), the workflow then ran update-index.mjs against a tree that held ONLY that cell — the rebuilt index listed just that one run-K even when run-1 + run-2 + run-3 were all on disk. Symptom: the published index for v1.4.15/20260605 only listed run-2.

Fix: fetch origin/main and check out the entire branch's results/ so the local working tree holds the FULL tree. update-index.mjs's whole-tree walk is then authoritative.

Fix 2: rate-rated subdirs aren't enumerated

The companion probatorium PR publishes the rated pass to a sibling run-K-rated/ subdir so it never clobbers the saturation grid at run-K/. listRuns / runCmp in lib/results.mjs only matched run-\d+; the new subdirs were invisible to the walker.

Fix:

  • listRuns regex extended to /^run-\d+(?:-rated)?$/
  • runCmp splits run ids into [k, variant] and sorts k numerically with variant as the tiebreak ("" < "rated" < any future variant), so the canonical order is run-1, run-1-rated, run-2, run-2-rated, .... A future run-K-soak variant would naturally land after the rated one with no comparator change.
  • default_run still resolves to run-1 (DEFAULT_RUN) — a rated subdir is NEVER picked as the default; the saturation grid at run-K is.

Tests

selftest.mjs extended with a multi-cell case that mirrors a 3-pass saturation + 3-pass rated back-to-back run (run-2, run-2-rated, run-3, run-3-rated):

  • validates each cell against its own dispatch payload
  • asserts the index enumerates all four in the right order
  • asserts the rated subdirs each carry their own files pointers (proves the rated pass didn't clobber the saturation grid at run-K)
  • asserts default_run still picks the lowest run-K (run-2) when run-1 is absent

All assertions pass.

Two fixes to the docs ingest for the v1.4.15 baseline:

1. The sync-benchmarks workflow's 'Sync committed cell to working
   tree' step was running 'git checkout $COMMIT -- results/', which
   replaced the local results/ with the single commit's delta. When
   the publisher pushed a single new cell (run-K), the workflow
   then ran update-index.mjs against a tree that held ONLY that
   cell, so the rebuilt index listed just that one run-K (e.g. only
   run-2 even when run-1 + run-2 + run-3 were on disk). Fix: fetch
   origin/main and check out the entire branch's results/ so the
   local working tree holds the FULL tree (every previously-
   published cell) and update-index.mjs's whole-tree walk is
   authoritative.

2. listRuns / runCmp in lib/results.mjs now accept the new
   run-K-rated/ subdirs a back-to-back rated pass publishes to
   (companion change in probatorium mage_tier.go). The regex
   extension is 'run-\d+(?:-rated)?' and the sort comparator
   breaks ties on the optional variant suffix lexicographically
   so a future 'run-K-soak' would naturally land after 'run-K-rated'
   with no comparator change. The default_run logic still resolves
   to 'run-1' (DEFAULT_RUN) — a rated subdir is not picked as the
   default; the saturation grid at run-K is.

Selftest: extended scripts/selftest.mjs with a multi-cell case
that mirrors a 3-pass saturation + 3-pass rated back-to-back run
(run-2, run-2-rated, run-3, run-3-rated), validates each cell
against its own dispatch payload, and asserts the index enumerates
all four in the right order with the rated subdirs carrying their
own files pointers.
@FumingPower3925 FumingPower3925 merged commit ba6ee52 into main Jun 6, 2026
1 check passed
@FumingPower3925 FumingPower3925 deleted the fix/index-sync-rated-subdirs branch June 6, 2026 13:34
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