T-9TYJ-audit-pr-fact-status-drift
Status: closed/superseded · Impact: medium · Complexity: small
Task statuses that mirror external facts can silently drift — a task left
in-progress after its PR merged, closed/done with no PR recorded, or
open/ready while its branch already exists on origin. Add report-only fact
checks so drift is detected instead of discovered
(D-3PDM-cross-project-data-model-adoption P9).
Proposed
Section titled “Proposed”Extend the origin-facing task lint surface (task lint-state-origin is the
natural home; a dedicated facts mode is the fallback) with three checks:
in-progress with a merged PR in prs; closed/done with an empty prs;
open/ready with an existing task/T-… branch on origin. Report-only —
close-out remains the procedural mover.
Acceptance criteria
Section titled “Acceptance criteria”- AC-1: an
in-progresstask whoseprsentry is merged is flagged. - AC-2: a
closed/donetask with an emptyprsarray is flagged (warning severity). - AC-3: an
open/readytask whose derivedtask/T-…branch exists on origin is flagged. - AC-4: all three checks are report-only and require network/gh access
explicitly — plain
entities auditgains no network dependency.
Out of scope
Section titled “Out of scope”- Auto-flipping any status (the mover stays procedural close-out).
- Lease reconcile changes — the lease remains the claim authority.
- Deriving
closed/donefrom merged PRs wholesale (DarkFactory’s PRD-226 end-state; not this task).
Dependencies
Section titled “Dependencies”- none
Discovery context
Section titled “Discovery context”D-3PDM-cross-project-data-model-adoptionP9 / finding F2: DarkFactory shipped six status-drift patch PRDs plus a janitorreconcilecommand; the only states that stayed correct were claims and fact-derived views.