You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
min session destroy -f prints a usage line that can never parse #1038
Surface:min session destroy · Severity: Medium · Class: clap group definition
Reproduce
min session destroy -f
error: the following required arguments were not provided:
--all
<SESSION>
Usage: min session destroy --all --force <SESSION>
The suggested invocation is impossible — the two are mutually exclusive:
min session destroy --all debug
-> error: the argument '--all' cannot be used with '[SESSION]'
Also wrong in the same error path
Bare min session destroy reports Usage: min session destroy <SESSION> — --all is
invisible in the error path despite satisfying the requirement, and [SESSION] is rendered as
required here while --help correctly shows it optional.
Fix
Model the choice as an ArgGroup with required = true, multiple = false so the usage line
renders <SESSION>|--all instead of demanding both.
QA sweep of the published min help tree against a live local-minvmd daemon (min 0.5.0-rc3.dev.31.gc1375225, HEAD c137522); every finding re-executed against main at df22d71 and read back to source. Ledger finding F6 (confirmed).
min session destroy is a subcommand of the min CLI (Rust/clap). The bug is a clap argument-group definition gap: --force/-f requires --all individually, but --all and [SESSION] are mutually exclusive, so the error-path usage line demands an impossible combination.
Evidence
Repo peek — gominimal/minimal: Code search returned a direct match in crates/minimal/src/lib.rs — DestroyArgs::force carries #[arg(long, short, requires = "all")] with no ArgGroup that expresses [SESSION] and --all as alternatives. This is exactly the structure that produces the bad usage line.
Similar issues: No prior tracking of this exact ArgGroup gap found in gominimal/minimal. Four sibling issues from the same QA sweep (same author, same commit anchor df22d711) are already open and routed to gominimal/minimal:
gominimal/minimal#1025 (min session policy silent false negative) — related
gominimal/minimal#1027 (min completions install silent no-op) — related
gominimal/minimal#1031 (bare min --no-input orphan session) — related
gominimal/minimal#1032 (min init config overwrite) — related
None duplicate this issue; all confirm the routing target.
Distillery enrichment: Confirms PR feat(minimald): implement session destroy + RPC #462 (feat(minimald): implement session destroy + RPC, project minimal) as the origin of the destroy subcommand. Clap is the arg-parsing crate in scope (confirmed via dependency PR in the minimal project).
Precedent pass: Multiple routing-outcome entries authored by inbox-route-retro in project inbox confirm that CLI bugs in the min session surface are routed to gominimal/minimal as patch at confidence 0.82–0.92 (informed by routing-outcome inbox-route/I_kwDOSUhdos8AAAABIsUoEg, inbox-route/I_kwDOSUhdos8AAAABI_ODew, inbox-route/I_kwDOSUhdos8AAAABJGQymQ).
Manifest:gominimal/minimal is route: allow; default ref is main. Estimated fix touches 1 file (crates/minimal/src/lib.rs), within max_patch_files = 5.
[inbox-route:decision]
{"schema":"inbox-route/v1","issue":384,"issue_node_id":"I_kwDOSUhdos8AAAABKmghtQ","dry_run":false,"kind":"bug","route":"patch","confidence":0.92,"targets":[{"repo":"gominimal/minimal","reason":"session destroy ArgGroup definition lives in crates/minimal/src/lib.rs"}],"labels":["kind:bug","priority:should-have"],"patch":{"target_ref":"main","brief":"In crates/minimal/src/lib.rs, DestroyArgs::force uses requires = \"all\", which makes clap demand both --all and <SESSION> on the error path — an impossible combination since they are mutually exclusive. Evidence suggests the fix is to introduce an ArgGroup covering [SESSION] and --all as alternatives (required = true, multiple = false), and wire force to require that group rather than --all directly.","files":["crates/minimal/src/lib.rs"]},"work_issue":{"title":"bug: session destroy -f produces impossible usage line (clap ArgGroup missing)","body":"## Summary\n\n`min session destroy --force` / `-f` generates a usage suggestion that cannot be executed: the error path demands both `--all` and `<SESSION>`, but these two arguments are mutually exclusive.\n\n## Details\n\nIn `crates/minimal/src/lib.rs`, `DestroyArgs::force` is declared with `requires = \"all\"`, which causes clap to list `--all` as a required argument on the error path. However, `--all` and `[SESSION]` are already mutually exclusive, so the suggested invocation `min session destroy --all --force <SESSION>` is impossible to execute.\n\nA secondary symptom: bare `min session destroy` reports `Usage: min session destroy <SESSION>` — `--all` is absent from the error-path usage despite being a valid way to satisfy the requirement, and `[SESSION]` is shown as required even though `--help` correctly marks it optional.\n\nEvidence in source: `crates/minimal/src/lib.rs` — `DestroyArgs::force`, `#[arg(long, short, requires = \"all\")]`, with no ArgGroup making `session` and `--all` alternatives.\n\n## Suggested next step\n\nIntroduce a clap `ArgGroup` on `DestroyArgs` with `required = true, multiple = false` covering `session` and `all`, and update `force` to require the group rather than `--all` individually."},"related":[{"repo":"gominimal/minimal","number":1025,"relation":"related"},{"repo":"gominimal/minimal","number":1027,"relation":"related"},{"repo":"gominimal/minimal","number":1031,"relation":"related"},{"repo":"gominimal/minimal","number":1032,"relation":"related"}],"rationale":"Issue gominimal/minimal#1038 reports that `min session destroy -f` emits an impossible usage line requiring both --all and <SESSION>, which are mutually exclusive. Code search in gominimal/minimal confirmed the root: crates/minimal/src/lib.rs defines DestroyArgs::force with #[arg(long, short, requires = \"all\")] but no ArgGroup — so clap demands --all alongside <SESSION> on the error path. The QA sweep that filed this also filed four sibling issues already routed to gominimal/minimal (#1025, #1027, #1031, #1032), confirming the target. Precedent routing-outcome entries for similar CLI bugs in the min session surface all route to gominimal/minimal as patch. Fix is a one-file change to introduce an ArgGroup in DestroyArgs, within the max_patch_files limit."}
Activity
github-actions commentedon Jul 29, 2026
[inbox-route] The routing run for this issue failed before completing.
Run: https://github.com/gominimal/inbox/actions/runs/30430272087
A human needs to look at the run log. After fixing the cause, clear
needs-humanand retry with:gominimal-aw-bot commentedon Jul 29, 2026
Routing triage — #1038
Kind: bug · Route: patch · Target: gominimal/minimal · Confidence: 0.92
min session destroyis a subcommand of theminCLI (Rust/clap). The bug is a clap argument-group definition gap:--force/-frequires--allindividually, but--alland[SESSION]are mutually exclusive, so the error-path usage line demands an impossible combination.Evidence
gominimal/minimal: Code search returned a direct match incrates/minimal/src/lib.rs—DestroyArgs::forcecarries#[arg(long, short, requires = "all")]with noArgGroupthat expresses[SESSION]and--allas alternatives. This is exactly the structure that produces the bad usage line.ArgGroupgap found ingominimal/minimal. Four sibling issues from the same QA sweep (same author, same commit anchordf22d711) are already open and routed togominimal/minimal:gominimal/minimal#1025(min session policysilent false negative) — relatedgominimal/minimal#1027(min completions installsilent no-op) — relatedgominimal/minimal#1031(baremin --no-inputorphan session) — relatedgominimal/minimal#1032(min initconfig overwrite) — relatedNone duplicate this issue; all confirm the routing target.
feat(minimald): implement session destroy + RPC, projectminimal) as the origin of thedestroysubcommand. Clap is the arg-parsing crate in scope (confirmed via dependency PR in theminimalproject).routing-outcomeentries authored byinbox-route-retroin projectinboxconfirm that CLI bugs in themin sessionsurface are routed togominimal/minimalaspatchat confidence 0.82–0.92 (informed by routing-outcomeinbox-route/I_kwDOSUhdos8AAAABIsUoEg,inbox-route/I_kwDOSUhdos8AAAABI_ODew,inbox-route/I_kwDOSUhdos8AAAABJGQymQ).gominimal/minimalisroute: allow; default ref ismain. Estimated fix touches 1 file (crates/minimal/src/lib.rs), withinmax_patch_files = 5.[inbox-route:decision]
{"schema":"inbox-route/v1","issue":384,"issue_node_id":"I_kwDOSUhdos8AAAABKmghtQ","dry_run":false,"kind":"bug","route":"patch","confidence":0.92,"targets":[{"repo":"gominimal/minimal","reason":"session destroy ArgGroup definition lives in crates/minimal/src/lib.rs"}],"labels":["kind:bug","priority:should-have"],"patch":{"target_ref":"main","brief":"In crates/minimal/src/lib.rs, DestroyArgs::force uses requires = \"all\", which makes clap demand both --all and <SESSION> on the error path — an impossible combination since they are mutually exclusive. Evidence suggests the fix is to introduce an ArgGroup covering [SESSION] and --all as alternatives (required = true, multiple = false), and wire force to require that group rather than --all directly.","files":["crates/minimal/src/lib.rs"]},"work_issue":{"title":"bug: session destroy -f produces impossible usage line (clap ArgGroup missing)","body":"## Summary\n\n`min session destroy --force` / `-f` generates a usage suggestion that cannot be executed: the error path demands both `--all` and `<SESSION>`, but these two arguments are mutually exclusive.\n\n## Details\n\nIn `crates/minimal/src/lib.rs`, `DestroyArgs::force` is declared with `requires = \"all\"`, which causes clap to list `--all` as a required argument on the error path. However, `--all` and `[SESSION]` are already mutually exclusive, so the suggested invocation `min session destroy --all --force <SESSION>` is impossible to execute.\n\nA secondary symptom: bare `min session destroy` reports `Usage: min session destroy <SESSION>` — `--all` is absent from the error-path usage despite being a valid way to satisfy the requirement, and `[SESSION]` is shown as required even though `--help` correctly marks it optional.\n\nEvidence in source: `crates/minimal/src/lib.rs` — `DestroyArgs::force`, `#[arg(long, short, requires = \"all\")]`, with no ArgGroup making `session` and `--all` alternatives.\n\n## Suggested next step\n\nIntroduce a clap `ArgGroup` on `DestroyArgs` with `required = true, multiple = false` covering `session` and `all`, and update `force` to require the group rather than `--all` individually."},"related":[{"repo":"gominimal/minimal","number":1025,"relation":"related"},{"repo":"gominimal/minimal","number":1027,"relation":"related"},{"repo":"gominimal/minimal","number":1031,"relation":"related"},{"repo":"gominimal/minimal","number":1032,"relation":"related"}],"rationale":"Issue gominimal/minimal#1038 reports that `min session destroy -f` emits an impossible usage line requiring both --all and <SESSION>, which are mutually exclusive. Code search in gominimal/minimal confirmed the root: crates/minimal/src/lib.rs defines DestroyArgs::force with #[arg(long, short, requires = \"all\")] but no ArgGroup — so clap demands --all alongside <SESSION> on the error path. The QA sweep that filed this also filed four sibling issues already routed to gominimal/minimal (#1025, #1027, #1031, #1032), confirming the target. Precedent routing-outcome entries for similar CLI bugs in the min session surface all route to gominimal/minimal as patch. Fix is a one-file change to introduce an ArgGroup in DestroyArgs, within the max_patch_files limit."}gominimal-aw-bot commentedon Jul 29, 2026
[inbox-route:ledger]
Routed from gominimal/inbox#384 by inbox-route (https://github.com/gominimal/inbox/actions/runs/30466306483)
Routing-Key: inbox-route/I_kwDOSUhdos8AAAABKmghtQ
Route: patch
Patch-Dispatched: https://github.com/gominimal/inbox/actions/runs/30466306483
fix(minimal): model session destroy target as a required arg group