Skip to content

fix(fleet): queue-domain --version rejects trailing arguments (#5603) - #5605

Merged
dezren39 merged 1 commit into
mainfrom
creator-a/5603-queue-version-args
Nov 4, 2026
Merged

dezren39 merged 1 commit into
mainfrom
creator-a/5603-queue-version-args

Conversation

@dezren39

@dezren39 dezren39 commented Nov 4, 2026 •

Copy link
Copy Markdown
Member

Fixes #5603.

The queue domain's --version shortcut in run_domain (pkgs/fleet/crates/fleet/src/main.rs) checked only args.first() and returned EXIT_OK for any trailing arguments — the one fleet version surface the #5572 (root built-ins) and #5592 (queue client verbs) arity fixes missed, because it intercepts the invocation before fleet_queue::client::run is reached. It is also the repo-queue argv0 alias's only version surface.

  • The arm now rejects a trailing argument with a usage error naming it (exit 2), mirroring run_root's reject_extra_args behavior.
  • New pinning test queue_domain_version_rejects_trailing_arguments alongside root_builtins_reject_trailing_arguments: --version/-V with --bogus → EXIT_USAGE; bare forms → EXIT_OK.

Verification (laptop, this branch):

  • cargo test -p fleet — 5 passed, including the new test.
  • Fixed binary re-probed: fleet queue --version junkextra → exit 2 naming the argument; fleet queue -V --bogus → exit 2; repo-queue --version junk (argv0) → exit 2; bare fleet queue --version and repo-queue --version → exit 0 with the version string.

Autofix with [code]smith
Open in [code]smith · Need help on this PR? Tag @codesmith-bot with what you need.

@dezren39
dezren39 requested a review from a team as a code owner November 4, 2026 17:46
@coderabbitai

coderabbitai Bot commented Nov 4, 2026

Copy link
Copy Markdown

Warning

Review limit reached

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Next included review available in 33 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available.

Learn how review limits work.

Review configuration:

Run configuration
  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 89f72e7c-e504-4e19-82a4-ba30f7a55bac
Commits

Reviewing files that changed from the base of the PR and between 3e0f3f4 and 6d49761.

Files selected for processing: 1
  • pkgs/fleet/crates/fleet/src/main.rs
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 4, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-04T17:49:02.066704Z 6d49761 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@dezren39
dezren39 merged commit 7912457 into main Nov 4, 2026
1 check passed
@dezren39
dezren39 deleted the creator-a/5603-queue-version-args branch November 4, 2026 17:47

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 6d49761948

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +845 to +846
#[test]
fn queue_domain_version_rejects_trailing_arguments() {

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Gate the queue-specific test on the queue feature

For the supported serve and connect feature sets, which do not enable queue, this unconditional test fails: Surface::new excludes Capability::Queue, so run_domain correctly takes the capability-stub path and returns EXIT_UNAVAILABLE (69), rather than the asserted EXIT_USAGE (2). The bare-version assertion also expects success despite that capability being unavailable. Gate this test with #[cfg(feature = "queue")] or assert the appropriate stub behavior when the feature is disabled.

Useful? React with 👍 / 👎.

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.

fleet(queue): fleet queue --version / repo-queue --version silently ignore trailing arguments

1 participant