diff --git a/workplans/STATE-WP-0083-forge-derived-projection-reset.md b/workplans/STATE-WP-0083-forge-derived-projection-reset.md index d64be5a..498bf06 100644 --- a/workplans/STATE-WP-0083-forge-derived-projection-reset.md +++ b/workplans/STATE-WP-0083-forge-derived-projection-reset.md @@ -397,3 +397,49 @@ Two things this exposed, neither yet addressed: stale pid, so its health signal did not reflect the dropped connection. A tunnel monitor that cannot detect the failure it exists to detect is the same defect class as a projection that cannot name its source commit. + + +## Repair workplan files whose frontmatter never terminates + +```task +id: STATE-WP-0083-T08 +status: todo +priority: high +``` + +**Blocks the first production reset.** Found 2026-08-26 by reviewing the reset's +diff before applying it — the diff proposed retiring `kont-wp-0015`, a live and +correctly registered workplan, which is what prompted the investigation. + +Eighteen workplan files across the fleet have a closing `---` fused onto the last +frontmatter value: + +```yaml +depends_on_workplans: + - KONT-WP-0016--- +``` + +There is no delimiter line, so the frontmatter never terminates. The file +declares a dependency on a workplan literally named `KONT-WP-0016---` and the +entire body is swallowed as frontmatter. Any parser selecting on `type: workplan` +sees nothing, so the file is not merely unparsed but *invisible* — it appears as +neither a workplan nor an error. + +Affected: `citation-evidence` (5), `infospace-bench` (2), `kontextual-engine`, +`net-kingdom` (2 incl. archived), and others — 18 in total. + +The consequence for reset is severe and must not be worked around: a repository +containing one of these files derives a projection missing that workplan, so the +reset proposes retiring a record that is entirely correct. Running it before this +is repaired would retire live work. + +That the refusal-by-default caught this is the design working, but the diff would +have looked plausible to anyone not checking a specific record — `created=0, +would_retire=N` reads like a tidy-up. + +Repair the frontmatter, then re-derive and confirm each affected repository's +diff no longer proposes retiring live workplans. + +Acceptance: no workplan file yields empty frontmatter while starting with `---`; +the reset diff for each affected repository proposes retiring only records whose +backing file genuinely no longer exists.