Skip to content

Wire DagScheduler execution into /plan confirm flow #1434

@bug-ops

Description

@bug-ops

Summary

/plan confirm currently attempts immediate aggregation without first executing the plan tasks through the DagScheduler. This causes aggregation failed: no completed or skipped tasks to aggregate because no tasks have been run.

Current Behavior

  1. /plan goal <text> → LlmPlanner decomposes into TaskGraph (works)
  2. /plan confirm → tries LlmAggregator::aggregate() immediately → fails because graph has 0 completed tasks
  3. Error message: "Plan confirmed. Execution and aggregation will run when the scheduler is wired."

Expected Behavior

  1. /plan goal <text> → creates TaskGraph (already works)
  2. /plan confirm → runs DagScheduler to execute tasks → then aggregates results
  3. Results shown to user

Root Cause

handle_plan_confirm() in agent/mod.rs:587 has a comment: "In a future integration phase the scheduler will run first; for now we aggregate whatever results are already present in the graph."

The DagScheduler (orchestration/scheduler.rs) and the AgentRouter (orchestration/router.rs) exist and are unit-tested but are not wired into the confirm flow.

Additional Issue

/plan list returns "No recent plans" even when a plan is awaiting confirmation. The pending graph is stored in self.pending_graph but /plan list apparently looks elsewhere.

Environment

  • v0.14.1, orchestration.enabled=true, provider=claude haiku-4.5

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions