fix(kanban): recover blocked implementations into review - #87385
fix(kanban): recover blocked implementations into review#87385manjaroblack wants to merge 2 commits into
Conversation
fix(kanban): recover blocked implementations into review This is a substantial, well-structured change: the provider verification runs outside the write transaction (no board lock held during provider latency), the final status change is a compare-and-swap with an append-only
No blocking issues found. |
0cd220b to
3849adb
Compare
Prefer exact reviewer assignees over a broad title regex so children like "release-candidate" stay in the implementation lane. Bound the active-PR comment scan to the 24h window while still fail-closing on malformed timestamps. Treat a rate_limited run with missing ended_at as elapsed so the card cannot park forever.
|
Addressed the non-blocking notes in 0f7298c:
Item 4 is unchanged: the newest block event remains authoritative so an unrelated later block cannot revive an older handoff. |
What does this PR do?
When a Kanban implementation worker finishes a green, open, non-draft PR after the card has already entered
blocked,kanban_completeis rejected as a terminal state. Manually unblocking the card leaves it in the ready implementation lane, where theactive_prrespawn guard correctly refuses to spawn another implementer. The work then sits blocked with no path into independent review.This change recovers that one state automatically: structured immutable PR evidence plus a live provider check (open, non-draft, exact head, required checks green) routes the card to the configured review lane. Free-form comments cannot promote. Missing, draft, closed, diverged, red, pending, or unknown evidence stays blocked with an actionable diagnostic. Ordinary unblock of a card that already has a PR still does not respawn the implementer. Same-card review and a pre-created downstream review child remain mutually exclusive.
changes_requestedrework on the existing PR is unchanged.Related Issue
No existing issue covered this lifecycle hole. Opened as a focused bug fix rather than expanding #42896 (first-class request-review transition).
Type of Change
Changes Made
hermes_cli/kanban_review_recovery.py— immutable evidence parsing and live GitHub PR/check validationhermes_cli/kanban_db.py— blocked-completion recovery, graph-exclusive review routing, CAS/event audit, structuredactive_prguardhermes_cli/kanban.py,tools/kanban_tools.py,agent/prompt_builder.py,hermes_cli/config_defaults.py— CLI, tool, prompt, and config surfacestests/hermes_cli/test_kanban_blocked_review_recovery.py— positive recovery, negative evidence, lane exclusivity, rework, concurrency, and persistencewebsite/docs/user-guide/features/kanban-worker-lanes.md— operator note for the recovery handoffHow to Test
blocked, then later has structuredreview_evidencefor an open non-draft PR whose exact head is green. Confirm the dispatcher now emitsreview_recovery_routedand does not spawn the implementer.blockedwithreview_recovery_blockedand an actionable reason.active_prafter ordinary unblock.changes_requestedstill returns the existing PR to the implementer without opening a second PR.Checklist
Code
fix(scope):,feat(scope):, etc.)scripts/run_tests.sh) for the Kanban/CLI/gateway slice aboveDocumentation & Housekeeping
docs/, docstrings) — or N/Acli-config.yaml.exampleif I added/changed config keys — or N/ACONTRIBUTING.mdorAGENTS.mdif I changed architecture or workflows — or N/A