claude-code - 💡(How to fix) Fix VSCode extension does not render `permissionDecisionReason` in permission prompt for "ask" decisions

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
RAW_BUFFERClick to expand / collapse

Problem

When a PreToolUse hook returns permissionDecision: "ask" with permissionDecisionReason, the Claude Code VSCode extension only displays a generic "Do you want to proceed with [Tool]?" header. The reason text is NOT visible anywhere in the prompt UI — not in the header, not in the body, not in the Details expansion.

Per official docs (https://code.claude.com/docs/en/hooks):

"When `permissionDecision` is `"ask"`, the `permissionDecisionReason` appears in the permission dialog as explanatory text below the tool name and parameters."

This behavior is not happening in the VSCode extension. Issue #57201 author confirmed it works in TUI/terminal mode of Claude Code 2.1.133, but the issue appears in the VSCode extension specifically.

Reproduction

  1. Create a PreToolUse hook that returns: ```json { "hookSpecificOutput": { "hookEventName": "PreToolUse", "permissionDecision": "ask", "permissionDecisionReason": "Elevated process via UAC - admin rights granted to spawned process" } } ```
  2. Trigger a PowerShell/Bash command that matches the hook's condition
  3. Observe the permission prompt in VSCode

Expected

Reason text appears in the dialog as explanatory text below the tool parameters.

Actual

Generic prompt header: "Do you want to proceed with PowerShell?" Details section (when expanded) shows only the command content. The `permissionDecisionReason` is not displayed anywhere visible to the user.

Environment

  • Claude Code VSCode extension: 2.1.145
  • VSCode: latest
  • OS: Windows 11 Home Single Language
  • Tested with both ASCII-only and unicode reason text — both fail

Hook output verified valid

Direct testing shows the hook emits valid JSON with correct field names: ``` {"hookSpecificOutput": {"hookEventName": "PreToolUse", "permissionDecision": "ask", "permissionDecisionReason": "Elevated process via UAC - admin rights granted to spawned process"}} ```

Impact

Hook-based safety guards can't communicate WHY they flagged something to the user. User sees generic prompt with no context to make informed decision. Defeats much of the purpose of hook-based permission control in IDE environments.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING