[BUG] Claude Code 2.1.27 freezes after first message - regression from 2.1.25

Resolved 💬 24 comments Opened Jan 31, 2026 by ashkonmousavi Closed Jan 31, 2026

Description

Claude Code 2.1.27 freezes after sending the first message. The UI shows "Frolicking..." (thinking animation) and then becomes completely unresponsive. Downgrading to 2.1.25 immediately fixes the issue.

Environment

  • OS: Windows 11 + WSL2 (Ubuntu)
  • Claude Code Version: 2.1.27 (broken), 2.1.25 (works)
  • Terminal: Windows Terminal, Zed terminal, standard WSL terminal
  • Shell: bash with custom .bashrc

Steps to Reproduce

  1. Install/update to Claude Code 2.1.27
  2. Run claude in any directory
  3. Type "hi" and press Enter
  4. Observe: Shows "Frolicking..." then freezes indefinitely

Expected Behavior

Claude should respond to the message.

Actual Behavior

  • UI freezes after showing "Frolicking..."
  • No response is displayed
  • Terminal becomes unresponsive (can't Ctrl+C)
  • When terminal is closed, Claude process becomes orphaned and runs at ~95% CPU

Workaround

Downgrade to 2.1.25:

ln -sf ~/.local/share/claude/versions/2.1.25 ~/.local/bin/claude

Suspected Cause

Based on the 2.1.27 changelog, one of these changes may be responsible:

  • "Fixed bash command execution failing for users with .bashrc files"
  • "Fixed console windows flashing when spawning child processes"

The user has a complex .bashrc with custom functions and aliases.

Additional Context

  • Plugins enabled/disabled makes no difference
  • Happens on both Windows filesystem (/mnt/c/) and Linux filesystem (~/)
  • Large session files (>50MB) were ruled out as the cause
  • CPU does not spike to 99% during freeze (stays around 18%)
  • The session that was already running before the update continues to work fine
  • Only new sessions freeze

Diagnostic Info

Platform: WSL2 (Linux 6.6.87.2-microsoft-standard-WSL2)
Node: v22.22.0
Claude Code: 2.1.27 (broken) / 2.1.25 (works)

View original on GitHub ↗

24 Comments

github-actions[bot] · 5 months ago

Found 3 possible duplicate issues:

  1. https://github.com/anthropics/claude-code/issues/22057
  2. https://github.com/anthropics/claude-code/issues/22097
  3. https://github.com/anthropics/claude-code/issues/22041

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

kerim · 5 months ago

Same issue here on MacOS

sarth6 · 5 months ago

rm -rf ~/.claude/projects/the-project-where-the-freeze-happened mitigates the issue for me, and then it comes back again an hour later, also on 2.1.27

belcaik · 5 months ago

same issue on linux

liuzili97 · 5 months ago

same issue on macos

aranej · 5 months ago

Confirming this issue on Ubuntu 24.04 LTS (Hetzner VPS, CX32 - 4 vCPU, 8 GB RAM).

Environment

  • OS: Ubuntu 24.04.3 LTS (headless server, SSH access via Termius)
  • Node.js: v22.21.1 (via NVM)
  • Claude Code: 2.1.27 (broken) → 2.1.25 (works)
  • Installation: npm global (via NVM)
  • Auth: OAuth (claude.ai subscription)

Symptoms (identical to OP)

  • Session starts normally, user sends first message
  • TUI shows thinking animation ("Creating...", "Enchanting...", "Marinating...") then freezes completely
  • Ctrl+C does not work, terminal becomes unresponsive
  • When terminal is force-closed, the claude process becomes orphaned (PPID=1) and runs at 60-99% CPU indefinitely
  • Multiple frozen attempts accumulated 8+ orphan processes, pushing CPU to 400% (all 4 cores maxed)

What did NOT help

  • Disabling all MCP servers (6 servers disabled)
  • Disabling all plugins
  • Removing custom statusLine configuration
  • Killing orphan processes and retrying (freeze immediately reoccurred)
  • Clearing project session data

What fixed it

Downgrade to 2.1.25 resolved the issue instantly. First response came back within seconds.

Important note for NVM users

If Claude Code is installed via NVM, a standard npm install -g @anthropic-ai/claude-code@2.1.25 may appear to work but the auto-updater silently upgrades it back to 2.1.27 on the next launch. The reliable approach:

# 1. Disable auto-updater FIRST (add to ~/.bashrc before NVM loads)
export DISABLE_AUTOUPDATER=1

# 2. Clean uninstall + reinstall
npm uninstall -g @anthropic-ai/claude-code
npm cache clean --force
npm install -g @anthropic-ai/claude-code@2.1.25

# 3. Verify the ACTUAL binary, not just package.json
head -5 $(npm root -g)/@anthropic-ai/claude-code/cli.js | grep Version
# Should show: // Version: 2.1.25

Also worth noting: npm install -g @version sometimes updates package.json without replacing the actual minified cli.js bundle. The head verification above catches this.

Additional observation

  • Sessions that were already running before the update to 2.1.27 continued to work fine (consistent with OP's report)
  • The freeze happens on the very first API call — debug logs show startup completing normally but no API response is ever logged
  • Orphan processes maintain active TCP connections to the API endpoint but never process the response
ZenAlexa · 5 months ago

Same on MacOS 26.3

yeongjunyoo · 5 months ago

same on MacOS 26.2

tbvl · 5 months ago

Also having the issue on MacOS 26.2. I have one session running fine, but starting the second session in another terminal window, it get stuck on the first message.

nicholas-stancio-saka · 5 months ago

+1 on Pi 5 (ARM64, 8GB). Downgrade to 2.1.25 fixed it.

codemile · 5 months ago

FYI:

rm -fr ~/.claude/projects && mkdir ~/.claude/projects

Brings Claude back for awhile, and if it gets stuck again, then repeat the above.

dqhieu · 5 months ago

happened to me after updating to 2.1.27 as well

amranalkerata · 5 months ago

v2.1.25 Fixed the issue

Kevin-Mok · 5 months ago

Reverted to 2.1.22 to fix on Linux.

rlallen · 5 months ago

same here on WSL2. Following fixed it.
curl -fsSL https://claude.ai/install.sh | bash -s 2.1.25

vdp1331 · 5 months ago

1. Rollback to 2.1.25

curl -fsSL https://claude.ai/install.sh | bash -s 2.1.25

2. Prevent update to 2.1.27

rm -f ~/.local/share/claude/versions/2.1.27
chmod 555 ~/.local/share/claude/versions

3. Create smart update script

mkdir -p ~/scripts
cat > ~/scripts/claude-smart-update.sh << 'EOF'
#!/bin/bash
SKIP_VERSION="2.1.27"
CURRENT=$(readlink ~/.local/bin/claude | grep -oP '\d+\.\d+\.\d+')
LATEST=$(ls ~/.local/share/claude/versions/ 2>/dev/null | grep -oP '\d+\.\d+\.\d+' | sort -V | tail -1)

if [ "$LATEST" != "$CURRENT" ] && [ "$LATEST" != "$SKIP_VERSION" ]; then
if [ "$(printf '%s\n' "$LATEST" "$CURRENT" | sort -V | tail -1)" = "$LATEST" ]; then
chmod 755 ~/.local/share/claude/versions
curl -fsSL https://claude.ai/install.sh | bash -s "$LATEST"
NEW_VERSION=$(readlink ~/.local/bin/claude | grep -oP '\d+\.\d+\.\d+')
# Auto-destroy after update to 2.1.28+
if [[ "$NEW_VERSION" > "2.1.27" ]]; then
crontab -l | grep -v "claude-smart-update" | crontab -
rm -f ~/scripts/claude-smart-update.sh
fi
fi
fi
EOF
chmod +x ~/scripts/claude-smart-update.sh

4. Setup cron (every 2 hours)

(crontab -l 2>/dev/null; echo "0 /2 $HOME/scripts/claude-smart-update.sh >> /tmp/claude-smart-update.log 2>&1") | crontab -

rupurt · 5 months ago

Same issue on Ubuntu 25.10 x86_64. Downgrading to 2.1.25 resolves it for now

mdonova33 · 5 months ago

Same issue on Mac Tahoe 26.2. Downgrading to 2.1.25 fixes it.

iraritchiemeek · 5 months ago

Same issue. Mac 15.3.1.
Downgrading to 2.1.25 did not fix it for me. Removing the project dir from ~/.claude/projects fixed it.

srgfrancisco · 5 months ago

I've fixed this issue by moving it to 2.1.29 instead of downgrading to 2.1.25. I also cleaned a few stale project entries from ~/.claude/projects since I've renamed my project name

jj-dominguez · 5 months ago
I've fixed this issue by moving it to 2.1.29 instead of downgrading to 2.1.25

Had the same problem, upgraded to v2.1.31 and it looks like things are working on my end. Good rec.

mykeln · 5 months ago

Issue still persists for me on v2.1.31. Deleting the project folder worked. I get the impression that something is "filling up," perhaps a cache get corrupted?

phillydoug · 5 months ago

This has been happening to me fr a few weeks. Very frustrating and no serious fix yet.

Have started going back to Cursor...

github-actions[bot] · 5 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.