dsh-plugin-wsl-env 0.22.0 → 0.23.1

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 (81) hide show
  1. package/CHANGELOG.md +68 -0
  2. package/CONTRIBUTING.md +7 -3
  3. package/README.md +11 -9
  4. package/SUPPORT.md +1 -1
  5. package/cordis.patch.yml +4 -4
  6. package/docs/AGENT-PROTOCOL-V7.md +4 -4
  7. package/docs/API.md +12 -2
  8. package/docs/ARCHITECTURE.md +59 -19
  9. package/docs/CONFIGURATION.md +40 -18
  10. package/docs/CONFIGURATION.zh.md +44 -8
  11. package/docs/DIAGNOSTICS.md +19 -6
  12. package/docs/DIAGNOSTICS.zh.md +15 -6
  13. package/docs/LIMITATIONS.md +42 -17
  14. package/docs/LIMITATIONS.zh.md +47 -12
  15. package/docs/MIGRATION.md +1 -1
  16. package/docs/PEER-PARITY.md +8 -7
  17. package/docs/QUICKSTART.md +16 -8
  18. package/docs/QUICKSTART.zh.md +22 -4
  19. package/docs/README.zh.md +19 -10
  20. package/docs/RELEASING.md +8 -3
  21. package/docs/REQUIREMENTS.zh.md +11 -6
  22. package/docs/ROADMAP-1.0.md +12 -11
  23. package/docs/ROADMAP.md +10 -8
  24. package/docs/UPSTREAM-FILE-REFERENCE-SEAM.md +3 -2
  25. package/docs/UPSTREAM-FSIO-EXPORT.md +8 -9
  26. package/docs/UPSTREAM-SERVICE-SWAP.md +9 -5
  27. package/docs/UPSTREAM-TERMINAL-TITLE.md +9 -8
  28. package/docs/VALUE.zh.md +5 -5
  29. package/docs/root-fs-routing.md +27 -19
  30. package/lib/agent-confined.d.ts +2 -2
  31. package/lib/agent-confined.js +0 -1
  32. package/lib/agent-exec.d.ts +2 -11
  33. package/lib/agent-protocol.d.ts +6 -5
  34. package/lib/agent.d.ts +5 -5
  35. package/lib/auto-preset.d.ts +4 -3
  36. package/lib/bwrap.d.ts +2 -1
  37. package/lib/client-host.d.ts +1 -1
  38. package/lib/client-host.js +1 -1
  39. package/lib/cwd-prompt-tool.d.ts +4 -20
  40. package/lib/cwd-prompt.d.ts +11 -10
  41. package/lib/distro-route.d.ts +3 -2
  42. package/lib/doctor-live.d.ts +2 -1
  43. package/lib/fs-routing.d.ts +30 -1
  44. package/lib/fs-routing.js +31 -3
  45. package/lib/fs-substrate.d.ts +0 -1
  46. package/lib/fs-substrate.js +0 -1
  47. package/lib/fsio-agent.d.ts +3 -21
  48. package/lib/fsio-agent.js +2 -4
  49. package/lib/git-exec.d.ts +3 -2
  50. package/lib/git-route.d.ts +4 -2
  51. package/lib/git-route.js +4 -2
  52. package/lib/index.d.ts +9 -10
  53. package/lib/index.js +124 -12
  54. package/lib/listing.d.ts +2 -1
  55. package/lib/messages.d.ts +1 -1
  56. package/lib/native-agent.d.ts +3 -2
  57. package/lib/paths.d.ts +2 -1
  58. package/lib/picker.d.ts +1 -14
  59. package/lib/picker.js +1 -2
  60. package/lib/preflight.d.ts +5 -4
  61. package/lib/probe-cache.d.ts +2 -1
  62. package/lib/sandbox-core.d.ts +2 -11
  63. package/lib/sandbox-core.js +1 -1
  64. package/lib/sandbox.d.ts +0 -1
  65. package/lib/sandbox.js +0 -4
  66. package/lib/search-exec.d.ts +2 -1
  67. package/lib/session-runtime.d.ts +3 -2
  68. package/lib/shell-env.d.ts +3 -2
  69. package/lib/shell.d.ts +1 -1
  70. package/lib/shell.js +1 -1
  71. package/lib/subprocess.d.ts +1 -1
  72. package/lib/update-check.d.ts +3 -3
  73. package/lib/wsl-doctor-command.d.ts +38 -10
  74. package/lib/wsl-doctor-command.js +168 -27
  75. package/lib/wsl-doctor-tool.d.ts +9 -16
  76. package/lib/wsl-doctor-tool.js +10 -4
  77. package/lib/wsl.d.ts +3 -2
  78. package/package.json +27 -33
  79. package/scripts/bootstrap-import.sh +189 -0
  80. package/scripts/open-wsl-vscode.ps1 +36 -0
  81. package/examples/preset-wsl-session-sandbox.cordis.patch.yml +0 -178
package/docs/README.zh.md CHANGED
@@ -12,6 +12,8 @@ Harness 进程仍在 Windows 上。命令执行、shell 脚本和文件访问都
12
12
 
13
13
  仅支持 Windows + WSL 2。
14
14
 
15
+ **刚接触?** 从 [docs/QUICKSTART.zh.md](QUICKSTART.zh.md) 开始:前置条件、常用配方与兼容性表。
16
+
15
17
  ## 需要这个插件吗?
16
18
 
17
19
  如果 harness 本身可以跑在发行版里,更简单的做法是**不用**这个插件:把 CLI 装在
@@ -45,7 +47,7 @@ Windows 上的编程工具要在 WSL 项目中工作,有三条路:把整个
45
47
  - **发行版内没有服务。** 没有辅助服务、没有守护进程、没有监听端口。唯一持久化的内容是 `~/.cache/dsh-wsl/agent/` 下按内容寻址的原生 agent 副本。
46
48
  - **默认有沙箱。** 受限命令在发行版内的 `bubblewrap` 中运行。缺少 `bubblewrap` 时命令直接失败,不会脱箱运行。
47
49
  - **按会话生效。** 打开发行版文件夹的会话获得发行版环境;打开 Windows 文件夹的会话保留 Windows 工具。两者可同时运行在一个 harness 进程中。
48
- - **与 GUI 集成。** 文件夹选择器列出已安装的发行版,终端在发行版内打开 shell,模型能看到监听端口。
50
+ - **与 GUI 集成。** 文件夹选择器列出已安装的发行版,终端在发行版内打开 shell,模型能看到监听端口。composer 里的诊断按钮以 `/wsl-doctor` 命令运行环境诊断——宿主侧执行,不进模型对话;会话启动预检在每次会话打开时通报环境判定。
49
51
 
50
52
  ### 为什么是 Linux,而不是 PowerShell
51
53
 
@@ -75,7 +77,7 @@ Windows 上的编程工具要在 WSL 项目中工作,有三条路:把整个
75
77
 
76
78
  - Windows 10 或 11,启用 WSL 2,并至少有一个发行版。
77
79
  - 发行版内安装 `bubblewrap`,必需。
78
- - 默认的会话沙箱需要 systemd:在 `/etc/wsl.conf` 设置 `[boot] systemd=true`,重启 WSL,然后执行一次 `loginctl enable-linger "$USER"`。没有 systemd 时,在 `wsl-shell` 和 `wsl-fs` 上都设置 `sessionSandbox: false`。
80
+ - 默认的会话沙箱需要 systemd:在 `/etc/wsl.conf` 设置 `[boot] systemd=true`,重启 WSL,然后执行一次 `loginctl enable-linger "$USER"`。没有 systemd 时,在 `wsl-shell` 和 `wsl-fs` 上把 `sessionSandbox` 设为 `auto`(可用时仍用 scope,否则每条命令单独约束)或显式 `false`。
79
81
  - 可选:`ripgrep` 用于搜索,`git` 用于变更快照,`inotify-tools` 用于文件监视。
80
82
 
81
83
  发行版内不需要 Node.js。
@@ -109,9 +111,11 @@ dsh --profile wsl # 启动
109
111
  wsl.exe -d <发行版> -u root -- apt-get install -y bubblewrap
110
112
  ```
111
113
 
112
- 在插件检出目录中,`pnpm run doctor` 是一键环境体检:Windows/WSL 版本、发行版及其 shell、bubblewrap 可用性、systemd / user manager / Linger、可选工具、peer 版本、agent 缓存、新 agent 握手、残留会话 scope 和已知的 profile 补丁陷阱。每个失败都打印一条可复制的处理办法;`--json` 供脚本使用,`--fix` 清理残留 scope(安装包需要 `--fix --install` 并显式确认)。`pnpm run diagnose` 是其只读别名。`pnpm run bootstrap <发行版>` 仍是较窄的工具安装助手:检查四个发行版工具,并按包管理器打印安装命令;加 `--install` 仅在缺少 bubblewrap 时执行该命令。若只缺少其他工具,请自行执行打印的命令。
114
+ 在插件检出目录中,`pnpm run doctor` 是一键环境体检:Windows/WSL 版本、每个发行版的 WSL 模式、`.wslconfig` 与 `/etc/wsl.conf` 交叉核对、磁盘、时钟与 DNS、bubblewrap 可用性、systemd / user manager / Linger、可选工具、peer 版本、agent 缓存、新 agent 握手、三条证明链路完好的冒烟腿(帧 I/O、受限围栏、批量 substrate)、残留会话 scope、已知的 profile 补丁与废弃键陷阱,以及 registry 上是否存在更新的稳定版。报告逐项列出每个检查——按 distro 分组,每项带显式状态标记,失败项下附可复制的处理办法——并以裁决收尾:`ready`(首条命令应能成功)或 `blocked`(列明待修项),按生效配置计算。运行可以收窄范围:`--quick` 只探首条命令的前置项(约 10 秒),`--sections <分区清单>`(逗号分隔)只运行指定分区,且范围化报告会把未运行的检查显式列为跳过项。`--json` 供脚本使用,`--fix` 会复核它修过的项(安装包需要 `--fix --install` 并显式确认),`--all` 检查每个已装发行版,`--bundle <路径>` 写出可附加到问题报告的诊断文件(`--redact` 将路径脱敏)。固定骨架按宿主语言渲染——从 Windows 区域设置检测,可用 `--locale <标签>` 或 `DSH_WSL_DOCTOR_LOCALE` 覆盖;`--json` 保持语言无关。同一份报告经三个入口给出:本 CLI、`/wsl-doctor` 命令(composer 按钮——宿主侧执行,不进模型对话)、以及 `wsl_doctor` 模型工具(进程内采集,合并常驻 agent 的实时状态)。`DSH_WSL_DOCTOR` 还携带一条现成命令(`sh -c "$DSH_WSL_DOCTOR --json"`),可在发行版内直接重放 doctor。`pnpm run diagnose` 是 CLI 的只读别名。`pnpm run bootstrap <发行版>` 仍是较窄的工具安装助手。
115
+
116
+ 插件大约每天自行检查一次更新(启动后 2–10 分钟内首查),方式是询问应用的插件管理器——它从不自行联网。当存在更新的稳定版时,每个发行版会话中受管的 `DSH_WSL_PLUGIN_UPDATE` 变量会携带该事实;补丁配置里的 `wsl-update-check.enabled: false` 可关闭该检查,`DSH_UPDATE_REGISTRIES` 覆盖 doctor 的按需检查询问哪些 registry(逗号分隔,留空可让气隙机器跳过)。升级保持手动,因为 harness 没有热重载:重新安装(Plugins 页面或 `add` 命令),然后重启。
113
117
 
114
- 升级:在 Plugins 页面重新安装,或再次执行 `add` 命令。卸载:在 Plugins 页面移除,或在 CLI 发行版执行 `dsh plugin --profile wsl remove dsh-plugin-wsl-env`;之后可删除 `~/.cache/dsh-wsl`。如果你为了恢复预览在 profile 里加过 `workspace-files-wsl` 的临时覆盖,升级后请删掉:插件不再挂载该行。
118
+ 卸载:在 Plugins 页面移除,或在 CLI 发行版执行 `dsh plugin --profile wsl remove dsh-plugin-wsl-env`;之后可删除 `~/.cache/dsh-wsl`。如果你为了恢复预览在 profile 里加过 `workspace-files-wsl` 的临时覆盖,升级后请删掉:插件不再挂载该行。
115
119
 
116
120
  ## 使用
117
121
 
@@ -131,18 +135,20 @@ wsl.exe -d <发行版> -u root -- apt-get install -y bubblewrap
131
135
  |---|---|---|---|
132
136
  | `wsl-shell` | `distro` | `''` | 发行版模式;空/`auto` 跟随工作区,`default` 强制 WSL 默认 |
133
137
  | | `sandbox` | `true` | 用 `bubblewrap` 约束命令 |
134
- | | `sessionSandbox` | 随包 `true` | 会话命令跑在同一个 systemd user scope 中 |
138
+ | | `sessionSandbox` | `false`;随包 `true` | 会话命令跑在同一个 systemd user scope 中 |
135
139
  | | `agentBackend` | `auto` | 发行版内 agent:`auto`、`native` 或 `shell` |
136
140
  | | `maskWindowsDrive` | `false` | 让受限命令看不到 `/mnt` |
137
141
  | `wsl-fs` | `distro` | `''` | 发行版模式;空/`auto` 跟随每个目标路径 |
138
142
  | | `restrictToDistro` | `true` | 固定发行版(`default` 或名字)时拒绝属于其他发行版的路径 |
139
143
  | | `sandbox` | `true` | 按策略检查受限写入 |
140
- | | `sessionSandbox` | 随包 `true` | 受限写入跑在会话 runtime 中 |
144
+ | | `sessionSandbox` | `false`;随包 `true` | 受限写入跑在会话 runtime 中 |
141
145
  | | `substrate` | `agent` | 发行版内 agent;`share` 在启动时被拒绝 |
142
146
  | `directory-picker-wsl` | `includeHostHome` | `true` | 同时列出 Windows 家目录 |
143
147
  | `subprocess-wsl` | `distro` | `''` | 发行版模式;空/`auto` 跟随启动目录 |
148
+ | `wsl-preflight` | `distro` | `''` | 环境检查探测的发行版;空/`auto` 跟随会话工作区 |
149
+ | | `startup` | `true` | 插件加载时预先运行同一组检查,让判定在任何会话打开之前就出现在日志里 |
144
150
 
145
- `wsl-shell` 和 `wsl-fs` 位于随包的 `wsl` preset 中,按 id 覆盖无效。要改就覆盖整个 `preset-wsl` 行;配方和其余键见 [docs/CONFIGURATION.md](CONFIGURATION.md)。[`cordis.patch.yml`](../cordis.patch.yml) 是随包值的注释参考。
151
+ `fs-routing` 是根级 `ctx.fs` 调用的顶层路由:它的发行版设置独立于 `wsl-fs`,也是按 id 在顶层补丁中覆盖的行。`wsl-shell` 和 `wsl-fs` 位于随包的 `wsl` preset 中,按 id 覆盖无效。要改就覆盖整个 `preset-wsl` 行;配方和其余键见 [docs/CONFIGURATION.md](CONFIGURATION.md)。[`cordis.patch.yml`](../cordis.patch.yml) 是随包值的注释参考。
146
152
 
147
153
  ## 架构
148
154
 
@@ -183,7 +189,7 @@ wsl preset(每个会话)
183
189
  | 现象 | 处理 |
184
190
  |---|---|
185
191
  | 每条命令都报 `SANDBOX_UNAVAILABLE` | 在发行版内安装 `bubblewrap`,或设置 `sandbox: false` |
186
- | 会话在第一条命令前就被拒绝 | 运行 `pnpm run doctor`;启用 systemd 和 linger,或在 `wsl-shell`、`wsl-fs` 上设置 `sessionSandbox: false` |
192
+ | 会话在第一条命令前就被拒绝 | 运行 `pnpm run doctor`;启用 systemd 和 linger,或把 `wsl-shell`、`wsl-fs` 上的 `sessionSandbox` 设为 `auto` 或 `false` |
187
193
  | 发行版内 `glob`、`grep` 很慢 | 运行 `pnpm run bootstrap <发行版>`,使用打印的安装命令安装 `ripgrep` |
188
194
  | `dsh plugin add` 没有输出,或 Plugins 页面装完没有日志 | 以 profile 的 `package.json` 与 `dsh.profile.bundles` 为准:列出插件即安装成功 |
189
195
  | 对 `wsl-shell`/`wsl-fs` 的 profile 补丁不生效 | 这些行嵌套在 `preset-wsl` 里。运行 `pnpm run preset --check <补丁>`;它会失败并输出需要粘贴的完整块 |
@@ -196,7 +202,7 @@ wsl preset(每个会话)
196
202
  ```bash
197
203
  pnpm install # 开发依赖
198
204
  pnpm run build # 从 src/ 生成 lib/(lib/ 提交进仓)
199
- pnpm test # 风格、语法、构建一致性、类型、单元测试
205
+ pnpm test # 风格、链接、需求引用、文档一致性、语法、构建一致性、类型、单元测试
200
206
  pnpm run test:coverage # 带覆盖率阈值的单元测试
201
207
  pnpm run sync:windows # 更新应用加载的 Windows 侧副本
202
208
  ```
@@ -210,9 +216,12 @@ pnpm run sync:windows # 更新应用加载的 Windows 侧副本
210
216
  | 文档 | 内容 |
211
217
  |---|---|
212
218
  | [docs/QUICKSTART.md](QUICKSTART.md) | 首次运行、常用配方、兼容性 |
219
+ | [docs/PERFORMANCE.md](PERFORMANCE.md) | ext4 agent 对比 9p 的实测延迟与复现方法 |
220
+ | [docs/MIGRATION.md](MIGRATION.md) | 从早期版本升级、发布门槛 |
221
+ | [docs/COMPATIBILITY.md](COMPATIBILITY.md) | 已测的 Windows/WSL/发行版矩阵与范围决定 |
222
+ | [docs/API.md](API.md) | 包的子路径导出一览 |
213
223
  | [docs/CONFIGURATION.md](CONFIGURATION.md) | 所有配置键及覆盖方法 |
214
224
  | [docs/ARCHITECTURE.md](ARCHITECTURE.md) | 服务、路径路由、沙箱、错误码 |
215
- | [docs/PERFORMANCE.md](PERFORMANCE.md) | ext4 agent 对比 9p 的实测延迟与复现方法 |
216
225
  | [docs/LIMITATIONS.md](LIMITATIONS.md) | 插件不做的事 |
217
226
  | [docs/ROADMAP.md](ROADMAP.md) | 当前计划和推迟项 |
218
227
  | [docs/ROADMAP-1.0.md](ROADMAP-1.0.md) | 1.0 与生态优化计划 |
package/docs/RELEASING.md CHANGED
@@ -68,7 +68,9 @@ See [CONTRIBUTING.md](../CONTRIBUTING.md) for individual probes, prerequisites,
68
68
  and optional performance probes not included in the suite.
69
69
 
70
70
  `npm publish` runs the `prepublishOnly` script, which is `pnpm test`. The local
71
- gates therefore run again during the release step.
71
+ gates therefore run again during the release step. (The release workflow
72
+ publishes with `--ignore-scripts` for exactly this reason — its Gates step has
73
+ already run the chain; a hand-run publish keeps the hook.)
72
74
 
73
75
  ## 4. Commit and tag
74
76
 
@@ -96,8 +98,11 @@ this order:
96
98
  3. Asks the registry whether this version is already published, and skips the
97
99
  upload when it is. Re-pushing the same tag therefore does not publish again —
98
100
  it only gets you as far as the GitHub Release.
99
- 4. Publishes with `npm publish --provenance --access public`. That attaches a
100
- signed attestation tying the tarball to this workflow run and this commit.
101
+ 4. Publishes with `npm publish --provenance --access public --ignore-scripts`.
102
+ That attaches a signed attestation tying the tarball to this workflow run
103
+ and this commit. `--ignore-scripts` skips the `prepublishOnly` hook: the
104
+ Gates step has already run the full chain, and npm would otherwise re-run
105
+ it a second time. A hand-run publish keeps the hook as its safety net.
101
106
  5. Creates the GitHub Release, with notes taken from the changelog section by
102
107
  `scripts/changelog-section.mjs`.
103
108
 
@@ -6,7 +6,9 @@ docs/ 各篇里的行为承诺登记成带编号的需求条目,并给每条
6
6
  第二份「当前状态陈述」——每条需求的权威正文仍在所指向的文档里,本文只回答
7
7
  三个问题:**有哪些需求、在哪里规定、靠什么验证**。
8
8
 
9
- **基线**:本文核对于 `main` 2026-10-19(基线 0.12.0)。每次发版,或 CI 配置、
9
+ **基线**:本文核对于 `main` 2026-10-19(基线 0.12.0);0.22.0(2026-11-08)
10
+ 复核了 doctor 与更新检查线(新增 R26–R28,R20 的测试文件数随发版刷新),
11
+ 其余条目仍以上次全表核验为准。每次发版,或 CI 配置、
10
12
  覆盖率阈值等可核验项变更后,本表须重新核验;一切以仓库现状为准。
11
13
 
12
14
  维护规则与 [PARITY.md](PARITY.md) 的纪律一致:需求变更与登记表改动进同一笔
@@ -38,25 +40,28 @@ docs/ 各篇里的行为承诺登记成带编号的需求条目,并给每条
38
40
  | R4 | GUI 终端按会话路由:WSL 目录会话得发行版 shell,Windows 目录会话得 PowerShell(`hostSessions`) | ARCHITECTURE「Why the terminal provider is app-level」;LIMITATIONS 终端诸条 | ①②③⑤:路由判定、无目录启动落发行版、idle/busy/unknown 三态回收(`unknown` 必须暂停回收)逐项规定;tab 标题极限给出根因、上游提案与用户缓解 | `terminal.test.mjs`(terminalRoute 判定)、`terminal-activity.test.mjs`;probe:terminal | tab 标题读 `WSL`(UPSTREAM-TERMINAL-TITLE);host 终端 unknown 不回收——均为已声明边界 |
39
41
  | R5 | 目录选择器列出已装发行版及其层级 | README「Install」;CONFIGURATION `directory-picker-wsl` 行 | ①②③⑤:根级列表、`includeHostHome`/`maxEntries`/`preferredDistro`、常驻 out 时 one-shot 回退;换行符文件名极限的边界论证闭合(`/` 不可能出现在名字里) | `listing.test.mjs`(`maxEntries` 封顶、行解析);probe:picker | `preferredDistro` 决定的根级 `path`/`home` 领位、`includeHostHome` 的排序姿态:单测与探针都没有断言(探针只查成员构成与截断旗标) |
40
42
  | R6 | 端口可见性:`DSH_WSL_PORTS` 按节奏经常驻 agent 刷新 | README「Using it」;CONFIGURATION「`wsl-shell-env`」表 | ①⑤:机制(`/proc/net/tcp{,6}` 扫描)、`portsRefreshMs` 默认 10s、与 WSL2 localhost 转发的关系(平台行为)成文 | `ports.test.mjs`(解析层) | 轮询使常驻 agent 永不闲置回收(OI-4,已入 LIMITATIONS) |
41
- | R7 | 模型可见的发行版事实与 WSLENV 政策:受管 `DSH_*` 前缀准入,`PATH` 刻意不转发 | README「Using it」「Recipes」 | ①②③:两个 Windows 路径变量带 `/p` 翻译、`PATH` 不转发的理由成文;传输环境钉死 essentials+`DSH_*`+过滤后 WSLENV;shell 解析失败则省略事实而非报假值(宁可缺报不误报) | `terminal.test.mjs`(`/p` 翻译)、`agent.test.mjs`(传输环境 WSLENV 钉死为受管项)、`provider.test.mjs`(探针失败重试、不钉占位符) | `lib/shell-env.js`(事实生成)无单测,覆盖率报告不含该模块 |
43
+ | R7 | 模型可见的发行版事实与 WSLENV 政策:受管 `DSH_*` 前缀准入,`PATH` 刻意不转发 | README「Using it」「Recipes」 | ①②③:两个 Windows 路径变量带 `/p` 翻译、`PATH` 不转发的理由成文;传输环境钉死 essentials+`DSH_*`+过滤后 WSLENV;shell 解析失败则省略事实而非报假值(宁可缺报不误报) | `terminal.test.mjs`(`/p` 翻译)、`agent.test.mjs`(传输环境 WSLENV 钉死为受管项)、`provider.test.mjs`(探针失败重试、不钉占位符)、`shell-env.test.mjs`(假 `wsl.exe` 下挂载/清扫/resolve 双路径与 doctorFact/windowsToPosix) | 已闭合(原残差:`lib/shell-env.js` 无单测、覆盖率报告不含该模块):`test:coverage` 实测该模块 行 97.7%/分支 83.6%/函数 92.9%,逐模块地板(85/70/60)达标,`coverage-allowlist` 豁免已撤;未覆盖项仅为需在驻 agent 的端口扫描成功臂(探针层) |
42
44
  | R8 | 权限三档(read-only / workspace-write / danger-full-access)与提权提议流 | README「Sandbox」表;ARCHITECTURE「Error codes」 | ①②:三档行为逐档成表;模型可见两行前缀逐字给出;`FS_SANDBOX_DENIED` 可提权而 `FS_OUTSIDE_DISTRO` 不可,且区分理由明文(宽权限开不出另一个发行版) | `fs-decisions.test.mjs`、`provider.test.mjs`、`fsio-agent.test.mjs`(分类) | — |
43
45
  | R9 | bubblewrap 沙箱:与 Linux runner 同参数、fail-closed、`enforcement: partial` 诚实上报 | ARCHITECTURE「Sandbox」全节;SECURITY「Sandbox enforcement is `partial` by design」 | ①②③⑤⑥:选型依据(ACL 令牌触不到 WSL)、探针失败不缓存、interop 洞 + `maskWindowsDrive` 收窄及其自身极限(binfmt 按内容分发)、完全关闭唯一路径(`wsl.conf`)、`sandbox: false` 退出——行为到边界到逃生门完整成链 | `sandbox.test.mjs`、`probe-cache.test.mjs`;probe:sandbox、probe:sandbox-off | interop 使 enforcement 恒为 partial——已声明的设计边界 |
44
46
  | R10 | 文件搜索跑发行版自身的 rg,绝不跨 9p share | PARITY「Contract audit」第 2 条;LIMITATIONS「glob 和 grep」条 | ①②③:拦截点与参数逐字转发成文;缺 rg 浮出 exit 127 附 bootstrap 指引;grep 回退被拒绝且理由明文(不读 `.gitignore`,非 rg 替身) | `search-route.test.mjs`、`search-exec.test.mjs` | — |
45
47
  | R11 | watch():inotify 优先(无界目录),轮询回退;粗粒度失效 | PARITY「Contract audit」第 1 条;LIMITATIONS watch 两条 | ①②③:契约向上追溯到宿主接缝(`changed()` 无载荷 → 粗粒度失效即可);inotify 递归且 0.5s 合并、文件/限深/无 inotify-tools 回退轮询;更旧 mtime 盲区只属轮询路径、`watchMaxDepth` 旋钮、目标消失响亮报错成文 | `watcher.test.mjs`;probe:watch(无 inotify 时 7/7;装 inotify-tools 后盲区检查改为期望事件) | 轮询回退的 mtime 盲区已声明;inotify 路径依赖发行版的 inotify-tools |
46
- | R12 | share 基座退役:携带 `substrate: "share"` 的 profile 在 boot 被拒并附迁移 | README/CONFIGURATION/LIMITATIONS 三处一致 | ①②⑤:旧值处置与用户所见成文,迁移指引内嵌 | `fs-decisions.test.mjs`(拒绝消息与迁移指引文案) | boot 期拒绝分支无测试(构造器调 `shareSubstrateRefusal`,`src/index.ts:1056`):`fs.boot.test.mjs` 只以 `sandbox: true` 启动该行,仓内没有构造 `substrate: "share"` profile 的测试 |
47
- | R13 | 会话级 systemd scope:命令共享后台进程/真实 `/tmp`/`ps`,scope 随会话结束停止;systemd + linger 缺失时预检带修复拒绝 | ADR 0001;README/CONFIGURATION/LIMITATIONS 的 `sessionSandbox` 条 | ①②③⑤:scope 生命周期(agent 为主进程、refcount、dispose stop)、`sessionSandbox: false` 退出、systemd/linger/systemd-run 四项预检与缓存策略成文;`/tmp` 与后台进程的保真边界限定在 runtime 开时 | `session-scope.test.mjs`、`session-runtime.test.mjs`、`provider.test.mjs`;真机会话验证(active scope、跨命令后台/`/tmp`、会话结束 0 units) | 硬崩溃可能留下 stale scope(启动清扫未随发,入 LIMITATIONS);受限写入已共享 runtime,读仍走无约束共享 agent,根级 fs-routing 不持有 session runtime |
48
+ | R12 | share 基座退役:携带 `substrate: "share"` 的 profile 在 boot 被拒并附迁移 | README/CONFIGURATION/LIMITATIONS 三处一致 | ①②⑤:旧值处置与用户所见成文,迁移指引内嵌 | `fs-decisions.test.mjs`(拒绝消息与迁移指引文案) | boot 期拒绝分支无测试(构造器调 `shareSubstrateRefusal`,`src/index.ts:1595`):`fs.boot.test.mjs` 只以 `sandbox: true` 启动该行,仓内没有构造 `substrate: "share"` profile 的测试 |
49
+ | R13 | 会话级 systemd scope:命令共享后台进程/真实 `/tmp`/`ps`,scope 随会话结束停止;systemd + linger 缺失时预检带修复拒绝 | ADR 0001;README/CONFIGURATION/LIMITATIONS 的 `sessionSandbox` 条 | ①②③⑤:scope 生命周期(agent 为主进程、refcount、dispose stop)、`sessionSandbox: false` 退出与 `auto` 回退、systemd/linger/systemd-run 四项预检与缓存策略成文;`/tmp` 与后台进程的保真边界限定在 runtime 开时 | `session-scope.test.mjs`、`session-runtime.test.mjs`、`provider.test.mjs`;真机会话验证(active scope、跨命令后台/`/tmp`、会话结束 0 units) | 硬崩溃可能留下 stale scope(启动清扫未随发,入 LIMITATIONS);受限写入已共享 runtime,读仍走无约束共享 agent,根级 fs-routing 不持有 session runtime |
48
50
  | R14 | bootstrap:bwrap/ripgrep 等的就地体检与安装 | README「Install」「Troubleshooting」;CONFIGURATION | ①②⑤:`--install` 与只读体检两式、体检对象、错误消息补救指引成文 | 0.7.4 起脚本随包(`files` 收录,补救指引在 npm 安装下可用) | 脚本本身无 CI 腿(真机排错路径覆盖) |
49
51
  | R15 | 错误码方言:每个 `FS_*` 码给出抛出者、含义、解除条件;`wsl.exe` 自身失败显式收编 | ARCHITECTURE「Error codes」表 | ①②:逐码三列成表;两类历史隐形失败(UTF-16 stdout、cwd 回退 exit 0)收编;`FS_OUTSIDE_DISTRO` 独立成码的理由明文 | `fs-decisions.test.mjs`、`fsio-agent.test.mjs`、`fs-substrate.test.mjs`、`provider.test.mjs`(断言码与消息) | — |
50
52
  | R16 | 对端 parity 合同:fsio 文本机制逐字节复刻钉死的对端版本 | PEER-PARITY 全文 | ①④⑥:钉版、验证方法(npm pack 逐函数比对)、验证日期、刻意分歧逐条声明、bump 钉版即重跑的维护规则 | `fsio-agent.test.mjs`(distro 内半区 canary);对端比对为手动方法 | 钉版升级后需重跑比对(维护规则) |
51
53
  | R17 | 常驻 agent 协议:ACK 计时看门狗、只读帧才重放、逐流输出上限、sha256 部署校验、租约存活、进程组两段杀 | CHANGELOG 0.3.0/0.6.0/0.7.3;PARITY Phase 1/Phase 3 | ①②④:每条健壮性属性有规格出处与实证记录;「EXEC/变异 FS 帧禁止盲重发」是写明的不变量 | `agent-protocol.test.mjs`(HELLO 版本+摘要)、`agent.test.mjs`、`agent-exec.test.mjs`(truncated 旗标)、`agent-fs-script.test.mjs`;probe:agent、probe:exec | — |
52
54
  | R18 | 配置面:每键默认值成文;层组合语义(整行替换、不深合并、后层胜) | CONFIGURATION;`cordis.patch.yml` 头注 | ⑤:随发键成表、未列表键点名;覆盖方式的正确心智模型(整行替换)成文 | `composition.test.mjs`(层组合);`style.mjs`(`files` 契约) | — |
53
55
  | R19 | 非目标集:不做什么与为什么 | LIMITATIONS 开篇原则;PARITY「Not applicable」 | ③:已知极限入册;不适用项「记下来免得像遗漏」 | —(文档性) | — |
54
- | R20 | 验证策略:三层(fake → 真脚本过真线 → 真机探针)+ CI 矩阵 + 覆盖率阈值 | ARCHITECTURE「Test layers」;README「Development」 | ④:CI 在 Node 22/24 × Linux/Windows 上跑 `pnpm test`,`pnpm run test:coverage` 只在 Node 24 上跑(门槛旗标需 Node 22.8);Node 20 有意排除(`engines` 下限);覆盖率阈值 85/84/70(行/分支/函数),测量集合覆盖 `test/` 下 41 个测试文件,且 `lib/*.js` 必须逐个实测或带理由豁免 | `pnpm test`、`pnpm run test:coverage`;CI(ci.yml) | 真机验证依赖 Windows 和可用的 WSL 发行版;非功能无量化目标(OI-1) |
56
+ | R20 | 验证策略:三层(fake → 真脚本过真线 → 真机探针)+ CI 矩阵 + 覆盖率阈值 | ARCHITECTURE「Test layers」;README「Development」 | ④:CI 在 Node 22/24 × Linux/Windows 上跑 `pnpm test`,`pnpm run test:coverage` 只在 Node 24 上跑(门槛旗标需 Node 22.8);Node 20 有意排除(`engines` 下限);覆盖率阈值 85/84/70(行/分支/函数),测量集合覆盖 `test/` 下 48 个测试文件,且 `lib/*.js` 必须逐个实测或带理由豁免 | `pnpm test`、`pnpm run test:coverage`;CI(ci.yml) | 真机验证依赖 Windows 和可用的 WSL 发行版;非功能无量化目标(OI-1) |
55
57
  | R21 | 安全过程:范围内外、响应时限、partial 属设计边界、凭据政策 | SECURITY 全文 | ②③⑥:范围、3/10/30 个工作日时限(标注「目标非合同」)、partial 定性、凭据零容忍成文 | —(过程性) | — |
56
58
  | R22 | 支持矩阵:Windows 10/11 + WSL2 + Node `^22.19.0 \|\| >=24.0.0` + peer 版本范围 | SUPPORT 全文 | ⑥:支持与不受支持清单、peer 范围及精确开发依赖成文;Node 20 在范围外(理由见 SUPPORT,`engines` 为准) | `peerDependencies`、`devDependencies` 与 `engines`(`package.json`);CI 矩阵(ci.yml) | 新 peer 版本仍需验证 |
57
59
  | R23 | 根平面 `ctx.fs` 按坐标路由:发行版 UNC 由发行版内 agent 服务(inotify 或轮询 watch),盘符路径留在宿主;接替随发的 `fs-sandbox` 行 | README「Architecture」;ARCHITECTURE「The root-plane filesystem takeover」;CONFIGURATION `fs-routing` 行;root-fs-routing.md(设计) | ①②③⑤:路由判定与接替理由(写围栏在根平面无消费者)成文;`distro` 的 `auto`/`default`/pin 三态、每个 UNC 目标由自身 distro 服务、pin 下拒外来路径,以及 `distroCwd`/`restrictToDistro`/`sandbox`/`maskWindowsDrive`/`watchMaxDepth` 逐键成表,且自成一行、不与会话级行联动;`sandbox` 失败关闭成文 | `fs-routing.test.mjs`(纯谓词与路径助手)、`provider.test.mjs`(per-distro substrate/worldPath) | 类本体无单测(需 DSH peers 与实机);由组合测试与真机探针覆盖 |
58
60
  | R24 | GUI 文件树与预览在发行版内服务:沿用随包 `workspace-files` 行(server/client 成对),经根级 `fs-routing` 读写 distro UNC;盘符 scope 交宿主 | README「Architecture」;ARCHITECTURE「The root-plane filesystem takeover」;CONFIGURATION `workspace-files` 行 | ①②③⑤:沿用官方 server/client,浏览器 `file` provider 不丢,预览可用;路由与宿主/发行版 scope 成文;容量键由官方行承载、可覆盖;较直连多 4–6 次往返及其取舍在 LIMITATIONS 成文 | `fs-routing.test.mjs`、组合测试(`workspace-files` 保持启用、接管行不存在) | — |
59
61
  | R25 | 安装/卸载/升级流:四步安装、幂等陷阱及补救、ES 模块重启须知 | README「Install」「Troubleshooting」 | ①③:每步预期输出、`add` 幂等性陷阱的补救(先 remove 再 add)、pnpm UNC 链接极限成文 | 人工步骤,无自动化(依赖真实 dsh CLI + Windows) | 无自动化守护 |
62
+ | R26 | 诊断三入口同一份逐项报告:独立 CLI、`/wsl-doctor` UI 命令(宿主侧、不进模型历史)、`wsl_doctor` 模型工具(进程内合并常驻状态);报告按 distro 分组逐项带显式状态标记与失败修复;`--quick`/`--sections`(工具侧 `depth`/`section`)收窄范围且未运行项显式列为跳过 | DIAGNOSTICS「The surfaces」;README「Install」;CONFIGURATION「Diagnose configuration and refusals」 | ①②④:三入口的分工与边界成文;范围化报告携带 `scope`、`--fix` 要求完整运行成文;逐项化与跳过行的形态由 parity 测试钉住 | `wsl-doctor-tool.test.mjs`(digest/渲染/CHECK_CATALOG parity)、`wsl-doctor-command.test.mjs`(语法/handler/子进程面)、`doctor.test.mjs`(CLI 采集) | 真机多 distro 报告依赖实机;报告形态的宿主渲染(命令面 UI)无单测 |
63
+ | R27 | doctor CLI 独立性:不加载 peer 依赖与宿主服务,插件运行时本身损坏时仍可诊断;固定骨架本地化(Windows 区域设置检测,`--locale`/`DSH_WSL_DOCTOR_LOCALE` 覆盖),逐项事实保持英文,`--json` 语言无关 | DIAGNOSTICS「The surfaces」;CONFIGURATION「Message language」;LIMITATIONS「消息本地化」条 | ①②④:peer-free 内联与防漂移对拍成文;catalog 键 parity 与占位符行为有测试 | `doctor.test.mjs`(inlining parity、locale catalog、检测与覆盖) | 语言检测需 Windows registry(非 Windows 上回退英文,`run` 不抛错) |
64
+ | R28 | 每日更新检查经宿主插件管理器委托,不自取;事实进 `DSH_WSL_PLUGIN_UPDATE`;`wsl-update-check.enabled: false` 可关闭 | README「Install」;CONFIGURATION `wsl-update-check` 行 | ①②⑤:委托路径、TTL、关闭开关成文 | `update-check.test.mjs` | doctor 的按需 registry 查询独立于此行(`DSH_UPDATE_REGISTRIES` 控制,气隙可跳过) |
60
65
 
61
66
  登记覆盖面:上表登记 README 与 docs/ 中对外成文的行为承诺(含随发的服务面)。
62
67
  **有意未接线**的模块不设条目——`lib/file-reference-wsl.js`(`@` 补全的发行版侧
@@ -72,7 +77,7 @@ docs/ 各篇里的行为承诺登记成带编号的需求条目,并给每条
72
77
  | OI-1 | 非功能无量化目标:冷启动上界、常驻 agent 内存上界、watch 通知延迟上界均无规定 | 决策待定(开发工具语境可辩护,企业语境缺口) | 本表 R20 残差 |
73
78
  | OI-2 | 真机回归(协议/基座/沙箱的最高风险面)仅手动探针;CI runner 无 WSL distro | 环境受限决策,已如实记录 | ARCHITECTURE「Test layers」 |
74
79
  | OI-3 | 默认翻转(substrate、协议 v3→v4)无灰度、无遥测;迁移安全押在 boot 拒绝与响亮错误上 | OSS 取舍,企业语境缺口 | CHANGELOG 0.3.0 / 0.7.3 |
75
- | OI-4 | 端口轮询经共享 agent 使常驻进程永不闲置回收(LIMITATIONS 已记);工程修复=移出共享 agent 或改 one-shot | 工程项 | `lib/shell-env.js:79` |
80
+ | OI-4 | 端口轮询经共享 agent 使常驻进程永不闲置回收(LIMITATIONS 已记);工程修复=移出共享 agent 或改 one-shot | 工程项 | `lib/shell-env.js:173`(端口扫描)、`:190`(刷新计时器) |
76
81
  | OI-5 | 发布后无目录 fsync,shell agent 忽略 `sync -f` 失败;机器崩溃可能丢失数据或目录项(见 LIMITATIONS) | 工程项 | `agent/wsl-agent.sh`、`agent/native/spike/src/main.rs` |
77
82
 
78
83
  OI-7 已解决(2026-10-19):`test/fs-routing.test.mjs` 已进入 `test:unit` 与
@@ -1,6 +1,6 @@
1
1
  # Roadmap 1.0: the WSL plugin the DSH ecosystem should have
2
2
 
3
- Status: working plan, last refreshed 2026-11-07 against `0.19.0` (WSL-316 doctor closed-loop planning; the §2 area tables were last refreshed at 0.15.0).
3
+ Status: working plan, last refreshed 2026-11-09 against `0.22.0` (the WSL-316 doctor loop and the 0.21/0.22 GUI/localization line; the §2 area tables remain the 0.15.0 baseline and are explicitly historical).
4
4
  The 0.12.0 baseline that motivated the plan is kept below as history.
5
5
  Audience: maintainers and contributors. This is a plan, not a release promise.
6
6
  The short version: **from "the only WSL plugin" to "the default WSL plugin"** —
@@ -44,20 +44,21 @@ North-star metrics:
44
44
  | Real-machine probe suite | 100% on Tier 1, nightly |
45
45
  | Known documentation drift | 0 |
46
46
 
47
- ## 2. Where 0.15.0 stands
47
+ ## 2. The 0.15.0 baseline
48
48
 
49
49
  > WSL-101 landed on 2026-10-19: the distro follows the workspace and the
50
50
  > per-distro caches are in place. 0.15.0 (2026-10-27) shipped the compatibility
51
51
  > matrix, container legs, qemu aarch64, doctor, preset helper, and
52
52
  > `interopVisibility`. The table that *motivated* the plan is frozen as the
53
- > 0.12.0 baseline; the 0.15.0 row is what a reader should act on.
53
+ > 0.12.0 baseline; the 0.15.0 row records the state at that point. Current
54
+ > status lives in the release notes and the WSL-316 section below.
54
55
 
55
- ### 0.15.0 (current)
56
+ ### 0.15.0 baseline (historical)
56
57
 
57
- | Area | Strong today | Remaining gap |
58
+ | Area | Strong at 0.15.0 | Remaining gap |
58
59
  |---|---|---|
59
60
  | Execution | Native agent default; systemd session scope; `distro: auto` coordinate routing; concurrent distros | Physical aarch64 WSL (out of scope); non-systemd real-machine session probe unrun |
60
- | Files | in-distro agent substrate, root-plane `fs-routing` in unit+coverage, kernel-enforced confined writes; protocol v7 `FSB` batch (0.18.0) serves the GUI preview's stat+list+read shape in one round trip | `@` completion still 9p until the upstream `FileReferenceTraversal` seam; the preview's remaining round trips (open/patch) are one per op by design |
61
+ | Files | in-distro agent substrate, root-plane `fs-routing` in unit+coverage, kernel-enforced confined writes; protocol v7 `FSB` batch (0.19.0) serves the GUI preview's stat+list+read shape in one round trip | `@` completion still 9p until the upstream `FileReferenceTraversal` seam; the preview's remaining round trips (open/patch) are one per op by design |
61
62
  | Sandbox | `bubblewrap`, fail-closed, `enforcement: partial`, `interopVisibility` / `maskWindowsDrive` | Plugin keys do not disable WSL interop; distro `[interop] enabled=false` must be configured separately |
62
63
  | Onboarding | `doctor`, `bootstrap` / `bootstrap-import`, session preflight, `profile-preset` helper | Clean-machine first-run timing still unmeasured; session UI has no toast seam |
63
64
  | Configuration | Every shipped key documented; nested `preset-wsl` rows edited through the helper | An id patch of `wsl-shell` / `wsl-fs` still only warns |
@@ -131,7 +132,7 @@ correct once configured" and "the plugin is correct on first contact".
131
132
  | [P1.1](#wsl-201--sessionsandbox-auto) | `sessionSandbox: auto` for distros without systemd | Non-systemd distro runs the first command under per-command bwrap and reports the narrower scope; explicit `true` still refuses | M |
132
133
  | [P1.2](#wsl-202--compatibility-matrix-and-aarch64) | Compatibility matrix and real validation | Tier 1 (Ubuntu/Debian, systemd, x86_64) green; aarch64 spike runs under qemu; Tier 2 status documented | L |
133
134
  | [P1.3](#wsl-203--installupgradeuninstall-e2e) | Install/upgrade/uninstall E2E | Temporary `DSH_HOME`, packed tarball, profile install (Plugins page or `dsh plugin add`), `--dump-config` where the CLI exists, remove; upgrade from the previous minor | M |
134
- | [P1.4](#wsl-204--references-seam) | `@` references seam | Measure the 9p cost; land the upstream `FileReferenceTraversal` seam or a declared, tested fallback | L |
135
+ | [P1.4](#wsl-204---references-seam) | `@` references seam | Measure the 9p cost; land the upstream `FileReferenceTraversal` seam or a declared, tested fallback | L |
135
136
  | [P1.5](#wsl-205--lsp-provider-spike) | LSP provider spike | A documented plan and prototype for `ctx.lsp` over fs + subprocess, conditional on the desktop composition mounting LSP | M |
136
137
  | [P1.6](#wsl-206--gui-preview-performance) | GUI preview performance | Baseline measured; p95 <= 1s/MiB for a representative page; v6 only if the measurement justifies it | M |
137
138
  | [P1.7](#wsl-207--agent-recovery-and-status) | Agent recovery and status | In-flight death recovers within 2s or fails with a named state; `doctor`/status shows agent and scope health | M |
@@ -167,7 +168,7 @@ may move if the compatibility matrix exposes a higher-severity failure.
167
168
  |---|---|---|---|
168
169
  | Time to first command | Not systematically measured | p50 <= 5 min, p90 <= 15 min | Ten clean-machine runs |
169
170
  | Tier 1 first-run success | Not measured | >= 95% | Compatibility matrix |
170
- | Real-machine probes | 15 with `--include-fs` (14 base scripts incl. `fs-routing.sh`, plus `run.sh`); nightly job on hosted `windows-latest` skips without WSL | 100% on a Windows+WSL runner | Dispatch or a self-hosted runner that actually has WSL |
171
+ | Real-machine probes | 17 with `--include-fs` (16 base scripts plus `run.sh`; suite grew to 17 on 2026-11-06); nightly on the self-hosted Windows+WSL runner since 0.15.0 (cron 21:30 UTC, hosted runners skip green) | 100% green on the nightly run | CI `probes` job history |
171
172
  | FS single-op p95 | ~22ms host round trip | <= 30ms | `fs-queue.mjs` |
172
173
  | 16 concurrent reads p95 | 2.4-8.2ms | <= 20ms | `fs-queue.mjs` |
173
174
  | GUI preview p95 | Backend 63.5 ms/MiB (service round trips on top) | <= 1s/MiB | `probe:gui-preview` |
@@ -370,7 +371,7 @@ remedy for `no-systemd`, `no-user-manager`, `no-systemd-run` and `no-linger`
370
371
  (`sessionSandbox: false` on the row skips the session half). The advisory is
371
372
  logged **and** published as a session-scoped `wsl-preflight` runtime-context
372
373
  entry, so it is visible in the session transcript rather than only in the app
373
- log. DSH 0.2.1 has no toast/banner seam; the exact ask was filed as
374
+ log. DSH 0.2.2-rc.1 still has no toast/banner seam; the exact ask was filed as
374
375
  [#10263](https://github.com/deepseek-ai/deepseek-harness/discussions/10263) and is recorded in
375
376
  [UPSTREAM-SESSION-NOTICE.md](UPSTREAM-SESSION-NOTICE.md), and
376
377
  [LIMITATIONS.md](LIMITATIONS.md#session-start-advisories) records the boundary.
@@ -606,7 +607,7 @@ agent queue; the service-level round-trip count remains qualitative.
606
607
 
607
608
  **Status:** implemented (2026-10-19): a resident that spends its one rebuild
608
609
  enters a bounded revival (2/4/8 s backoff, one fresh transport and one rebuild
609
- per attempt); after three deaths the refusal is permanent and names the restart
610
+ per attempt); after three revivals the fourth death is permanent and names the restart
610
611
  remedy. `WslAgent.status()` exposes state, pid, lastError, deaths and pending.
611
612
  `pnpm run doctor` probes a fresh shell resident (`agent.handshake`: pid,
612
613
  protocol, script digest) and reports the agent cache and live/stale
@@ -829,7 +830,7 @@ release gate; full probe suite.
829
830
  **Priority:** P2 · **Size:** L · **Labels:** `area:onboarding`,
830
831
  `type:feature`, `priority:P2`
831
832
 
832
- **Status:** implemented on the plugin side (2026-11-07); the app-closed probe suite legs and the GUI-session closed-loop leg are on the maintainer checklist — the real-machine record is [2026-11-07 doctor real-machine](https://github.com/Big-Dao/dsh-plugin-wsl-env/blob/main/docs/superpowers/probe-runs/2026-11-07-doctor-real-machine.md). Designed and implemented the same day. The initial three
833
+ **Status:** implemented on the plugin side (2026-11-07); the app-closed probe suite legs and the GUI-session closed-loop leg are on the maintainer checklist — the real-machine record is [2026-11-07 doctor real-machine](https://github.com/Big-Dao/dsh-plugin-wsl-env/blob/main/docs/superpowers/probe-runs/2026-11-07-doctor-real-machine.md). Designed and implemented the same day; 0.21–0.22 then added the itemized per-distro digest, the `/wsl-doctor` command, the `wsl_doctor` tool and CLI/OS-locale localization. The initial three
833
834
  check groups (`distro.wsl-mode`, `config.wslconfig`, `distro.wsl-conf-*`) were
834
835
  filed in [issue #35](https://github.com/Big-Dao/dsh-plugin-wsl-env/issues/35)
835
836
  from the competitive triage (gaps #2/#3/#4). A commercial-doctor review added
package/docs/ROADMAP.md CHANGED
@@ -23,7 +23,7 @@ section.
23
23
  | A7 | native shared read agent (protocol v5 at the time); 16 concurrent shared reads 2.4–4.1 ms at the A7 measurement; shell remains the fallback |
24
24
  | A8 | aarch64 18-check under qemu-user in CI (built binary and committed `linux-aarch64` artifact); physical aarch64 WSL out of scope, see COMPATIBILITY.md |
25
25
 
26
- ## Next
26
+ ## Step details
27
27
 
28
28
  ### A7 — native shared read agent (v5) — done
29
29
 
@@ -34,13 +34,13 @@ shell as the fallback:
34
34
 
35
35
  - **selection:** `shell` forces the shell; otherwise the shared agent tries
36
36
  the packaged binary for the distro's architecture (or the dev override).
37
- Unlike session-runtime preparation with `agentBackend: native`, shared reads
38
- fall back to the shell when native preparation fails;
37
+ In `auto`, shared reads fall back to the shell when native preparation fails;
38
+ `agentBackend: native` refuses instead;
39
39
  - **preparation:** `ensureNativeBackend` once per distro (cache/digest/exec
40
- probe); the `WslAgent` with `expectedDigest` and `signalable: false`; on a
41
- preparation or HELLO failure the shell agent serves the reads — fail-open to
42
- the shell, never fail-closed;
43
- - **surface:** the same six FS ops (unchanged since v5) and `dsh-fs` side
40
+ probe); the `WslAgent` with `expectedDigest` and `signalable: false`; in
41
+ `auto`, a preparation or HELLO failure lets the shell agent serve the reads;
42
+ `native` reports the failure instead;
43
+ - **surface:** the six FS ops of that era and `dsh-fs` side
44
44
  channel; the
45
45
  `fs-substrate`/`DistroFs` parse is unchanged; the A2 differential covers the
46
46
  records;
@@ -49,7 +49,7 @@ shell as the fallback:
49
49
  concurrent shared reads at **2.4-4.1 ms** (from 342-614 ms; later reruns
50
50
  span 2.4-8.2 ms); the first start
51
51
  pays the ensure/cache cost (~70 ms once). The shell still serves the reads
52
- under `agentBackend: shell` and after a native failure.
52
+ under `agentBackend: shell`, and under `auto` after a native failure.
53
53
 
54
54
  ### A8 — aarch64 functional validation — done
55
55
 
@@ -59,6 +59,8 @@ and the committed `agent/native/linux-aarch64/dsh-wsl-agent`. Physical
59
59
  aarch64 WSL is out of scope (COMPATIBILITY.md). The native-session probe on
60
60
  real aarch64 hardware is not planned.
61
61
 
62
+ ## Next
63
+
62
64
  ### A9 — maintenance
63
65
 
64
66
  - Release A7 as a minor (0.11.0) through the tag workflow — done;
@@ -2,8 +2,9 @@
2
2
 
3
3
  Status: measured and deferred (2026-10-19; checked against a
4
4
  `dsh-v0.2.1-rc.2`-era upstream — the checked version was not recorded at
5
- the time. Plugin-side behavior re-verified 2026-11-02 against the current
6
- peer floor, `>=0.2.1-rc.3`). Online check 2026-11-06: upstream `v0.2.2-rc.1` (2026-11-04) still mounts no
5
+ the time. Plugin-side behavior re-verified 2026-11-02 against the peer floor
6
+ then in force, `>=0.2.1-rc.3`; the floor has since moved to `>=0.2.2-rc.1` in
7
+ `package.json`). Online check 2026-11-06: upstream `v0.2.2-rc.1` (2026-11-04) still mounts no
7
8
  `FileReferenceTraversal`; the interface lives in open discussion
8
9
  [#10264](https://github.com/deepseek-ai/deepseek-harness/discussions/10264) with no implementation. The `@` completion in
9
10
  `@deepseek-ai/dsh-file-reference-local` walks the workspace with
@@ -115,7 +115,7 @@ The rest of the module stays. `BINARY_SAMPLE_BYTES`, `FsCodedError`,
115
115
  `notTextError`, `decodeUtf8`, `decodeUtf8Stream` and `throwIfAborted`
116
116
  (`src/fsio-text.ts:23`, `:30`, `:53`, `:67`, `:86`, `:179`) have no counterpart
117
117
  in the fsio declarations, and the module's other consumers keep importing them
118
- locally (`src/fsio-agent.ts:27-36`, `src/fs-substrate.ts:37`,
118
+ locally (`src/fsio-agent.ts:27-34`, `src/fs-substrate.ts:37`,
119
119
  `src/index.ts:57`). `lib/fsio-text.js` is not deleted; four of its ten exports
120
120
  are.
121
121
 
@@ -164,7 +164,7 @@ Files that move with it:
164
164
 
165
165
  - `src/fsio-text.ts` — drop `applyLiteralEdit`, `detectLineEndings`,
166
166
  `normalizeLineEndings`, `restoreLineEndings`; keep the rest.
167
- - `src/fsio-agent.ts` (imports `:27-36`, `detectLineEndings` used at `:528`)
167
+ - `src/fsio-agent.ts` (imports `:27-34`, `detectLineEndings` used at `:756`)
168
168
  and `src/fs-substrate.ts` (`:37`) — take the four from the peer. Where they
169
169
  land decides the module's peer story: importing them directly keeps
170
170
  `src/fsio-text.ts` peer-free — and `test/fsio-text.test.mjs`, which imports
@@ -176,13 +176,12 @@ Files that move with it:
176
176
  - `test/fsio-text.test.mjs` (the replica's tests, including the
177
177
  `detectLineEndings` checks at `:69-72`) and `test/fsio-agent.test.mjs:22`,
178
178
  which imports two of the four from `lib/fsio-text.js`. If that test file is
179
- dropped or renamed, also the `test:coverage` and `test:unit` lists at
180
- `package.json:114` and `:116`.
181
- - The documents that describe the replica as current: `docs/ARCHITECTURE.md:173`
182
- and `:416` (the two entries marked "replicated … pending the … export"),
183
- `docs/PEER-PARITY.md:3` and `:17` (plus its Maintenance section),
184
- `docs/upstream/promotion-map.md:82` — and this file, whose status then becomes
185
- "landed".
179
+ dropped or renamed, update the `test:coverage` and `test:unit` script lists
180
+ in `package.json` too.
181
+ - The documents that describe the replica as current: `docs/ARCHITECTURE.md`
182
+ (the entries marked "replicated … pending the … export"), `docs/PEER-PARITY.md`
183
+ (plus its Maintenance section), `docs/upstream/promotion-map.md` — and this
184
+ file, whose status then becomes "landed".
186
185
 
187
186
  Done when: the pinned peer resolves the four names from both its runtime entry
188
187
  and its declarations, the plugin imports them there, `pnpm test` passes, and no
@@ -1,11 +1,15 @@
1
1
  # Upstream proposal: a same-name service swap that survives live recomposition
2
2
 
3
- Status: observed, not yet filed. The failure was first seen on the desktop
4
- `0.2.2-rc.1` release (app-bundled `@deepseek-ai/cordis@4.1.0` +
3
+ Status: observed, filing payload drafted; **not filed yet** — filing against
4
+ `deepseek-ai/deepseek-harness` is a maintainer action. The failure was first
5
+ seen on the desktop `0.2.2-rc.1` release (app-bundled
6
+ `@deepseek-ai/cordis@4.1.0` +
5
7
  `@deepseek-ai/cordis-plugin-loader@1.1.0`; the npm line still ships
6
- cordis `4.0.5` / loader `1.0.5`, which this repository pins), reproduced
7
- in isolation against both version pairs on 2026-11-05, and the mechanism
8
- is confirmed down to the `_unload` diff. Filing payload not yet drafted.
8
+ cordis `4.0.5` / loader `1.0.5`), reproduced in isolation against both
9
+ version pairs on 2026-11-05, and the mechanism is confirmed down to the
10
+ `_unload` diff. The exact filing payload (title, body, command; drafted
11
+ 2026-11-09) is
12
+ [proposal-service-swap.md](https://github.com/Big-Dao/dsh-plugin-wsl-env/blob/main/docs/upstream/proposal-service-swap.md).
9
13
 
10
14
  ## The gap
11
15
 
@@ -95,18 +95,19 @@ With either, this plugin deletes the limitation paragraph in
95
95
  [LIMITATIONS.md](LIMITATIONS.md) and the `WSL`-over-PowerShell title, for any
96
96
  provider that rewrites launches — not just WSL. The same limitation is stated
97
97
  as current fact in four places. Three go stale the day the proposal lands; the
98
- fourth is already out of step and needs the corrections above whenever it is
99
- next touched:
98
+ fourth — the `WSL` tab-title bullet under "Terminals" in
99
+ [LIMITATIONS.md](LIMITATIONS.md) — was already out of step and needed the
100
+ corrections above: it said the controller titles a tab *before* the provider
101
+ rewrites the launch, the reverse of the ordering corrected at the top of this
102
+ file, and it carried the one-line `shellCandidates` workaround that drops the
103
+ row's `shell` block. Corrected on 2026-11-09 (the LIMITATIONS paragraph and
104
+ its Chinese mirror now follow the ordering at the top of this file); the
105
+ remaining three still go stale the day the proposal lands:
100
106
 
101
107
  - the GUI-terminal comment block in [`cordis.patch.yml`](../cordis.patch.yml);
102
108
  - the closing paragraph of "Why the terminal provider is app-level" in
103
109
  [ARCHITECTURE.md](ARCHITECTURE.md);
104
- - R4's `残差` (residual) column in [REQUIREMENTS.zh.md](REQUIREMENTS.zh.md);
105
- - the `WSL` tab-title bullet under "Terminals" in
106
- [LIMITATIONS.md](LIMITATIONS.md) — the paragraph named just above. It says
107
- the controller titles a tab *before* the provider rewrites the launch, the
108
- reverse of the ordering corrected at the top of this file, and it carries the
109
- one-line `shellCandidates` workaround that drops the row's `shell` block.
110
+ - R4's `残差` (residual) column in [REQUIREMENTS.zh.md](REQUIREMENTS.zh.md).
110
111
 
111
112
  ## Workarounds until then
112
113
 
package/docs/VALUE.zh.md CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  本文只回答一个问题:**在 Windows 上用 DeepSeek Harness 做 WSL 项目,为什么值得装这个插件。**
4
4
  功能、安装与逐项行为见 [README](../README.md) 和 [ARCHITECTURE.md](ARCHITECTURE.md),这里谈收益、代价与适用边界。
5
- 文中每条主张都指向仓库内可复核的证据;基线为 v0.9.0(2026-10-17)。
5
+ 文中每条主张都指向仓库内可复核的证据;基线为 v0.22.0(2026-11-08)。早期条目在 v0.9.0 基线上引入,2026-11-09 对版本、工具面与门禁链做了复核。
6
6
 
7
7
  > **一句话**:它把 WSL 发行版变成 DSH 会话真正的执行环境——命令、文件、终端、目录选择器都在发行版内完成,
8
8
  > 同时保留 DSH 的权限模型和发行版内的 bubblewrap 沙箱;不往发行版里装自己的服务,也不开端口。
@@ -52,13 +52,13 @@ DSH 是 Windows 桌面应用,项目在 WSL 的 ext4 里。不做集成,三
52
52
 
53
53
  **机制。** 组合层按路径坐标路由:发行版 UNC 路径交给 agent 实现,盘符路径留给宿主后端;GUI 终端按会话路由,WSL 目录会话得到发行版 shell,Windows 目录会话仍是 PowerShell;`wsl-shell`/`wsl-fs` 挂在 preset 层,所以环境按会话生效。
54
54
 
55
- **可感知的差别。** 不需要为 WSL 单开一个应用或 profile,也不需要把整个应用切成「WSL 模式」。同一个窗口里,开 Windows 文件夹的会话不受影响,开 `\\wsl.localhost\...` 的会话自动进入发行版。换项目只是换一个打开的文件夹。模型侧尤其重要:插件不新增任何模型工具,现有工具的名字、参数、返回语义不变,变的只是它们实际作用的世界。
55
+ **可感知的差别。** 不需要为 WSL 单开一个应用或 profile,也不需要把整个应用切成「WSL 模式」。同一个窗口里,开 Windows 文件夹的会话不受影响,开 `\\wsl.localhost\...` 的会话自动进入发行版。换项目只是换一个打开的文件夹。模型侧尤其重要:插件只新增 `wsl_doctor` 一个模型工具(另有 `/wsl-doctor` 命令);其余现有工具的名字、参数、返回语义不变,变的只是它们实际作用的世界。
56
56
 
57
57
  **证据。** [README「Architecture」](../README.md#architecture)、[docs/root-fs-routing.md](root-fs-routing.md);`test/composition.test.mjs`、`test/terminal.test.mjs`、`test/fs.boot.test.mjs`。
58
58
 
59
59
  ### 价值五:不装服务、不开端口、没有残留
60
60
 
61
- **机制。** 发行版里没有安装任何服务,也没有监听端口;插件只替换 DSH 的服务实现。文件操作与命令走发行版内按 distro 缓存的常驻 agent——它是传输层,不注册系统服务,agent 脚本在握手时校验 sha256。
61
+ **机制。** 发行版里没有安装任何服务,也没有监听端口;插件替换 DSH 的服务实现,并新增 `wsl_doctor` 工具与 `/wsl-doctor` 命令。文件操作与命令走发行版内按 distro 缓存的常驻 agent——它是传输层,不注册系统服务,agent 脚本在握手时校验 sha256。
62
62
 
63
63
  **可感知的差别。** 不会多出 `~/.vscode-server` 这类目录,不会和本机端口冲突,卸载后发行版里没有需要手动清理的服务端目录。WSL 升级或发行版重启后,下一次调用重建传输;只有 agent 在「有请求在飞」时死亡才可能耗尽它的一次重建额度(见 [LIMITATIONS](LIMITATIONS.md)),这是已声明的边界,不是日常路径。
64
64
 
@@ -107,12 +107,12 @@ DSH 是 Windows 桌面应用,项目在 WSL 的 ext4 里。不做集成,三
107
107
 
108
108
  | 层面 | 证据 |
109
109
  |---|---|
110
- | 每次提交 | `pnpm test`:风格、语法、构建逐字节一致、`tsc --noEmit`、单测全过 |
110
+ | 每次提交 | `pnpm test`:风格、相对链接、需求引用、文档一致性、语法、构建逐字节一致、`tsc --noEmit`、单测全过 |
111
111
  | 覆盖率 | `pnpm run test:coverage`,门限 85/84/70(行/分支/函数) |
112
112
  | 真机 | 探针套件(`test/probe/run-all-when-closed.sh --include-fs`),含沙箱边界演示、agent/one-shot 双路径对拍、文件基座、终端、选择器 |
113
113
  | CI | Node 22 / 24 × Linux / Windows 跑 `pnpm test`;覆盖率在 Node 24 |
114
114
  | 上游接缝 | peer 钉版逐字节比对,[PEER-PARITY.md](PEER-PARITY.md)、[upstream/promotion-map.md](https://github.com/Big-Dao/dsh-plugin-wsl-env/blob/main/docs/upstream/promotion-map.md) |
115
- | 行为承诺 | [REQUIREMENTS.zh.md](REQUIREMENTS.zh.md) 的 24 条登记与追溯矩阵 |
115
+ | 行为承诺 | [REQUIREMENTS.zh.md](REQUIREMENTS.zh.md) 的 28 条登记(R1–R28)与追溯矩阵 |
116
116
 
117
117
  真机探针是手动步骤(托管 runner 没有 WSL 发行版),这是已记录的验证缺口(REQUIREMENTS 的 OI-2),不是隐性遗漏。
118
118
 
@@ -56,19 +56,20 @@ home 缓存,所以同一个根平面可以同时服务多个发行版;`distr
56
56
  | stat / listDir / readText / streamText / readBytes / readByteRange | targetKey 坐标 | substrate 对应操作 | super |
57
57
  | watch | targetKey 坐标 | distro inotify 或轮询(粗粒度失效) | chokidar |
58
58
  | writeText / editText | targetKey 坐标 | distro 写(substrate 守卫 + confined agent 内核强制) | super |
59
- | contains / processPath | parent/targetKey 坐标 | Linux 路径语义(`contains` 按两个目标的 `processPath` 做 POSIX 包含判定) | super |
59
+ | patchText / deleteFile / moveFile(v7) | targetKey 坐标;move 任一端为 distro 即整体路由 | distro 写(同一守卫 + confined agent;move 两端版本复核) | super |
60
+ | contains / processPath | parent/targetKey 坐标 | `contains` 按两个 UNC 的 POSIX 坐标判定;`processPath` 返回 UNC 宿主拼写 | super |
60
61
 
61
- 未覆写的出口:本类覆写的是上表这 13 个方法,`fileUrl` 与
62
+ 未覆写的出口:本类覆写的是上表这 16 个方法,`fileUrl` 与
62
63
  `processPathFromHostPath` 沿用宿主实现——「按坐标路由」不等于接口全覆盖。
63
64
 
64
65
  - `fileUrl` 由继承的实现从 `processPath` 派生
65
66
  (`pathToFileURL(this.processPath(target)).href`,`dsh-fs-local/lib/index.js:795-796`):
66
- distro 目标的 Linux 路径走的是**宿主平台**的编码路径,在 Windows 上 Node
67
- 先 `path.win32.resolve` 它,`file:///home/...` 不是可靠的形态。接口把 URI
68
- 编码留给后端,正是因为执行平台可能与宿主不同
69
- (`dsh-fs/lib/types/index.d.ts:117-123`);真有消费者时需要按 POSIX 语义覆写。
67
+ `processPath` 现在返回 UNC 宿主拼写,Windows 上得到
68
+ `file://wsl.localhost/<distro>/<path>`。它仍不是客户端媒体 URL 的形态——
69
+ 客户端 `fileMediaUrl` 拒绝 `\\` 开头的路径(§2.2)——真有消费者时需要
70
+ 按需覆写。
70
71
  - `processPathFromHostPath` 也是宿主实现(绝对宿主路径取 `resolve`)。被路由的
71
- `WslFileSystem` 自己有一份 distro 映射(`src/index.ts:1412`),那份映射不经
72
+ `WslFileSystem` 自己有一份 distro 映射(`src/index.ts:2133`),那份映射不经
72
73
  本路由。
73
74
 
74
75
  ### 2.2 有意的行为差异(对照原根 fs-sandbox)
@@ -77,15 +78,22 @@ home 缓存,所以同一个根平面可以同时服务多个发行版;`distr
77
78
  检查)只护写路径,而根平面当前没有写消费者(tool-fs 的写在 preset)。
78
79
  distro 侧写入自带更强的围栏(Linux 前缀包含 + confined agent 内核强制)。
79
80
  文档明示:若未来出现根平面写消费者,围栏语义需随行。
80
- - **UNC 目标的 `processPath` 变为 Linux 形态**:`processPath` 返回 distro
81
- 路径,而读它的根消费者仍在——正是本路由所服务的 workspace-files change
82
- feed:它在每个 `change` 事件里发出 `ctx.fs.processPath(target)`
83
- (`@deepseek-ai/dsh-api-workspace-files/lib/index.js:92`),distro 工作区的事件路径因此
84
- 是 Linux 形态。GUI 文件服务现在也用随包的 `workspace-files` 行,`stat`/读
85
- 同样经 `ctx.fs.processPath`,两种形态一致;此前的 `workspace-files-wsl`
86
- 接管把 `stat` 的 `absolutePath` 合成 UNC,已随该行删除。
87
- `fileUrl` 不在覆写之列(§2.1 注):它由 `processPath` 派生,同样不能假定为
88
- `file:///home/...`。
81
+ - **UNC 目标的 `processPath` 返回宿主拼写(UNC)**:与随包宿主后端和会话后端
82
+ `WslFileSystem`(继承 `LocalFileSystem`)一致——它们都回答 `String(targetKey)`。
83
+ 这是宿主路径消费者的硬契约:`session.openWorkspacePath` 与
84
+ `session.workspacePathApplications` 的 `verifyDesktopPath` 要求
85
+ `processPath(resolve(processPathFromHostPath(hostPath))) === hostPath`,而
86
+ `processPathFromHostPath` 是宿主实现(UNC 输入原样返回)。此前返回 Linux
87
+ 形态时该往返永不闭合,WSL 工作区里「在应用中打开 / 在文件管理器中显示」对
88
+ 任何 distro 文件都以 `Path has no verified Host path` 拒绝(issue #37);
89
+ `ui-deliverables` 的交付物打开路由(`present-open.ts`)用同一等式,一并失败。
90
+ workspace-files 的 change feed 与 `stat.absolutePath` 因此同为 UNC 形态,两者
91
+ 一致;Linux 形态保留在目标的 `displayPath`(模型看到的那一面)。共享根
92
+ (distro 根)保留 substrate 的尾分隔符:宿主 `resolve` 会去掉它,因此根目标
93
+ 通不过宿主路径校验;根目录本身不可 open/reveal(Windows 的 opener 也不接受
94
+ 共享根 URL),根下面的路径不受影响。
95
+ **代价**:客户端 `fileMediaUrl` 拒绝 `\\` 开头的路径,WSL 工作区里 Markdown
96
+ 预览的相对图片因此不渲染;聊天侧此前就已如此(其 `cwd` 本就是 UNC)。
89
97
  - **watch 的事件粒度**:无限深目录且有 `inotifywait` 时,distro 侧优先使用
90
98
  inotify;文件目标、限深目录或缺少工具时回退轮询。回调是粗粒度失效而非
91
99
  逐文件事件;轮询的 mtime 盲点见 [LIMITATIONS.md](LIMITATIONS.md)。
@@ -165,9 +173,9 @@ export `./fs-routing`)。config 承载两侧旋钮:宿主侧 `cwd`/`diffBasi
165
173
  (`wsl.exe --terminate <distro>`),根级对 UNC 目标的调用应 fail-closed 报
166
174
  `FS_IO_ERROR`(§2.3),而不是回落到 9P;同一次验证里宿主盘符路径照常工作。
167
175
 
168
- `changes` 与 `stat` 的 `absolutePath` 现在都来自 `ctx.fs.processPath`,都是
169
- Linux 形态;客户端归一化后可比对。此前的 `workspace-files-wsl` 接管让
170
- `stat` 返回 UNC、与 `changes` 不一致;该接管已删除,这一形态差异不再存在。
176
+ `changes` 与 `stat` 的 `absolutePath` 都来自 `ctx.fs.processPath`,现在同为
177
+ UNC 宿主形态;两者一致,客户端归一化后可比对。Linux 形态只保留在目标的
178
+ `displayPath`(模型读到的那一面)。
171
179
 
172
180
  回退:`fs-routing` 是顶层行,可以在你自己的 profile 层
173
181
  (`$DSH_HOME/profiles/<name>/cordis.patch.yml`,按 id 覆盖插件行)里恢复随发的
@@ -38,7 +38,7 @@ export declare function runSpawnChecklist({ wslPath, distro, root, runFn }: {
38
38
  runFn?: (argv: string[]) => Promise<unknown>;
39
39
  }): Promise<void>;
40
40
  /** One confinement request. */
41
- export interface ConfinedAgentRequest {
41
+ interface ConfinedAgentRequest {
42
42
  /** The distro to run in. */
43
43
  distro: string;
44
44
  /** The `wsl.exe` path. */
@@ -77,4 +77,4 @@ export interface ConfinedAgentRequest {
77
77
  export declare function confinedAgent({ distro, wslPath, policy, maskWindowsDrive, realTmp }: ConfinedAgentRequest): WslAgent;
78
78
  /** Test hook: forget every confined resident (the plain agent has no factory state). */
79
79
  export declare function resetConfinedAgents(): void;
80
- export default confinedAgent;
80
+ export {};
@@ -138,4 +138,3 @@ export function confinedAgent({ distro, wslPath = "wsl.exe", policy, maskWindows
138
138
  export function resetConfinedAgents() {
139
139
  confinedAgents.clear();
140
140
  }
141
- export default confinedAgent;