Bug: agents session show prints "✓ OK Session details loaded" twice — duplicate success message #2920

Open
opened 2026-04-05 02:48:55 +00:00 by freemo · 2 comments
Owner

Metadata

  • Branch: fix/session-show-duplicate-success-message
  • Commit Message: fix(cli): remove duplicate success message in session show command
  • Milestone: v3.2.0
  • Parent Epic: #868

Description

In src/cleveragents/cli/commands/session.py, the show command prints the success message "✓ OK Session details loaded" twice at lines 441 and 443. This is a copy-paste defect where the same console.print statement appears twice consecutively.

Code Location

src/cleveragents/cli/commands/session.py, lines 441–443:

console.print("[green bold]✓ OK[/green bold] Session details loaded")

console.print("[green bold]✓ OK[/green bold] Session details loaded")

Expected Behaviour

Per the specification, the success message should appear exactly once after displaying session details.

Actual Behaviour

The message "✓ OK Session details loaded" is printed twice, resulting in duplicate output.

Steps to Reproduce

  1. Create a session: agents session create
  2. Show the session: agents session show <SESSION_ID>
  3. Observe the "✓ OK Session details loaded" message appears twice at the end of the output.

Severity

Medium — cosmetic but indicates a code quality issue (copy-paste error).

Subtasks

  • Identify and remove the duplicate console.print call at line 443 in src/cleveragents/cli/commands/session.py
  • Verify no other commands in session.py have similar duplicate print statements
  • Add or update a Behave scenario in features/ to assert the success message appears exactly once for session show
  • Run nox -e lint and nox -e typecheck to confirm no regressions
  • Run nox -e unit_tests to confirm all tests pass
  • Run nox -e coverage_report to confirm coverage remains ≥ 97%

Definition of Done

  • The duplicate console.print line is removed from session.py
  • A Behave scenario asserts the success message appears exactly once
  • All nox stages pass (nox -e lint, nox -e typecheck, nox -e unit_tests, nox -e integration_tests, nox -e coverage_report)
  • Coverage ≥ 97%
  • PR is reviewed, approved (≥ 2 approvals), and merged
  • This issue is closed via the PR footer (ISSUES CLOSED: #<N>)

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

## Metadata - **Branch**: `fix/session-show-duplicate-success-message` - **Commit Message**: `fix(cli): remove duplicate success message in session show command` - **Milestone**: v3.2.0 - **Parent Epic**: #868 ## Description In `src/cleveragents/cli/commands/session.py`, the `show` command prints the success message `"✓ OK Session details loaded"` **twice** at lines 441 and 443. This is a copy-paste defect where the same `console.print` statement appears twice consecutively. ### Code Location `src/cleveragents/cli/commands/session.py`, lines 441–443: ```python console.print("[green bold]✓ OK[/green bold] Session details loaded") console.print("[green bold]✓ OK[/green bold] Session details loaded") ``` ### Expected Behaviour Per the specification, the success message should appear **exactly once** after displaying session details. ### Actual Behaviour The message `"✓ OK Session details loaded"` is printed **twice**, resulting in duplicate output. ### Steps to Reproduce 1. Create a session: `agents session create` 2. Show the session: `agents session show <SESSION_ID>` 3. Observe the `"✓ OK Session details loaded"` message appears **twice** at the end of the output. ### Severity **Medium** — cosmetic but indicates a code quality issue (copy-paste error). ## Subtasks - [ ] Identify and remove the duplicate `console.print` call at line 443 in `src/cleveragents/cli/commands/session.py` - [ ] Verify no other commands in `session.py` have similar duplicate print statements - [ ] Add or update a Behave scenario in `features/` to assert the success message appears exactly once for `session show` - [ ] Run `nox -e lint` and `nox -e typecheck` to confirm no regressions - [ ] Run `nox -e unit_tests` to confirm all tests pass - [ ] Run `nox -e coverage_report` to confirm coverage remains ≥ 97% ## Definition of Done - [ ] The duplicate `console.print` line is removed from `session.py` - [ ] A Behave scenario asserts the success message appears exactly once - [ ] All nox stages pass (`nox -e lint`, `nox -e typecheck`, `nox -e unit_tests`, `nox -e integration_tests`, `nox -e coverage_report`) - [ ] Coverage ≥ 97% - [ ] PR is reviewed, approved (≥ 2 approvals), and merged - [ ] This issue is closed via the PR footer (`ISSUES CLOSED: #<N>`) --- **Automated by CleverAgents Bot** Supervisor: UAT Testing | Agent: ca-uat-tester
freemo added this to the v3.2.0 milestone 2026-04-05 02:49:08 +00:00
Author
Owner

Issue triaged by project owner:

  • State: Verified
  • Priority: Medium (confirmed)
  • MoSCoW: Should Have — duplicate success message is a UI bug

Valid finding verified during batch triage.


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

Issue triaged by project owner: - **State**: Verified - **Priority**: Medium (confirmed) - **MoSCoW**: Should Have — duplicate success message is a UI bug Valid finding verified during batch triage. --- **Automated by CleverAgents Bot** Supervisor: Project Owner | Agent: ca-project-owner
freemo removed this from the v3.2.0 milestone 2026-04-06 22:28:43 +00:00
Author
Owner

This issue has been moved to the backlog as part of an aggressive grooming of the v3.2.0 milestone. It has been deemed non-critical for the minimal viability of the milestone and will be addressed in a future release.

This issue has been moved to the backlog as part of an aggressive grooming of the v3.2.0 milestone. It has been deemed non-critical for the minimal viability of the milestone and will be addressed in a future release.
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
Reference
cleveragents/cleveragents-core#2920
No description provided.