Skip to content

fleet dispatch status silently ignores all arguments — --help performs a live GET /health and typos are swallowed #5560

Closed

Description

@dezren39

Bug: fleet dispatch status silently ignores all arguments — --help performs a live GET /health instead of printing help, and typos are swallowed

pkgs/fleet/crates/fleet-dispatch/src/lib.rs (new in step 4, #5432):

  • run() routes the verb and discards the rest of argv for status:
Some("status") => verb_status(config),
  • verb_status(config) takes no argument list at all — it unconditionally
    picks a transport and exchanges GET /health.
  • Its sibling verbs behave differently: verb_launch / verb_enqueue both
    scan for --help/-h first and print their usage with no network
    call
    , and their arguments go through parse_args, which rejects
    unknown options with a usage error (exit 2).

So fleet dispatch status --help does a real network request (possibly a
CONNECT tunnel through the proxy egress on the sandbox seat) and prints the
service's health JSON; fleet dispatch status --bogus-junk (or any stray
positional/typo) is silently accepted and does the same. There is no way to
ask what status accepts, and a mistyped invocation looks like a
successful health check.

Verified this run (laptop probe, real crate @ main 7cd293e)

Probe crate ~/git/fleet/probe-dispatch-status (path-dep on the real
fleet-dispatch) calling fleet_dispatch::run with
[dispatch] url = http://127.0.0.1:48931 pointed at a fake pm-dispatch
server that logs requests and returns {"ok":true,"build":"probe"}:

  • Case 1 — status --help: printed the health JSON + transport line,
    exit 0; server log shows GET /health. No help text.
  • Case 2 — status --bogus-junk: identical output, exit 0; server log
    shows GET /health. The unknown argument was never rejected.
  • Case 3 — control, status: same output, exit 0, GET /health
    (correct behavior).
  • Case 4 — control, launch --help: printed Usage: fleet dispatch launch …, exit 0, no server hit.

Server log after all four cases: exactly three GET /health lines
(cases 1–3).

Why it matters

Acceptance criteria

  • fleet dispatch status --help (and -h) prints a status usage
    text and performs no network request, mirroring
    launch/enqueue.
  • fleet dispatch status <anything-else> fails with a usage error
    (exit 2) naming the unexpected argument, before any transport is
    opened.
  • Bare fleet dispatch status is unchanged: GET /health, health
    JSON + transport line, exit 0.
  • Unit tests pin all three behaviors (help returns without touching
    the network; unknown args are usage errors; the help/rejection
    paths need no live service).
  • cargo test -p fleet-dispatch green.

Activity

  1. 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
    priority/normalOrdinary priority (the default)
    work/self-assignedAn agent grabbed this item directly, outside the queue
    app/fleetpkgs/fleet multicall binary + platform crates
    on Nov 4, 2026
  2. dezren39 commented on Nov 4, 2026

    @dezren39
    MemberAuthor

    🤖 Agent note · filed

    • Agent: new-issue-creator-code-b (creator lane B)
    • Session / ID: new-issue-creator-code-b run 2026-11-04 09:20 CST
    • Found via: filed this run
    • Task: Fix fleet dispatch status ignoring all arguments — --help/-h prints status usage with no network call; any other argument is a usage error (exit 2) before transport; bare status unchanged. Verified pre-filing with a laptop probe (real fleet-dispatch crate @ 7cd293e) against a fake pm-dispatch server: status --help and status --bogus-junk both issued GET /health and printed health JSON, while launch --help printed usage with no server hit.
    • Expectation: effort xs; done = fix merged, cargo test -p fleet-dispatch green on the laptop, probe re-run shows help/rejection make no server request. Guarded self-solve this run (trivial, small, low-risk).
    • Links: probe ~/git/fleet/probe-dispatch-status (laptop); body evidence in the issue.
  3. dezren39 commented on Nov 4, 2026

    @dezren39
    MemberAuthor

    🤖 Agent note · done

    • Agent: new-issue-creator-code-b (creator lane B)
    • Session / ID: new-issue-creator-code-b run 2026-11-04 09:20 CST
    • Found via: filed this run; guarded self-solve (§4)
    • Task: Fixed — PR fix(fleet-dispatch): status honors --help and rejects stray arguments #5564 squash-merged (d3fb961). verb_status now takes the verb's args: --help/-h prints STATUS_USAGE and returns before any transport is opened; any other argument is a usage error (exit 2) naming it; bare status unchanged. New pinning test status_help_and_rejection_need_no_service.
    • Expectation: done — cargo test -p fleet-dispatch green on the laptop (7 passed, fmt applied); behavioral re-probe against the fixed crate (fake pm-dispatch server): status --help → usage, exit 0, no request; status --bogus-junk → usage error, exit 2, no request; bare status → health JSON, exit 0; server log shows exactly one GET /health (the control). Worktree/branch removed; laptop primary fast-forwarded to merged main.
    • Links: PR fix(fleet-dispatch): status honors --help and rejects stray arguments #5564; probes ~/git/fleet/probe-dispatch-status (pre-fix) and ~/git/fleet/probe-dispatch-fixed (post-fix) on the laptop.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    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 jobtask/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