finish inline chat session when EH restarts or dies (#229132)

fixes https://github.com/microsoft/vscode-copilot-release/issues/1535
This commit is contained in:
Johannes Rieken
2024-09-20 10:53:06 +02:00
committed by GitHub
parent 527e41ff55
commit 82a1f0b276
2 changed files with 2 additions and 5 deletions

View File

@@ -157,7 +157,7 @@ export class InlineChatSessionServiceImpl implements IInlineChatSessionService {
}));
store.add(this._chatAgentService.onDidChangeAgents(e => {
if (e === undefined && !this._chatAgentService.getAgent(agent.id)) {
if (e === undefined && (!this._chatAgentService.getAgent(agent.id) || !this._chatAgentService.getActivatedAgents().includes(agent))) {
this._logService.trace(`[IE] provider GONE for ${editor.getId()}, ${agent.extensionId}`);
this._releaseSession(session, true);
}