claude-code icon indicating copy to clipboard operation
claude-code copied to clipboard

[BUG] Settings not applied: alwaysThinkingEnabled ignored and inconsistent permission behavior

Open scruffymongrel opened this issue 1 month ago • 7 comments

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/settings.json configuration is not being applied correctly. Two main issues:

  1. alwaysThinkingEnabled: true is completely ignored - no thinking blocks appear in the UI despite being enabled
  2. Bash permission allow list behaves inconsistently - bun run lint (matching the allow pattern "bun run lint*") was blocked on first attempt but succeeded on second attempt
  3. Message truncation - assistant response was cut off mid-sentence at the exact point of referencing a thinking block tag

The assistant confirmed it is generating thinking blocks, but they are not visible in the UI. Settings file exists at the correct location and Claude Code was restarted after settings modification.

What Should Happen?

With alwaysThinkingEnabled: true in settings:

  • Thinking blocks should be visible in all assistant responses

With bash allow list configured:

  • Commands matching allow patterns (like "bun run lint*") should execute without permission prompts or blocks

Error Messages/Logs

When first attempting to run `bun run lint`, the following error was shown:
  The user doesn't want to proceed with this tool use. The tool use was rejected (eg. if it was
  a file edit, the new_string was NOT written to the file). STOP what you are doing and wait for
   the user to tell you how to proceed.

  The second attempt of the same command succeeded without any changes.

  Message truncation example - assistant's message ended abruptly:
  ⏺ That's definitely a bug then. The facts:

  1. Thinking blocks: I am generating them (in `

Steps to Reproduce

  1. Create .claude/settings.json with the configuration below
  2. Restart Claude Code session
  3. Request: "please lint"
  4. Observe: First attempt is blocked/rejected
  5. Request again: "please lint"
  6. Observe: Second attempt succeeds
  7. Throughout: No thinking blocks visible despite alwaysThinkingEnabled: true

Claude Model

Sonnet (default)

Is this a regression?

I don't know

Last Working Version

No response

Claude Code Version

2.0.28

Platform

Anthropic API

Operating System

macOS

Terminal/Shell

Warp

Additional Information

Configuration file (.claude/settings.json):

{
  "alwaysThinkingEnabled": true,
  "permissions": {
    "bash": {
      "allow": [
        "bun run lint*",
        "bun run test*",
        "bun run types:check*",
        "bun run types:generate*",
        "git status*",
        "git diff*",
        "git log*",
        "git show*",
        "ls*",
        "pwd"
      ]
    }
  },
  "hooks": {
    "PreToolUse": [
      {
        "matcher": "Edit|Write",
        "hooks": [
          {
            "type": "command",
            "command": "FILE=$(jq -r '.tool_input.file_path' 2>/dev/null || echo ''); case
\"$FILE\" in *.env|*credentials*|*secrets*) echo 'Blocked: sensitive file' >&2; exit 1;; esac"
          }
        ]
      },
      {
        "matcher": "Bash",
        "hooks": [
          {
            "type": "command",
            "command": "CMD=$(jq -r '.tool_input.command' 2>/dev/null || echo ''); if echo
\"$CMD\" | grep -q 'deploy'; then cd [PATH REDACTED] && bun run types:check
|| (echo 'Build check failed - fix errors before deploying' >&2; exit 1); fi"
          }
        ]
      }
    ],
    "PostToolUse": [
      {
        "matcher": "Edit|Write",
        "hooks": [
          {
            "type": "command",
            "command": "cd [PATH REDACTED] && bun run lint"
          },
          {
            "type": "command",
            "command": "FILE=$(jq -r '.tool_input.file_path' 2>/dev/null || echo ''); if [[
\"$FILE\" == *package.json ]]; then echo '💡 Remember: run bun install to update lockfile'
>&2; fi"
          }
        ]
      }
    ],
    "Stop": [
      {
        "hooks": [
          {
            "type": "command",
            "command": "echo '\n💡 Consider running: bun run test' >&2"
          }
        ]
      }
    ],
    "SessionStart": [
      {
        "hooks": [
          {
            "type": "command",
            "command": "cd [PATH REDACTED] && test -f .env.dev && echo '✓
Environment ready' || echo '⚠️  Missing .env.dev'"
          }
        ]
      }
    ],
    "Notification": [
      {
        "hooks": [
          {
            "type": "command",
            "command": "osascript -e 'display notification \"Claude needs input\" with title
\"Claude Code\"' 2>/dev/null || true"
          }
        ]
      }
    ]
  }
}

scruffymongrel avatar Oct 30 '25 10:10 scruffymongrel

This issue has been inactive for 30 days. If the issue is still occurring, please comment to let us know. Otherwise, this issue will be automatically closed in 30 days for housekeeping purposes.

github-actions[bot] avatar Dec 09 '25 10:12 github-actions[bot]

I'm also experiencing this issue with alwaysThinkingEnabled: true being ignored.

My environment:

  • OS: Windows 11
  • Terminal: Claude Code in VSCode integrated terminal
  • Claude Code Version: Latest (2.0.62)
  • Platform: Anthropic API

Configuration (~/.claude/settings.json):

{
  "alwaysThinkingEnabled": true,
  "hooks": { ... }
}

Behavior:

  • Every time I start a new Claude Code session, thinking mode is OFF by default
  • I have to manually press Tab to enable thinking mode each session
  • The setting is correctly placed in the global settings file and the JSON is valid

This confirms the bug is cross-platform (macOS + Windows), not just macOS-specific. Would appreciate a fix or at least documentation on the expected behavior of this setting.

+1 for prioritizing this fix 🙏

elfenlieds7 avatar Dec 09 '25 12:12 elfenlieds7

Confirming this issue is still present.

My environment:

  • OS: macOS (Darwin 25.1.0)
  • Terminal: CLI
  • Claude Code Version: 2.0.64
  • Platform: Anthropic API

Important note: This only started happening for me on v2.0.64. It hasn't been an issue until this build - the setting was being respected in previous versions.

Configuration (~/.claude/settings.json):

{
  "alwaysThinkingEnabled": true
}

Behavior:

  • Thinking mode always defaults to OFF on session start
  • Have to manually press Tab to enable thinking mode each session
  • The alwaysThinkingEnabled: true setting in settings.json is being ignored

This appears to be a regression introduced in a recent version.

andrewklingelhofer avatar Dec 10 '25 06:12 andrewklingelhofer

I'm having the same issue and I noticed it started prior to 2.0.64 (at least in 2.0.62).

I'm using Linux (6.6.107-1-MANJARO) and Claude Code CLI via Terminal.

antoniocascais avatar Dec 10 '25 10:12 antoniocascais

Same issue here, using MacOS 26.1 and Claude Code CLI via Terminal. Reverting to 2.0.61 fixed the issue

antonio-bounce avatar Dec 10 '25 11:12 antonio-bounce

Confirming this issue on macOS (Darwin 24.5.0) with Claude Code v2.0.62

Same problem here:

  • alwaysThinkingEnabled: true in both ~/.claude/settings.json and .claude/settings.local.json
  • Setting is completely ignored - thinking mode is OFF by default every session
  • Must press Tab manually to enable thinking

Workaround that works: Using MAX_THINKING_TOKENS environment variable instead: export MAX_THINKING_TOKENS=16000

This reliably enables thinking mode on startup, while alwaysThinkingEnabled does not.

cherryout avatar Dec 10 '25 11:12 cherryout

Fixed in 2.0.67 apparently:


⎿  • Thinking mode is now enabled by default for Opus 4.5
  ⎿  • Thinking mode configuration has moved to /config
Image

edit: and alwaysThinkingEnabled removed from settings docs: https://code.claude.com/docs/en/settings

antoniocascais avatar Dec 12 '25 11:12 antoniocascais

I'm experiencing the opposite problem - alwaysThinkingEnabled: false is being ignored and thinking mode remains active. This suggests the setting isn't being respected in either direction since v2.0.67.

@antoniocascais The link you pasted does include the alwaysThinkingEnabled setting, implying it should still be possible to override the default behavior. This is extra frustrating since v2.0.67 also removed the tab shortcut to quickly toggle thinking mode.

Image

Edit: Here's my minimal config file:

❯ cat .claude/settings.json
{
  "alwaysThinkingEnabled": false
}

vcekron avatar Dec 15 '25 10:12 vcekron

@vcekron thanks for pointing that out.

I checked and they added it to the docs again. On 11th it was not in the docs :D https://web.archive.org/web/20251211233922/https://code.claude.com/docs/en/settings

antoniocascais avatar Dec 15 '25 11:12 antoniocascais

@antoniocascais Ah, gotcha! Thanks for the clarification.

vcekron avatar Dec 15 '25 12:12 vcekron

As a slight aside, now that the bug is "reversed," in the sense that the default behavior is to enforce thinking but Claude still ignores the alwaysThinkingEnabled value, the best way I have found to avoid the thinking mode except when explicitly desired is to echo the MAX_THINKING_TOKENS variable before calling Claude.

So, something like:

# Add to ~/.zshrc or ~/.bashrc
alias claude='MAX_THINKING_TOKENS=0 command claude'
alias claude-think='command claude'

Usage:

  • claude → No thinking (default)
  • claude-think → Thinking enabled

vcekron avatar Dec 15 '25 14:12 vcekron