Skip to content

Commit 51f3d4d

Browse files
authored
Fix copilot cli sdk session retrieval to use cached sessions (#1389)
1 parent a831ce0 commit 51f3d4d

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/extension/agents/copilotcli/node/copilotcliSessionService.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -154,6 +154,10 @@ export class CopilotCLISessionService implements ICopilotCLISessionService {
154154
const sessionManager = await this.getSessionManager();
155155

156156
if (sessionId) {
157+
if (this._sessions.has(sessionId)) {
158+
return this._sessions.get(sessionId)!.sdkSession;
159+
}
160+
157161
try {
158162
const sdkSession = await sessionManager.getSession(sessionId);
159163

0 commit comments

Comments
 (0)