Spurious "Your tool call was malformed and could not be parsed" injected after tool calls that actually executed

Resolved 💬 1 comment Opened Jun 6, 2026 by TKMD Closed Jul 12, 2026

Summary

Repeatedly within a session, the message "Your tool call was malformed and could not be parsed. Please retry." is injected immediately after a tool call — but the tool actually executed and returned normal output. It appears to be a false positive from the tool-call parsing layer rather than a genuinely malformed call.

Environment

  • Claude Code: 2.1.167
  • Model: claude-opus-4-8 (Opus 4.8)
  • OS: Linux 6.8.0-117-generic
  • Session shape: long-running session with frequent background subagents (Agent tool), MCP tools, deferred-tool loading (ToolSearch), and occasional parallel tool calls.

Symptoms

  • After a tool call (observed with single Bash, Edit, Agent, SendMessage, AskUserQuestion), a "malformed … Please retry" line is appended even though the tool ran and output came back.
  • Frequency rose as the session grew longer / tool-call volume increased.

Expected

No "malformed" error when the call was well-formed and executed successfully.

Actual

The error is injected after successful execution, causing confusion and wasted retries.

Notes

  • Could not isolate a 100% reproduction; correlates with long sessions and high tool-call volume. Some cases might be schema-extra fields on a call, but it also occurs on plain single Bash calls that succeed.

View original on GitHub ↗

This issue has 1 comment on GitHub. Read the full discussion on GitHub ↗