GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — fleet: serve <broker-role> silently ignores all trailing arguments — a typo'd flag starts the daemon instead of erroring · Issue #5568 · developing-today/code

fleet: serve <broker-role> silently ignores all trailing arguments — a typo'd flag starts the daemon instead of erroring #5568

New issue
Copy link
New issue
Copy link
Closed
#6323
Closed
fleet: serve <broker-role> silently ignores all trailing arguments — a typo'd flag starts the daemon instead of erroring#5568
#6323
Copy link
Assignees
dezren39
Labels
app/fleetpkgs/fleet multicall binary + platform crateskind/bugSomething isn't working (prefixed form of the classic bug label)priority/normalOrdinary priority (the default)source/creatorFiled by the new-issue-creator jobstatus:donetask/small-fixQueue packet kind: bounded fix with reproduction and targeted tests

Description

@dezren39
dezren39
opened on Nov 4, 2026
Issue body actions

Problem

fleet serve <broker-role> <anything> silently discards every argument after the role and starts the daemon anyway. The broker entry points take no arguments at all, so there is nothing for a stray argument to bind to — a typo'd flag or an extra word does not produce an error, it produces a running queue-broker / secrets-broker.

This is the un-fixed remainder of #5488: that fix intercepted a help flag in the one position after the role (wants_domain_help), but any non-help argument in the same position — and any argument at all through the argv0 aliases — still flows straight into the daemon entry point.

Evidence (verified this run, laptop primary at e844ed1)

Code:

  • pkgs/fleet/crates/fleet/src/main.rs — run_domain: for serve + queue-broker it calls fleet_queue::queue_broker::run() and for secrets-broker fleet_queue::secrets_broker::run(), never inspecting args[1..]. The argv0-alias route (queue-broker / secrets-broker as argv0) lands in the same run_domain after the implied role arg is prepended, so it has the same hole.
  • pkgs/fleet/crates/fleet-queue/src/queue_broker.rs:589 — pub fn run() -> i32 (no args).
  • pkgs/fleet/crates/fleet-queue/src/secrets_broker.rs:189 — pub fn run() -> i32 (no args).

Probe (fleet binary rebuilt on the laptop from e844ed1, Source rev: e844ed152dd1; HOME pointed at an empty dir so the daemon dies at its first startup step — the token-file read — proving which path was entered):

invocation result
fleet serve queue-broker --help domain help, exit 0 (control — #5488 fix works)
fleet serve queue-broker queue-broker: cannot read token file …, exit 3 (daemon startup)
fleet serve queue-broker --bogus-junk identical token-file error, exit 3
fleet serve queue-broker frobnicate identical token-file error, exit 3
fleet serve secrets-broker --bogus-junk secrets-broker: cannot read token file …, exit 3
queue-broker --bogus-junk (argv0 alias) identical token-file error, exit 3

With the real token files present the same invocations proceed past the token read to binding the broker port (observed with the pre-fix binary: cannot bind 100.99.113.103:4801: Address already in use — it had entered run() far enough to attempt the bind).

Why it matters

These brokers hold the queue's service-role credentials path and the secrets resolver. A systemd unit, wrapper script, or operator invocation with a typo'd or stale flag (e.g. a removed --bind option, exactly the shape #5488's test comment worries about) silently starts a daemon with default bind/token settings instead of failing loudly — the same fail-open shape the fleet has been stamping out in #5560 (dispatch status), #5460 (fleet-config) and the deploy-script series (#3287/#3297/#3296).

Acceptance criteria

  • fleet serve queue-broker <any extra arg> and fleet serve secrets-broker <any extra arg> exit 2 with a usage error naming the unexpected argument, before any daemon startup (no token-file read, no bind attempt).
  • The argv0 aliases behave identically: queue-broker <extra> / secrets-broker <extra> exit 2.
  • fleet serve <role> --help / -h / help still prints domain help with exit 0 (fleet: serve <role> --help (and the queue-broker/secrets-broker argv0 aliases) starts the daemon instead of printing help #5488 behavior preserved), and a bare fleet serve <role> still starts the daemon.
  • A pinning unit test covers the rejection (in the style of the existing wants_domain_help tests in crates/fleet/src/main.rs).
  • cargo test -p fleet passes on the laptop or in CI.

Activity

Next
  1. developing-today commented on Nov 4, 2026

    @developing-today
    developing-todayBot
    on Nov 4, 2026 – with developing.today
    Contributor
    More actions

    CODE-1376

  2. dezren39
    added
    kind/bugSomething isn't working (prefixed form of the classic bug label)
    task/small-fixQueue packet kind: bounded fix with reproduction and targeted tests
    source/creatorFiled by the new-issue-creator job
    status/needs-triageNot yet triaged; needs a first look
    queue/queuedHas a queued queue task
    priority/normalOrdinary priority (the default)
    app/fleetpkgs/fleet multicall binary + platform crates
    on Nov 4, 2026
  3. dezren39 commented on Nov 4, 2026

    @dezren39
    dezren39
    on Nov 4, 2026
    MemberAuthor
    More actions

    🤖 Agent note · filed

    • Agent: new-issue-creator job (new-issue-creator-code-a)
    • Session / ID: new-issue-creator-code-a run 2026-11-04T15:35Z (cron job new-issue-creator-code-a)
    • Found via: filed this run
    • Task: fleet serve broker roles (queue-broker / secrets-broker) silently ignore all trailing arguments and start the daemon; verified by code read + laptop probe at e844ed1 (see issue body). Remainder of fleet: serve <role> --help (and the queue-broker/secrets-broker argv0 aliases) starts the daemon instead of printing help #5488, same fail-open class as fleet dispatch status silently ignores all arguments — --help performs a live GET /health and typos are swallowed #5560.
    • Expectation: effort/xs — reject extra args with a usage error (exit 2) before daemon startup, pinning test included; "done" = acceptance criteria in the issue body met.
    • Links: evidence + probe table in the issue body; body file hidden_files/issue-fleet-serve-broker-args.md
  4. dezren39 commented on Nov 4, 2026

    @dezren39
    dezren39
    on Nov 4, 2026
    MemberAuthor
    More actions

    🤖 Agent note · picked up

    • Agent: new-issue-creator job (new-issue-creator-code-a)
    • Session / ID: new-issue-creator-code-a run 2026-11-04T15:35Z
    • Found via: self-assigned during new-issue-creator-code-a run (guarded self-solve, lifecycle protocol §4 — filed this run, trivial, no safety labels)
    • Task: reject trailing args after the queue-broker/secrets-broker roles in run_domain (exit 2 usage error) + pinning test; branch creator-a/5568-serve-broker-args; queue task 9662 cancelled as self-assigned in the same pass.
    • Expectation: effort/xs — done = PR merged with cargo test -p fleet green on the laptop and the fixed binary re-probed (junk → exit 2, --help → exit 0, bare role → daemon path).
    • Links: task 9662 (cancelled, self-assigned)
  5. dezren39
    added
    work/self-assignedAn agent grabbed this item directly, outside the queue
    status/in-progressQueue worker lifecycle state
    and removed
    status/needs-triageNot yet triaged; needs a first look
    queue/queuedHas a queued queue task
    on Nov 4, 2026
  6. dezren39 commented on Nov 4, 2026

    @dezren39
    dezren39
    on Nov 4, 2026
    MemberAuthor
    More actions

    🤖 Agent note · handed off

    • Agent: new-issue-creator job (new-issue-creator-code-a)
    • Session / ID: new-issue-creator-code-a run 2026-11-04T15:35Z
    • Found via: filed this run
    • Task: Stand-down correction to my "picked up" note above: the guarded self-solve takeover raced a queue claim — task 9662 was already claimed by the queue worker when the cancel ran (cancel_repo_task: task 9662 is not queued or parked). Per lifecycle protocol §6 Duty 4, the first holder keeps the item: the queue worker holds task 9662; I am NOT self-solving. Labels reset to the claimed state (queue/claimed + work/assigned + status/in-progress).
    • Expectation: effort/xs — the claiming worker implements the acceptance criteria in the issue body.
    • Links: task 9662 (claimed, repo-health-code-pilot)
  7. 48 remaining items

  8. dezren39
    added
    queue/claimedQueue worker lifecycle state
    status/in-progressQueue worker lifecycle state
    and removed
    status/parkedDeliberately paused with a recorded resume condition
    queue/parkedQueue task is parked (waiting on CI, time, or an event)
    on Nov 5, 2026
  9. dezren39 commented on Nov 7, 2026

    @dezren39
    dezren39
    on Nov 7, 2026
    MemberAuthor
    More actions

    Picked up by repo-worker-code-w — working this now. (Fleet queue fallback mode: the queue backend is down, so this issue's comments carry the claim. The claim stays live while repo-worker-code-w posts progress markers; after 30 minutes of silence any other worker may pick this up.)

  10. dezren39 commented on Nov 7, 2026

    @dezren39
    dezren39
    on Nov 7, 2026
    MemberAuthor
    More actions

    Progress from repo-worker-code-w: verified: PR #6323 implements fix, Codex clean, but branch diverged/conflicted vs current main; resolving conflict on laptop, re-running cargo test -p fleet, then merge

  11. dezren39 commented on Nov 7, 2026

    @dezren39
    dezren39
    on Nov 7, 2026
    MemberAuthor
    More actions

    Progress from repo-worker-code-w: implementation_complete: PR #6323 conflict resolved (merge 375b717, both helpers kept), cargo test -p fleet 15 unit + 7 integration passed on laptop, rustfmt clean, PR mergeable; checking Codex/checks on new head then merge

  12. dezren39
    closed this as completedin #6323on Nov 7, 2026
  13. dezren39 commented on Nov 7, 2026

    @dezren39
    dezren39
    on Nov 7, 2026
    MemberAuthor
    More actions

    🤖 Agent note · done (fixed_merged)

    • Agent: repo-worker-code, lane code-w (fallback mode — queue backend down, code#6619)
    • Task: small-fix issue fleet: serve <broker-role> silently ignores all trailing arguments — a typo'd flag starts the daemon instead of erroring #5568 — fleet serve <broker-role> silently ignored trailing arguments.
    • What happened: the fix already existed as PR fix(fleet): reject stray broker role arguments #6323 (single commit 633c630, Codex round 1 clean) but the branch had diverged 384 commits behind main and was conflicted in pkgs/fleet/crates/fleet/src/main.rs (both sides added a helper after wants_domain_help). I resolved the conflict on the laptop keeping both helpers (broker_argument_error + search_serve_tail), merge commit 375b717 pushed to the PR branch.
    • Verification: cargo test -p fleet on the laptop — 15 unit + 7 integration passed, including the pinning test broker_roles_reject_trailing_args_through_serve_and_argv0_aliases and main's new search_serve tests; rustfmt --check clean. Codex re-review of the new head 375b717 completed with no findings. PR CI checks were still QUEUED at merge (slow infra, noted fleet-wide this shift); merged under the standing merge authority after the laptop verification.
    • Outcome: PR fix(fleet): reject stray broker role arguments #6323 MERGED, merge commit 5edd83a; issue fleet: serve <broker-role> silently ignores all trailing arguments — a typo'd flag starts the daemon instead of erroring #5568 auto-closed. Acceptance criteria met: extra args after either broker role (serve form and argv0 aliases) exit 2 naming the argument before daemon startup, --help/-h/help still exit 0, bare role unchanged, pinning test included.
    • Terminal: fallback release, outcome done (fixed_merged).
  14. dezren39 commented on Nov 7, 2026

    @dezren39
    dezren39
    on Nov 7, 2026
    MemberAuthor
    More actions

    Released by repo-worker-code-w (outcome: done). fixed_merged: PR #6323 merged 5edd83a (conflict vs main resolved in merge 375b717 keeping both helpers; cargo test -p fleet 15 unit + 7 integration passed on laptop, rustfmt clean, Codex re-review of new head clean); issue #5568 closed by merge; note #5568 (comment) heartbeat chain

  15. dezren39
    removed
    queue/claimedQueue worker lifecycle state
    work/assignedQueue worker lifecycle state
    status:in-review
    status/in-progressQueue worker lifecycle state
    on Nov 7, 2026
  16. developing-today
    added
    status:done
    on Nov 7, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

  • @dezren39
    dezren39

Labels

app/fleetpkgs/fleet multicall binary + platform crateskind/bugSomething isn't working (prefixed form of the classic bug label)priority/normalOrdinary priority (the default)source/creatorFiled by the new-issue-creator jobstatus:donetask/small-fixQueue packet kind: bounded fix with reproduction and targeted tests

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

    You are visitor 01402775 — GeezerVison does not store the pages you look up.
    Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.