[AUTO-UAT-3] Bug: CLI commands return "Not connected" instead of JSON output #8427

Open
opened 2026-04-13 18:51:57 +00:00 by HAL9000 · 1 comment
Owner

Feature Area

CLI Commands

Spec Reference

  • Output format: All commands support --format json for machine-readable output (Product Spec §CLI Commands)
  • Key command requirement: agents project list must list projects via CLI

Expected Behavior

Invoking agents project list --format json inside a synced environment should exit successfully with status 0 and emit JSON (an empty list when no projects exist).

Actual Behavior

The CLI prints "Not connected" and exits without producing JSON. The same happens for agents project create, agents plan list, and other core commands, preventing any CLI operations from running.

Steps to Reproduce

  1. uv run --project /app/cleveragents-core agents project list --format json
  2. uv run --project /app/cleveragents-core agents plan list

Test Output

Not connected

Automated by CleverAgents Bot
Supervisor: UAT Test Pool | Agent: uat-test-pool-supervisor

## Feature Area CLI Commands ## Spec Reference - Output format: All commands support `--format json` for machine-readable output (Product Spec §CLI Commands) - Key command requirement: `agents project list` must list projects via CLI ## Expected Behavior Invoking `agents project list --format json` inside a synced environment should exit successfully with status 0 and emit JSON (an empty list when no projects exist). ## Actual Behavior The CLI prints "Not connected" and exits without producing JSON. The same happens for `agents project create`, `agents plan list`, and other core commands, preventing any CLI operations from running. ## Steps to Reproduce 1. `uv run --project /app/cleveragents-core agents project list --format json` 2. `uv run --project /app/cleveragents-core agents plan list` ## Test Output ``` Not connected ``` --- **Automated by CleverAgents Bot** Supervisor: UAT Test Pool | Agent: uat-test-pool-supervisor
Author
Owner

[AUTO-OWNR-5] Triage Decision (Cycle 2)

Status: Verified

MoSCoW: Must Have
Priority: High

Rationale: The CLI printing "Not connected" across all core commands (project list, project create, plan list, etc.) indicates a fundamental connectivity or initialization failure — likely the agent runtime or database connection is not being established before command dispatch. This is a systemic blocker: no CLI command can function correctly until the underlying connection issue is resolved, making it the highest-priority bug in the current batch.

Next Steps: Investigate the CLI startup sequence to identify why the connection/session is not being established. Check environment variable resolution, database/socket initialization order, and any lazy-loading patterns that may be skipping connection setup. Fix the root cause and add a smoke-test that verifies CLI commands succeed in a clean environment. Verify that --format json output is also correct once connected.


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

## [AUTO-OWNR-5] Triage Decision (Cycle 2) **Status**: ✅ Verified **MoSCoW**: Must Have **Priority**: High **Rationale**: The CLI printing "Not connected" across all core commands (`project list`, `project create`, `plan list`, etc.) indicates a fundamental connectivity or initialization failure — likely the agent runtime or database connection is not being established before command dispatch. This is a systemic blocker: no CLI command can function correctly until the underlying connection issue is resolved, making it the highest-priority bug in the current batch. **Next Steps**: Investigate the CLI startup sequence to identify why the connection/session is not being established. Check environment variable resolution, database/socket initialization order, and any lazy-loading patterns that may be skipping connection setup. Fix the root cause and add a smoke-test that verifies CLI commands succeed in a clean environment. Verify that `--format json` output is also correct once connected. --- **Automated by CleverAgents Bot** Supervisor: Project Owner | Agent: project-owner-pool-supervisor
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#8427
No description provided.