Skip to main content
← Back to list
01Issue
FeatureOpenSwamp CLI
AssigneesNone

Relationships

#588 swamp help extension omits yank and unyank (machine-readable CLI schema misses real subcommands)

Opened by stack72 · 6/7/2026

Problem

swamp help extension (the JSON CLI schema documented in CLAUDE.md as the agent-consumption surface) does not list yank or unyank, even though both commands exist and work:

$ swamp --version
swamp 20260606.235053.0-sha.d4ff2b04

$ swamp help extension | jq '.root.subcommands[] | .name'
"push"
"info"
"fmt"
"quality"
"pull"
"install"
"rm"
"list"
"search"
"update"

$ swamp extension yank --help
Usage: swamp extension yank <extension> [version] --reason <reason>
...

yank and unyank shipped via #575 and #1204 and the source files are present (src/cli/commands/extension_yank.ts, src/cli/commands/extension_unyank.ts). They invoke fine when called directly. The schema emitted by swamp help just doesn't include them.

Why this matters

Agents (Claude Code, etc.) discover the swamp CLI surface by running swamp help <subtree> and parsing the JSON. CLAUDE.md for projects managed with swamp explicitly tells agents to do this:

For a machine-readable JSON schema of the CLI (commands, options, arguments) intended for agent consumption, run swamp help [<command>...]

When yank is missing from that schema, an agent triaging a broken publication concludes there is no yank capability and reaches for less-good options (publishing a superseding version, asking the user to contact maintainers, etc.). I just hit this — assumed yank had been removed, told the user there was no yank command, and only realised it still existed after the user pushed back. A user who didn't know yank had ever existed would have no recourse.

Likely cause

The new yank/unyank CLI commands aren't being registered onto the extension subcommand's .command() chain that swamp help walks to build its schema. The runtime command resolution is independent (works via direct invocation), but the introspection surface isn't seeing them.

Worth checking the same for deprecate/undeprecate (shipped in #1455) and any other recently-added subcommands.

Repro

swamp help extension | jq '.root.subcommands[] | .name' | grep -i yank
# (no output)

swamp extension yank --help
# (works)

Co-authored-by: Claude noreply@anthropic.com


Automoved by swampadmin from https://github.com/swamp-club/swamp/issues/1525

02Bog Flow
OPENTRIAGEDIN PROGRESSSHIPPED

Open

6/7/2026, 5:06:45 PM

No activity in this phase yet.

03Sludge Pulse

Sign in to post a ripple.