UAT: agents lsp add duplicate server error message says "already registered" instead of spec-required "already exists" #4404

Open
opened 2026-04-08 12:14:44 +00:00 by HAL9000 · 0 comments
Owner

Summary

The agents lsp add command produces a different error message when a duplicate server is registered than what the specification requires.

Expected Behavior (from spec, lines 8749-8751)

$ agents lsp add --config lsp/pyright.yaml

✗ ERROR LSP server 'local/pyright' already exists
Hint: Use --update to overwrite: agents lsp add --update --config lsp/pyright.yaml

The spec requires the error message: LSP server 'local/pyright' already exists

Actual Behavior

From src/cleveragents/lsp/registry.py (line 64):

raise ValueError(f"LSP server '{config.name}' is already registered")

The implementation raises: LSP server 'local/pyright' is already registered

Additionally, the hint format in the CLI (src/cleveragents/cli/commands/lsp.py, lines 188-191) is:

To overwrite, re-run with --update:
  agents lsp add --config lsp/pyright.yaml --update

But the spec shows:

Hint: Use --update to overwrite: agents lsp add --update --config lsp/pyright.yaml

Differences:

  1. Error message: "already registered" vs spec's "already exists"
  2. Hint prefix: "To overwrite, re-run with --update:" vs spec's "Hint: Use --update to overwrite:"
  3. Hint command order: --config ... --update vs spec's --update --config ...

Code Locations

  • src/cleveragents/lsp/registry.py, line 64: error message
  • src/cleveragents/cli/commands/lsp.py, lines 186-192: hint formatting

Steps to Reproduce

  1. Register an LSP server: agents lsp add --config lsp/pyright.yaml
  2. Try to register the same server again: agents lsp add --config lsp/pyright.yaml
  3. Observe the error message says "already registered" instead of "already exists"

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

## Summary The `agents lsp add` command produces a different error message when a duplicate server is registered than what the specification requires. ## Expected Behavior (from spec, lines 8749-8751) ``` $ agents lsp add --config lsp/pyright.yaml ✗ ERROR LSP server 'local/pyright' already exists Hint: Use --update to overwrite: agents lsp add --update --config lsp/pyright.yaml ``` The spec requires the error message: `LSP server 'local/pyright' already exists` ## Actual Behavior From `src/cleveragents/lsp/registry.py` (line 64): ```python raise ValueError(f"LSP server '{config.name}' is already registered") ``` The implementation raises: `LSP server 'local/pyright' is already registered` Additionally, the hint format in the CLI (`src/cleveragents/cli/commands/lsp.py`, lines 188-191) is: ``` To overwrite, re-run with --update: agents lsp add --config lsp/pyright.yaml --update ``` But the spec shows: ``` Hint: Use --update to overwrite: agents lsp add --update --config lsp/pyright.yaml ``` Differences: 1. Error message: `"already registered"` vs spec's `"already exists"` 2. Hint prefix: `"To overwrite, re-run with --update:"` vs spec's `"Hint: Use --update to overwrite:"` 3. Hint command order: `--config ... --update` vs spec's `--update --config ...` ## Code Locations - `src/cleveragents/lsp/registry.py`, line 64: error message - `src/cleveragents/cli/commands/lsp.py`, lines 186-192: hint formatting ## Steps to Reproduce 1. Register an LSP server: `agents lsp add --config lsp/pyright.yaml` 2. Try to register the same server again: `agents lsp add --config lsp/pyright.yaml` 3. Observe the error message says "already registered" instead of "already exists" --- **Automated by CleverAgents Bot** Supervisor: UAT Testing | Agent: uat-tester
HAL9000 added this to the v3.5.0 milestone 2026-04-08 17:42:54 +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.

Dependencies

No dependencies set.

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