dsh-plugin-upgrade 0.1.3 → 2.0.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.
package/README.zh.md DELETED
@@ -1,172 +0,0 @@
1
- <div align="center">
2
-
3
- # ⬆️ dsh-plugin-upgrade
4
- - **1024 商店通道**:先 `npm i -g dsh1024`,再执行 `dsh1024 plugin --profile web add dsh-plugin-upgrade`(计入 [deepseek1024.com](https://deepseek1024.com) 安装排行)。
5
- [![Gitee](https://img.shields.io/badge/Gitee-mirror-c71d23?logo=gitee)](https://gitee.com/perrylink/dsh-plugin-upgrade)
6
-
7
- **DeepSeek Harness 插件升级技能(版本锁定)——`0.1.3-alpha.1` → `0.1.5-alpha.1`。**
8
-
9
- *一张版本卡 + 一个零依赖接缝扫描器,让「typecheck 绿了」不再被误当成「插件还能跑」。*
10
-
11
- > **官方仓库。** 这是 dsh-plugin-upgrade 唯一的官方仓库,由 PerryLink 维护。其他账号下的同名仓库与本项目无关。
12
-
13
- [![License](https://img.shields.io/badge/license-Apache%202.0-blue.svg)](LICENSE)
14
- [![DSH plugin](https://img.shields.io/badge/dsh--plugin-✅-green)](https://github.com/topics/dsh-plugin)
15
- [![dsh-doctor](https://raw.githubusercontent.com/PerryLink/dsh-plugin-doctor/main/badges/PerryLink__dsh-plugin-upgrade.svg)](https://github.com/PerryLink/dsh-plugin-doctor#verified-徽章)
16
- [![Node](https://img.shields.io/badge/node-%5E22.19%20%7C%7C%20%3E%3D24-brightgreen.svg)](#)
17
- [![CI](https://img.shields.io/github/actions/workflow/status/PerryLink/dsh-plugin-upgrade/ci.yml?branch=main&label=CI)](https://github.com/PerryLink/dsh-plugin-upgrade/actions)
18
- [![Version](https://img.shields.io/github/v/tag/PerryLink/dsh-plugin-upgrade?label=version)](https://github.com/PerryLink/dsh-plugin-upgrade/releases)
19
- [![npm version](https://img.shields.io/npm/v/dsh-plugin-upgrade)](https://www.npmjs.com/package/dsh-plugin-upgrade)
20
- [![npm downloads](https://img.shields.io/npm/dm/dsh-plugin-upgrade)](https://www.npmjs.com/package/dsh-plugin-upgrade)
21
-
22
- [English](README.md) · [简体中文](README.zh.md) · [Español](README.es.md) · [Português](README.pt.md) · [हिन्दी](README.hi.md)
23
-
24
- </div>
25
-
26
- ---
27
-
28
- ## 兼容性
29
-
30
- | 面 | 状态 |
31
- |---|---|
32
- | 宿主 | DeepSeek Harness `0.1.5-rc.1`(checkout `2efea31131`,tag `dsh-v0.1.5-rc.1` = `183f08e9c6dd`)。peer 区间 `@deepseek-ai/dsh-skill >=0.1.2-rc.1 <0.2.0 \|\| >=0.1.5-alpha.1 <0.2.0`、`@deepseek-ai/cordis ^4.0.2`、`@deepseek-ai/schemastery ^3.18.2`。 |
33
- | Node | `^22.19.0 \|\| >=24.0.0` |
34
- | 平台 | 有 Node 即可;扫描器只读文件系统,与平台无关 |
35
- | 模型 | 纯文本模型完全支持;技能就是一段 Markdown,不要求工具或视觉能力 |
36
- | 范围 | **只覆盖一条走廊**:`0.1.3-alpha.1` → `0.1.5-alpha.1`。它不是通用迁移框架。 |
37
-
38
- ## 你得到什么
39
-
40
- 两半,一套接缝目录:
41
-
42
- - **一个随包发布的 agent 技能(`plugin-upgrade-015`)** —— 版本卡 + 「修-验」循环。只有任务真正需要时模型才会加载它;本包不贡献任何系统提示词段落,也不注册工具。
43
- - **一个零依赖 CLI(`dsh-plugin-upgrade-scan`)** —— 按 `file:line` 报告十类接缝;这些接缝来自 2026-09-09 那轮对 40 个真实插件仓的实测。命中 error 级即退出码 `1`,可直接接进 CI。
44
-
45
- 它要消灭的失效模式是:**本地门禁绿了,不等于适配完成。** 有两类破坏能穿过 `typecheck` + `test`:
46
-
47
- 1. 已发布的类型线把接缝藏住,仓库对着旧类型编译(接缝 `M1`);
48
- 2. 测试是按旧形状 mock 的,于是测试通过而宿主拒收。
49
-
50
- 十类接缝中的 `S3`、`S8`、`S9`、`M1` 在本包成文时仍未被任何社区升级 PR 覆盖;其余六类已与该轮证据交叉核对。
51
-
52
- ## 快速开始
53
-
54
- ```sh
55
- # 1. 把 bundle 装进 profile
56
- dsh plugin --profile web add dsh-plugin-upgrade
57
-
58
- # 2. 确认这一行挂上了
59
- dsh --profile web --dump-config | grep -A3 'id: dsh-plugin-upgrade'
60
-
61
- # 3. 扫描你正在升级的插件
62
- npx dsh-plugin-upgrade-scan --repo ../my-plugin
63
- ```
64
-
65
- 然后让 agent 使用 `plugin-upgrade-015` 技能,或者自己照着版本卡走:
66
- `skills/plugin-upgrade-015/references/v0.1.3-alpha.1-to-v0.1.5-alpha.1.md`。
67
-
68
- ## 安装与卸载
69
-
70
- ```sh
71
- dsh plugin --profile web add dsh-plugin-upgrade # 从 npm 安装
72
- dsh plugin --profile web add "github:PerryLink/dsh-plugin-upgrade#main" # 从源码安装
73
- dsh plugin --profile web remove dsh-plugin-upgrade # 卸载(可逆)
74
- ```
75
-
76
- 装 bundle 只是注册一个技能;删掉那一行就删掉技能。CLI 是普通的 `npx` 目标,完全不需要 profile。
77
-
78
- ## 配置
79
-
80
- 所有键都可选,写在 profile patch 里:
81
-
82
- | 键 | 默认 | 含义 |
83
- |---|---|---|
84
- | `enabled` | `true` | 是否注册随包技能。设为 `false` 可保留依赖但不生效。 |
85
- | `skillName` | `plugin-upgrade-015` | `skillsRoot` 下要注册的目录名,也是目录里显示的名字。 |
86
- | `skillsRoot` | 包自带的 `./skills` | `<skillName>/SKILL.md` 所在目录。指向你自己的卡即可复用整套管线。 |
87
- | `userInvocable` | `true` | 除模型外,是否允许人按名字调用该技能。 |
88
-
89
- ```yaml
90
- - insert:
91
- - id: dsh-plugin-upgrade
92
- name: dsh-plugin-upgrade
93
- config:
94
- skillName: plugin-upgrade-015
95
- ```
96
-
97
- 挂载是「大声失败」的:`SKILL.md` 缺失、正文为空、或 frontmatter 没有 `name`,都会让挂载失败,而不是注册一个空技能。
98
-
99
- ## 暴露面
100
-
101
- **技能** —— `plugin-upgrade-015`(默认模型可调用、人也可调用)。正文:6 步循环。引用:版本卡。脚本:扫描器,随技能目录一起发布,因此相对路径可解析。
102
-
103
- **CLI** —— `dsh-plugin-upgrade-scan`:
104
-
105
- ```sh
106
- dsh-plugin-upgrade-scan [--repo <path>] [--json <out.json>] [--seams S3,S8,M1] [--quiet]
107
- ```
108
-
109
- | 参数 | 含义 |
110
- |---|---|
111
- | `--repo <path>` | 要扫描的仓库(默认:当前目录)。 |
112
- | `--json <out.json>` | 同时写出机器可读报告(`repo`、`scannedAt`、`files`、`hits[]`、`bySeam`)。 |
113
- | `--seams S3,S8,M1` | 只扫指定接缝。 |
114
- | `--quiet` | 不打印人类可读渲染(与 `--json` 搭配)。 |
115
-
116
- 退出码:`0` 无 error 级命中 · `1` 至少一个 error 级命中 · `2` 用法或扫描失败。扫描干净是必要条件而非充分条件 —— 卡上的出口标准是在临时 `DSH_HOME` 上做一次真机冒烟。
117
-
118
- ## 十类接缝
119
-
120
- | Id | 级别 | `0.1.5-alpha.1` 线里变了什么 |
121
- |---|---|---|
122
- | `S1` | warn | 会话格式为 V3,日志文件名带世代(`session.v3.jsonl.zstd`)。硬编码 `session.jsonl.zstd` 会静默失效。 |
123
- | `S2` | warn | `EpochHeader.system` 已移除;系统提示词是 surface 节点 0 的 `system/message`。读取方需要结构式回退。 |
124
- | `S3` | error | `assistant/message` 必须带 `stream`;缺了会话能导入但无法续聊(`Session.fromRestore` 拒绝非法 settlement 字段)。 |
125
- | `S4` | error | `tool/code-dispatch` 改名为 `tool/ptc-dispatch`。 |
126
- | `S5` | error | `ctx.agent` 已移除;调用方改为显式接收 `Agent`。 |
127
- | `S6` | error | `Inbox` 变成类型接口,不再可构造;请用 `agent.inbox` 与官方夹具形状。 |
128
- | `S7` | warn | `SubprocessHandle.pid` 已移除(只有 `SubprocessTerminalHandle` 保留 `pid`)。 |
129
- | `S8` | error | `SessionHandle.read()` 现在返回 `SessionHandleReadResult` —— 要解包 `.events`。 |
130
- | `S9` | error | `SystemPrompt` 配置的 `persona` 改为 `personaPrefix` / `personaSuffix`。 |
131
- | `M1` | error | `tsconfig` 的 `paths` 指向不存在的 checkout 目录时,TypeScript 会静默回退到已发布类型 —— 本地门禁变成**假绿**。 |
132
-
133
- `S7`、`S1`、`S2`、`S10` 刻意保持「提示」级别:它们有合法命中(Node 自带的 `pid`、旧世代读取器、插件自建的自适应事件门),所以扫描器把它们报成待人工复核的线索,而不是失败。
134
-
135
- ## 本包不覆盖什么
136
-
137
- - **其他走廊。** `0.1.1` → `0.1.2` 以及未来版本线不在范围内;版本卡刻意锁死版本 —— 会漂移的卡比没有卡更糟。
138
- - **DSH 面向用户的升级路径。** 本包升级的是**插件源码**,不是用户的 harness 安装。
139
- - **客户端/浏览器行为。** 扫描器是静态的;client 半边仍需真实浏览器断言。
140
- - **证明。** 扫描干净只是假设。出口标准是真机冒烟(临时 `DSH_HOME`、目标 CLI、`plugin add <tarball>`、`--dump-config`,会话日志写入方还要加一次 resume 往返)。
141
-
142
- ## 安全边界
143
-
144
- - **只读扫描。** CLI 绝不往被扫仓库里写文件;`--json` 只写你指定的路径。
145
- - **无网络、无 shell。** 扫描器除 Node 标准库外不引入任何依赖,也从不创建进程。
146
- - **不碰密钥。** 本包不读取凭据、环境令牌或会话数据。
147
- - **沙箱化冒烟配方。** 卡上的真机检查使用 `mkdtemp` 出来的 `DSH_HOME`,绝不碰你真实的 `~/.dsh`。
148
-
149
- ## 开发
150
-
151
- ```sh
152
- pnpm install
153
- pnpm test # node --test(真实 Cordis + 真实 SkillRegistry)
154
- pnpm run verify:self-contained # 所有 import 都在包内解析
155
- pnpm run verify:artifacts # 打包产物带齐技能、CLI 与 patch
156
- pnpm run check:readmes # 五语 README 一致性
157
- pnpm pack
158
- ```
159
-
160
- 扫描器自带合成的 `fixtures/bad-repo` 与 `fixtures/good-repo`,外加一个针对已适配仓库的 live negative —— 目录回归会让测试套件失败,而不是让下游用户踩坑。
161
-
162
- ## 主题标签
163
-
164
- `dsh`、`dsh-plugin`、`deepseek-harness`、`deepseek`、`cordis`、`plugin-upgrade`、`migration`、`skill`、`version-card`、`scanner`(与 `package.json` 的 keywords 一致;`dsh-plugin` 是生态的曝光通道)。
165
-
166
- ## PerryLink DSH 插件家族
167
-
168
- 属于 PerryLink DSH 插件家族 —— 40 个仓库,覆盖会话、记忆、权限、交付、可观测性与开发者工具。目录见 [perrylink-dsh-catalog.perrylink.workers.dev](https://perrylink-dsh-catalog.perrylink.workers.dev) 或 [`dsh-plugin` 主题](https://github.com/topics/dsh-plugin)。
169
-
170
- ## 许可证
171
-
172
- Apache-2.0 —— 见 [LICENSE](LICENSE)。安装期依赖及其许可证列在 [THIRD_PARTY_NOTICES.md](THIRD_PARTY_NOTICES.md);本包不打包任何第三方代码。
@@ -1,38 +0,0 @@
1
- ---
2
- name: plugin-upgrade-015
3
- description: Migrate a DeepSeek Harness plugin repo from the 0.1.3-alpha.1 line to 0.1.5-alpha.1. Runs a zero-dependency seam scanner (V3 session format, assistant/message.stream, SessionHandleReadResult, ctx.agent, Inbox, SubprocessHandle.pid, SystemPrompt persona, PTC rename, EpochHeader.system, and the tsconfig stale-path false-green), then walks the fix-and-verify loop with real-host smoke.
4
- whenToUse: Use when a DSH plugin must support @deepseek-ai/dsh 0.1.5-alpha.1 (or any host line in >=0.1.3-alpha.1 <0.1.5-alpha.2) while keeping the 0.1.2-rc.1 peer band working. Not for 0.1.1→0.1.2 migrations (use the community convergence skill) and not for the DSH user-facing upgrade/repair path.
5
- metadata:
6
- corridor: "0.1.3-alpha.1 -> 0.1.5-alpha.1"
7
- host-baseline: "0.1.5-alpha.1 (checkout 19d2e38480, tag dsh-v0.1.5-alpha.1 5dda764ed3)"
8
- evidence: "40 plugin repos, 2026-09-09 wave"
9
- status: "published"
10
- user-invocable: true
11
- ---
12
-
13
- # Plugin upgrade · 0.1.3-alpha.1 → 0.1.5-alpha.1
14
-
15
- You are migrating **one plugin repository** to the DSH `0.1.5-alpha.1` line. The goal is not "make typecheck pass" — it is "prove the plugin still works on the target host". Local gates are necessary but not sufficient: two failure classes survive a green gate (stale-type false green, and tests mocked against the old shape).
16
-
17
- ## Hard rules
18
-
19
- 1. **Run the scanner first.** `node ./scripts/scan-0.1.5.mjs --repo <repo>` — it prints `file:line` facts. Do not trust a green `typecheck` before M1 is cleared.
20
- 2. **M1 is a blocker, not a warning.** If `tsconfig` `paths` do not resolve, TypeScript silently falls back to published types and every other signal is fake. Fix the paths, then re-run; new red is real signal.
21
- 3. **Only adapt what the card says changed.** Do not refactor beyond the card; keep the old peer band working (the repo must still boot on `0.1.2-rc.1`).
22
- 4. **Behavior change ⇒ test change ⇒ docs change, in one commit.** Five-language READMEs and CHANGELOG move with the code.
23
- 5. **Real-host smoke is the exit criterion.** Temp `DSH_HOME` (mkdtemp) + target CLI + `dsh plugin --profile web add <tarball>` + `--dump-config`. Never touch the user's real `~/.dsh`.
24
-
25
- ## Loop
26
-
27
- 1. **Identify** — record: repo, current version, peer band, target host tag, node/pnpm, and whether the repo has client half / tracked `lib/`.
28
- 2. **Baseline** — run the repo's own gate chain and *record pre-existing failures*; never let them be counted as migration regressions.
29
- 3. **Scan** — run `./scripts/scan-0.1.5.mjs`; load only the version card facts that hit.
30
- 4. **Plan** — group by host/client/config/distribution; list files, why they change, tests, rollback point. Get confirmation before editing.
31
- 5. **Adapt + verify per module** — fix, run the module's tests, keep commits conventional and independently revertable.
32
- 6. **Prove** — full gate chain + real-host smoke (+ resume round-trip for log writers, + browser assertion for client halves). Report done / not-hit / pre-existing / unverified / rollback.
33
-
34
- ## Reference
35
-
36
- - `./references/v0.1.3-alpha.1-to-v0.1.5-alpha.1.md` — the version card: 10 seams with host path + commit + minimal fix + regression, and the 4 that no community PR covers yet (S3/S8/S9/M1).
37
- - `./scripts/scan-0.1.5.mjs` — the detector (zero dependency, `file:line`, exit 1 on error-severity hits).
38
- - The package's own test suite (`node --test`) — synthetic bad/good fixtures plus a live negative on a repo already adapted by this wave.
@@ -1,90 +0,0 @@
1
- # Version card · `0.1.3-alpha.1` → `0.1.5-alpha.1`
2
-
3
- > 适用:任何 `@deepseek-ai/dsh-*` peer 落在 `>=0.1.2-rc.1 <0.2.0`、且需要同时支持 `0.1.5-alpha.1` 的插件仓。
4
- > 状态:**已发布**(当前发布版本见本包 `package.json`;npm `dsh-plugin-upgrade` · GitHub `PerryLink/dsh-plugin-upgrade` · Gitee 镜像)。
5
- > 证据:2026-09-09 批次 **40 个真实插件仓**的实测升级波(宿主 checkout `0.1.5-alpha.1`,HEAD `19d2e38480`;官方 tag `dsh-v0.1.5-alpha.1` = `5dda764ed3`)。复现方式:本包 CLI `dsh-plugin-upgrade-scan --repo <仓库>` 输出 `file:line`,再按本卡逐缝处理。
6
-
7
- ## 0. 这一跳与其它跳的关系
8
-
9
- | 走廊 | 社区状态(2026-09-09 实测) |
10
- |---|---|
11
- | `0.1.0-rc.8 → 0.1.3-alpha.2` | 合流仓 `oh-my-dsh/dsh-plugin-upgrade-skill` 已合入 |
12
- | `0.1.3-alpha.2 → 0.1.5-alpha.1` | **两条 open PR 已认领**(#195 18 卡 / #197 6 卡),均未合入 |
13
- | 本卡覆盖 | `0.1.3-alpha.1 → 0.1.5-alpha.1`,**只补已被实测、但上述 PR 未覆盖的 4 类**(S3 / S8 / S9 / M1),其余 seam 作为交叉核对 |
14
-
15
- **本卡的四类独家内容**:S3(`assistant/message.stream`)、S8(`SessionHandleReadResult`)、S9(`SystemPrompt.persona` → `personaPrefix`)、**M1(tsconfig 陈旧路径导致 typecheck 静默假绿)**。
16
-
17
- ## 1. M1 · tsconfig 陈旧路径 → 本地门禁假绿(**最高优先级,独家**)
18
-
19
- | 项 | 内容 |
20
- |---|---|
21
- | 旧假设 | `tsconfig.json` 的 `paths` 把 `@deepseek-ai/*` 指到本地 harness checkout,`pnpm run typecheck` 即"对最新版编译" |
22
- | 触发 | 工作区搬迁(2026-09-07)后 `../../../packages|vendor` 不再指向 checkout(实测解析到 `D:\Projects\packages`,不存在) |
23
- | 真实行为 | TypeScript 对**解析失败的 path 映射静默回退**到 `node_modules` 的已发布类型 → 门禁全绿,但编译的不是目标版本 |
24
- | 实测规模 | 40 仓中 **11 仓**命中;修复路径后**3 仓立刻暴露真实 TS 错误**(原本"全绿") |
25
- | 正确写法 | 相对仓库根:`../../../../deepseek-harness/packages/<pkg>/lib/types/index.d.ts`(及 `vendor/...`) |
26
- | 检测 | `node scripts/scan-0.1.5.mjs --seams M1`:逐条解析 `paths`,目标不存在即报 error |
27
- | 回归 | 修复后 `pnpm run typecheck` 必须仍绿;**若变红,那才是真实适配缺口**(先修代码,不要回退路径) |
28
- | 剩余风险 | 路径依赖本地 checkout 布局;CI 侧应改用 `typecheck:ci`(清空 paths)做已发布线回归,两把尺子都要绿 |
29
-
30
- ## 2. S3 · `assistant/message` 必填 `stream`(**独家**)
31
-
32
- | 项 | 内容 |
33
- |---|---|
34
- | 目标契约 | `packages/core/session/src/index.ts` 的 `assertAssistantSettlementShape` 要求 `Array.isArray(data.stream)` |
35
- | 谁受影响 | **写入会话日志的一方**(导入器/转换器/eval 产物生成器),不是只读消费者 |
36
- | 失败形态 | 日志写入成功、`Session.fromRestore` 抛 `seed assistant/message at index N has invalid settlement fields` → **会话不可续聊**(比 typecheck 红更隐蔽) |
37
- | 实测案例 | `dsh-claude-move`:handle 基线导入成功但 resume 失败;修复 = `normalizeHandleEvents` 在格式版本 ≥2 时为 `assistant/message` 补 `stream: []`(legacy 与版本 <2 路径零改动) |
38
- | 注意 | 这不是 0.1.5 新增:0.1.3-alpha.1 的旧断言同样会抛,只是 0.1.2-rc.1 线无该字段;**升级到 alpha 线后成为阻断项** |
39
- | 检测 | 扫描器 S3:文件出现 `assistant/message` + 会话写入迹象、且全文无 `stream:` → error |
40
- | 回归 | L6 级往返测试:新日志可 resume、缺 `stream` 形状被拒、legacy 可读回 |
41
-
42
- ## 3. S8 · `SessionHandleReadResult`(**独家**)
43
-
44
- | 项 | 内容 |
45
- |---|---|
46
- | 目标契约 | `SessionHandle.read()` 返回 `{ eventState, events, ... }`(`packages/session/session-persistence/src/*`,commit `9b78f99dec`) |
47
- | 旧假设 | `read()` 返回 `SessionEvent[]`(直接 `.filter()` / `.findLast()` / 当数组用) |
48
- | 实测案例 | `dsh-background-agents` 生产代码 `src/tools.ts:713`(`TS2740: missing length, concat, join, slice…`)+ 两处测试;`dsh-output-styles` 的 `scripts/verify-session-log.mjs` 直接 TypeError |
49
- | 正确写法 | `const { events } = await handle.read()` 或 `(await handle.read()).events` |
50
- | 检测 | 扫描器 S8:`await X.read()` 出现但全文无 `.events`/解构解包 → error |
51
- | 回归 | 测试夹具改成 `.events`;verify 脚本用同一契约 |
52
-
53
- ## 4. S9 · `SystemPrompt` 配置改名(**独家**)
54
-
55
- | 项 | 内容 |
56
- |---|---|
57
- | 目标契约 | `packages/core/system-prompt/src/index.ts` 的 Config:`includeHarnessIdentity?` / `includeRuntimeContext?` / `personaPrefix?` / `personaSuffix?` / `toolOrder?`(commit `40792330c0`) |
58
- | 旧假设 | `{ persona: '' }` |
59
- | 实测案例 | `dsh-data-quality`、`dsh-industry-research`、`dsh-research-report`、`dsh-fast` 的测试夹具(`TS2353: 'persona' does not exist in type 'Config'`) |
60
- | 正确写法 | `{ personaPrefix: '' }`;**不要**用 `includeHarnessIdentity: false` 代替——那会删掉 `harness:identity` 段,语义不等价 |
61
- | 官方先例 | `apps/cli/tests/profiles/headless/tests/harness.ts:59` |
62
- | 检测 | 扫描器 S9:`{ persona:` 且文件含 `SystemPrompt` → error |
63
- | 回归 | typecheck + typecheck:ci 双绿 |
64
-
65
- ## 5. 其余 seam(交叉核对用,细节见 COMPLETION-REPORT §2)
66
-
67
- | seam | 一句话 | 影响仓(实测) |
68
- |---|---|---|
69
- | S1 | 会话格式 V3 + 日志世代名 `session.v3.jsonl.zstd` | 日志读写方;硬编码旧名会静默失效 |
70
- | S2 | `EpochHeader.system` 移除,系统提示词进 `system/message` | auto-review / fast / observe / output-styles |
71
- | S4 | `tool/code-dispatch` → `tool/ptc-dispatch`(V3 迁移映射) | doublecheck(4 处)/ observe(2 处) |
72
- | S5 | `ctx.agent` 移除 | wechat(唯一命中;替代 = setup 第 2 参) |
73
- | S6 | `Inbox` 类型化(不可构造) | fund-research / score / test-drive(夹具) |
74
- | S7 | `SubprocessHandle.pid` 移除 | click / talk / score / test-drive / lsp-actions |
75
- | S10 | 事件词表 fail-closed、`append` 无 `ignorable` 写入通道 | permission-rules(版本预检未覆盖新线 → 审计行未盖章 → 会话不可恢复) |
76
-
77
- ## 6. 强制验证顺序(本地门禁是必要非充分)
78
-
79
- 1. `scan-0.1.5.mjs` 出 `file:line` 事实(先看 M1:假绿不排掉,后面全是幻觉)。
80
- 2. `pnpm install --no-frozen-lockfile` → `typecheck`(对 checkout)+ `typecheck:ci`(对已发布线)双绿。
81
- 3. `test` + `build` + 仓内 `verify:*` + `pack`。
82
- 4. **真实宿主冒烟**:临时 `DSH_HOME`(`%TEMP%` mkdtemp)+ 目标版 CLI → `dsh plugin --profile web add <tgz>` → `--dump-config` 出现插件行。
83
- 5. 写会话日志的插件追加 **resume 往返**(S3);有 client 半的追加真实浏览器断言(L9)。
84
- 6. 记录:改动面、未命中项、迁移前既有失败、未验证边界、回滚点。
85
-
86
- ## 7. 剩余风险与边界
87
-
88
- - 版本卡会过期:`0.1.5-alpha.1` 之后仍有新跳;本卡只对 `0.1.3-alpha.1 → 0.1.5-alpha.1` 负责。
89
- - 扫描器是启发式:S2/S7/S10 为 warn 级,需人工复核;M1/S3/S8/S9 为 error 级且已在合成夹具 + 真实仓双向验证。
90
- - 未覆盖:真机 L9(浏览器)与 L11(真实模型)在无凭据/无浏览器环境下未执行。
@@ -1,14 +0,0 @@
1
- #!/usr/bin/env node
2
- /**
3
- * Skill-relative scanner entry.
4
- *
5
- * The skill body resolves its relative paths against this skill's own directory
6
- * (the `resourceBase`), so `./scripts/scan-0.1.5.mjs` must exist here as well as
7
- * at the package root. Both are thin wrappers over the single implementation in
8
- * `<package>/lib/scan.mjs`, so the skill, the CLI and the tests share one catalog.
9
- *
10
- * Usage: node ./scripts/scan-0.1.5.mjs --repo <path>
11
- */
12
- import { main } from '../../../lib/scan.mjs'
13
-
14
- process.exit(main(process.argv.slice(2)))