Skip to content

fix: gate the min dirs Mesh enrolment row behind the remote-access feature - #1150

Merged
norrietaylor merged 1 commit into
mainfrom
inbox-patch/gate-min-dirs-mesh-row-b98f707a73112dd1
Jul 31, 2026
Merged

fix: gate the min dirs Mesh enrolment row behind the remote-access feature#1150
norrietaylor merged 1 commit into
mainfrom
inbox-patch/gate-min-dirs-mesh-row-b98f707a73112dd1

Conversation

@gominimal-aw-bot

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

Copy link
Copy Markdown
Contributor

Routing-Key: inbox-route/I_kwDOSUhdos8AAAABKmgrag

min dirs listed a "Mesh enrolment" row in every build, yet the mesh
subcommands compile only under the remote-access feature (off by
default) — so in a default build min mesh is an unrecognized
subcommand while min dirs still advertised its path, and the row also
silently switched from the Config group to State under --minimal-dir.
Gating the row, its group selection, and the mesh-enrolment path lookup
behind remote-access shows it only when the mesh commands exist, which
also stops it relocating between groups.

Verification

  • cargo fmt --all --check — clean
  • cargo clippy --workspace --locked -- -D warnings — 0 warnings
  • cargo build --workspace --locked — ok
  • cargo test --workspace --locked — ok (minimal crate: 165 passed, 0 failed)

Note

Gate the Mesh enrolment row in dirs behind the remote-access feature flag

The DirsLookup struct, MeshGroup type, and related row-building logic in crates/minimal/src/dirs.rs are now compiled only when the remote-access feature is enabled. Builds without the feature omit the Mesh enrolment row from the dirs report output entirely. Tests are updated to conditionally expect the Mesh row based on the feature flag.

Macroscope summarized 8cde98c.

min dirs printed a Mesh enrolment row in every build, but the mesh
subcommands compile only under the remote-access feature, which is off
by default, so min mesh is an unrecognized subcommand there. The same
row also silently moved from the Config group to State under
--minimal-dir with no hint it had relocated.

Gate the row, its group selection, and the mesh-enrolment path lookup
behind remote-access so it appears only when the commands it points at
exist. A gated row can no longer surprise anyone by moving groups.
@coderabbitai

coderabbitai Bot commented Jul 31, 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: 23 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: aa07965b-e93a-4a1e-8ed2-23bebfb02ba3

📥 Commits

Reviewing files that changed from the base of the PR and between 4a738d4 and 8cde98c.

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

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

@norrietaylor
norrietaylor marked this pull request as ready for review July 31, 2026 22:13
@norrietaylor
norrietaylor requested a review from a team as a code owner July 31, 2026 22:13
@norrietaylor

Copy link
Copy Markdown
Member

Reviewed — correct, and I verified the path CI cannot reach

The gating is symmetric and complete: the import, both DirsLookup fields, the MeshGroup enum and its impl, the mesh_row closure, both use sites (the Config and State branches), and the test fixture are all behind #[cfg(feature = "remote-access")]. No dangling reference on either side.

The part worth flagging: remote-access is off by default (crates/minimal/Cargo.toml: "Off by default: gates the mesh and ssh-forward CLI subcommands"), and no workflow passes --features remote-access. So green CI here only proves the feature-off build compiles — which is the easy half, since that is the half where the code is removed. The newly gated code is the side nothing builds.

I compiled it locally to close that gap:

cargo check -p minimal --features remote-access
Finished `dev` profile [unoptimized + debuginfo] target(s) in 28.65s

Clean — no errors, no new warnings in minimal (the sandbox2 warnings are pre-existing and unrelated).

This is a general property of the repo rather than a problem with this PR: any future change to feature-gated code lands unverified by machine. Worth a cargo check --features remote-access step in CI if this gating pattern spreads — cheap, since it is a check rather than a build.

The fix itself is right for gominimal/inbox#390: the row advertised a path for a command this build does not ship, and gating it at the same feature that gates the command keeps the two from drifting apart again.

@norrietaylor
norrietaylor merged commit 9fb0d65 into main Jul 31, 2026
30 checks passed
@norrietaylor
norrietaylor deleted the inbox-patch/gate-min-dirs-mesh-row-b98f707a73112dd1 branch July 31, 2026 22:39
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.

1 participant