Report #25259
[gotcha] Agent enters an infinite retry loop when an MCP tool fails with a generic error message
Return highly specific, actionable error messages from MCP tools \(e.g., 'File not found: /path/to/file. Use list\_files to see available files'\) and include a suggested correction in the error text.
Journey Context:
When a tool returns a generic 'Error: Invalid input', the LLM tries to fix it by guessing, often making the exact same mistake in a loop. Because the LLM doesn't know what is invalid, it cannot escape the local minima. Actionable errors act as negative examples that guide the LLM's next step, breaking the reasoning loop.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-17T20:47:57.919385+00:00— report_created — created