[Bug] Permission mode "auto" not inherited in new sessions and cannot be set mid-session
Bug Description
Title: auto permission mode not inherited by new sessions and cannot be set mid-session
Product: Claude Code Desktop (Windows)
defaultMode setting: "auto" in ~/.claude/settings.json
SUMMARY
When defaultMode is set to "auto" in ~/.claude/settings.json, new Claude Code sessions do not inherit it. The session appears to start in auto mode but switches to "default" (ask-every-time) after the first message. Additionally, clicking auto mode in the permission selector mid-session causes the UI to immediately flip back to the previous mode — auto cannot be set at all during that session.
This does NOT occur with defaultMode: "bypassPermissions" — that value is correctly inherited by all new sessions and persists without issue.
STEPS TO REPRODUCE
- Set permissions.defaultMode: "auto" in ~/.claude/settings.json
- Set skipAutoPermissionPrompt: true
- Restart Claude Desktop
- Open a new Claude Code session
- Send one message
- Check the permission mode indicator
Expected: Session stays in auto mode
Actual: Session switches to "default" after first message
- Click the permission selector and choose "auto"
Expected: Mode switches to auto and stays
Actual: Mode immediately flips back — auto cannot be set mid-session
OBSERVED SESSION STATE
Per-session state files at:
C:/Users/[user]/AppData/Roaming/Claude/claude-code-sessions/[account-uuid]/[workspace-uuid]/[session-id].json
Each file has a permissionMode field. With defaultMode: "bypassPermissions", all session files correctly show permissionMode: bypassPermissions. With defaultMode: "auto", new session files show permissionMode: default instead — the global default is being ignored specifically for the "auto" value.
ENVIRONMENT
- OS: Windows 11
- Claude Desktop, auto-updates enabled (latest channel)
- skipAutoPermissionPrompt: true
- skipDangerousModePermissionPrompt: true
HYPOTHESIS
There may be a validation or normalisation step that strips "auto" when writing the per-session state file after the first turn. Worth checking the code path that writes permissionMode to the session JSON on first message completion.
Environment Info
- Platform: win32
- Terminal: null
- Version: 2.1.77
- Feedback ID: 23374772-748a-4920-99b5-09f2cbc8b181
Errors
[{"error":"Error: Plugin path not found: C:\\Users\\Robbie\\.claude\\plugins\\marketplaces\\claude-plugins-official\\external_plugins\\autofix-bot\n at AU1 (B:/~BUN/root/src/entrypoints/cli.js:2525:8003)\n at processTicksAndRejections (native:7:39)","timestamp":"2026-05-02T11:20:31.397Z"},{"error":"Error: Plugin MCP server error - mcp-config-invalid: MCP server github invalid: Missing environment variables: GITHUB_PERSONAL_ACCESS_TOKEN\n at FEH (B:/~BUN/root/src/entrypoints/cli.js:2532:32833)\n at processTicksAndRejections (native:7:39)","timestamp":"2026-05-02T11:20:31.482Z"},{"error":"Error: Plugin MCP server error - mcp-config-invalid: MCP server github invalid: Missing environment variables: GITHUB_PERSONAL_ACCESS_TOKEN\n at FEH (B:/~BUN/root/src/entrypoints/cli.js:2532:32833)\n at async X (B:/~BUN/root/src/entrypoints/cli.js:4860:17025)\n at processTicksAndRejections (native:7:39)","timestamp":"2026-05-02T11:21:17.906Z"},{"error":"Error: Plugin MCP server error - mcp-config-invalid: MCP server github invalid: Missing environment variables: GITHUB_PERSONAL_ACCESS_TOKEN\n at FEH (B:/~BUN/root/src/entrypoints/cli.js:2532:32833)\n at async G (B:/~BUN/root/src/entrypoints/cli.js:4860:17741)\n at processTicksAndRejections (native:7:39)","timestamp":"2026-05-02T11:21:17.907Z"}]This issue has 6 comments on GitHub. Read the full discussion on GitHub ↗