@feng0531/dsh-execution-bus 0.2.8 → 0.2.9

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 CHANGED
@@ -4,7 +4,7 @@
4
4
 
5
5
  “萧何”是产品与模式显示名,执行总线是其技术功能;不新增人物 Agent,不进行角色扮演。仓库 dsh-execution-bus、npm 包名、execution_bus 工具名及 execution-bus-test 预设 ID 保持不变。历史版本发布说明保留当时名称。
6
6
 
7
- DSH 独立插件:`@feng0531/dsh-execution-bus` · 当前版本 **0.2.8**
7
+ DSH 独立插件:`@feng0531/dsh-execution-bus` · 当前版本 **0.2.9**
8
8
 
9
9
  > 当前是早期可运行版本,不是完整生产验收版。已验证真实 DSH 组件和脚本模型驱动的内存会话;真实模型、桌面界面和 PTC 完整链路尚未验收。**不支持重启后恢复任务。**
10
10
 
@@ -102,7 +102,7 @@ flowchart TD
102
102
  2. 在你选定的隔离 DSH 配置依赖目录安装固定版本,不要在 DSH 程序安装目录执行:
103
103
 
104
104
  ```powershell
105
- npm install --ignore-scripts @feng0531/dsh-execution-bus@0.2.8
105
+ npm install --ignore-scripts @feng0531/dsh-execution-bus@0.2.9
106
106
  ```
107
107
 
108
108
  这是 npm 目录示例。若目标配置使用 pnpm,应沿用其包管理器,不混用锁文件。遇到宿主 peer 版本冲突就停止,不用强制安装绕过。
@@ -231,7 +231,7 @@ npm run test:install # 临时目录安装,不操作日常 DSH
231
231
 
232
232
  - [协议和投递语义](<docs/protocol.md>):字段、状态、重复处理与取消规则。
233
233
  - [宿主兼容性与源码调用链](<docs/host-compatibility.md>):为什么可以等待,为什么不能跨重启恢复。
234
- - [验证记录](<docs/validation.md>)、[0.2.8 发布说明](<docs/releases/0.2.8.md>):已验证与未验证范围。
234
+ - [验证记录](<docs/validation.md>)、[0.2.9 发布说明](<docs/releases/0.2.9.md>):已验证与未验证范围。
235
235
  - [维护者发布流程](<docs/RELEASING.md>):标签 CI、安装包校验与正式发布门禁。
236
236
 
237
237
  ## 许可
package/dist/plugin.js CHANGED
@@ -108,12 +108,24 @@ export function apply(ctx) {
108
108
  const ownerId = exec.agent.id;
109
109
  // One registered host waiter suppresses extra completion messages for every attachment.
110
110
  settled = (async () => {
111
- for (;;) {
112
- const view = await ctx.jobs.wait(job, 60000, ownerId);
113
- if (view.status !== "running" && view.status !== "stopping")
114
- break;
111
+ try {
112
+ for (;;) {
113
+ const view = await ctx.jobs.wait(job, 60000, ownerId);
114
+ if (view.status !== "running" && view.status !== "stopping")
115
+ break;
116
+ }
117
+ ctx.jobs.remove(job, ownerId);
118
+ }
119
+ catch (error) {
120
+ // rc.2 has no typed not-found code. Match only this minted Job and
121
+ // confirm absence in the original owner scope; never swallow access/service errors.
122
+ if (!(error instanceof Error) ||
123
+ error.message !== `unknown job ${job}` ||
124
+ ctx.jobs.list(ownerId).some((view) => view.id === job))
125
+ throw error;
126
+ // Record cleanup is not execution completion. Drain the original result.
127
+ await attached.done;
115
128
  }
116
- ctx.jobs.remove(job, ownerId);
117
129
  })();
118
130
  sharedJobs.set(jobKey, settled);
119
131
  void settled.then(() => sharedJobs.delete(jobKey), () => sharedJobs.delete(jobKey));
@@ -0,0 +1,13 @@
1
+ # 萧何 / Xiao He 0.2.9
2
+
3
+ ## BUG 修复
4
+
5
+ 修复终态 Job 被其他合法订阅者先行移除时,原工具调用错误返回 unknown job、无法交付已有执行结果的问题。等待及清理路径仅对当前调用创建的确切 Job 未找到错误、且同一 owner 查询确认已不存在时做幂等处理;继续等待原执行结果,不把记录移除当作成功。权限及其他服务异常仍明确失败,不一概吞掉。
6
+
7
+ 宿主 0.2.0-rc.2 未提供类型化 not-found 错误码,因此此兼容处理限定精确错误消息与已创建 Job 身份,不能推广为所有宿主版本的错误协议。
8
+
9
+ ## 验证与边界
10
+
11
+ 新增真实 Cordis/ToolRuntime/LocalJobs 回归,覆盖先行清理不覆盖成功及失败结果、交付标记更新、清理服务异常仍报错。缺陷用例修复前失败。全量与标签四矩阵 CI、包校验及生产隔离安装按既有发布门禁执行。
12
+
13
+ DSH 0.2.0-rc.2,非商业源码公开许可。真实模型、GUI 和 PTC 完整链路未验收,不支持跨重启恢复;发布不自动安装或重启 DSH。
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@feng0531/dsh-execution-bus",
3
- "version": "0.2.8",
3
+ "version": "0.2.9",
4
4
  "type": "module",
5
5
  "private": false,
6
6
  "license": "SEE LICENSE IN LICENSE",