Skip to content

Commit 1caa84c

Browse files
authored
chat - do not activate core agent which is not an extension (microsoft#250717)
1 parent e997280 commit 1caa84c

File tree

1 file changed

+10
-7
lines changed

1 file changed

+10
-7
lines changed

src/vs/workbench/contrib/chat/common/chatServiceImpl.ts

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -493,13 +493,16 @@ export class ChatService extends Disposable implements IChatService {
493493
throw new ErrorNoTelemetry('No default agent contributed');
494494
}
495495

496-
// No setup participant to fall back on- wait for extension activation
497-
// Using `activateById` as workaround for https://github.com/microsoft/vscode/issues/250590
498-
await this.extensionService.activateById(defaultAgentData.extensionId, {
499-
activationEvent: `onChatParticipant:${defaultAgentData.id}`,
500-
extensionId: defaultAgentData.extensionId,
501-
startup: false
502-
});
496+
// Await activation of the extension provided agent
497+
// Using `activateById` as workaround for the issue
498+
// https://github.com/microsoft/vscode/issues/250590
499+
if (!defaultAgentData.isCore) {
500+
await this.extensionService.activateById(defaultAgentData.extensionId, {
501+
activationEvent: `onChatParticipant:${defaultAgentData.id}`,
502+
extensionId: defaultAgentData.extensionId,
503+
startup: false
504+
});
505+
}
503506

504507
const defaultAgent = this.chatAgentService.getActivatedAgents().find(agent => agent.id === defaultAgentData.id);
505508
if (!defaultAgent) {

0 commit comments

Comments
 (0)