UAT: agents actor context list, show, and clear CLI subcommands are missing — spec requires all three #2577

Open
opened 2026-04-03 18:58:35 +00:00 by freemo · 1 comment
Owner

Metadata

  • Branch: fix/actor-context-list-show-clear
  • Commit Message: feat(cli): implement agents actor context list, show, and clear subcommands
  • Milestone: v3.4.0
  • Parent Epic: #396

Bug Description

The agents actor context subcommand group in src/cleveragents/cli/commands/actor_context.py is missing three of the six subcommands required by the specification.

What Was Tested

Code-level analysis of src/cleveragents/cli/commands/actor_context.py.

Expected Behavior (from spec)

The specification (§ agents actor context, lines 5766–6336) defines six subcommands for agents actor context:

agents actor context remove [--yes|-y] (--all|-a|<NAME>)
agents actor context list [<REGEX>]
agents actor context show <NAME>
agents actor context export (--output|-o) <FILE> <NAME>
agents actor context import [--update] (--input|-i) <FILE> [<NAME>]
agents actor context clear [--yes|-y] (--all|-a|<NAME>)
  • agents actor context list [<REGEX>]: Lists all named actor contexts stored under ~/.cleveragents/context/. Accepts an optional regex to filter context names. Shows context name, message count, size, and last-updated timestamp.
  • agents actor context show <NAME>: Shows the content of a named actor context — messages, metadata, state, and global_context fields.
  • agents actor context clear [--yes|-y] (--all|-a|<NAME>): Clears (empties) the messages and state of a named context without deleting the context directory. Distinct from remove which deletes the directory entirely.

Actual Behavior

Only three subcommands are implemented in actor_context.py:

@app.command("remove")   # line 99
@app.command("export")   # line 234
@app.command("import")   # line 333

Running agents actor context list, agents actor context show <NAME>, or agents actor context clear <NAME> results in:

Error: No such command 'list'.
Error: No such command 'show'.
Error: No such command 'clear'.

Code Location

  • src/cleveragents/cli/commands/actor_context.py — missing list, show, and clear command handlers
  • src/cleveragents/reactive/context_manager.pyContextManager.clear() method exists and can be used by the clear command

Distinction Between remove and clear

The spec makes a clear distinction:

  • remove: Deletes the context directory entirely (data is not recoverable). Uses ContextManager.delete().
  • clear: Empties the context (messages, state, global_context) but keeps the context directory. Uses ContextManager.clear().

The ContextManager.clear() method already exists at line 96 of context_manager.py and resets messages, state, and global_context while preserving the directory.

Impact

High. Three of the six spec-required agents actor context subcommands are completely absent. Users cannot:

  • List available actor contexts (list)
  • Inspect context content without exporting to a file (show)
  • Clear a context's messages without deleting it (clear)

Steps to Reproduce

agents actor context list
# Error: No such command 'list'.

agents actor context show docs
# Error: No such command 'show'.

agents actor context clear docs
# Error: No such command 'clear'.

Subtasks

  • Implement agents actor context list [<REGEX>] — list all context names with optional regex filter, show name/message count/size/last-updated
  • Implement agents actor context show <NAME> — display messages, metadata, state, global_context for a named context
  • Implement agents actor context clear [--yes|-y] (--all|-a|<NAME>) — clear context content using ContextManager.clear() without deleting the directory
  • Add BDD scenarios for all three new commands in features/actor_context_cmds.feature
  • Verify coverage >= 97% via nox -s coverage_report
  • Run nox (all default sessions) and fix any errors

Definition of Done

This issue is complete when:

  • All three subcommands (list, show, clear) are implemented in actor_context.py
  • All three commands produce spec-compliant output in rich, json, yaml, plain, and table formats
  • BDD scenarios cover all three commands including error cases
  • All nox sessions pass with coverage >= 97%

Automated by CleverAgents Bot
Supervisor: UAT Testing | Agent: ca-new-issue-creator

## Metadata - **Branch**: `fix/actor-context-list-show-clear` - **Commit Message**: `feat(cli): implement agents actor context list, show, and clear subcommands` - **Milestone**: v3.4.0 - **Parent Epic**: #396 ## Bug Description The `agents actor context` subcommand group in `src/cleveragents/cli/commands/actor_context.py` is missing three of the six subcommands required by the specification. ### What Was Tested Code-level analysis of `src/cleveragents/cli/commands/actor_context.py`. ### Expected Behavior (from spec) The specification (§ `agents actor context`, lines 5766–6336) defines six subcommands for `agents actor context`: ``` agents actor context remove [--yes|-y] (--all|-a|<NAME>) agents actor context list [<REGEX>] agents actor context show <NAME> agents actor context export (--output|-o) <FILE> <NAME> agents actor context import [--update] (--input|-i) <FILE> [<NAME>] agents actor context clear [--yes|-y] (--all|-a|<NAME>) ``` - **`agents actor context list [<REGEX>]`**: Lists all named actor contexts stored under `~/.cleveragents/context/`. Accepts an optional regex to filter context names. Shows context name, message count, size, and last-updated timestamp. - **`agents actor context show <NAME>`**: Shows the content of a named actor context — messages, metadata, state, and global_context fields. - **`agents actor context clear [--yes|-y] (--all|-a|<NAME>)`**: Clears (empties) the messages and state of a named context without deleting the context directory. Distinct from `remove` which deletes the directory entirely. ### Actual Behavior Only three subcommands are implemented in `actor_context.py`: ```python @app.command("remove") # line 99 @app.command("export") # line 234 @app.command("import") # line 333 ``` Running `agents actor context list`, `agents actor context show <NAME>`, or `agents actor context clear <NAME>` results in: ``` Error: No such command 'list'. Error: No such command 'show'. Error: No such command 'clear'. ``` ### Code Location - `src/cleveragents/cli/commands/actor_context.py` — missing `list`, `show`, and `clear` command handlers - `src/cleveragents/reactive/context_manager.py` — `ContextManager.clear()` method exists and can be used by the `clear` command ### Distinction Between `remove` and `clear` The spec makes a clear distinction: - **`remove`**: Deletes the context directory entirely (data is not recoverable). Uses `ContextManager.delete()`. - **`clear`**: Empties the context (messages, state, global_context) but keeps the context directory. Uses `ContextManager.clear()`. The `ContextManager.clear()` method already exists at line 96 of `context_manager.py` and resets messages, state, and global_context while preserving the directory. ### Impact **High.** Three of the six spec-required `agents actor context` subcommands are completely absent. Users cannot: - List available actor contexts (`list`) - Inspect context content without exporting to a file (`show`) - Clear a context's messages without deleting it (`clear`) ### Steps to Reproduce ```bash agents actor context list # Error: No such command 'list'. agents actor context show docs # Error: No such command 'show'. agents actor context clear docs # Error: No such command 'clear'. ``` ## Subtasks - [ ] Implement `agents actor context list [<REGEX>]` — list all context names with optional regex filter, show name/message count/size/last-updated - [ ] Implement `agents actor context show <NAME>` — display messages, metadata, state, global_context for a named context - [ ] Implement `agents actor context clear [--yes|-y] (--all|-a|<NAME>)` — clear context content using `ContextManager.clear()` without deleting the directory - [ ] Add BDD scenarios for all three new commands in `features/actor_context_cmds.feature` - [ ] Verify coverage >= 97% via `nox -s coverage_report` - [ ] Run `nox` (all default sessions) and fix any errors ## Definition of Done This issue is complete when: - All three subcommands (`list`, `show`, `clear`) are implemented in `actor_context.py` - All three commands produce spec-compliant output in rich, json, yaml, plain, and table formats - BDD scenarios cover all three commands including error cases - All nox sessions pass with coverage >= 97% --- **Automated by CleverAgents Bot** Supervisor: UAT Testing | Agent: ca-new-issue-creator
freemo added this to the v3.4.0 milestone 2026-04-03 19:00:02 +00:00
Author
Owner

Issue triaged by project owner:

  • State: Verified
  • Priority: High — Three of six spec-required agents actor context subcommands are completely missing. Users cannot list, inspect, or clear actor contexts.
  • Milestone: v3.4.0 (M5: ACMS v1 + Context Scaling)
  • MoSCoW: Must Have — The spec (§5766–6336) explicitly defines all six subcommands. The ContextManager.clear() method already exists, so the clear command is straightforward. list and show are essential for context management workflows.
  • Parent Epic: #396 (ACMS Context Pipeline)

Note: This milestone (v3.4.0) was due March 6, 2026 and is overdue. This issue should be prioritized as part of the ACMS context pipeline completion effort.


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

Issue triaged by project owner: - **State**: Verified - **Priority**: High — Three of six spec-required `agents actor context` subcommands are completely missing. Users cannot list, inspect, or clear actor contexts. - **Milestone**: v3.4.0 (M5: ACMS v1 + Context Scaling) - **MoSCoW**: Must Have — The spec (§5766–6336) explicitly defines all six subcommands. The `ContextManager.clear()` method already exists, so the `clear` command is straightforward. `list` and `show` are essential for context management workflows. - **Parent Epic**: #396 (ACMS Context Pipeline) Note: This milestone (v3.4.0) was due March 6, 2026 and is overdue. This issue should be prioritized as part of the ACMS context pipeline completion effort. --- **Automated by CleverAgents Bot** Supervisor: Project Owner | Agent: ca-project-owner
freemo removed this from the v3.4.0 milestone 2026-04-06 21:01:37 +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
#396 Epic: ACMS Context Pipeline
cleveragents/cleveragents-core
Reference
cleveragents/cleveragents-core#2577
No description provided.