@codingame/monaco-vscode-chat-service-override 38.0.3 → 38.0.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@codingame/monaco-vscode-chat-service-override",
|
|
3
|
-
"version": "38.0.
|
|
3
|
+
"version": "38.0.5",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "VSCode public API plugged on the monaco editor - chat service-override",
|
|
6
6
|
"keywords": [],
|
|
@@ -15,10 +15,10 @@
|
|
|
15
15
|
},
|
|
16
16
|
"type": "module",
|
|
17
17
|
"dependencies": {
|
|
18
|
-
"@codingame/monaco-vscode-api": "38.0.
|
|
19
|
-
"@codingame/monaco-vscode-files-service-override": "38.0.
|
|
20
|
-
"@codingame/monaco-vscode-katex-common": "38.0.
|
|
21
|
-
"@codingame/monaco-vscode-xterm-common": "38.0.
|
|
18
|
+
"@codingame/monaco-vscode-api": "38.0.5",
|
|
19
|
+
"@codingame/monaco-vscode-files-service-override": "38.0.5",
|
|
20
|
+
"@codingame/monaco-vscode-katex-common": "38.0.5",
|
|
21
|
+
"@codingame/monaco-vscode-xterm-common": "38.0.5"
|
|
22
22
|
},
|
|
23
23
|
"main": "index.js",
|
|
24
24
|
"module": "index.js",
|
|
@@ -4,8 +4,8 @@ var skillAssets = {
|
|
|
4
4
|
'vs/sessions/skills/commit/SKILL.md': new URL('../commit/SKILL.md', import.meta.url).href,
|
|
5
5
|
'vs/sessions/skills/create-draft-pr/SKILL.md': new URL('../create-draft-pr/SKILL.md', import.meta.url).href,
|
|
6
6
|
'vs/sessions/skills/create-pr/SKILL.md': new URL('../create-pr/SKILL.md', import.meta.url).href,
|
|
7
|
-
'vs/sessions/skills/fix-ci/SKILL.md': new URL('../fix-ci/SKILL.md', import.meta.url).href,
|
|
8
7
|
'vs/sessions/skills/generate-run-commands/SKILL.md': new URL('../generate-run-commands/SKILL.md', import.meta.url).href,
|
|
8
|
+
'vs/sessions/skills/fix-ci/SKILL.md': new URL('../fix-ci/SKILL.md', import.meta.url).href,
|
|
9
9
|
'vs/sessions/skills/merge/SKILL.md': new URL('../merge/SKILL.md', import.meta.url).href,
|
|
10
10
|
'vs/sessions/skills/sync/SKILL.md': new URL('../sync/SKILL.md', import.meta.url).href,
|
|
11
11
|
'vs/sessions/skills/sync-upstream/SKILL.md': new URL('../sync-upstream/SKILL.md', import.meta.url).href,
|
|
@@ -2232,9 +2232,10 @@ let AgentHostSessionHandler = class AgentHostSessionHandler extends Disposable {
|
|
|
2232
2232
|
return request;
|
|
2233
2233
|
}));
|
|
2234
2234
|
const startedClientToolCalls = ( new Set());
|
|
2235
|
+
const pendingExecutionDisposals = store.add(( new DisposableMap()));
|
|
2235
2236
|
const clientToolExecutions = ( new Map());
|
|
2236
2237
|
const releaseClientToolExecution = (key, execution) => {
|
|
2237
|
-
if (execution.ownerCount > 0 || clientToolExecutions.get(key) !== execution) {
|
|
2238
|
+
if (execution.ownerCount > 0 || ( pendingExecutionDisposals.has(key)) || clientToolExecutions.get(key) !== execution) {
|
|
2238
2239
|
return;
|
|
2239
2240
|
}
|
|
2240
2241
|
clientToolExecutions.delete(key);
|
|
@@ -2271,21 +2272,25 @@ let AgentHostSessionHandler = class AgentHostSessionHandler extends Disposable {
|
|
|
2271
2272
|
};
|
|
2272
2273
|
clientToolExecutions.set(key, execution);
|
|
2273
2274
|
}
|
|
2275
|
+
pendingExecutionDisposals.deleteAndDispose(key);
|
|
2274
2276
|
execution.ownerCount++;
|
|
2275
2277
|
const targetsConfirmation = initial.toolCall.status === ToolCallStatus.PendingConfirmation;
|
|
2276
2278
|
requestLifecycle.value = toDisposable(() => {
|
|
2277
2279
|
execution.ownerCount--;
|
|
2278
|
-
if (execution.ownerCount > 0) {
|
|
2280
|
+
if (execution.ownerCount > 0 || store.isDisposed) {
|
|
2279
2281
|
return;
|
|
2280
2282
|
}
|
|
2281
|
-
|
|
2282
|
-
|
|
2283
|
-
|
|
2284
|
-
|
|
2285
|
-
|
|
2286
|
-
|
|
2287
|
-
|
|
2288
|
-
|
|
2283
|
+
pendingExecutionDisposals.set(key, disposableTimeout(() => {
|
|
2284
|
+
pendingExecutionDisposals.deleteAndDispose(key);
|
|
2285
|
+
const state = this._clientToolInvocations.get(key)?.state.get();
|
|
2286
|
+
const targetsState = state?.type === IChatToolInvocation.StateKind.Streaming || state?.type === (targetsConfirmation ? IChatToolInvocation.StateKind.WaitingForConfirmation : IChatToolInvocation.StateKind.Executing) || (execution.activeAttempts > 0 && (state?.type === IChatToolInvocation.StateKind.Cancelled || state?.type === IChatToolInvocation.StateKind.Completed));
|
|
2287
|
+
if (targetsState) {
|
|
2288
|
+
execution.source.cancel();
|
|
2289
|
+
}
|
|
2290
|
+
if (!targetsConfirmation || state?.type !== IChatToolInvocation.StateKind.Executing) {
|
|
2291
|
+
releaseClientToolExecution(key, execution);
|
|
2292
|
+
}
|
|
2293
|
+
}, 1000));
|
|
2289
2294
|
});
|
|
2290
2295
|
let generation = 0;
|
|
2291
2296
|
let observedRequest;
|