[BUG] Crash: (i || "").toLowerCase is not a function on Write/Resume (Windows, v2.1.89-2.1.90)

Resolved 💬 4 comments Opened Apr 2, 2026 by kostikbond Closed Apr 18, 2026

Bug Description

Claude Code crashes with (i || "").toLowerCase is not a function error during:

  1. Writing a large file (HTML, ~21k tokens via Write tool)
  2. Resuming (/resume) the same session afterward

The crash is 100% reproducible on resume — selecting the crashed session immediately triggers the same error.

Error Output

ERROR (i || "").toLowerCase is not a function

file:///C:/Users/820g2/AppData/Roaming/npm/node_modules/@anthropic-ai/claude-code/cli.js:1588:2076

- Object.g (file:///C:/Users/820g2/AppData/Roaming/npm/node_modules/@anthropic-ai/claude-code/cli.js:1588:2076)
-  _OK (file:///C:/Users/820g2/AppData/Roaming/npm/node_modules/@anthropic-ai/claude-code/cli.js:3012:6423)
- ls1.render (file:///C:/Users/820g2/AppData/Roaming/npm/node_modules/@anthropic-ai/claude-code/cli.js:3015:71)
-  (file:///C:/Users/820g2/AppData/Roaming/npm/node_modules/@anthropic-ai/claude-code/cli.js:3015:3779)
- zY (file:///C:/Users/820g2/AppData/Roaming/npm/node_modules/@anthropic-ai/claude-code/cli.js:554:20984)
- Kw (file:///C:/Users/820g2/AppData/Roaming/npm/node_modules/@anthropic-ai/claude-code/cli.js:554:39522)
- F6 (file:///C:/Users/820g2/AppData/Roaming/npm/node_modules/@anthropic-ai/claude-code/cli.js:554:36891)
- u6 (file:///C:/Users/820g2/AppData/Roaming/npm/node_modules/@anthropic-ai/claude-code/cli.js:554:36418)
- dk (file:///C:/Users/820g2/AppData/Roaming/npm/node_modules/@anthropic-ai/claude-code/cli.js:554:52607)
- jb6 (file:///C:/Users/820g2/AppData/Roaming/npm/node_modules/@anthropic-ai/claude-code/cli.js:554:86862)

Context

  • The crash occurs in the renderer (ls1.render), not in business logic
  • The file being written was constructor.html — a large single-file HTML app (~21.2k tokens)
  • Task progress was visible (Phase 1 checkboxes) before the crash
  • The crash happens both during the initial Write and on every subsequent Resume of that session

Environment

  • OS: Windows 10 Home 10.0.19045
  • Shell: PowerShell + Git Bash
  • Claude Code version: 2.1.89 (also reproduced on 2.1.90)
  • Install method: npm (global)
  • Node.js: v24.11.1
  • Terminal: Windows Terminal
  • Plugins: 16 enabled (including codex, chrome-devtools-mcp, playwright, etc.)
  • MCP servers: context7, conv-search + claude.ai connectors (Gmail, Calendar, Notion)

Steps to Reproduce

  1. Start Claude Code in a project directory
  2. Ask Claude to write a large HTML file (~20k+ tokens) via the Write tool
  3. Observe crash during write OR after write completes
  4. Try /resume to resume the session — crash repeats immediately

Expected Behavior

Write should complete successfully and session should be resumable.

Workaround

None found. The session is permanently unresumable.

View original on GitHub ↗

This issue has 4 comments on GitHub. Read the full discussion on GitHub ↗