[BUG] Maximum call stack exceeded
Open 💬 5 comments Opened Jan 5, 2026 by vjeux
Preflight Checklist
- [x] I have searched existing issues and this hasn't been reported yet
- [x] This is a single bug report (please file separate reports for different bugs)
- [ ] I am using the latest version of Claude Code
What's Wrong?
I've been using Claude Code in a loop 24/7 for the past 2 weeks and it's been flawless, just encountered my first fatal, wanted to share it so your team knows about it. Note that it's from a version a month old, so may already have been fixed: 2.0.61 (Claude Code).
What Should Happen?
Should not crash
Error Messages/Logs
⏵⏵ accept edits on (shift+tab to cycle)
Exception in PromiseRejectCallback:
file:///usr/local/bin/claude_code/node_modules/@anthropic-ai/claude-code/cli.js:3094
`)||J.includes("**")||J.includes("*"))return;if(X.includes("prompt is too long")||X.includes("context length")||X.includes("token limit"))return;if(X.includes("thanks")||X.includes("thank you")||X.includes("looks good")||X.includes("that worked")||X.includes("that's all"))return;A.toolUseContext.setAppState((W)=>({...W,promptSuggestion:{text:J,shownAt:Date.now()}}));let I=G.totalUsage.input_tokens+G.totalUsage.cache_creation_input_tokens+G.totalUsage.cache_read_input_tokens;QA("tengu_prompt_suggestion_shown",{source:"forked_agent",...I>0&&{cacheHitRate:G.totalUsage.cache_read_input_tokens/I},...!1})}catch(Q){t(Q instanceof Error?Q:Error("Prompt suggestion generation failed"))}}var Px7="tengu_prompt_suggestion",SX1=!1;var _V0=O(()=>{EX1();AB();t2();v0();M0();m1(); // ....
RangeError: Maximum call stack size exceeded
Exception in PromiseRejectCallback:
file:///usr/local/bin/claude_code/node_modules/@anthropic-ai/claude-code/cli.js:3094
`)||J.includes("**")||J.includes("*"))return;if(X.includes("prompt is too long")||X.includes("context length")||X.includes("token limit"))return;if(X.includes("thanks")||X.includes("thank you")||X.includes("looks good")||X.includes("that worked")||X.includes("that's all"))return;A.toolUseContext.setAppState((W)=>({...W,promptSuggestion:{text:J,shownAt:Date.now()}}));let I=G.totalUsage.input_tokens+G.totalUsage.cache_creation_input_tokens+G.totalUsage.cache_read_input_tokens;QA("tengu_prompt_suggestion_shown",{source:"forked_agent",...I>0&&{cacheHitRate:G.totalUsage.cache_read_input_tokens/I},...!1})}catch(Q){t(Q instanceof Error?Q:Error("Prompt suggestion generation failed"))}}var Px7="tengu_prompt_suggestion",SX1=!1;var _V0=O(()=>{EX1();AB();t2();v0();M0();m1(); // ...
RangeError: Maximum call stack size exceeded
file:///usr/local/bin/claude_code/node_modules/@anthropic-ai/claude-code/cli.js:3094
`)||J.includes("**")||J.includes("*"))return;if(X.includes("prompt is too long")||X.includes("context length")||X.includes("token limit"))return;if(X.includes("thanks")||X.includes("thank you")||X.includes("looks good")||X.includes("that worked")||X.includes("that's all"))return;A.toolUseContext.setAppState((W)=>({...W,promptSuggestion:{text:J,shownAt:Date.now()}}));let I=G.totalUsage.input_tokens+G.totalUsage.cache_creation_input_tokens+G.totalUsage.cache_read_input_tokens;QA("tengu_prompt_suggestion_shown",{source:"forked_agent",...I>0&&{cacheHitRate:G.totalUsage.cache_read_input_tokens/I},...!1})}catch(Q){t(Q instanceof Error?Q:Error("Prompt suggestion generation failed"))}}var Px7="tengu_prompt_suggestion",SX1=!1;var _V0=O(()=>{EX1();AB();t2();v0();M0();m1(); // ...
RangeError: Maximum call stack size exceeded
at m$.next (<anonymous>)
at m$ (file:///usr/local/bin/claude_code/node_modules/@anthropic-ai/claude-code/cli.js:3094:7954)
at m$.next (<anonymous>)
at m$ (file:///usr/local/bin/claude_code/node_modules/@anthropic-ai/claude-code/cli.js:3094:7954)
at m$.next (<anonymous>)
at m$ (file:///usr/local/bin/claude_code/node_modules/@anthropic-ai/claude-code/cli.js:3094:7954)
at m$.next (<anonymous>)
at m$ (file:///usr/local/bin/claude_code/node_modules/@anthropic-ai/claude-code/cli.js:3094:7954)
at m$.next (<anonymous>)
at m$ (file:///usr/local/bin/claude_code/node_modules/@anthropic-ai/claude-code/cli.js:3094:7954)
Node.js v24.10.0
Steps to Reproduce
Not really sure what I did. I did close my laptop while it was running, so maybe that triggered it.
Claude Model
Opus
Is this a regression?
I don't know
Last Working Version
_No response_
Claude Code Version
2.0.61
Platform
Anthropic API
Operating System
macOS
Terminal/Shell
iTerm2
Additional Information
This issue has 5 comments on GitHub. Read the full discussion on GitHub ↗