VS Code extension: no way to remove auto-attached `ide_opened_file` from context
Resolved 💬 4 comments Opened Mar 26, 2026 by vladimir-mikhailov Closed May 30, 2026
Problem
When a file is open in the editor at the moment a message is sent, it gets automatically attached to the conversation context as ide_opened_file. Once attached, there is no way to remove it from the context without running /clear and losing the entire conversation history.
This is different from manually attached files (via @ or drag-and-drop), which have an X button to remove them.
Steps to reproduce
- Have a file open in VS Code editor
- Send a message in the Claude Code extension — the file gets attached as
ide_opened_file - Close the file tab and deselect it in Explorer
- The file remains in the conversation context with no option to remove it
Expected behavior
- Either an
Xbutton / right-click option to removeide_opened_fileentries from context - Or a way to manage all context items (auto-attached and manual) in a unified context panel
Current workaround
/clear to reset the entire conversation, which is disruptive if mid-task.
This issue has 4 comments on GitHub. Read the full discussion on GitHub ↗