Skip to content

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).

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.

  • AC-1: an in-progress task whose prs entry is merged is flagged.
  • AC-2: a closed/done task with an empty prs array is flagged (warning severity).
  • AC-3: an open/ready task whose derived task/T-… branch exists on origin is flagged.
  • AC-4: all three checks are report-only and require network/gh access explicitly — plain entities audit gains no network dependency.
  • Auto-flipping any status (the mover stays procedural close-out).
  • Lease reconcile changes — the lease remains the claim authority.
  • Deriving closed/done from merged PRs wholesale (DarkFactory’s PRD-226 end-state; not this task).
  • none
  • D-3PDM-cross-project-data-model-adoption P9 / finding F2: DarkFactory shipped six status-drift patch PRDs plus a janitor reconcile command; the only states that stayed correct were claims and fact-derived views.

← Back to Tasks