[BUG] Workspace trust not persisting in Claude Code CLI - MCP servers fail to load despite accepting trust prompt

Resolved 💬 4 comments Opened Nov 24, 2025 by laura-opendoor Closed Dec 9, 2025

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?

Description:
When running Claude Code CLI from any directory, the workspace trust prompt appears and I select "Yes, proceed", but the trust decision is not persisted. This prevents MCP servers from loading in interactive sessions, even though they are properly configured and can connect successfully.

Environment:
OS: macOS (Darwin 25.1.0)
Claude Code CLI version: 2.0.50
Installation method: Native installer
Configuration location: ~/.claude/config.json

Steps to Reproduce:

  1. Configure an MCP server in ~/.claude/config.json:

{
"mcpServers": {
"snowflake": {
"command": "/Users/laura/.local/bin/run_snowflake_mcp.sh"
}
}
}

  1. Run claude from home directory:

cd ~
claude

  1. Trust prompt appears:

Do you trust the files in this folder?
/Users/laura

❯ 1. Yes, proceed

  1. No, exit

Select "Yes, proceed"
Ask Claude to use MCP tools (e.g., query Snowflake)

Expected Behavior:
Trust decision should be saved/persisted
MCP servers should load in the session
MCP tools should be available (e.g., mcp__snowflake__*)

Actual Behavior:
Trust prompt is accepted but not persisted
On every new session, trust prompt appears again
MCP servers do not load in interactive sessions
Debug logs show: "workspace trust not accepted" even after accepting
MCP tools are not available in the session

Evidence:

  1. MCP server CAN connect (outside of sessions):

$ claude mcp list
Checking MCP server health...
snowflake: /Users/laura/.local/bin/mcp_snowflake_server - ✓ Connected

  1. Debug logs show trust not accepted:

From ~/.claude/debug/latest:
2025-11-24T01:54:41.624Z [DEBUG] Skipping SessionStart:startup hook execution - workspace trust not accepted
2025-11-24T01:54:41.646Z [DEBUG] Trust not accepted for current directory - skipping plugin installations

  1. No MCP initialization attempts in logs:

Searching for "mcp" or "MCP" in debug logs returns no results during session startup, indicating MCP servers are never being initialized when trust is not accepted.

  1. No trust persistence:

No trust-related keys found in ~/.claude.json
Created test file at ~/.claude/workspaces/trusted.json but it's not being read
Trust decision doesn't appear to be saved anywhere

What We've Tried:

  1. Moving MCP server components outside workspace to avoid trust issues:

Script: ~/.local/bin/run_snowflake_mcp.sh
Virtual env: ~/.local/mcp-servers/snowflake/.venv/
Credentials: ~/.config/snowflake/mcp.env

  1. Updated settings in ~/.claude/settings.local.json:

{
"permissions": {
"allow": ["mcp__snowflake__*"],
"defaultMode": "dontAsk"
},
"enableAllProjectMcpServers": true
}

  1. Manually created trust file at ~/.claude/workspaces/trusted.json:

{
"trustedWorkspaces": ["/Users/laura", "/Users/laura/monorepo"]
}
→ Not being read/used

Additional Context:
This happens from any directory (home, monorepo, /tmp, etc.)
The trust prompt appears every single session
Accepting trust has no effect - logs still show "workspace trust not accepted"
The -p (print mode) flag mentions trust is skipped, confirming trust is intentionally checked in interactive mode

Workaround:
Using VSCode extension instead of CLI, which doesn't have this trust persistence issue.

Impact:
MCP servers are completely unusable in Claude Code CLI interactive sessions due to workspace trust not persisting, despite proper configuration.

What Should Happen?

Expected Behavior:
Trust decision should be saved/persisted
MCP servers should load in the session
MCP tools should be available (e.g., mcp__snowflake__*)

Error Messages/Logs

**Actual Behavior:**
Trust prompt is accepted but not persisted
On every new session, trust prompt appears again
MCP servers do not load in interactive sessions
Debug logs show: "workspace trust not accepted" even after accepting
MCP tools are not available in the session

Steps to Reproduce

Steps to Reproduce:

  1. Configure an MCP server in ~/.claude/config.json:

{
"mcpServers": {
"snowflake": {
"command": "/Users/laura/.local/bin/run_snowflake_mcp.sh"
}
}
}

  1. Run claude from home directory:

cd ~
claude

  1. Trust prompt appears:

Do you trust the files in this folder?
/Users/laura

❯ 1. Yes, proceed

  1. No, exit

Select "Yes, proceed"
Ask Claude to use MCP tools (e.g., query Snowflake)

Claude Model

None

Is this a regression?

I don't know

Last Working Version

_No response_

Claude Code Version

Claude Code CLI version: 2.0.50

Platform

Anthropic API

Operating System

macOS

Terminal/Shell

Terminal.app (macOS)

Additional Information

_No response_

View original on GitHub ↗

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