Add tests and docs for in_review stage unblocking dependency-edge dependents#548
Conversation
Co-authored-by: SorraTheOrc <250240+SorraTheOrc@users.noreply.github.com>
|
@copilot this PR does not seem to change the behaviour of the application, only the tests. How does this PR achive the goal of unblocking items when blockers move to in_review. How is it the tests introduced pass if the code itself has not changed? |
You’re right that this PR does not change runtime logic. The behavior was already present before this branch: |
isDependencyActive()already treatsin_reviewanddonestages as non-blocking for dependency edges, but this was untested and undocumented. This PR surfaces that behavior with test coverage and updated docs.Tests
Unit (
tests/database.test.ts) — newin_review stage unblocking (dependency edges only)block:in_reviewunblocks dependentin_reviewunblocks dependentin_review+completedblockersin_reviewtoin_progressCLI integration (
tests/cli/issue-management.test.ts) — three end-to-end scenarios exercisingupdate --status completed --stage in_reviewtriggering reconciliation (single blocker, partial multi-blocker, all-blockers).Docs
CLI.md: updated automatic unblocking blurb to namein_reviewanddonestages explicitly as non-blocking.docs/dependency-reconciliation.md: expanded behaviour table within_reviewrows, updatedisDependencyActivedescription, updated test coverage section. Includes a callout that this applies to dependency edges only — parent/child relationships are unaffected.Original prompt
This section details on the original issue you should resolve
<issue_title>Items should be unblocked when all clockers are moved to done or in_review</issue_title>
<issue_description>
Headline: Unblock dependents when dependency edges move to in_review or done
Problem statement
Currently blocked work items are automatically unblocked when all blocking items are marked as completed/done. We should also treat dependency edges whose targets have moved to stage
in_review(or equivalent non-blocking states) as resolved for the purpose of unblocking dependent items — but only for explicit dependency edges (not parent/child relationships).Users
wl next,wl search) without manual changes.in_review.wl nextor filtered queries should surface items consistently when blockers become non-blocking.Example user stories
in_revieworcompleted, I can see the dependent item becomeopenand therefore actionable.Success criteria
in_reviewor to a completed/done status, its dependents are markedopenif no other active blockers remain.CLI.mdand developer docs with a concise note describing thatin_reviewis treated as non-blocking for dependency edges.Constraints
in_reviewfor dependency-edge unblocking.in_reviewas a non-blocking condition rather than a broad refactor.Existing state
completed/deleted(seetests/database.test.tsand related CLI tests). CLI/TUI paths call into the same reconciliation logic in the database layer.Desired change
in_reviewis treated as non-blocking for dependent items.CLI.md) and a short developer note (e.g.,docs/dependency-reconciliation.md) describing the change and rationale.Related work
src/database.ts— containsreconcileDependentsForTarget()and core unblock logic (implementation reference).tests/database.test.ts— existing tests for unblock behaviour (examples and locations: unblock tests around lines ~476–620).CLI.md— documentation mentioning automatic unblocking (lines referencing unblock behaviour).Open questions
in_reviewand completed/done as non-blocking for dependency edges.Acceptance / next step for this intake
Please review this draft and either approve or provide targeted edits (short clarifications are best). After your approval I will run the five intake review passes, update the work item description, and add a related-work report.
Risks & assumptions
in_reviewas non-blocking could surface dependents prematurely if review uncovers ...💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.