[BUG] CLI hangs silently on startup when known_marketplaces.json contains an invalid or missing local marketplace

Resolved 💬 2 comments Opened Feb 14, 2026 by tzengyuxio Closed Feb 14, 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?

Claude Code CLI hangs indefinitely on startup with no output, no error message, and no way to recover (Ctrl+C unresponsive). Even claude --verbose produces zero output.

Root Cause

The file ~/.claude/plugins/known_marketplaces.json contained a registered local marketplace entry:

{
  "local-skills": {
    "source": {
      "source": "local"
    },
    "installLocation": "/Users//.claude/plugins/marketplaces/local-skills"
  }
}

The directory at installLocation was either missing or had incomplete/invalid contents. When the CLI attempted to load this marketplace during initialization, it hung indefinitely instead of failing gracefully.

Steps to Reproduce

  1. Register a local marketplace in ~/.claude/plugins/known_marketplaces.json with "source": "local"
  2. Ensure the installLocation path is missing or contains invalid plugin structure
  3. Run claude
  4. CLI hangs silently — no output, no error, unresponsive to Ctrl+C

Expected Behavior

  • CLI should timeout or show an error message like: Failed to load marketplace "local-skills": directory not found
  • CLI should still start, skipping the broken marketplace
  • claude --verbose should at minimum show which step the initialization is on

Suggested Fix

  • Add timeout and error handling when loading marketplaces during CLI initialization
  • Log meaningful errors when a marketplace path is missing or invalid
  • Don't block the entire CLI startup on a single marketplace failure

What Should Happen?

  • CLI should timeout or show an error message like: Failed to load marketplace "local-skills": directory not found
  • CLI should still start, skipping the broken marketplace
  • claude --verbose should at minimum show which step the initialization is on

Error Messages/Logs

- CLI hangs indefinitely with zero output
- `claude --verbose` also hangs with zero output
- `claude --version` works fine (no plugin loading)
- No log files are written
- Only fix is to remove the `local-skills` entry from `known_marketplaces.json` or delete the entire `~/.claude/plugins` directory

Steps to Reproduce

  1. Verified network connectivity (curl -I https://api.anthropic.com returned HTTP/2 response)
  2. Confirmed authentication is valid
  3. Removed all enabledPlugins from settings.json — still hung
  4. Removed statusLine config — still hung
  5. Renamed ~/.claude entirely — CLI started successfully
  6. Used binary search to isolate: restoring ~/.claude/plugins caused the hang
  7. Further narrowed down to known_marketplaces.json containing the local-skills entry
  8. Removing the local-skills entry from known_marketplaces.json resolved the issue

Claude Model

None

Is this a regression?

Yes, this worked in a previous version

Last Working Version

_No response_

Claude Code Version

2.1.41

Platform

Anthropic API

Operating System

macOS

Terminal/Shell

Terminal.app (macOS)

Additional Information

_No response_

View original on GitHub ↗

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