Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 19 additions & 0 deletions docs/now/2026-08-23-departure-is-not-repair.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# NOW -- a spec leaving the index was scored as a repair (2026-08-23)

Refs #2325.

- `check_specs_generate.py` built `bad` only from `git ls-files "*.t27"`, and
then computed `fixed = known - bad`. That folds two different events into one
congratulation: a spec that started compiling, and a spec that stopped being
TRACKED while still failing on disk.
- Reproduced: untracking a debt spec printed
`NOTE 1 spec(s) in the baseline now generate` and exited 0.
- It has already happened at scale. Commit `2255e4c32` removed 58 ledger lines
with 455 deletions and 0 modifications to the specs themselves; its own
message concedes "those 58 would read as fixed".
- Departure is now its own class: `DEPARTED` is reported by name and fails.
`fixed` is `(known & tracked) - bad`. Control fires; clean tree still exits 0
with 712 specs / 541 generate / 171 known-broken.
- Not fixed here, filed instead: `generates()` returns True on `rc == 0` alone
and never opens the artefact, so a 0-byte spec counts as generating. Two
tracked 0-byte specs exist. That is a bigger change than this one.
26 changes: 25 additions & 1 deletion tools/check_specs_generate.py
Original file line number Diff line number Diff line change
Expand Up @@ -170,13 +170,37 @@ def cls(m):

known = baseline()
new = [(sp, m) for sp, m in bad if sp not in known]
fixed = sorted(known - {sp for sp, _ in bad})

# T69: a spec that LEAVES the index has not been repaired. `bad` is built
# only from `git ls-files "*.t27"`, so `known - bad` folded two very
# different events into one congratulation: a spec that started compiling,
# and a spec that stopped being tracked while still failing on disk.
# Untracking three debt specs printed "NOTE 3 spec(s) in the baseline now
# generate" and exited 0. Commit 2255e4c32 removed 58 ledger lines with 455
# deletions and 0 modifications to the specs themselves -- its own message
# concedes "those 58 would read as fixed". Departure is now its own class,
# and it fails.
tracked = set(all_specs)
departed = sorted(known - tracked)
fixed = sorted((known & tracked) - {sp for sp, _ in bad})
if departed:
print(f"DEPARTED {len(departed)} spec(s) in the baseline are no longer tracked.")
print("They did not start generating -- they left the measured set, which")
print("reads as progress in the count below and is not. Drop their ledger")
print("lines in the same commit that removes them, deliberately:")
for sp in departed[:10]:
print(f" {sp}")
if len(departed) > 10:
print(f" ... and {len(departed) - 10} more")
print()
if fixed:
print(f"NOTE {len(fixed)} spec(s) in the baseline now generate. Remove them from "
f"{BASELINE.name} so the gate holds them:")
for sp in fixed[:10]:
print(f" {sp}")
print()
if departed:
return 1
if not new:
print(f"OK: {len(all_specs)} specs, {len(all_specs)-len(bad)} generate, "
f"{len(bad)} known-broken in {BASELINE.name}")
Expand Down
Loading