[BUG] ERROR undefined is not an object (evaluating 'U.length')

Status Fixed / completed
Reported on v2.1.32
Maintainer reply None cached
Activity 4 comments · opened Feb 5, 2026 · closed Feb 6, 2026

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)
  • [x] I am using the latest version of Claude Code

What's Wrong?

I had this conversation in a directory with claude code just now (this is from a new session with claude -r resuming the conversation)

<img width="931" height="1445" alt="Image" src="https://github.com/user-attachments/assets/8284da4d-4c97-48de-a313-8852df490e20" />

But in the original window I got this long JS error: https://gist.github.com/ehsan/35782c17b2aeabfcff6216923a23417b

Claude was in the background after I typed the last message so I didn't see exactly when it hit the bug.

What Should Happen?

Ideally no JS error :)

Error Messages/Logs

Steps to Reproduce

I am not sure if this can reproduce it but here is what I did:

  1. Go to a fresh checkout of my project
  2. Run claude v2.1.32.
  3. Accept the warning about trusting this project.
  4. Type this line how to enable using teams
  5. Type this line when it finished can you put it in my .claude/settings.local.json please? also set "teammateMode" to tmux

Claude Model

Opus

Is this a regression?

I don't know

Last Working Version

_No response_

Claude Code Version

2.1.32

Platform

Anthropic API

Operating System

macOS

Terminal/Shell

iTerm2

Additional Information

_No response_

View original on GitHub ↗

4 Comments

github-actions[bot] · 8 months ago

Found 3 possible duplicate issues:

  1. https://github.com/anthropics/claude-code/issues/23428
  2. https://github.com/anthropics/claude-code/issues/23435
  3. https://github.com/anthropics/claude-code/issues/23415

This issue will be automatically closed as a duplicate in 3 days.

  • If your issue is a duplicate, please close it and 👍 the existing issue instead
  • To prevent auto-closure, add a comment or 👎 this comment

🤖 Generated with Claude Code

sangemaru · 8 months ago

Additional report — same crash on Linux

Environment

  • Claude Code: 2.1.32
  • OS: Linux 6.18.3-arch1-1 (Arch Linux, x86_64)
  • Bun: 1.3.6
  • Node: v22.19.0
  • Terminal: Ghostty (via Hyprland/Wayland)
  • Model: Opus 4.6

Error

Same root cause, different minified symbol (w.length vs U.length in the macOS report):

ERROR  undefined is not an object (evaluating 'w.length')

 /$bunfs/root/claude:682:20562

Stack trace (deobfuscated path)

i8   (areHookInputsEqual)  ← crashes here: w (previous deps) is undefined
mK   (updateEffect)
rX   (useEffect update)
_f   (useSyncExternalStore)
<anonymous>                 ← app component
J$                          ← Ink render
OIB                         ← Ink reconciler
x8H                         ← Ink reconciler
$8   (renderWithHooks)
OU   (updateFunctionComponent)

Analysis

The crash is in React's areHookInputsEqual function, invoked from the useSyncExternalStore hook update path. A useSyncExternalStore hook received undefined as its previous dependency array during a re-render — meaning the store's snapshot or subscribe function reference became invalid between renders.

This is consistent with the original report's scenario (background session / resumed session), suggesting a race condition in store teardown/subscription during session state changes.

Context

The crash occurred during normal usage. Multiple MCP servers were active (Serena, Playwright, Asana, etc.). Full minified React reconciler source was dumped to terminal (~700 lines of minified code from /$bunfs/root/claude:679-685).

Confirming

  • Same version (2.1.32)
  • Same class of error (React reconciler, undefined is not an object, .length property access)
  • Cross-platform: occurs on both macOS and Linux
ehsan · 8 months ago

this is probably a duplicate of #23428

github-actions[bot] · 8 months ago

This issue has been automatically locked since it was closed and has not had any activity for 7 days. If you're experiencing a similar issue, please file a new issue and reference this one if it's relevant.