Current Behavior
When a task is archived via archive_task, dependent child tasks are left permanently stuck in todo — recompute_ready only checks for status == 'done', so an archived parent never satisfies the gate.
1. create parent A
2. create child B with parent=A, child C with parent=A
3. archive A
→ B and C stay todo forever (recompute_ready promotes 0 tasks)
There is no warning when archiving a task that has dependent children. The user archives a parent, forgets about the children, and they silently rot in todo.
Proposed Solution
When archive_task is called on a task that has dependent child tasks (non-archived children linked via task_links), give the user a choice:
Task 'A' has 2 dependent child tasks: B, C.
What should happen to them?
[1] Unlink — remove the dependency on A and let them proceed
[2] Archive — also archive B and C
[3] Cancel — don't archive A either
Implementation sketch:
- A new helper
dependent_child_ids(conn, parent_id) -> list[str] queries children
- The caller checks before calling
archive_task
- If children exist, present the choice; if none, archive immediately
This is an interaction change — no modification to dependency resolution semantics.
Alternative / Follow-up
A simpler variant is warning-only. Separately, whether archived should be treated as terminal for dependency resolution (child auto-promotes) can be discussed as its own follow-up.
References
Current Behavior
When a task is archived via
archive_task, dependent child tasks are left permanently stuck intodo—recompute_readyonly checks forstatus == 'done', so anarchivedparent never satisfies the gate.There is no warning when archiving a task that has dependent children. The user archives a parent, forgets about the children, and they silently rot in
todo.Proposed Solution
When
archive_taskis called on a task that has dependent child tasks (non-archived children linked viatask_links), give the user a choice:Implementation sketch:
dependent_child_ids(conn, parent_id) -> list[str]queries childrenarchive_taskThis is an interaction change — no modification to dependency resolution semantics.
Alternative / Follow-up
A simpler variant is warning-only. Separately, whether
archivedshould be treated as terminal for dependency resolution (child auto-promotes) can be discussed as its own follow-up.References
archive_task:hermes_cli/kanban_db.pyrecompute_ready:hermes_cli/kanban_db.py