Skip to content

CLI: -q does not suppress the "Wrote N bytes … to <path>" status line when --output is used #2614

Closed

Description

@cliffhall

Problem

mcp-inspector --cli -q still prints a status line when --output is used:

$ mcp-inspector --cli --server demo -q --method tools/call --tool-name echo --tool-arg message=x --output out.json
Wrote 85 bytes (json) to /…/out.json        ← stderr

--help describes -q, --quiet as suppressing "everything except the result payload on stdout (or the error envelope on stderr): status lines, warnings, advisory summaries, and a stdio server's own stderr". The Wrote N bytes … line is a status line, so -q should suppress it.

Where

clients/cli/src/handlers/emit-result.ts, in the text-format branch:

} else if (written) {
  await awaitableError(
    `Wrote ${written.bytes} bytes (${written.format}) to ${written.path}\n`,
  );
}

That branch never checks args.quiet, although the same function already passes args.quiet to writeSchemaLintReport a few lines later.

Expected

With -q and --output, nothing is printed on success. Stdout stays empty, as it already does, and stderr is empty too. Without -q, the line still prints. --format json is unaffected, since it reports the write through the stdout envelope ({"output": …}).

Reproduce

Run any successful --method tools/call … --output <file> -q in text format. Found while smoke-testing #2613. The behavior predates that PR: output-file.ts moved unchanged, and emit-result.ts was not touched.

Activity

  1. added this to the v2.11.0 milestone on Oct 7, 2026
  2. added
    bugSomething isn't working
    v2Issues and PRs for v2
    on Oct 7, 2026
  3. cliffhall commented on Oct 7, 2026

    @cliffhall
    MemberAuthor

    Triage: Priority Low (total 5)

    • Severity 2: minor friction. A -q run prints one extra stderr line, and 2>/dev/null is an easy workaround.
    • Urgency 2: wanted eventually. Nothing is blocked on it.
    • Bonuses: +1 bug label
  4. modified the milestones: v2.11.0, v2.10.0 on Oct 7, 2026
  5. self-assigned this
    on Oct 12, 2026
  6. cliffhall commented on Oct 12, 2026

    @cliffhall
    MemberAuthor

    Shipped in #2702.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

bugSomething isn't workingv2Issues and PRs for v2

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions