Skip to content

Agent mode: edit_notebook_file tool silently fails — no diff banner, no disk write #314852

@csigalany

Description

@csigalany

Copilot Chat Extension Version: 0.47.0 (built into VS Code)
VS Code Version: 1.119.0
OS Version: macOS Tahoe Version 26.3.1 (a) (25D771280a)
Feature: Agent mode
Selected model: Claude Sonnet 4.6
Logs: ERR da: Unable to create file '/path/to/notebook.ipynb' that already exists when overwrite flag is not set
at Yse.doValidateCreateFile (fileService.ts:363:1)
at async Yse.canCreateFile (fileService.ts:351:1)
...
at async v6._createModifiedFileEntry (chatEditingSession.ts:1210:1)
at async v6._getOrCreateModifiedFileEntry (chatEditingSession.ts:1148:1)
at async v6._acceptStreamingEditsStart (chatEditingSession.ts:954:1)
Steps to Reproduce:

Open a Jupyter notebook (.ipynb) in VS Code agent mode
Ask the agent to edit a cell (e.g. "add a comment to the top of this cell")
The agent calls edit_notebook_file and reports "Notebook edited successfully"
Expected: A diff/accept banner appears in the notebook editor showing the proposed change
Actual: No diff banner appears, no change is visible in the editor, and the file on disk is also unchanged (verified with grep)
Additional context: This worked correctly in a previous version of VS Code/Copilot. The regression appears to have started recently. The notebook is ~46MB (has cell outputs). The edit_notebook_file tool silently fails — it returns success but performs no action.
The error in the logs shows VS Code is calling _createModifiedFileEntry on an already-existing file without the overwrite flag, causing it to silently fail. This only affects .ipynb files — the same agent editing works on .py files.

Metadata

Metadata

Assignees

No one assigned

    Labels

    chat-ext-issueTriaging assistance tag. Automatically applied if an issue comes from the chat oss repo.new releaseIssues found in a recent release of VS Code

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions