UAT: agents plan rollback Rich output format doesn't match spec — missing panels, checkpoint label, side effects, and actor state #3445

Open
opened 2026-04-05 16:52:28 +00:00 by freemo · 1 comment
Owner

Background and Context

During UAT testing of the checkpoint-rollback-system feature area, a code-level analysis of src/cleveragents/cli/commands/plan.py lines 3424–3434 against the spec's agents plan rollback Command → Output Formatting section revealed that the Rich output format is substantially incomplete and does not match the spec.

Current Behavior

The current output implementation:

console.print(
    f"[green]Rollback complete.[/green]\n"
    f"  Plan: {plan_id}\n"
    f"  Checkpoint: {result.from_checkpoint_id}\n"
    f"  Restored files: {result.restored_files_count}\n"
    f"  Elapsed: {elapsed:.3f}s\n"
    f"  Changed paths:"
)
for path in result.changed_paths:
    console.print(f"    {path}")

Missing elements:

  1. Rich Panel formatting (no ╭─ Rollback Complete ─╮ panel)
  2. Checkpoint label (e.g., 'before-db-migration')
  3. Status: "Restored, pending execution"
  4. "Side Effects" panel entirely missing
  5. Decisions Invalidated count
  6. Child Plans Cancelled count and names
  7. "Actor State: Reverted" line
  8. ✓ OK Plan rolled back successfully footer

Code Location: src/cleveragents/cli/commands/plan.py lines 3424–3434 — rollback_plan Rich output

Expected Behavior

The spec defines the Rich output format as two panels:

╭─ Rollback Complete ───────────────────────────╮
│ Plan: 01HXM7A9                                │
│ Checkpoint: 01HXRK4V ('before-db-migration')  │
│ Status: Restored, pending execution           │
╰───────────────────────────────────────────────╯

╭─ Side Effects ────────────────────────────────╮
│ Decisions Invalidated: 12                     │
│ Child Plans Cancelled: 2                      │
│   - 01HXRM5Z (local/run-tests)                │
│   - 01HXRN8A (local/seed-data)                │
│ Sandbox: Restored from snapshot               │
│ Actor State: Reverted                         │
╰───────────────────────────────────────────────╯

✓ OK Plan rolled back successfully

Spec Reference: docs/specification.mdagents plan rollback Command → Output Formatting

Acceptance Criteria

  • Output uses Rich Panel for "Rollback Complete" section
  • "Rollback Complete" panel includes checkpoint label and status
  • "Side Effects" panel is present with decisions invalidated count
  • "Side Effects" panel lists cancelled child plans with IDs and names
  • "Side Effects" panel includes "Sandbox: Restored from snapshot" and "Actor State: Reverted"
  • ✓ OK Plan rolled back successfully footer is displayed
  • Behave tests cover the updated output format
  • Coverage ≥ 97%

Metadata

  • Branch: fix/uat-rollback-rich-output-format
  • Commit Message: fix(cli): replace plain rollback output with spec-compliant Rich panels including side effects and actor state
  • Milestone: (none — backlog)
  • Parent Epic: #368

Subtasks

  • Replace plain text output with Rich Panel for "Rollback Complete"
  • Add checkpoint label to the panel
  • Add "Status: Restored, pending execution" to the panel
  • Add "Side Effects" panel with decisions invalidated count
  • Add child plans cancelled count and names to side effects panel
  • Add "Sandbox: Restored from snapshot" line
  • Add "Actor State: Reverted" line
  • Add ✓ OK Plan rolled back successfully footer
  • Write Behave tests for the updated output format
  • Verify coverage >= 97%

Definition of Done

This issue is complete when:

  • All subtasks above are completed and checked off.
  • A Git commit is created where the first line of the commit message matches the Commit Message in Metadata exactly, followed by a blank line, then additional lines providing relevant details about the implementation.
  • The commit is pushed to the remote on the branch matching the Branch in Metadata exactly.
  • The commit is submitted as a pull request to master, reviewed, and merged before this issue is marked done.
  • All nox stages pass.
  • Coverage >= 97%

Backlog note: This issue was discovered during autonomous operation
on milestone . It does not block milestone completion and has been
placed in the backlog for human review and future milestone assignment.


Automated by CleverAgents Bot
Supervisor: Acting on behalf of: UAT Testing | Agent: ca-new-issue-creator

## Background and Context During UAT testing of the checkpoint-rollback-system feature area, a code-level analysis of `src/cleveragents/cli/commands/plan.py` lines 3424–3434 against the spec's `agents plan rollback` Command → Output Formatting section revealed that the Rich output format is substantially incomplete and does not match the spec. ## Current Behavior The current output implementation: ```python console.print( f"[green]Rollback complete.[/green]\n" f" Plan: {plan_id}\n" f" Checkpoint: {result.from_checkpoint_id}\n" f" Restored files: {result.restored_files_count}\n" f" Elapsed: {elapsed:.3f}s\n" f" Changed paths:" ) for path in result.changed_paths: console.print(f" {path}") ``` Missing elements: 1. Rich Panel formatting (no `╭─ Rollback Complete ─╮` panel) 2. Checkpoint label (e.g., `'before-db-migration'`) 3. Status: "Restored, pending execution" 4. "Side Effects" panel entirely missing 5. Decisions Invalidated count 6. Child Plans Cancelled count and names 7. "Actor State: Reverted" line 8. `✓ OK Plan rolled back successfully` footer **Code Location:** `src/cleveragents/cli/commands/plan.py` lines 3424–3434 — `rollback_plan` Rich output ## Expected Behavior The spec defines the Rich output format as two panels: ``` ╭─ Rollback Complete ───────────────────────────╮ │ Plan: 01HXM7A9 │ │ Checkpoint: 01HXRK4V ('before-db-migration') │ │ Status: Restored, pending execution │ ╰───────────────────────────────────────────────╯ ╭─ Side Effects ────────────────────────────────╮ │ Decisions Invalidated: 12 │ │ Child Plans Cancelled: 2 │ │ - 01HXRM5Z (local/run-tests) │ │ - 01HXRN8A (local/seed-data) │ │ Sandbox: Restored from snapshot │ │ Actor State: Reverted │ ╰───────────────────────────────────────────────╯ ✓ OK Plan rolled back successfully ``` **Spec Reference:** `docs/specification.md` — `agents plan rollback` Command → Output Formatting ## Acceptance Criteria - Output uses Rich Panel for "Rollback Complete" section - "Rollback Complete" panel includes checkpoint label and status - "Side Effects" panel is present with decisions invalidated count - "Side Effects" panel lists cancelled child plans with IDs and names - "Side Effects" panel includes "Sandbox: Restored from snapshot" and "Actor State: Reverted" - `✓ OK Plan rolled back successfully` footer is displayed - Behave tests cover the updated output format - Coverage ≥ 97% ## Metadata - **Branch**: `fix/uat-rollback-rich-output-format` - **Commit Message**: `fix(cli): replace plain rollback output with spec-compliant Rich panels including side effects and actor state` - **Milestone**: *(none — backlog)* - **Parent Epic**: #368 ## Subtasks - [ ] Replace plain text output with Rich Panel for "Rollback Complete" - [ ] Add checkpoint label to the panel - [ ] Add "Status: Restored, pending execution" to the panel - [ ] Add "Side Effects" panel with decisions invalidated count - [ ] Add child plans cancelled count and names to side effects panel - [ ] Add "Sandbox: Restored from snapshot" line - [ ] Add "Actor State: Reverted" line - [ ] Add `✓ OK Plan rolled back successfully` footer - [ ] Write Behave tests for the updated output format - [ ] Verify coverage >= 97% ## Definition of Done This issue is complete when: - All subtasks above are completed and checked off. - A Git commit is created where the **first line** of the commit message matches the Commit Message in Metadata exactly, followed by a blank line, then additional lines providing relevant details about the implementation. - The commit is pushed to the remote on the branch matching the **Branch** in Metadata exactly. - The commit is submitted as a **pull request** to `master`, reviewed, and **merged** before this issue is marked done. - All nox stages pass. - Coverage >= 97% > **Backlog note:** This issue was discovered during autonomous operation > on milestone <M>. It does not block milestone completion and has been > placed in the backlog for human review and future milestone assignment. --- **Automated by CleverAgents Bot** Supervisor: Acting on behalf of: UAT Testing | Agent: ca-new-issue-creator
freemo added this to the v3.7.0 milestone 2026-04-05 17:13:00 +00:00
Author
Owner

Issue triaged by project owner:

  • State: Verified
  • Priority: Backlog (confirmed) — Rollback Rich output format doesn't match spec. Output polish.
  • Milestone: v3.7.0 (assigned — CLI output completeness)
  • Story Points: 3 (M) — Replace plain text with Rich panels, add side effects panel, add footer
  • MoSCoW: Could Have — The rollback command works functionally. Missing panels are cosmetic spec compliance.
  • Parent Epic: #368 (Subplans & Parallelism)

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

Issue triaged by project owner: - **State**: Verified - **Priority**: Backlog (confirmed) — Rollback Rich output format doesn't match spec. Output polish. - **Milestone**: v3.7.0 (assigned — CLI output completeness) - **Story Points**: 3 (M) — Replace plain text with Rich panels, add side effects panel, add footer - **MoSCoW**: Could Have — The rollback command works functionally. Missing panels are cosmetic spec compliance. - **Parent Epic**: #368 (Subplans & Parallelism) --- **Automated by CleverAgents Bot** Supervisor: Project Owner | Agent: ca-project-owner
freemo removed this from the v3.7.0 milestone 2026-04-06 23:49:10 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Blocks
#368 Epic: Subplans & Parallelism
cleveragents/cleveragents-core
Reference
cleveragents/cleveragents-core#3445
No description provided.