claude-code - 💡(How to fix) Fix [Bug] Claude Code hangs indefinitely at 38 tokens with no output [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#48239Fetched 2026-04-15 06:29:16
View on GitHub
Comments
1
Participants
2
Timeline
5
Reactions
0
Timeline (top)
labeled ×4commented ×1

Error Message

[{"error":"Error: Request was aborted.\n at makeRequest (/$bunfs/root/src/entrypoints/cli.js:50:3448)\n at processTicksAndRejections (native:7:39)","timestamp":"2026-04-15T02:10:03.497Z"},{"error":"MaxFileReadTokenExceededError: File content (25472 tokens) exceeds maximum allowed tokens (10000). Use offset and limit parameters to read specific portions of the file, or search for specific content instead of reading the whole file.\n at cO7 (/$bunfs/root/src/entrypoints/cli.js:4537:12021)\n at processTicksAndRejections (native:7:39)","timestamp":"2026-04-15T02:12:15.543Z"},{"error":"MaxFileReadTokenExceededError: File content (15092 tokens) exceeds maximum allowed tokens (10000). Use offset and limit parameters to read specific portions of the file, or search for specific content instead of reading the whole file.\n at cO7 (/$bunfs/root/src/entrypoints/cli.js:4537:12021)\n at processTicksAndRejections (native:7:39)","timestamp":"2026-04-15T02:12:15.557Z"},{"error":"Error: Stream idle timeout - partial response received\n at Ap7 (/$bunfs/root/src/entrypoints/cli.js:8039:11200)\n at processTicksAndRejections (native:7:39)","timestamp":"2026-04-15T02:27:44.013Z"}]

Code Example

[{"error":"Error: Request was aborted.\n    at makeRequest (/$bunfs/root/src/entrypoints/cli.js:50:3448)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-04-15T02:10:03.497Z"},{"error":"MaxFileReadTokenExceededError: File content (25472 tokens) exceeds maximum allowed tokens (10000). Use offset and limit parameters to read specific portions of the file, or search for specific content instead of reading the whole file.\n    at cO7 (/$bunfs/root/src/entrypoints/cli.js:4537:12021)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-04-15T02:12:15.543Z"},{"error":"MaxFileReadTokenExceededError: File content (15092 tokens) exceeds maximum allowed tokens (10000). Use offset and limit parameters to read specific portions of the file, or search for specific content instead of reading the whole file.\n    at cO7 (/$bunfs/root/src/entrypoints/cli.js:4537:12021)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-04-15T02:12:15.557Z"},{"error":"Error: Stream idle timeout - partial response received\n    at Ap7 (/$bunfs/root/src/entrypoints/cli.js:8039:11200)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-04-15T02:27:44.013Z"}]
RAW_BUFFERClick to expand / collapse

Bug Description its stuck on 38 tokens for more than 10 minutes, no output, nothing.

Environment Info

  • Platform: linux
  • Terminal: zed
  • Version: 2.1.108
  • Feedback ID: ed8414cd-ad81-4362-b6eb-86047cacfa5a

Errors

[{"error":"Error: Request was aborted.\n    at makeRequest (/$bunfs/root/src/entrypoints/cli.js:50:3448)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-04-15T02:10:03.497Z"},{"error":"MaxFileReadTokenExceededError: File content (25472 tokens) exceeds maximum allowed tokens (10000). Use offset and limit parameters to read specific portions of the file, or search for specific content instead of reading the whole file.\n    at cO7 (/$bunfs/root/src/entrypoints/cli.js:4537:12021)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-04-15T02:12:15.543Z"},{"error":"MaxFileReadTokenExceededError: File content (15092 tokens) exceeds maximum allowed tokens (10000). Use offset and limit parameters to read specific portions of the file, or search for specific content instead of reading the whole file.\n    at cO7 (/$bunfs/root/src/entrypoints/cli.js:4537:12021)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-04-15T02:12:15.557Z"},{"error":"Error: Stream idle timeout - partial response received\n    at Ap7 (/$bunfs/root/src/entrypoints/cli.js:8039:11200)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-04-15T02:27:44.013Z"}]

extent analysis

TL;DR

The issue can be resolved by using offset and limit parameters to read specific portions of the file instead of reading the whole file, which exceeds the maximum allowed tokens.

Guidance

  • The MaxFileReadTokenExceededError suggests that the file content exceeds the maximum allowed tokens (10000), so using offset and limit parameters can help mitigate this issue.
  • Review the code to identify where the file is being read and modify it to use offset and limit parameters to read specific portions of the file.
  • Consider searching for specific content instead of reading the whole file to reduce the number of tokens being read.
  • Verify that the file size and content are within the expected limits to prevent similar issues in the future.

Example

No code snippet is provided as the issue does not contain sufficient information about the code.

Notes

The issue seems to be related to the file size and the maximum allowed tokens, but without more information about the code and the file being read, it's difficult to provide a more specific solution.

Recommendation

Apply workaround: Use offset and limit parameters to read specific portions of the file, as this is the suggested solution in the error message and it directly addresses the MaxFileReadTokenExceededError.

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