.claude-plugin directory in working directory causes 100% CPU freeze (v2.1.27)

Resolved 💬 3 comments Opened Jan 31, 2026 by TPG24 Closed Mar 1, 2026

Environment

  • Claude Code version: 2.1.27
  • OS: macOS Darwin 25.2.0 (arm64, Apple Silicon)

Bug Description

When Claude Code is started in a directory containing a .claude-plugin folder, it immediately spikes to 100% CPU and freezes on the first user prompt. The process must be killed with kill -9.

Steps to Reproduce

  1. Have a directory with a .claude-plugin folder (e.g., a plugin marketplace repo)
  2. Start Claude Code: cd /path/to/repo && claude
  3. Type any prompt and press Enter
  4. Process immediately goes to 100% CPU and freezes

Expected Behavior

Claude Code should either:

  • Ignore the .claude-plugin folder in the working directory
  • Or process it without entering an infinite loop

Actual Behavior

  • Process spikes to 100% CPU
  • UI becomes completely frozen
  • No output is displayed
  • Must force kill with kill -9 <PID>

Diagnostic Process

Systematically tested by disabling:

  1. All plugins in settings → Still freezes
  2. Project CLAUDE.md → Still freezes
  3. Project .claude folder → Still freezes
  4. .claude-plugin folder → WORKS!

Renaming .claude-plugin to .claude-plugin.disabled resolves the freeze.

.claude-plugin Contents

.claude-plugin/
├── plugin.json (444 bytes)
└── marketplace.json (5277 bytes)

plugin.json:

{
  "name": "secondbrain",
  "description": "...",
  "version": "6.76.2"
}

Additional Context

  • The same marketplace is also installed in ~/.claude/plugins/marketplaces/
  • The freeze occurs even with zero plugins enabled in settings
  • Working from /tmp or parent directories without .claude-plugin works fine
  • This appears to be an infinite loop when Claude Code detects a local plugin definition

Workaround

Rename the .claude-plugin folder before starting Claude Code:

mv .claude-plugin .claude-plugin.disabled

View original on GitHub ↗

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