You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
REGRESSION - BUG FIX - Harden the golden mechanism per adversarial review
Fifteen findings from a line-level adversarial review, the load-bearing ones:
- A --check that finds no golden file for any requested case now exits 1: a green gate
that checked nothing was indistinguishable from a passing one, so a deleted or
typo-named golden file silently disabled CI. Mixed coverage warns per case.
- --update-golden now prints a REMOVED line for every pin it drops: an h5 rename made
extraction return missing, the entry silently vanished from the rewritten file, and
the git diff read like intentional cleanup. Deleting a gate is now loud.
- Golden provenance records "-dirty" when generated from an uncommitted tree; the
commit field is what a reviewer uses to reproduce a disputed number, and it was
recording HEAD for numbers HEAD cannot reproduce.
- save_golden refuses valueless entries (a NaN scalar became a gating entry with a
class and tolerance but no number — failing forever, with regeneration reproducing
it identically). SLAYER gamma is legitimately NaN when no root is found, so this
path is reachable.
- The check path now normalizes SQLite missing before compare_to_golden (the update
path already did); a NULL reaching the === nothing guards crashed the report with a
non-boolean Missing TypeError instead of failing the quantity.
- Tolerance validation runs on every load, not only at write: a hand edit or a merge
taking the wrong side could otherwise ship a gating entry with no finite rtol
(unsatisfiable) or an rtol below its recorded platform_spread (the exact quiet
loosening this mechanism exists to prevent).
- A value_type change resets carry-forward: a topological rtol=0 landing on a float
gates at bit-exactness forever; a float tolerance landing on a count lets it drift.
- A crashed run under --check reports as a crash, not as N tolerance failures.
- Non-finite tolerances short-circuit within (Inf + NaN arithmetic made zero-valued
diagnostic entries compare false); checksums no longer inflate the untracked count;
sing_psi/sing_q reclassified physics_converged (root-found, not pure quadrature);
nstep matched exactly instead of by prefix.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
println(@sprintf(" %-34s REMOVED — extraction returned missing (renamed h5 path?) or the quantity left the case. This deletes its gate; confirm it is intentional.", name))
456
+
end
457
+
end
416
458
for (name, g) insort(collect(values); by=first)
417
459
old =get(existing, name, nothing)
418
460
old ===nothing&& (println(@sprintf(" %-34s NEW", name)); continue)
@@ -449,6 +491,12 @@ function build_golden_values(extracted::Vector{ExtractedQuantity}, specs::Vector
0 commit comments