Skip to content

[Bug] MCP tool parameters arrive at MCP servers as {} — affects tavily/brave/context7/chrome-devtools on glm-5.3-flash and gpt-5.6-luna; built-in tools unaffected #1306

Description

@dvelm

Status (2026-09-09): Still reproduces on 0.0.172 after a clean reinstall. Root cause is covered by PR #1259 (bug families 1, 5, 6); fix files are not yet present in the 0.0.172 package (no zod-safe-clone in the shipped bundle).

What happened

Every tool call to any MCP-server-provided tool arrives at the MCP server with an empty arguments object ({}) — the model's parameters never reach the tool. Validation fails with zod errors like expected string, received undefined.

Built-in tools (read_files, write_file, run_terminal_command, web_search, ask_user with deeply nested schemas, …) accept identical multi-parameter payloads with zero problems in the same session. The failure is model-independent: it reproduces on glm-5.3-flash and was independently observed on gpt-5.6-luna (separate session, same user), so this looks like a client/tool-bridge serialization bug rather than a model issue.

Repro rate: ~100% — zero successful parameterized MCP calls in the entire session, retried across many turns and tool servers.

This looks like the same root cause as #912 (tool inputSchema.properties stripped at registration → empty schema → expected string, received undefined). Filed as a standalone report because it reproduces on 4 mainstream servers (not just a niche Dart server) and 2 different models, which widens the blast radius. A fix for #912 is already pending in #1259 — this report adds reproduction evidence for merging it.

Steps to reproduce

  1. Start a freebuff session with any MCP server configured (tested: tavily, brave-search, context7, chrome-devtools).
  2. Ask the agent anything that triggers an MCP tool call, e.g. "search the web for X" (tavily__tavily_search) or "open https://example.com in the browser" (chrome-devtools__navigate_page).
  3. The model emits a well-formed tool call with parameters (e.g. {"query": "X"}).
  4. The MCP server receives an empty arguments object and returns a zod validation error (see Logs).

Controls in the same session (proves the model emits parameters correctly):

  • chrome-devtools__list_pages (zero params): SUCCESS
  • built-in web_search {query, depth}: SUCCESS (dozens of calls)
  • built-in read_files [{path}, {path, offset, limit}]: SUCCESS
  • built-in ask_user {questions: [{question, header, options: [{label, description}], multiSelect}]} (deeply nested schema): SUCCESS

So: zero-param MCP tools work; 1+-param MCP tools receive {}; built-in tools with equal or more complex schemas work flawlessly. The parameters exist in the model's tool call but the object delivered to the MCP server is {}.

Where does this happen?

MCP servers or tools

Operating system

Windows

Version

0.0.172 (also reproduces on 0.0.93; retested after clean reinstall on 2026-09-09)

Model

glm-5.3-flash (also reproduced on gpt-5.6-luna in a separate session)

Logs or screenshots

Error during tool call: Invalid parameters for tavily__tavily_search: [
  { "expected": "string", "code": "invalid_type", "path": ["query"],
    "message": "Invalid input: expected string, received undefined" }
]
Original tool call input: {}. Please check the tool name and arguments and try again.

Same signature for every affected tool:

Tool zod path expected
brave__brave_web_search ["query"] string
context7__resolve-library-id ["query", "libraryName"] string
chrome-devtools__navigate_page ["pageId"] number
chrome-devtools__new_page ["url"] string

Similar upstream bugs where tool-call arguments were dropped in the client→MCP path, for reference:

Debugging pointers: dump the raw tool_call arguments at the agent-loop boundary vs. what is dispatched to the MCP server; check any serializer that drops the whole arguments object on a falsy/empty value; check the strict JSON-schema↔zod conversion of MCP inputSchema (an unparseable conversion can make the client discard provided args before dispatch) — cf. the cloneDeepKeepingZod fix in #1259.

Activity

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

    bot:triagedClassified by the community triage bottype:bugA defect in the code with a reproducible failure

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions