Skip to content

fix: Redact internal spec identifiers (DM1, R4.4) from min --help output - #1017

Merged
norrietaylor merged 3 commits into
mainfrom
inbox-patch/redact-spec-ids-help-eba0f37b4a0ba2ff
Jul 29, 2026
Merged

fix: Redact internal spec identifiers (DM1, R4.4) from min --help output#1017
norrietaylor merged 3 commits into
mainfrom
inbox-patch/redact-spec-ids-help-eba0f37b4a0ba2ff

Conversation

@gominimal-aw-bot

@gominimal-aw-bot gominimal-aw-bot Bot commented Jul 29, 2026

Copy link
Copy Markdown
Contributor

Fixes #1013
Routing-Key: inbox-route/I_kwDOSUhdos8AAAABKk1ZkQ

Problem

clap's derive macro publishes /// doc comments verbatim as user-facing help text, so two internal spec identifiers were shipping in min --help:

  • crates/minimal/src/lib.rs: the --provider global arg carried (DM1). Being global = true, that line renders on all 18 help surfaces — the single most-printed string in the CLI.
  • crates/minimal/src/lib.rs: the login subcommand description carried (R4.4, R4.5), rendered by min login --help.

Change

Drop the parenthetical spec tags from both doc comments, leaving the descriptive prose intact. Copy-only, no behavioural change.

That is the whole diff: +2/-2 in one file.

On the CI guard

The issue asked for a CI guard enforcing the convention (internal spec IDs in // comments, never ///). This PR originally carried one — a dependency-free crates/minimal/tests/help_text.rs that rendered help recursively and scanned it for DM<n>, UC<n>, FR<n>, NFR<n>, R<n>.<n>, and PTask.

It has been removed. 149 lines of hand-rolled byte-level scanning, plus a second test to test the scanner, is disproportionate to catching two string literals. If this class of leak recurs, a grep -E step in CI covers it at a fraction of the cost and none of the maintenance surface.

The convention itself still stands and is worth applying in review.

Scope notes

The Provider enum-level doc (DM2/DM1) and the cmd_login fn doc (R4.4) are Rust docs on non-clap items, so they never reach help output and were left untouched.

The PTask/R4.8 references on mesh and ssh-forward sit behind the default-off remote-access feature and do not ship today. They will leak if those commands are ever enabled — worth catching then.

Verification

The full Rust gate (cargo fmt --check, cargo clippy -- -D warnings, cargo build, cargo test --workspace) was run green against the tree as originally authored, i.e. with the guard present. Those results no longer describe this diff.

The current head is d581366. CI on that commit is the authority for this PR. The remaining change is two doc-comment strings, so the risk surface is limited to whether the help text still reads correctly:

--provider <PROVIDER>
    Select the daemon backend that hosts sessions. On Linux, `local-minimald`
    (the default) runs minimald on the host; `local-minvmd` runs it inside the
    minvmd microVM. No effect on macOS, where minvmd is the only backend

Generated by inbox-patch ·

Note

Redact internal spec identifiers from min --help output

Removes parenthetical internal spec references (e.g. DM1, R4.4) from the CLI help text in lib.rs. Affected descriptions are the mTLS client certificate subcommand and the microVM backend provider option.

Macroscope summarized d581366.

clap's derive macro publishes `///` doc comments verbatim as help
text, so two internal spec references shipped in `min --help`:

- the global `--provider` arg carried `(DM1)` and, being `global`,
  rendered on all 18 help surfaces;
- the `login` subcommand carried `(R4.4, R4.5)`.

Drop the parenthetical spec tags, leaving the descriptive prose
intact. Both edits are copy-only and carry no behavioural change.

Add a convention-discovered guard (crates/minimal/tests/help_text.rs)
that renders long help for the root command and every subcommand
recursively and fails on `DM<n>`, `UC<n>`, `FR<n>`, `NFR<n>`,
`R<n>.<n>`, and the retired `PTask` vocabulary — so the convention
"internal spec IDs go in `//` comments, never `///`" is enforced
rather than merely remembered.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@coderabbitai

coderabbitai Bot commented Jul 29, 2026

Copy link
Copy Markdown

Warning

Review limit reached

You’ve reached a temporary PR review limit under our Fair Usage Limits Policy.

Your recent review volume is higher than typical usage, so adaptive limits are currently applied.

Next review available in: 40 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 391d178c-762f-41ce-b147-a3341f770138

📥 Commits

Reviewing files that changed from the base of the PR and between 0f08972 and d581366.

📒 Files selected for processing (1)
  • crates/minimal/src/lib.rs

Comment @coderabbitai help to get the list of available commands.

The 149-line byte-level scanner is disproportionate to what it protects.
Keeping the copy fixes; the convention can be enforced more cheaply later
if it proves it needs enforcing.
@norrietaylor
norrietaylor enabled auto-merge (squash) July 29, 2026 04:46
@norrietaylor
norrietaylor merged commit cc11ac2 into main Jul 29, 2026
29 checks passed
@norrietaylor
norrietaylor deleted the inbox-patch/redact-spec-ids-help-eba0f37b4a0ba2ff branch July 29, 2026 04:58
gominimal-aw-bot Bot added a commit that referenced this pull request Jul 29, 2026
Redact the internal deployment-model IDs DM1/DM2/DM3 from the
user-facing linux-host-setup reference, describing the deployments
functionally instead. This follows #1017, which cleaned the same
class from `min --help` but stopped before the docs.

Refresh two stale counts in AGENTS.md: 40 justfile recipes on Linux
(was 33; `just --summary`) and 12 CI workflows (was 11 — the
docs-hotfix workflow was missing from the table).

Drop the two docs.minimal.dev/concepts links (stacks, sessions) that
404, keeping the surrounding prose as plain text; sibling concept
pages resolve but no slug is published for these two.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
norrietaylor added a commit that referenced this pull request Jul 31, 2026
Redact the internal deployment-model IDs DM1/DM2/DM3 from the
user-facing linux-host-setup reference, describing the deployments
functionally instead. This follows #1017, which cleaned the same
class from `min --help` but stopped before the docs.

Refresh two stale counts in AGENTS.md: 40 justfile recipes on Linux
(was 33; `just --summary`) and 12 CI workflows (was 11 — the
docs-hotfix workflow was missing from the table).

Drop the two docs.minimal.dev/concepts links (stacks, sessions) that
404, keeping the surrounding prose as plain text; sibling concept
pages resolve but no slug is published for these two.

Co-authored-by: gominimal-aw-bot[bot] <281738952+gominimal-aw-bot[bot]@users.noreply.github.com>
Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
Co-authored-by: Norrie Taylor <91171431+norrietaylor@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Internal spec acronyms (DM1, R4.4, UC*) are leaking into min --help output

1 participant