Match the record to what the owners were told, and stop the tracker hiding ids

RISK-F-0002's fix_tracking now names ZONE-WP-0001 / WARDEN-WP-0032, with
the superseded pair kept beside it — the register had told ops-warden the
path had changed and then left the old ids in the file.

An unresolvable fix_tracking (TEN-IN-0002 is an intake, not a workplan)
printed nothing at all, which reads identically to a finding with no
tracking. It now says so by name. Both ZONE-WP-0001 and WARDEN-WP-0032
read proposed, which is the true state of the successor.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
tegwick 2026-08-21 09:34:57 +02:00
parent 78d4914808
commit 623f7ccb2e
2 changed files with 9 additions and 2 deletions

View file

@ -83,7 +83,13 @@ def report() -> list[str]:
if not tracking or str(tracking).startswith("unset"):
lines.append(f"{f['id']} ({f.get('severity')}) — NO FIX TRACKING; owner {f.get('fix_owner')}")
continue
for r in resolve(tracking):
resolved = resolve(tracking)
if not resolved:
# An id the tracker cannot parse is not the same as no tracking, and
# silently printing neither is how a gap hides.
lines.append(f"{f['id']} — fix_tracking '{tracking}' names no workplan this tool can resolve")
continue
for r in resolved:
if r["moved"]:
age = (now - r["moved"]).days
window = STALL_DAYS.get(f.get("severity"), 30)