[BUG] Blank TUI hang on startup with parent-directory project state

Resolved 💬 1 comment Opened Jun 1, 2026 by JCSnap Closed Jul 5, 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 can hang on startup with a blank TUI when launched from a nested project directory. The issue appears related to local project state in ~/.claude.json, specifically when there is a trusted project entry for a broad parent directory rather than the exact workspace directory. Fresh claude launches may stay blank for minutes before rendering, and concurrent launches make the delay worse.

What Should Happen?

Claude Code should render the TUI promptly. If project state is stale, overly broad, semantically invalid, or expensive to resolve, Claude Code should ignore/repair it or show a recoverable warning instead of leaving the terminal blank.

Error Messages/Logs

Cannot acquire lock for <version> - held by PID <pid>
  NON-FATAL: Lock acquisition failed for <claude-version-path>
  [STARTUP] showSetupScreens() completed
  Fast mode unavailable: Fast mode is currently unavailable

  Observed long gap before REPL mount:

  <timestamp> ... Fast mode unavailable
  <several minutes later> ... [REPL:mount] REPL mounted, disabled=false

  In one delayed launch, MCP startup also took several minutes:

  MCP server "<server-name>": Connection failed after <~235000ms>
  MCP server "<server-name>": Successfully connected ... in <~236000ms>

Steps to Reproduce

  1. Use Claude Code 2.1.159 on macOS.
  2. Have ~/.claude.json contain a trusted project entry for a broad parent directory, for example:

/path/to/projects

  1. Launch Claude from a nested child workspace, for example:

/path/to/projects/my-project

  1. Run:

claude --debug-file /tmp/claude-debug.log

  1. Observe the terminal remains blank for a long time before the TUI eventually renders, or appears hung.
  2. Launching multiple Claude instances concurrently appears to amplify the delay due to lock contention.

Workaround observed: remove the broad parent directory entry from ~/.claude.json and add an exact trusted entry for the specific workspace directory.

Claude Model

None

Is this a regression?

Yes, this worked in a previous version

Last Working Version

_No response_

Claude Code Version

2.1.159

Platform

Anthropic API

Operating System

macOS

Terminal/Shell

Terminal.app (macOS)

Additional Information

_No response_

View original on GitHub ↗

This issue has 1 comment on GitHub. Read the full discussion on GitHub ↗