When I open the chat panel (Agents) on my right, I am selecting/clicking on other files in the resource manager, and suddenly the current chat panel (Agents) automatically closes. This is not triggered every time, but occasionally it can trigger this bug correctly!
Do you have the function of automatically closing the chat panel (Agents)? Perhaps the problem lies here! I don’t know if you can understand? If there is anything you don’t understand, please leave a comment and I will reply!
Steps to Reproduce
Open the chat panel (Agents) on the right,
Select/click on files in the resource manager
This can’t be triggered every time, occasionally it can trigger this bug correctly!
Hey, thanks for the detailed report. Just to be clear, we don’t have a feature that auto-closes the Agents panel when you click a file, so this is definitely unintended behavior.
A couple things to check:
Update Cursor to the latest version. You’re on 3.8.23, and we fixed a few right sidebar visibility glitches after that. Your case might already be covered.
The diagnostics show Layout: editor, which suggests the Agents chat is opened as an editor tab, not docked in the right sidebar. If that’s the case, a single click on a file in the Explorer can reuse the preview tab and replace the chat tab, which looks like it “closed”. Workaround: pin the chat tab right click the tab > Pin, or disable preview editors by setting workbench.editor.enablePreview to false. Panel toggle is Cmd+Alt+B.
If it still happens after updating, please share a short screencast showing the panel closing so we can file an accurate bug. Let me know how it goes.
good Automatically closing the panel for me has been bothering me for a long time!
During the process of opening this panel, when I click/switch files, it will automatically close. After closing and opening, it defaults to opening a new session!
It caused me to be irritable for a long time! Hope to resolve it as soon as possible, okay?
From your video, it’s clear what’s happening. Your chat Invite feature integra… is opened as an editor tab in the same row as askQuestions.md, not pinned in the sidebar. That tab is in preview mode, so when you single click a file in the tree (in your video it’s withdraw.controller.ts), Cursor reuses the same preview tab and replaces the chat with that file. That’s why it looks like the chat “closes itself”, and why you get a new session when you reopen it. This isn’t a bug, it’s how preview tabs work.
Any of these fixes will help:
Pin the chat tab: right click the tab > Pin. Then file clicks won’t replace it.
Turn off preview editors: set workbench.editor.enablePreview to false. Files will always open in a new tab and won’t overwrite anything.
Keep Agents in the right sidebar instead of an editor tab. Then chat and files are in different areas and won’t conflict. You can toggle the panel with Cmd+Alt+B.