Skip to content

[BUG] Edit preview/diff not showing in VSCode extension UI when confirming changes #8660

Description

@apinanaivot

UPDATE: This bug is still present as of 8. March 2026...

Preflight Checklist

  • I have searched existing issues and this hasn't been reported yet
  • This is a single bug report (please file separate reports for different bugs)
  • I am using the latest version of Claude Code

What's Wrong?

When using the Claude Code VSCode extension, edit previews are not visible when confirming code changes. The UI prompts me to confirm changes but only shows the file in its current state, without displaying the diff/preview of what will be changed.

  • Confirmation dialog appears
  • File opens in current state without showing the diff
  • No preview of what will change is visible
  • Changes work correctly once confirmed, but I can't see what I'm confirming

The same functionality works perfectly when running Claude Code via terminal in VSCode. The diff preview displays as expected.

What Should Happen?

Should show a diff/preview of the proposed changes before confirmation, similar to the terminal CLI version.

Error Messages/Logs

This is visible in vscode dev tools console, not sure if relevant. It says failed to apply edit even though It doesn't fail if I accept it.

index.js:1008 Uncaught (in promise) Error: String not found in file. Failed to apply edit.
    at uX.readMessages (index.js:1008:30299)
localProcessExtensionHost.ts:280 Extension Host
localProcessExtensionHost.ts:281 Claude Code stderr: [DEBUG] "Permission suggestions for Edit: [\n  {\n    \"type\": \"setMode\",\n    \"mode\": \"acceptEdits\",\n    \"destination\": \"session\"\n  }\n]"

Steps to Reproduce

  1. Open VSCode with Claude Code extension
  2. Request code changes via the extension UI
  3. Observe confirmation prompt - diff preview is not visible
  4. Compare with terminal CLI version where diff shows correctly

Claude Model

None

Is this a regression?

Yes, this worked in a previous version

Last Working Version

No response

Claude Code Version

2.0.1 (Claude Code)

Platform

Anthropic API

Operating System

Windows

Terminal/Shell

VS Code integrated terminal

Additional Information

Image

VSCode Version: 1.104.2 (e3a5acfb517a443235981655413d566533107e92 x64)

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:idebugSomething isn't workinghas reproHas detailed reproduction stepsplatform:windowsIssue specifically occurs on Windows

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions