UAT: PR #2629 — session show command prints "Session details loaded" twice (duplicate console.print) #2785

Open
opened 2026-04-04 19:28:05 +00:00 by freemo · 4 comments
Owner

Bug Report

PR Under Test: #2629 (branch fix/master-ci-quality-gates, HEAD 938ea8194c6a)
Feature Area: Session CLI output format changes
Severity: Low

What Was Tested

The agents session show <id> command was tested for correct output.

Expected Behavior

The success message "✓ OK Session details loaded" should appear exactly once at the end of the session show output.

Actual Behavior

The message "✓ OK Session details loaded" appears twice in the output:

╭─ Session Summary ──────────────────────────────────────────────────╮
│ Session ID: ...                                                     │
│ ...                                                                 │
╰────────────────────────────────────────────────────────────────────╯
...
✓ OK Session details loaded
✓ OK Session details loaded    ← DUPLICATE

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")  # ← DUPLICATE

Steps to Reproduce

from unittest.mock import MagicMock
from typer.testing import CliRunner
from ulid import ULID
from datetime import datetime
from cleveragents.cli.commands import session as session_mod
from cleveragents.cli.commands.session import app as session_app
from cleveragents.domain.models.core.session import Session, SessionTokenUsage, SessionMessage, MessageRole

runner = CliRunner()
sid = str(ULID())
svc = MagicMock()
session = Session(
    session_id=sid, actor_name=None, namespace='local',
    messages=[SessionMessage(message_id=str(ULID()), role=MessageRole.USER, content='Hello', sequence=0, timestamp=datetime.now())],
    token_usage=SessionTokenUsage(input_tokens=100, output_tokens=50, estimated_cost=0.005),
    created_at=datetime.now(), updated_at=datetime.now(),
)
svc.get.return_value = session
session_mod._service = svc
result = runner.invoke(session_app, ['show', sid])
session_mod._service = None
count = result.output.count('Session details loaded')
print(f'Count: {count}')  # Prints: Count: 2

Fix Required

Remove the duplicate console.print on line 443 in session.py. Only one occurrence should remain.


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

## Bug Report **PR Under Test**: #2629 (branch `fix/master-ci-quality-gates`, HEAD `938ea8194c6a`) **Feature Area**: Session CLI output format changes **Severity**: Low ## What Was Tested The `agents session show <id>` command was tested for correct output. ## Expected Behavior The success message "✓ OK Session details loaded" should appear exactly once at the end of the `session show` output. ## Actual Behavior The message `"✓ OK Session details loaded"` appears **twice** in the output: ``` ╭─ Session Summary ──────────────────────────────────────────────────╮ │ Session ID: ... │ │ ... │ ╰────────────────────────────────────────────────────────────────────╯ ... ✓ OK Session details loaded ✓ OK Session details loaded ← DUPLICATE ``` ## 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") # ← DUPLICATE ``` ## Steps to Reproduce ```python from unittest.mock import MagicMock from typer.testing import CliRunner from ulid import ULID from datetime import datetime from cleveragents.cli.commands import session as session_mod from cleveragents.cli.commands.session import app as session_app from cleveragents.domain.models.core.session import Session, SessionTokenUsage, SessionMessage, MessageRole runner = CliRunner() sid = str(ULID()) svc = MagicMock() session = Session( session_id=sid, actor_name=None, namespace='local', messages=[SessionMessage(message_id=str(ULID()), role=MessageRole.USER, content='Hello', sequence=0, timestamp=datetime.now())], token_usage=SessionTokenUsage(input_tokens=100, output_tokens=50, estimated_cost=0.005), created_at=datetime.now(), updated_at=datetime.now(), ) svc.get.return_value = session session_mod._service = svc result = runner.invoke(session_app, ['show', sid]) session_mod._service = None count = result.output.count('Session details loaded') print(f'Count: {count}') # Prints: Count: 2 ``` ## Fix Required Remove the duplicate `console.print` on line 443 in `session.py`. Only one occurrence should remain. --- **Automated by CleverAgents Bot** Supervisor: UAT Testing | Agent: ca-uat-tester
Author
Owner

Issue triaged by project owner:

  • State: Verified | MoSCoW: Could Have — Duplicate success message in session show is a cosmetic issue. Note: This may be a duplicate of #2560 which reports the same bug. Should be checked before starting work.

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

Issue triaged by project owner: - **State**: Verified | **MoSCoW**: Could Have — Duplicate success message in session show is a cosmetic issue. Note: This may be a duplicate of #2560 which reports the same bug. Should be checked before starting work. --- **Automated by CleverAgents Bot** Supervisor: Project Owner | Agent: ca-project-owner
Author
Owner

⚠️ Milestone compliance — this issue is in State/Verified but has no milestone assigned.

Per CONTRIBUTING.md, non-Epic/non-Legendary issues in State/Verified or later MUST have a milestone. Please assign this issue to the appropriate milestone (likely v3.2.0 since it's a UAT bug related to PR #2629 which targets v3.2.0).


Automated by CleverAgents Bot
Supervisor: Backlog Grooming | Agent: ca-backlog-groomer

⚠️ **Milestone compliance** — this issue is in `State/Verified` but has no milestone assigned. Per CONTRIBUTING.md, non-Epic/non-Legendary issues in `State/Verified` or later MUST have a milestone. Please assign this issue to the appropriate milestone (likely v3.2.0 since it's a UAT bug related to PR #2629 which targets v3.2.0). --- **Automated by CleverAgents Bot** Supervisor: Backlog Grooming | Agent: ca-backlog-groomer
freemo added this to the v3.2.0 milestone 2026-04-05 04:50:43 +00:00
Author
Owner

Milestone compliance fix applied:

  • Assigned to milestone: v3.2.0
  • Reason: Issue is State/Verified (ready for implementation) but had no milestone. This is a session CLI bug that should be addressed in the earliest active milestone.

Automated by CleverAgents Bot
Supervisor: Backlog Grooming | Agent: ca-backlog-groomer

Milestone compliance fix applied: - Assigned to milestone: `v3.2.0` - Reason: Issue is `State/Verified` (ready for implementation) but had no milestone. This is a session CLI bug that should be addressed in the earliest active milestone. --- **Automated by CleverAgents Bot** Supervisor: Backlog Grooming | Agent: ca-backlog-groomer
freemo removed this from the v3.2.0 milestone 2026-04-06 22:29:17 +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.

Dependencies

No dependencies set.

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