From 07cc469c10881a09146c930e70f4fba81fae96a6 Mon Sep 17 00:00:00 2001 From: Turtle Date: Wed, 25 Nov 2026 12:39:56 +0800 Subject: [PATCH 1/4] fix(workspace-changes): give up a git command after 3 s instead of 30 s Co-authored-by: CreatixChu <142372241+CreatixChu@users.noreply.github.com> --- packages/deliverables/workspace-changes/README.md | 2 +- packages/deliverables/workspace-changes/README.zh.md | 2 +- packages/deliverables/workspace-changes/src/index.ts | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/deliverables/workspace-changes/README.md b/packages/deliverables/workspace-changes/README.md index 71adbb4738..d422bcd94d 100644 --- a/packages/deliverables/workspace-changes/README.md +++ b/packages/deliverables/workspace-changes/README.md @@ -35,7 +35,7 @@ The shipped Web bundle mounts this plugin. Mount it in any composition with the | Field | Default | Meaning | |---|---|---| -| `timeoutMs` | `30000` | Milliseconds one git command may run before the turn's record is abandoned | +| `timeoutMs` | `3000` | Milliseconds one git command may run before the turn's record is abandoned; tool calls wait up to this long for the turn-start snapshot | | `outputMaxBytes` | `8388608` | Bytes of git output retained per command; a larger diff listing abandons the record | | `maxFiles` | `500` | Maximum files carried by one summary; `total` still reports the complete count | | `maxFileBytes` | `2097152` | Bytes a file may hold to be captured around a file-tool edit or read from a snapshot for its comparison; a larger file gets no comparison, and one captured around a file-tool edit is also listed without counts | diff --git a/packages/deliverables/workspace-changes/README.zh.md b/packages/deliverables/workspace-changes/README.zh.md index d53234109d..777352a2b5 100644 --- a/packages/deliverables/workspace-changes/README.zh.md +++ b/packages/deliverables/workspace-changes/README.zh.md @@ -35,7 +35,7 @@ kind: "package-reference" | 字段 | 默认值 | 含义 | |---|---|---| -| `timeoutMs` | `30000` | 单条 git 命令允许运行的毫秒数,超时则放弃本轮记录 | +| `timeoutMs` | `3000` | 单条 git 命令允许运行的毫秒数,超时则放弃本轮记录;工具调用最多等待这么久的轮初快照 | | `outputMaxBytes` | `8388608` | 每条命令保留的 git 输出字节数,diff 列表更大时放弃本轮记录 | | `maxFiles` | `500` | 单份摘要携带的最大文件数;`total` 仍报告完整数量 | | `maxFileBytes` | `2097152` | 文件在文件工具编辑前后被捕获、或从快照读出做对比所允许的最大字节数;更大的文件不提供对比,其中在文件工具编辑前后被捕获的也不带行数 | diff --git a/packages/deliverables/workspace-changes/src/index.ts b/packages/deliverables/workspace-changes/src/index.ts index c5e833b0e3..b0e18e307e 100644 --- a/packages/deliverables/workspace-changes/src/index.ts +++ b/packages/deliverables/workspace-changes/src/index.ts @@ -50,7 +50,7 @@ export interface Config { /** Schemastery validation for {@link Config}. */ export const Config: z = z.object({ - timeoutMs: z.number().default(30_000), + timeoutMs: z.number().default(3_000), outputMaxBytes: z.number().default(8 * 1024 * 1024), maxFiles: z.number().default(500), maxFileBytes: z.number().default(2 * 1024 * 1024), From 2b1d2149077a8d6069946a047771f8b8a9d6cc47 Mon Sep 17 00:00:00 2001 From: Turtle Date: Wed, 25 Nov 2026 12:42:09 +0800 Subject: [PATCH 2/4] docs(workspace-changes): drop inaccurate tool wait bound Co-authored-by: CreatixChu <142372241+CreatixChu@users.noreply.github.com> --- packages/deliverables/workspace-changes/README.md | 2 +- packages/deliverables/workspace-changes/README.zh.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/deliverables/workspace-changes/README.md b/packages/deliverables/workspace-changes/README.md index d422bcd94d..eda85ad4c4 100644 --- a/packages/deliverables/workspace-changes/README.md +++ b/packages/deliverables/workspace-changes/README.md @@ -35,7 +35,7 @@ The shipped Web bundle mounts this plugin. Mount it in any composition with the | Field | Default | Meaning | |---|---|---| -| `timeoutMs` | `3000` | Milliseconds one git command may run before the turn's record is abandoned; tool calls wait up to this long for the turn-start snapshot | +| `timeoutMs` | `3000` | Milliseconds one git command may run before the turn's record is abandoned | | `outputMaxBytes` | `8388608` | Bytes of git output retained per command; a larger diff listing abandons the record | | `maxFiles` | `500` | Maximum files carried by one summary; `total` still reports the complete count | | `maxFileBytes` | `2097152` | Bytes a file may hold to be captured around a file-tool edit or read from a snapshot for its comparison; a larger file gets no comparison, and one captured around a file-tool edit is also listed without counts | diff --git a/packages/deliverables/workspace-changes/README.zh.md b/packages/deliverables/workspace-changes/README.zh.md index 777352a2b5..b5b0af9726 100644 --- a/packages/deliverables/workspace-changes/README.zh.md +++ b/packages/deliverables/workspace-changes/README.zh.md @@ -35,7 +35,7 @@ kind: "package-reference" | 字段 | 默认值 | 含义 | |---|---|---| -| `timeoutMs` | `3000` | 单条 git 命令允许运行的毫秒数,超时则放弃本轮记录;工具调用最多等待这么久的轮初快照 | +| `timeoutMs` | `3000` | 单条 git 命令允许运行的毫秒数,超时则放弃本轮记录 | | `outputMaxBytes` | `8388608` | 每条命令保留的 git 输出字节数,diff 列表更大时放弃本轮记录 | | `maxFiles` | `500` | 单份摘要携带的最大文件数;`total` 仍报告完整数量 | | `maxFileBytes` | `2097152` | 文件在文件工具编辑前后被捕获、或从快照读出做对比所允许的最大字节数;更大的文件不提供对比,其中在文件工具编辑前后被捕获的也不带行数 | From fe3065735f1543a4647ebb33df4f2440ceacfd03 Mon Sep 17 00:00:00 2001 From: Turtle Date: Wed, 25 Nov 2026 12:51:22 +0800 Subject: [PATCH 3/4] docs(upgrade-guide): record the workspace-changes timeout default Co-authored-by: CreatixChu <142372241+CreatixChu@users.noreply.github.com> --- .../workspace-changes-timeout/guide.i18n.yaml | 16 +++++++++++++++ .../workspace-changes-timeout/guide.md | 20 +++++++++++++++++++ .../workspace-changes-timeout/guide.zh.md | 20 +++++++++++++++++++ 3 files changed, 56 insertions(+) create mode 100644 docs/upgrade-guide/v0.2.3-alpha.2/workspace-changes-timeout/guide.i18n.yaml create mode 100644 docs/upgrade-guide/v0.2.3-alpha.2/workspace-changes-timeout/guide.md create mode 100644 docs/upgrade-guide/v0.2.3-alpha.2/workspace-changes-timeout/guide.zh.md diff --git a/docs/upgrade-guide/v0.2.3-alpha.2/workspace-changes-timeout/guide.i18n.yaml b/docs/upgrade-guide/v0.2.3-alpha.2/workspace-changes-timeout/guide.i18n.yaml new file mode 100644 index 0000000000..f6e9028a19 --- /dev/null +++ b/docs/upgrade-guide/v0.2.3-alpha.2/workspace-changes-timeout/guide.i18n.yaml @@ -0,0 +1,16 @@ +# Bilingual-pair consistency record for guide.md (docs/i18n/README.md): per heading +# section, a hash of its English and Chinese blocks outside code blocks and generated regions. +# After editing either side, bring the other along and re-record with: +# pnpm run verify-translation-pairing --write docs/upgrade-guide/v0.2.3-alpha.2/workspace-changes-timeout/guide.md +/: + en: 7a2f7f6109b8b319 + zh: f9e94429c08e8df1 +/workspace-changes-give-up-a-git-command-after-3-seconds: + en: aee012e6a3556f45 + zh: 4728c8f80e791237 +/workspace-changes-give-up-a-git-command-after-3-seconds/change: + en: ec458c8b35f5c789 + zh: 66f9a9dece38992d +/workspace-changes-give-up-a-git-command-after-3-seconds/migration: + en: fa92e5be40cc471d + zh: f5ae3b0c11d12997 diff --git a/docs/upgrade-guide/v0.2.3-alpha.2/workspace-changes-timeout/guide.md b/docs/upgrade-guide/v0.2.3-alpha.2/workspace-changes-timeout/guide.md new file mode 100644 index 0000000000..5d6f89f7d2 --- /dev/null +++ b/docs/upgrade-guide/v0.2.3-alpha.2/workspace-changes-timeout/guide.md @@ -0,0 +1,20 @@ +--- +kind: upgrade-guide +description: "workspace-changes.timeoutMs now defaults to 3000 instead of 30000, so a turn whose git command runs longer than 3 seconds gets no changed-files card." +--- + +# Workspace changes give up a git command after 3 seconds + +English | [中文](guide.zh.md) + +## Change + +The `@deepseek-ai/dsh-workspace-changes` plugin terminated a git command after `timeoutMs`, which defaulted to `30000`. It now defaults to `3000`. Tool calls wait for the turn-start snapshot, so a working directory with many non-ignored untracked files no longer stalls each tool call for up to 30 seconds; when a snapshot or diff command exceeds 3 seconds, that turn records no changes and the Web shows no changed-files card for it. A per-file comparison opened from the card is also abandoned after 3 seconds. + +Affected: Web and Desktop users whose repositories need more than 3 seconds for one snapshot command, such as large untracked content, a cold disk cache, or a slow filesystem. A `timeoutMs` set explicitly on the `workspace-changes` row is kept. + +## Migration + +1. To keep the previous bound, add `- {id: workspace-changes, config: {timeoutMs: 30000}}` to the profile patch `$DSH_HOME/profiles//cordis.patch.yml`. Tool calls in such a repository then wait up to that long again. +2. To keep the card without the wait, add the large untracked directories to the repository's `.gitignore`. +3. Confirm with `dsh --profile --dump-config` that the `workspace-changes` row shows the intended `timeoutMs`. diff --git a/docs/upgrade-guide/v0.2.3-alpha.2/workspace-changes-timeout/guide.zh.md b/docs/upgrade-guide/v0.2.3-alpha.2/workspace-changes-timeout/guide.zh.md new file mode 100644 index 0000000000..d5f9147449 --- /dev/null +++ b/docs/upgrade-guide/v0.2.3-alpha.2/workspace-changes-timeout/guide.zh.md @@ -0,0 +1,20 @@ +--- +kind: upgrade-guide +description: "workspace-changes.timeoutMs 默认值由 30000 改为 3000,单条 git 命令超过 3 秒的轮次不再显示改动文件卡片。" +--- + +# 工作区改动记录在 3 秒后放弃 git 命令 + +[English](guide.md) | 中文 + +## 变更 + +`@deepseek-ai/dsh-workspace-changes` 插件在 `timeoutMs` 后终止 git 命令,原默认值为 `30000`,现在为 `3000`。工具调用会等待轮初快照,因此工作目录里有大量未忽略的未跟踪文件时,每次工具调用不再卡住最多 30 秒;快照或 diff 命令超过 3 秒时,该轮不记录改动,Web 也不显示该轮的改动文件卡片。从卡片打开的单文件对比同样在 3 秒后放弃。 + +受影响的是单条快照命令需要 3 秒以上的仓库的 Web 与 Desktop 用户,例如含大量未跟踪内容、磁盘缓存为冷或文件系统较慢。在 `workspace-changes` 条目上显式设置的 `timeoutMs` 保持不变。 + +## 迁移 + +1. 如需保留原上限,在 profile patch `$DSH_HOME/profiles//cordis.patch.yml` 中加入 `- {id: workspace-changes, config: {timeoutMs: 30000}}`。此后这类仓库中的工具调用会重新等待最多这么久。 +2. 如需保留卡片又不等待,把大的未跟踪目录加入仓库的 `.gitignore`。 +3. 用 `dsh --profile --dump-config` 确认 `workspace-changes` 条目显示预期的 `timeoutMs`。 From d6bb7edd5d468bd6af4fa5f96334b3158c937a00 Mon Sep 17 00:00:00 2001 From: Turtle Date: Wed, 25 Nov 2026 13:02:28 +0800 Subject: [PATCH 4/4] docs(workspace-changes): re-record README translation pairing Co-authored-by: CreatixChu <142372241+CreatixChu@users.noreply.github.com> --- packages/deliverables/workspace-changes/README.i18n.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/deliverables/workspace-changes/README.i18n.yaml b/packages/deliverables/workspace-changes/README.i18n.yaml index a2ebeb5523..79b2502203 100644 --- a/packages/deliverables/workspace-changes/README.i18n.yaml +++ b/packages/deliverables/workspace-changes/README.i18n.yaml @@ -15,8 +15,8 @@ en: d152484eb41ac6b4 zh: 09388d293f9be9cb /deepseek-ai-dsh-workspace-changes/use-this-package: - en: 27239874e99bc94d - zh: 93b437cc02de2064 + en: 38e467cfe33046a4 + zh: 7ee9fb04c4316439 /deepseek-ai-dsh-workspace-changes/understand-the-implementation: en: 9bfc66bea548bda2 zh: 7023c42cdb44569b