dsh-rewind-plugin 0.4.0 → 0.4.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.md +16 -2
- package/docs/compat-audit.md +137 -0
- package/docs/harness-reference.md +10 -0
- package/docs/release.md +18 -0
- package/docs/troubleshooting.md +24 -0
- package/package.json +33 -27
package/README.md
CHANGED
|
@@ -135,11 +135,25 @@ This plugin only appends rewind-marker events to the session log; it never delet
|
|
|
135
135
|
```sh
|
|
136
136
|
npm install # devDeps from the npm registry
|
|
137
137
|
npm run typecheck # tsc on all three surfaces (host + client + client-test)
|
|
138
|
-
npm test # vitest: rewind / snapshot / hidden / session-cwd / integration
|
|
138
|
+
npm test # vitest: rewind / snapshot / hidden / session-cwd / integration / compat-invariants / compat-interop
|
|
139
139
|
npm run build # esbuild: lib/index.js (host ESM) + lib/client.js (loader closure) + .d.ts
|
|
140
|
-
node scripts/verify-host.mjs # boot the BUILT host artifact end-to-end
|
|
140
|
+
node scripts/verify-host.mjs # boot the BUILT host artifact end-to-end (incl. real /compact after rewind)
|
|
141
141
|
```
|
|
142
142
|
|
|
143
|
+
`npm test` and `verify-host` include the **compatibility probe suites**
|
|
144
|
+
([docs/compat-audit.md](docs/compat-audit.md)): scenario-generated logs drive the
|
|
145
|
+
real harness packages (token-meter, compaction, session-stats/title/goal folds,
|
|
146
|
+
resume preflight) through rewind markers and assert the compatibility
|
|
147
|
+
invariants. A failing probe is a discovered incompatibility, not a mock
|
|
148
|
+
artifact. One finding is recorded: **R-OPENSTEP** — a log carrying an
|
|
149
|
+
unclosed `step/start` (crash leftover) makes any later step activity,
|
|
150
|
+
including a rewind's ghost-step frame, break token-meter replay (and
|
|
151
|
+
/compact). Harness `0.1.1-rc.2` fixes the crash path (`interruptedTurnClosers`
|
|
152
|
+
closes leftover step/turn boundaries on load). A plugin-side guard was tried
|
|
153
|
+
and reverted: it produced false positives on real session logs (rewind
|
|
154
|
+
feature broken), so the plugin deliberately ships no guard — the residual
|
|
155
|
+
risk (runtime-produced unclosed steps) is accepted.
|
|
156
|
+
|
|
143
157
|
`prepare` runs the full build, so git installs and `npm pack` / `npm publish` always produce a complete `lib/` and the `LICENSE`.
|
|
144
158
|
|
|
145
159
|
Maintainers: the module map and harness interface reference live in [docs/harness-reference.md](docs/harness-reference.md); publishing steps in [docs/release.md](docs/release.md).
|
|
@@ -0,0 +1,137 @@
|
|
|
1
|
+
# 兼容性排查记录(compat-audit)
|
|
2
|
+
|
|
3
|
+
> 排查方式:**测试即排查**。`tests/compat-invariants.test.ts`、`tests/compat-interop.test.ts`
|
|
4
|
+
> 与 `scripts/verify-host.mjs` 中的探针,把插件的真实执行路径插入 DSH 各子系统的
|
|
5
|
+
> **真实消费路径**(真实 `@deepseek-ai/*` 包),断言兼容性不变量。探针失败即发现,
|
|
6
|
+
> 进入「修复 / 钉住 / 记录」闭环。
|
|
7
|
+
>
|
|
8
|
+
> 针对版本:npm `@deepseek-ai/*@0.1.1-rc.2`(与 `package-lock.json` 一致);
|
|
9
|
+
> 源码参考:`oss/deepseek-harness` 本地 fork。
|
|
10
|
+
>
|
|
11
|
+
> 版本适配说明:peerDependencies 采用 OR 并集(如 `^0.1.0-rc.6 || ^0.1.1-rc.2`),
|
|
12
|
+
> 覆盖 DSH 已发布的 rc 元组系列。npm 的 prerelease 匹配规则要求候选与范围内比较器
|
|
13
|
+
> **同 `[major, minor, patch]` 元组**,因此 DSH 每次发布新元组(如未来的 `0.1.2-rc.x`、
|
|
14
|
+
> `0.2.x`)时需追加并集项;同元组内 rc 滚动(如 `0.1.1-rc.2 → rc.3`)无需动作。
|
|
15
|
+
> 判断信号:`npm view @deepseek-ai/dsh version`;流程见 `scripts/check-dsh-version.mjs`。
|
|
16
|
+
|
|
17
|
+
## 「完全适配」的可执行定义(不变量)
|
|
18
|
+
|
|
19
|
+
| 不变量 | 含义 | 探针位置 |
|
|
20
|
+
|---|---|---|
|
|
21
|
+
| I1 日志可重放 | rewind 后日志过 token-meter 重放、`Session.create`(resume preflight 同款校验)均不抛 | `compat-invariants` I1、`verify-host` 12/13 |
|
|
22
|
+
| I2 surface 一致 | 切割后 surface 无重复节点、节点存在于日志、被撤目标不再回到 surface、`deriveMessages()` 合法 | `compat-invariants` I2 |
|
|
23
|
+
| I3 step/turn 结构合法 | 客户端 turn-tail 顺序、step/start 唯一、step/end 与 assistant/message 均有配对 step/start、无幽灵 turn | `compat-invariants` I3、`helpers.assertTurnTailOrdering` |
|
|
24
|
+
| I4 折叠服务安全 | stats / title / goal / projection 对含 marker 日志折叠不抛且值可预测 | `compat-invariants` I4 |
|
|
25
|
+
| I5 compact 互操作 | 取消 turn 遗留的 tool-call 被 rewind 遮蔽后配对恢复平衡;跨 checkpoint 的 rewind 明确拒绝;rewind 后 compact 事务合法 | `compat-interop` I5、`verify-host` 12/14 |
|
|
26
|
+
| I6 工具管线正确 | before-快照捕获/提交/恢复正确(既有 `snapshot.test.ts` + `verify-host` 4-8);取消时序不悬挂 | `verify-host` 4-8、15 |
|
|
27
|
+
| I7 客户端顺序合法 | 含工具 turn、rewind marker、幽灵 step 的日志满足客户端 builder 顺序 | `compat-interop` I7 |
|
|
28
|
+
| I8 运行时安全 | rewind/compact 组合不留下悬空 step/turn 帧 | `verify-host` 15 |
|
|
29
|
+
|
|
30
|
+
## 发现的兼容性问题
|
|
31
|
+
|
|
32
|
+
### R-OPENSTEP:日志存在未闭合 step 时,rewind 会破坏 token-meter 重放(**harness 侧问题;插件守卫已尝试并回退**)
|
|
33
|
+
|
|
34
|
+
> **根因(harness 侧)**:崩溃遗留的未闭合 step 会让 token-meter 重放拒绝任何后续
|
|
35
|
+
> step 活动。DSH `0.1.1-rc.2` 已在加载时用 `interruptedTurnClosers`
|
|
36
|
+
> (`dsh-session/repair`)自动闭合崩溃遗留的 step/turn/tool 边界——**崩溃路径已根治**。
|
|
37
|
+
>
|
|
38
|
+
> **插件守卫(已尝试并回退)**:曾实现 `hasOpenStep` + `planRewind` 前置拒绝
|
|
39
|
+
> (`open-step`),但在**真实会话日志上产生误判**(正常回退被拒、GUI 验证功能缺失),
|
|
40
|
+
> 已 revert(`177ec14`)。结论:**插件不设守卫**,接受残余风险(运行中第三方插件
|
|
41
|
+
> 产生未闭合 step 时,rewind 可能破坏 /compact——该日志本身已异常,继续对话同样触发)。
|
|
42
|
+
> 根治方向在 harness(token-meter 对未闭合 step 的恢复),不在插件。
|
|
43
|
+
|
|
44
|
+
#### 未闭合 `step/start` 的具体触发情况(源码确认)
|
|
45
|
+
|
|
46
|
+
全仓**只有一处** append `step/start`:`packages/core/agent-loop/src/agent.ts:279`(官方包内
|
|
47
|
+
无其他生产者;`session/end-seed` 等修复只做 torn-write 截断,不处理逻辑未闭合)。
|
|
48
|
+
|
|
49
|
+
| # | 触发路径 | 现实性 | 依据 |
|
|
50
|
+
|---|---|---|---|
|
|
51
|
+
| P1 | **进程非优雅终止**:`step/start` 经 write-behind 批量落盘(`session-persistence/src/write-behind.ts`,`maxDelayMs` 后写一批)→ step 执行中(LLM 流式/工具,秒级到分钟级)→ SIGKILL / OOM-kill / 断电 / WSL 强关 → `step/end`(在 `finally`,进程活着才执行)未落盘 | **最现实** | `agent.ts:292` finally;write-behind 批量;torn-write 修复只截断写一半的行 |
|
|
52
|
+
| P2 | **第三方插件 bug**:官方包只有 agent-loop 一个生产者,但外部插件可任意 `session.append('step/start', …)` 不闭合 | 可能 | 公开 `Session.append` |
|
|
53
|
+
| P3 | **手工编辑会话文件**:改 `~/.dsh/…/session.jsonl[.zstd]`(zstd 需解压/重压;plaintext 配置可直接改) | 可能但费事 | `persistence-jsonl/format.ts`(`JsonlCompression = 'zstd' \| 'none'`) |
|
|
54
|
+
| P4 | **append 自身故障**:`finally` 里 `append('step/end')` 抛错(payload 是纯数字,几乎不可能) | 理论 | `agent.ts:292` |
|
|
55
|
+
|
|
56
|
+
**放大机制(rewind 不是唯一触发者)**:崩溃后 resume,agent-loop `turn()` 直接
|
|
57
|
+
`phase.turn + 1` 开新 turn(`agent.ts:251-255`),**不闭合遗留 step**——所以「继续对话」
|
|
58
|
+
(新 `step/start`)同样踩中 token-meter 校验。影响范围精确界定:
|
|
59
|
+
|
|
60
|
+
- **对话本身不受影响**(请求路径不调用 `tokenMeter.measure`,全仓仅 compaction-basic 调用);
|
|
61
|
+
- **手动 `/compact` 永久报错**(`compactNow` 首步 `measure()` 抛原始错误);
|
|
62
|
+
- **自动压缩永久静默失效**(`agent/pre-step` 钩子 catch 后仅 warn,对话继续);
|
|
63
|
+
- **rewind 的角色**:若用户先 rewind(而非继续对话),幽灵 step/start 成为第一个踩中者,
|
|
64
|
+
且插件无防御性检测——把「局部异常日志」升级为「用户可感知的 /compact 失效」。
|
|
65
|
+
|
|
66
|
+
### G3(已确认:合理行为,非缺陷):rewind 让 token-meter 的 usage 锚点短暂失效
|
|
67
|
+
|
|
68
|
+
- **机制**:rewind 的 marker 是日志最后一条 `assistant/message` 且无 `usage`,token-meter
|
|
69
|
+
的 `_sync` 重放以它收尾,把 `MeasurementAnchor.baseline` 从 provider 实测 `usage` 覆盖为
|
|
70
|
+
启发式 `estimated`——直到下一条带 usage 的真实消息才恢复(探针验证了完整链条:
|
|
71
|
+
`usage → rewind → estimated → 真实 turn → usage`)。
|
|
72
|
+
- **定性(已确认)**:marker 语义上就是空消息,不携带 usage 是正确的;锚点短暂退回估算
|
|
73
|
+
是该语义的自然结果,且短暂、自愈、不破坏功能。**属于预期行为,不修复**。
|
|
74
|
+
- **探针**:`tests/compat-gaps.test.ts` → `G3`(钉住该行为,防止未来 harness 变更改变它)。
|
|
75
|
+
|
|
76
|
+
## 已验证兼容的面(探针通过)
|
|
77
|
+
|
|
78
|
+
- **token-meter 重放**(含 marker + 幽灵 step 帧 + 多次 rewind + 交错真实 turn + compact 叠加)。
|
|
79
|
+
- **compaction 事务**:`toolPairingBalancedBefore/After` 对 marker 切割后的 surface 恒平衡;
|
|
80
|
+
真实 `/compact` 命令(`command-compact` + `compaction-basic`,stub summarizer)可在 rewind
|
|
81
|
+
marker 之上落地 `compaction/start…end` 并保持可重放;小 surface 时 `/compact` 合法 no-op。
|
|
82
|
+
- **resume 重放**:`Session.create(id, events)` 对含 rewind/compact 的日志重放通过。
|
|
83
|
+
- **session-stats**:ghost step 帧只 +1 step、不新增 phantom turn(复用 turn 号)。
|
|
84
|
+
- **session-title / goal fold**:marker 不干扰 `foldSessionTitle` / `foldGoal`。
|
|
85
|
+
- **客户端顺序**:turn-tail ordering + step/start 唯一性对工具 turn + marker 日志成立。
|
|
86
|
+
- **跨 compact checkpoint 的 rewind**:`RewindError('not-on-surface')` 明确拒绝,不崩溃。
|
|
87
|
+
- **plan-mode**:`hasOpenTurn` 只配对 `turn/start`/`turn/end`,marker 不产生 `turn/start`,
|
|
88
|
+
激活 plan 期间 rewind 无影响(静态审查确认)。
|
|
89
|
+
- **agent-loop 取消**:`finally` 保证 step/turn 闭合,rewind 的 force-stop 路径不悬挂帧。
|
|
90
|
+
|
|
91
|
+
## 已知边界(行为差异,非崩溃,文档化)
|
|
92
|
+
|
|
93
|
+
- **session-stats / session-telemetry 折叠完整日志**:rewind 后统计**不回退**——`turns` /
|
|
94
|
+
`steps` / `llmMs` 仍含被撤内容;telemetry 逐条上报 marker 与幽灵 step 帧(归入被复用
|
|
95
|
+
的旧 turn)。这是「折叠完整日志」的预期语义,探针钉住该行为。
|
|
96
|
+
- **token-meter usage 锚点短暂失效**(G3):rewind 后 baseline 退回启发式 `estimated`,
|
|
97
|
+
下一条真实 usage 调用恢复(探针钉住)。
|
|
98
|
+
- **被撤内容仍可搜索、可导出**:session-query 全文搜索与 `/export` 基于原始日志,
|
|
99
|
+
rewind 只切 surface,被撤消息仍在其中(README 已声明)。
|
|
100
|
+
- **session-title 自动重生成**:标题由 surface 派生,rewind 后自动标题可能变化。
|
|
101
|
+
- **取消 turn 中已写盘但未提交快照的文件**:rewind both 无法恢复(工具副作用时序,
|
|
102
|
+
Claude Code 同限制)。
|
|
103
|
+
- **附件消息被遮蔽后文件残留**:attachment 存储不随 surface 清理(`dsh-attachment-local`
|
|
104
|
+
未装,未自动化验证)。
|
|
105
|
+
|
|
106
|
+
## 未覆盖边界(需要额外端到端层,不阻塞)
|
|
107
|
+
|
|
108
|
+
- 真实 LLM 流式与自动标题生成(L2 stub 化)。
|
|
109
|
+
- 真实 SQLite 索引生命周期(`dsh-session-query-sqlite` 未安装、含原生依赖)。
|
|
110
|
+
- 浏览器端实际渲染 replay(客户端契约已由 `client-contract.test.ts` 覆盖逻辑层)。
|
|
111
|
+
- 真实 JSONL 持久化往返(`dsh-session-persistence-jsonl` 依赖 native `koffi`;往返验证的是
|
|
112
|
+
harness 自身 zstd/JSON 编解码,插件不参与,价值/成本不划算,未安装)。
|
|
113
|
+
- session-reference 的 `SessionReferenceResolver.prepare` 需完整 session-query 服务;其数据
|
|
114
|
+
基础(current-surface 投影)已由 G1 探针(`foldSurface` 转换)覆盖。
|
|
115
|
+
- telemetry 管道(`dsh-session-telemetry-otel`)与附件 provider(`dsh-attachment-local`)。
|
|
116
|
+
- 运行中的 workflow/jobs 被 rewind 取消:工具契约要求 observe `exec.signal` 并 settle
|
|
117
|
+
(`packages/core/tools/src/index.ts`),rewind 触发的是 harness 标准取消,非插件特有——
|
|
118
|
+
静态确认,未实测真实 workflow。
|
|
119
|
+
|
|
120
|
+
## 排查矩阵(子系统 × 不变量)
|
|
121
|
+
|
|
122
|
+
| DSH 子系统 | I1 | I2 | I3 | I4 | I5 | I6 | I7 | I8 |
|
|
123
|
+
|---|:-:|:-:|:-:|:-:|:-:|:-:|:-:|:-:|
|
|
124
|
+
| 会话内核(append/surface/deriveMessages) | ✓ | ✓ | ✓ | — | ✓ | — | ✓ | ✓ |
|
|
125
|
+
| token-meter | ✓ | — | ✓ | — | ✓ | — | — | — |
|
|
126
|
+
| compaction(事务/命令/tool-pairing) | ✓ | — | — | — | ✓ | — | — | ✓ |
|
|
127
|
+
| session-stats / projection | — | — | ✓ | ✓ | — | — | — | — |
|
|
128
|
+
| session-title | — | — | — | ✓ | — | — | — | — |
|
|
129
|
+
| goal | — | — | — | ✓ | — | — | — | — |
|
|
130
|
+
| resume / session-query 重放 | ✓ | — | ✓ | — | — | — | ✓ | — |
|
|
131
|
+
| 工具管线(快照/恢复) | — | — | — | — | — | ✓ | — | ✓ |
|
|
132
|
+
| 客户端顺序 | — | — | ✓ | — | — | — | ✓ | — |
|
|
133
|
+
| plan-mode | — | — | — | — | — | — | — | ✓(静态) |
|
|
134
|
+
|
|
135
|
+
✓ = 探针通过;— = 不适用。R-OPENSTEP 见上(harness 已修、插件不设守卫)。G3 见「已知边界」。
|
|
136
|
+
缺口探针 `tests/compat-gaps.test.ts`:G1 surface 分类(`foldSurface` current/shadowed/log-only)
|
|
137
|
+
与 G2 projection checkpoint 均验证通过;G3 钉住 token-meter baseline 行为差异。
|
|
@@ -12,6 +12,16 @@
|
|
|
12
12
|
- [commands.md](https://github.com/deepseek-ai/deepseek-harness/blob/main/docs/subsystems/commands.md) — command registration (`ctx.commands.register`, `CommandInvocation`, `CommandResult`)
|
|
13
13
|
- [tools.md](https://github.com/deepseek-ai/deepseek-harness/blob/main/docs/subsystems/tools.md) — tool execution seam (`tools/pre-execute` / `tools/post-execute`, `ToolExecution`)
|
|
14
14
|
- [session-query.md](https://github.com/deepseek-ai/deepseek-harness/blob/main/docs/subsystems/session-query.md) — session query / `foldSurface` read-only interfaces
|
|
15
|
+
- [token-meter.md](https://github.com/deepseek-ai/deepseek-harness/blob/main/docs/subsystems/token-meter.md) — replay-aware token meter (`TokenMeter.measure`, surface pricing)
|
|
16
|
+
- [compaction.md](https://github.com/deepseek-ai/deepseek-harness/blob/main/docs/subsystems/compaction.md) — compaction seam / `compaction/*` events / `BasicCompactionEngine` (`summarize()` hook)
|
|
17
|
+
- [session-projection.md](https://github.com/deepseek-ai/deepseek-harness/blob/main/docs/subsystems/session-projection.md) — projection registry (`SessionProjectionRegistry.snapshot/checkpoint`)
|
|
18
|
+
- [session-stats](https://github.com/deepseek-ai/deepseek-harness/blob/main/packages/session/session-stats) — whole-log stats projection (folds ALL events; rewind does not roll back counts)
|
|
19
|
+
- [session-title.md](https://github.com/deepseek-ai/deepseek-harness/blob/main/docs/subsystems/session-title.md) — durable title state (`foldSessionTitle`)
|
|
20
|
+
- [goal.md](https://github.com/deepseek-ai/deepseek-harness/blob/main/docs/subsystems/goal.md) — goal fold (`foldGoal`) and round admission
|
|
21
|
+
|
|
22
|
+
Compatibility probes against these subsystems (test-driven investigation, the
|
|
23
|
+
`compat-invariants` / `compat-interop` vitest suites + the `verify-host` real
|
|
24
|
+
`/compact` chain): [compat-audit.md](compat-audit.md).
|
|
15
25
|
|
|
16
26
|
Also under `docs/` at the repo root: `persistence-catalog.md` (full
|
|
17
27
|
`SessionEventMap`), `tool-catalog.md` (tool inventory), `config-catalog.md`
|
package/docs/release.md
CHANGED
|
@@ -88,3 +88,21 @@ git push origin main --tags # 触发 .github/workflows/publish.yml
|
|
|
88
88
|
**幂等**——已发布的版本会跳过。
|
|
89
89
|
- CI(`.github/workflows/ci.yml`)在每次 push / PR 跑相同检查,外加
|
|
90
90
|
`npm pack --dry-run` 校验 tarball 含 `lib/` 与 `LICENSE`。
|
|
91
|
+
|
|
92
|
+
## DSH 版本适配(peer 范围维护)
|
|
93
|
+
|
|
94
|
+
DSH 仍在 rc 阶段,npm 的 prerelease 匹配规则要求 peer 范围与宿主版本
|
|
95
|
+
**同 `[major, minor, patch]` 元组**才能匹配。因此 peerDependencies 采用
|
|
96
|
+
OR 并集覆盖 DSH 已发布的每个 rc 元组系列(如 `^0.1.0-rc.6 || ^0.1.1-rc.2`),
|
|
97
|
+
并随 DSH 发版追加。
|
|
98
|
+
|
|
99
|
+
- **何时需要更新**:仅当 DSH 发布新元组(`0.1.1 → 0.1.2 → 0.2.x`)时;
|
|
100
|
+
同元组内 rc 滚动(`0.1.1-rc.2 → rc.3`)无需动作。DSH 所有包同版本发布,
|
|
101
|
+
`npm view @deepseek-ai/dsh version` 即权威信号。
|
|
102
|
+
- **自动检测**:`node scripts/check-dsh-version.mjs` 对比 npm 最新版本与
|
|
103
|
+
peer 覆盖的元组,输出是否需追加(exit 0 无需动作,exit 1 需要)。
|
|
104
|
+
- **更新步骤**:给每个 `@deepseek-ai/dsh-*` peer 追加 `|| ^<新元组>-rc.<n>`
|
|
105
|
+
→ devDependencies 同步升到最新 → `npm install` → `npm run typecheck` /
|
|
106
|
+
`npm test` / `npm run verify:host` → 发版。
|
|
107
|
+
- **正式版后收敛**:DSH 发布 final 版本后,正式版不受 prerelease 元组规则
|
|
108
|
+
限制,peer 可收敛为稳定的 `^0.1.x` 单范围,此节即可删除。
|
package/docs/troubleshooting.md
CHANGED
|
@@ -18,3 +18,27 @@ npm exec --yes --package=dsh-rewind-plugin@0.3.3 -- dsh-rewind-repair -- --dry-r
|
|
|
18
18
|
```
|
|
19
19
|
|
|
20
20
|
It only rewrites the marker events' `data.turn` (seqs, order, and zstd frame structure intact) and backs up the original file before writing — safe to run repeatedly. From a source checkout of a pre-v0.4.0 tag: `node scripts/repair-markers.mjs` (identical flags).
|
|
21
|
+
|
|
22
|
+
## Known compatibility boundaries
|
|
23
|
+
|
|
24
|
+
Behavioral notes verified by the compatibility probe suites
|
|
25
|
+
([compat-audit.md](compat-audit.md)) — none of these is a crash:
|
|
26
|
+
|
|
27
|
+
- **Session stats / telemetry do not roll back**: whole-log folds count the
|
|
28
|
+
withdrawn turns, and telemetry records the rewind's marker and ghost-step
|
|
29
|
+
frame under the reused turn. Expected whole-log semantics.
|
|
30
|
+
- **Withdrawn messages stay searchable and exported**: rewind cuts only the
|
|
31
|
+
model-visible surface; full-text search and `/export` still see the raw log.
|
|
32
|
+
- **Session titles may regenerate** after a rewind (title derives from the
|
|
33
|
+
current surface).
|
|
34
|
+
- **Files written by a cancelled tool call** (write happened, no result, no
|
|
35
|
+
snapshot commit) cannot be restored by "conversation and code".
|
|
36
|
+
|
|
37
|
+
**R-OPENSTEP** (harness-side, plugin does not guard): a session log carrying
|
|
38
|
+
an *unclosed* `step/start` (a crash before the agent loop's `finally` closed
|
|
39
|
+
the step) makes any later step activity break token-meter replay (and
|
|
40
|
+
`/compact`). Harness `0.1.1-rc.2` fixes the crash path on load
|
|
41
|
+
(`interruptedTurnClosers` closes leftover step/turn boundaries). A plugin-side
|
|
42
|
+
up-front rejection was implemented and **reverted** (false positives broke the
|
|
43
|
+
rewind feature on real session logs, `177ec14`); the residual runtime-produced
|
|
44
|
+
risk is accepted. Tracked in the compat-audit.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "dsh-rewind-plugin",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.1",
|
|
4
4
|
"description": "DeepSeek Harness plugin: in-place conversation rewind in the same session window (Claude Code /rewind semantics) with optional workspace file restore",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"deepseek-harness",
|
|
@@ -69,17 +69,17 @@
|
|
|
69
69
|
},
|
|
70
70
|
"peerDependencies": {
|
|
71
71
|
"@deepseek-ai/cordis": "^4.0.1",
|
|
72
|
-
"@deepseek-ai/dsh-client-locale": "^0.1.0-rc.6",
|
|
73
|
-
"@deepseek-ai/dsh-client-runtime": "^0.1.0-rc.6",
|
|
74
|
-
"@deepseek-ai/dsh-client-ui-commands": "^0.1.0-rc.6",
|
|
75
|
-
"@deepseek-ai/dsh-client-ui-slots": "^0.1.0-rc.6",
|
|
76
|
-
"@deepseek-ai/dsh-commands": "^0.1.0-rc.6",
|
|
77
|
-
"@deepseek-ai/dsh-fs": "^0.1.0-rc.6",
|
|
78
|
-
"@deepseek-ai/dsh-llm": "^0.1.0-rc.6",
|
|
79
|
-
"@deepseek-ai/dsh-sandbox": "^0.1.0-rc.6",
|
|
80
|
-
"@deepseek-ai/dsh-session": "^0.1.0-rc.6",
|
|
81
|
-
"@deepseek-ai/dsh-settings": "^0.1.0-rc.8",
|
|
82
|
-
"@deepseek-ai/dsh-tools": "^0.1.0-rc.6"
|
|
72
|
+
"@deepseek-ai/dsh-client-locale": "^0.1.0-rc.6 || ^0.1.1-rc.2",
|
|
73
|
+
"@deepseek-ai/dsh-client-runtime": "^0.1.0-rc.6 || ^0.1.1-rc.2",
|
|
74
|
+
"@deepseek-ai/dsh-client-ui-commands": "^0.1.0-rc.6 || ^0.1.1-rc.2",
|
|
75
|
+
"@deepseek-ai/dsh-client-ui-slots": "^0.1.0-rc.6 || ^0.1.1-rc.2",
|
|
76
|
+
"@deepseek-ai/dsh-commands": "^0.1.0-rc.6 || ^0.1.1-rc.2",
|
|
77
|
+
"@deepseek-ai/dsh-fs": "^0.1.0-rc.6 || ^0.1.1-rc.2",
|
|
78
|
+
"@deepseek-ai/dsh-llm": "^0.1.0-rc.6 || ^0.1.1-rc.2",
|
|
79
|
+
"@deepseek-ai/dsh-sandbox": "^0.1.0-rc.6 || ^0.1.1-rc.2",
|
|
80
|
+
"@deepseek-ai/dsh-session": "^0.1.0-rc.6 || ^0.1.1-rc.2",
|
|
81
|
+
"@deepseek-ai/dsh-settings": "^0.1.0-rc.8 || ^0.1.1-rc.2",
|
|
82
|
+
"@deepseek-ai/dsh-tools": "^0.1.0-rc.6 || ^0.1.1-rc.2"
|
|
83
83
|
},
|
|
84
84
|
"peerDependenciesMeta": {
|
|
85
85
|
"@deepseek-ai/cordis": {
|
|
@@ -121,21 +121,27 @@
|
|
|
121
121
|
},
|
|
122
122
|
"devDependencies": {
|
|
123
123
|
"@deepseek-ai/cordis": "^4.0.1",
|
|
124
|
-
"@deepseek-ai/dsh-agent": "^0.1.
|
|
125
|
-
"@deepseek-ai/dsh-client-locale": "^0.1.
|
|
126
|
-
"@deepseek-ai/dsh-client-runtime": "^0.1.
|
|
127
|
-
"@deepseek-ai/dsh-client-ui-commands": "^0.1.
|
|
128
|
-
"@deepseek-ai/dsh-client-ui-input-trigger": "^0.1.
|
|
129
|
-
"@deepseek-ai/dsh-client-ui-slots": "^0.1.
|
|
130
|
-
"@deepseek-ai/dsh-
|
|
131
|
-
"@deepseek-ai/dsh-
|
|
132
|
-
"@deepseek-ai/dsh-
|
|
133
|
-
"@deepseek-ai/dsh-
|
|
134
|
-
"@deepseek-ai/dsh-
|
|
135
|
-
"@deepseek-ai/dsh-
|
|
136
|
-
"@deepseek-ai/dsh-
|
|
137
|
-
"@deepseek-ai/dsh-
|
|
138
|
-
"@deepseek-ai/dsh-
|
|
124
|
+
"@deepseek-ai/dsh-agent": "^0.1.1-rc.2",
|
|
125
|
+
"@deepseek-ai/dsh-client-locale": "^0.1.1-rc.2",
|
|
126
|
+
"@deepseek-ai/dsh-client-runtime": "^0.1.1-rc.2",
|
|
127
|
+
"@deepseek-ai/dsh-client-ui-commands": "^0.1.1-rc.2",
|
|
128
|
+
"@deepseek-ai/dsh-client-ui-input-trigger": "^0.1.1-rc.2",
|
|
129
|
+
"@deepseek-ai/dsh-client-ui-slots": "^0.1.1-rc.2",
|
|
130
|
+
"@deepseek-ai/dsh-command-compact": "^0.1.1-rc.2",
|
|
131
|
+
"@deepseek-ai/dsh-commands": "^0.1.1-rc.2",
|
|
132
|
+
"@deepseek-ai/dsh-compaction": "^0.1.1-rc.2",
|
|
133
|
+
"@deepseek-ai/dsh-compaction-basic": "^0.1.1-rc.2",
|
|
134
|
+
"@deepseek-ai/dsh-fs": "^0.1.1-rc.2",
|
|
135
|
+
"@deepseek-ai/dsh-goal": "^0.1.1-rc.2",
|
|
136
|
+
"@deepseek-ai/dsh-llm": "^0.1.1-rc.2",
|
|
137
|
+
"@deepseek-ai/dsh-sandbox": "^0.1.1-rc.2",
|
|
138
|
+
"@deepseek-ai/dsh-session": "^0.1.1-rc.2",
|
|
139
|
+
"@deepseek-ai/dsh-session-projection": "^0.1.1-rc.2",
|
|
140
|
+
"@deepseek-ai/dsh-session-stats": "^0.1.1-rc.2",
|
|
141
|
+
"@deepseek-ai/dsh-session-title": "^0.1.1-rc.2",
|
|
142
|
+
"@deepseek-ai/dsh-settings": "^0.1.1-rc.2",
|
|
143
|
+
"@deepseek-ai/dsh-token-meter": "^0.1.1-rc.2",
|
|
144
|
+
"@deepseek-ai/dsh-tools": "^0.1.1-rc.2",
|
|
139
145
|
"@types/node": "^24.0.0",
|
|
140
146
|
"@types/react": "^18.3.31",
|
|
141
147
|
"@types/react-dom": "^18.3.7",
|