claude-code - ๐Ÿ’ก(How to fix) Fix Tool calls silently fail / return empty mid-session [1 comments, 2 participants]

Official PRs (โ€ฆ)
ON THIS PAGE

Recommended Tools

ร—6

Utilities matched from this issueโ€™s tags and category โ€” try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful ยท Quick feedback

Loadingโ€ฆ
GitHub stats
anthropics/claude-code#48195โ€ขFetched 2026-04-15 06:30:28
View on GitHub
Comments
1
Participants
2
Timeline
5
Reactions
0
Timeline (top)
labeled ร—4commented ร—1

Error Message

~/.claude/logs/ on the affected machine.

Root Cause

Repro

Unclear root cause. Degradation appeared mid-session after ~dozen successful tool calls. No obvious trigger (no large outputs, no special characters, no long-running commands at the point of failure).

Fix Action

Workaround

Restart the Claude Code session (exit + claude again).

RAW_BUFFERClick to expand / collapse

Environment

  • OS: Fedora 43 (Gram17-fedora laptop, GNOME Wayland)
  • Model: claude-opus-4-6[1m]
  • Claude Code: latest as of 2026-04-14

Symptom

Bash tool calls mid-session either:

  1. Return Tool result missing due to internal error, OR
  2. Hang indefinitely with no output returned to the model

Failure is intermittent within the same session โ€” some calls succeed, others silently fail. Once degradation begins, the session becomes unusable as the model cannot observe command results.

Impact

From the user's perspective the assistant appears to freeze or loop. From the model's perspective, tool results are missing so it cannot make progress or diagnose. Creates long frustrating back-and-forth where neither side can tell what's broken.

Repro

Unclear root cause. Degradation appeared mid-session after ~dozen successful tool calls. No obvious trigger (no large outputs, no special characters, no long-running commands at the point of failure).

Expected

Tool calls should either succeed with output, or return a structured error the model can recognize and recover from.

Workaround

Restart the Claude Code session (exit + claude again).

Logs

~/.claude/logs/ on the affected machine.

extent analysis

TL;DR

Restarting the Claude Code session is a reliable workaround for the intermittent tool call failures.

Guidance

  • Investigate the logs in ~/.claude/logs/ for any error patterns or clues that might indicate the root cause of the internal error or hanging issue.
  • Monitor the number of successful tool calls before the degradation begins to see if there's a consistent threshold or trigger.
  • Consider adding additional logging or debugging statements to the Bash tool calls to gather more information about the failures.
  • Test the tool calls with a variety of inputs and commands to see if the issue is specific to certain types of commands or outputs.

Example

No specific code snippet can be provided without more information about the Bash tool calls or the Claude Code implementation.

Notes

The root cause of the issue is unclear, and the workaround of restarting the session may not be a long-term solution. Further investigation and debugging are needed to determine the underlying cause of the problem.

Recommendation

Apply the workaround of restarting the Claude Code session when the issue occurs, as it is a reliable way to restore functionality, although it does not address the underlying cause.

Vote matrix ยท Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loadingโ€ฆ

Still need to ship something?

ร—6

Another batch ranked right after the header list โ€” different links, same matching logic.

Back to top recommendations

TRENDING

claude-code - ๐Ÿ’ก(How to fix) Fix Tool calls silently fail / return empty mid-session [1 comments, 2 participants]