@ycodium-ai/agent-dsh 0.2.3072 → 0.2.3076

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.
Files changed (2) hide show
  1. package/dist/index.js +14 -3
  2. package/package.json +4 -4
package/dist/index.js CHANGED
@@ -34179,11 +34179,22 @@ function createAcpExecutor(options) {
34179
34179
  // ../../packages/ycodium-acp-executor/src/prompt-dispatch.ts
34180
34180
  var dispatchAcpPrompt = (executor, input2) => {
34181
34181
  const { promise: dispatched, resolve: resolve2 } = Promise.withResolvers();
34182
- const finished = executor.prompt({ ...input2, onDispatched: resolve2 });
34182
+ let written = false;
34183
+ const finished = executor.prompt({
34184
+ ...input2,
34185
+ onDispatched: (turnId) => {
34186
+ written = true;
34187
+ resolve2(turnId);
34188
+ }
34189
+ });
34183
34190
  return Promise.race([
34184
34191
  dispatched.then((turnId) => ({ turnId })),
34185
- // 写入之前就落定:成功(写入前被取消)带 turnId;拒绝原样交给调用方,那是起轮失败。
34186
- finished.then((result) => ({ turnId: result.turnId }))
34192
+ finished.then((result) => {
34193
+ if (!written && input2.expectedActiveTurnId !== void 0 && result.stopReason === "cancelled") {
34194
+ throw new AcpExecutorTurnEndedError();
34195
+ }
34196
+ return { turnId: result.turnId };
34197
+ })
34187
34198
  ]);
34188
34199
  };
34189
34200
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ycodium-ai/agent-dsh",
3
- "version": "0.2.3072",
3
+ "version": "0.2.3076",
4
4
  "description": "DeepSeek Harness executor: dsh CLI over Agent Client Protocol stdio.",
5
5
  "keywords": [
6
6
  "ycodium",
@@ -22,9 +22,9 @@
22
22
  "esbuild": "0.28.1",
23
23
  "vite-plus": "0.2.2",
24
24
  "yaml": "^2.9.0",
25
- "@ycodium-ai/plugin-api": "0.2.3072",
26
- "ycodium-acp-executor": "0.2.3072",
27
- "ycodium-executor-testing": "0.0.0"
25
+ "@ycodium-ai/plugin-api": "0.2.3076",
26
+ "ycodium-executor-testing": "0.0.0",
27
+ "ycodium-acp-executor": "0.2.3076"
28
28
  },
29
29
  "ycodium": {
30
30
  "plugin": "./dist/index.js",