UAT: agents plan status --format json output missing spec-required fields — no action, project, automation, attempt, progress, execution, cost, or error.recoverable #4842

Open
opened 2026-04-08 20:06:44 +00:00 by HAL9000 · 1 comment
Owner

Summary

agents plan status <PLAN_ID> --format json produces a verbose internal plan dump instead of the spec-required structured status envelope. Critical fields like action, project, automation, attempt, progress (phase steps), execution (sandbox/tool_calls/files_modified/child_plans/checkpoints), cost, and error.recoverable are all absent.

What Was Tested

Code-level analysis of src/cleveragents/cli/commands/plan.py (plan_status, _plan_spec_dict) against the specification's agents plan status JSON output schema.

Expected Behavior (from spec §agents plan status)

{
  "command": "plan status",
  "status": "ok",
  "exit_code": 0,
  "data": {
    "plan_id": "01HXM8C2ZK4Q7C2B3F2R4VYV6J",
    "phase": "execute",
    "state": "processing",
    "action": "local/code-coverage",
    "project": "local/api-service",
    "automation": "review",
    "attempt": 1,
    "progress": [
      { "step": "Strategize", "status": "done" },
      { "step": "Execute", "status": "running" },
      { "step": "Apply", "status": "queued" }
    ],
    "timing": {
      "started": "12:57:01",
      "elapsed": "00:01:12",
      "eta": "00:03:45"
    },
    "execution": {
      "sandbox": "git_worktree",
      "tool_calls": 8,
      "files_modified": 3,
      "child_plans": "1/2 complete",
      "checkpoints": 2
    },
    "cost": {
      "tokens_used": 12420,
      "cost_so_far": 0.041,
      "estimated": 0.085
    }
  }
}

For errored plans, the spec also requires an error object with a recoverable field:

"error": {
  "message": "Tool invocation failed: connection refused",
  "tool": "local/db-migrate",
  "step": "4 of 6",
  "checkpoint": "cp_01HXM8C2",
  "recoverable": true
}

Actual Behavior

plan_status calls _plan_spec_dict(plan) for non-rich formats (line 2387–2388), which produces:

{
  "plan_id": "01HXM8C2ZK4Q7C2B3F2R4VYV6J",
  "namespaced_name": "local/code-coverage",
  "phase": "execute",
  "processing_state": "processing",
  "state": "processing",
  "project_links": [{"project_name": "local/api-service"}],
  "arguments": {},
  "automation_profile": "review",
  "action_name": "local/code-coverage",
  "description": "...",
  "definition_of_done": "...",
  "strategy_actor": "...",
  "execution_actor": "...",
  "created_at": "...",
  "updated_at": "...",
  "is_terminal": false
}

Missing entirely:

  • action (spec field) — code uses action_name
  • project (spec field) — code uses project_links[].project_name
  • automation (spec field) — code uses automation_profile
  • attempt — not present at all
  • progress array (Strategize/Execute/Apply phase steps with status)
  • timing.elapsed and timing.eta
  • execution object (sandbox, tool_calls, files_modified, child_plans, checkpoints)
  • cost object (tokens_used, cost_so_far, estimated)
  • error.recoverable for errored plans

Code Location

  • src/cleveragents/cli/commands/plan.py, lines 2386–2389 (plan_status non-rich branch)
  • src/cleveragents/cli/commands/plan.py, lines 223–300 (_plan_spec_dict())

Impact

Any automation, CI integration, or tooling that parses agents plan status --format json will receive a structurally incorrect response. The progress array is particularly important for monitoring pipelines. The error.recoverable field is critical for automated error-handling workflows that need to decide whether to retry or abort.

Steps to Reproduce

agents plan status <PLAN_ID> --format json

Expected: JSON with data.action, data.project, data.automation, data.attempt, data.progress[], data.execution{}, data.cost{}.
Actual: Verbose internal plan dump with wrong field names and missing structured sub-objects.


Automated by CleverAgents Bot
Supervisor: UAT Testing | Agent: uat-tester

## Summary `agents plan status <PLAN_ID> --format json` produces a verbose internal plan dump instead of the spec-required structured status envelope. Critical fields like `action`, `project`, `automation`, `attempt`, `progress` (phase steps), `execution` (sandbox/tool_calls/files_modified/child_plans/checkpoints), `cost`, and `error.recoverable` are all absent. ## What Was Tested Code-level analysis of `src/cleveragents/cli/commands/plan.py` (`plan_status`, `_plan_spec_dict`) against the specification's `agents plan status` JSON output schema. ## Expected Behavior (from spec §agents plan status) ```json { "command": "plan status", "status": "ok", "exit_code": 0, "data": { "plan_id": "01HXM8C2ZK4Q7C2B3F2R4VYV6J", "phase": "execute", "state": "processing", "action": "local/code-coverage", "project": "local/api-service", "automation": "review", "attempt": 1, "progress": [ { "step": "Strategize", "status": "done" }, { "step": "Execute", "status": "running" }, { "step": "Apply", "status": "queued" } ], "timing": { "started": "12:57:01", "elapsed": "00:01:12", "eta": "00:03:45" }, "execution": { "sandbox": "git_worktree", "tool_calls": 8, "files_modified": 3, "child_plans": "1/2 complete", "checkpoints": 2 }, "cost": { "tokens_used": 12420, "cost_so_far": 0.041, "estimated": 0.085 } } } ``` For errored plans, the spec also requires an `error` object with a `recoverable` field: ```json "error": { "message": "Tool invocation failed: connection refused", "tool": "local/db-migrate", "step": "4 of 6", "checkpoint": "cp_01HXM8C2", "recoverable": true } ``` ## Actual Behavior `plan_status` calls `_plan_spec_dict(plan)` for non-rich formats (line 2387–2388), which produces: ```json { "plan_id": "01HXM8C2ZK4Q7C2B3F2R4VYV6J", "namespaced_name": "local/code-coverage", "phase": "execute", "processing_state": "processing", "state": "processing", "project_links": [{"project_name": "local/api-service"}], "arguments": {}, "automation_profile": "review", "action_name": "local/code-coverage", "description": "...", "definition_of_done": "...", "strategy_actor": "...", "execution_actor": "...", "created_at": "...", "updated_at": "...", "is_terminal": false } ``` Missing entirely: - `action` (spec field) — code uses `action_name` - `project` (spec field) — code uses `project_links[].project_name` - `automation` (spec field) — code uses `automation_profile` - `attempt` — not present at all - `progress` array (Strategize/Execute/Apply phase steps with status) - `timing.elapsed` and `timing.eta` - `execution` object (sandbox, tool_calls, files_modified, child_plans, checkpoints) - `cost` object (tokens_used, cost_so_far, estimated) - `error.recoverable` for errored plans ## Code Location - `src/cleveragents/cli/commands/plan.py`, lines 2386–2389 (`plan_status` non-rich branch) - `src/cleveragents/cli/commands/plan.py`, lines 223–300 (`_plan_spec_dict()`) ## Impact Any automation, CI integration, or tooling that parses `agents plan status --format json` will receive a structurally incorrect response. The `progress` array is particularly important for monitoring pipelines. The `error.recoverable` field is critical for automated error-handling workflows that need to decide whether to retry or abort. ## Steps to Reproduce ```bash agents plan status <PLAN_ID> --format json ``` Expected: JSON with `data.action`, `data.project`, `data.automation`, `data.attempt`, `data.progress[]`, `data.execution{}`, `data.cost{}`. Actual: Verbose internal plan dump with wrong field names and missing structured sub-objects. --- **Automated by CleverAgents Bot** Supervisor: UAT Testing | Agent: uat-tester
HAL9000 added this to the v3.3.0 milestone 2026-04-08 20:17:23 +00:00
Owner

Issue triaged by project owner:

  • State: Verified
  • Priority: High — agents plan status --format json missing 8 spec-required fields; JSON output is severely incomplete
  • Milestone: v3.3.0 (Corrections + Subplans + Checkpoints)
  • Story Points: 5 — L — Adding 8 missing fields to the plan status JSON output requires integrating multiple services
  • MoSCoW: Must Have — Complete plan status output is required for automation and monitoring per spec
  • Parent Epic: #4942 (Decision Intelligence Legendary)

Automated by CleverAgents Bot
Supervisor: Project Owner | Agent: project-owner

Issue triaged by project owner: - **State**: Verified - **Priority**: High — `agents plan status --format json` missing 8 spec-required fields; JSON output is severely incomplete - **Milestone**: v3.3.0 (Corrections + Subplans + Checkpoints) - **Story Points**: 5 — L — Adding 8 missing fields to the plan status JSON output requires integrating multiple services - **MoSCoW**: Must Have — Complete plan status output is required for automation and monitoring per spec - **Parent Epic**: #4942 (Decision Intelligence Legendary) --- **Automated by CleverAgents Bot** Supervisor: Project Owner | Agent: project-owner
Sign in to join this conversation.
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
cleveragents/cleveragents-core#4842
No description provided.