* Topology predicate: does this workspace still have child agent-task nodes in config? * Unlike hasActiveDescendantAgentTasks (which checks runtime activity for scheduling), * this checks structural tree shape — any child node blocks parent deletion regardless * of its status.
(index: AgentTaskIndex, workspaceId: string)
| 6941 | * of its status. |
| 6942 | */ |
| 6943 | private hasChildAgentTasks(index: AgentTaskIndex, workspaceId: string): boolean { |
| 6944 | return (index.childrenByParent.get(workspaceId)?.length ?? 0) > 0; |
| 6945 | } |
| 6946 | |
| 6947 | private getTaskDepth( |
| 6948 | config: ReturnType<Config["loadConfigOrDefault"]>, |
no test coverage detected