Skip to content
SprecherEast
Issue 1425

process: Board status rule as one tested function, with a report-only run

Back to our plan
Done
ciprocesstoolingpriority: highready

Problem

In plain words: the board does not match the real work. A card's column is set by single events and only ever moves forward, so a missed event, an issue assigned but never started, or work that merged without closing its issue leaves the card wrong for good. This first piece writes the one rule that says what each card should be, and reports the differences without moving anything.

Summary of the owner's decision (2026-11-22, Claude session, voice): he approved the reliable-board pattern recorded on #890 and wants the first step to be the status rule as a tested script, run in report-only mode, so he sees what it would change before it is switched on.

Proposed fix

  • One pure function decides a card's status from facts GitHub already records, in this order:
    1. the issue is closed: Done;
    2. an open pull request closes it: In review;
    3. it is claimed (assigned, and a ### [STEP] claim comment names a branch) and not resolved: In progress;
    4. it has the ready label, passes the issue check and has no needs owner: Ready;
    5. anything else that is open: Backlog.
  • The function also returns the reason in one plain sentence, and flags the provable problems without acting on them: assigned but never started (no claim comment, no branch, no pull request); a merged pull request that referenced the issue while the issue is still open; an open epic whose children are all closed; an open child of a closed parent.
  • An epic's status is never taken from its assignee.
  • A report-only command reads every open issue and its card as the planner app and prints, per card, the current status, the status the rule gives, the reason, and any flag. It writes the same table to the workflow's job summary. It changes nothing: no card, no label, no assignee.
  • A manually started job in the planner workflow runs that command. No schedule yet.
  • The existing event-driven moves in scripts/planner-board.mjs keep working unchanged; switching them to the new rule is the next issue.
  • Native first: GitHub's built-in board workflows already set Done and In review and stay as they are; this rule only has to agree with them. No new dependency.

Existing work compared

Searched open and closed issues on 2026-11-22 for board, planner, card, stale, claim, drift and reconcile. #890 holds the approved pattern and stays the record. #941 and #1089 (closed) built the planner app and its event moves, which this extends. #903 (closed) proved the app can read the board. scripts/card-history.mjs reports hand-made moves and is unaffected. Nothing computes a card's status from the whole state of an issue, and nothing reports drift across the board.

Acceptance criteria

  • Not done: A pure, exported function returns { status, reason, flags } for an issue and its facts, with a failing test first for each of the five rows and each flag
  • Not done: A claimed issue with no activity for any length of time still gives In progress
  • Not done: An epic gives its status from its children, never from its assignee
  • Not done: The report command lists every open card whose current status differs from the rule, with the reason and flags, and exits 0 when it could read everything and non-zero when it could not
  • Not done: The report run changes nothing on GitHub, and a test proves the command issues no write
  • Not done: The job can be started by hand from the planner workflow and shows the table in its summary
  • Not done: The board section of how we work says what the rule is and that this run only reports

Files likely touched

scripts/planner-status.mjs, scripts/planner-status.test.mjs, scripts/planner-report.mjs, scripts/planner-report.test.mjs, .github/workflows/planner-board.yml, docs/process/project-management.md

Must not touch

src/, scripts/planner-board.mjs, scripts/planner-rules.mjs, .github/workflows/ci.yml

Open questions

None

Area

tooling, ci

Priority

priority: high


Generated by Claude Code, opens in a new tab

See it on GitHub, opens in a new tab