dsh-session-superagent 0.9.140 → 0.9.141

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/CHANGELOG.md CHANGED
@@ -2,6 +2,32 @@
2
2
 
3
3
  格式参照 [Keep a Changelog](https://keepachangelog.com/zh-CN/1.1.0/),版本号遵循 [语义化版本](https://semver.org/lang/zh-CN/)。
4
4
 
5
+ ## [0.9.141] - 2026-11-03 —— 给"截图骗人"装上自动门禁
6
+
7
+ ### 为什么
8
+ 0.9.140 的教训:诊断页看着空,查了半天样式,结果是**预览快照没写 `triageSignals`**。
9
+ 这种问题肉眼才能发现,而且极易被误判成 UI 缺陷。
10
+
11
+ ### 改法
12
+ 1. 预览快照补齐 client.js 读的全部 16 个 `body.*` 字段(此前只有 6 个):
13
+ `serverVersion / runningVersion / installedVersion / routeBase / defaults / retryPolicy /
14
+ sessionUsage / tokenScopes / isolation / error`;
15
+ 2. 新增 `test/preview-contract.test.mjs` 两条断言:
16
+ - 顶层字段:`client.js 里出现的每一个 body.X` 都必须在快照里有同名键;
17
+ - 嵌套字段:`isolation.roots[].{count,bytes}`、`isolation.totalBytes`、`sessionUsage.{used,cap,capped}`、
18
+ `defaults.*`、`retryPolicy.*` 必须出现。
19
+
20
+ ### 顺手抓到自己的错
21
+ 我第一版快照写的是 `isolation.roots[].sizeBytes`,而服务端与客户端用的是 **`bytes` / `totalBytes`**,
22
+ 出图显示「2 个 · **0 B**」。字段名一错,界面就是一行错数据 —— 正是这条门禁要防的东西。
23
+ 改正后出图:`2 个 · 256.0 KB(合计 256.0 KB)`。
24
+
25
+ ### 证据
26
+ ```
27
+ node --test → 254/254(新增 2 例)
28
+ out: 设置(来源)出图,隔离占用 256.0 KB 显示正确
29
+ ```
30
+
5
31
  ## [0.9.140] - 2026-11-03 —— 诊断页出图核对:把客户能读到的「N」换成具体说法
6
32
 
7
33
  ### 现场(出图)
package/README.md CHANGED
@@ -3,7 +3,7 @@
3
3
  <img src="assets/icon-180.png" width="88" height="88" alt="">
4
4
 
5
5
  [![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](LICENSE)
6
- [![Version](https://img.shields.io/badge/version-0.9.140-green.svg)](https://github.com/MYCF711/dsh-session-superagent/releases)
6
+ [![Version](https://img.shields.io/badge/version-0.9.141-green.svg)](https://github.com/MYCF711/dsh-session-superagent/releases)
7
7
  [![npm](https://img.shields.io/npm/v/dsh-session-superagent.svg)](https://www.npmjs.com/package/dsh-session-superagent)
8
8
  [![dsh](https://img.shields.io/badge/DeepSeek%20Harness-plugin-orange.svg)](https://github.com/topics/dsh-plugin)
9
9
 
@@ -123,7 +123,7 @@ dsh plugin install /path/to/dsh-session-superagent
123
123
  ## 开发
124
124
 
125
125
  ```sh
126
- node --test # 252 项单测
126
+ node --test # 254 项单测
127
127
  ```
128
128
 
129
129
  ### 工具输出:文本给人和 agent,JSON 给程序
package/client.js CHANGED
@@ -14,7 +14,7 @@ window.__ModuleLoader__.load({
14
14
  const { useCallback, useEffect, useRef, useState } = React
15
15
 
16
16
  // 客户端版本探针:每次模块加载写一次,用来确认浏览器里跑的是哪一版
17
- const CLIENT_VERSION = '0.9.140'
17
+ const CLIENT_VERSION = '0.9.141'
18
18
  let BASE = '/session-superagent'
19
19
  /**
20
20
  * 挑「最新的那个服务端实例」。
package/lib/index.js CHANGED
@@ -40,7 +40,7 @@ import {
40
40
 
41
41
  export const name = 'dsh-session-superagent'
42
42
  /** 服务端版本:随 package.json 同步(meta 测试守着)。客户端据此挑「最新的那个实例」。 */
43
- export const SERVER_VERSION = '0.9.140'
43
+ export const SERVER_VERSION = '0.9.141'
44
44
  export const inject = ['tools', 'agents', 'webServer']
45
45
  /** 一条会话每小时最多被唤醒几次(跨所有守累计)。单守上限挡不住多守叠加。 */
46
46
  // 本进程启动时刻:用来区分「刚重启还没轮到」与「定时器真的丢了」
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "dsh-session-superagent",
3
- "version": "0.9.140",
3
+ "version": "0.9.141",
4
4
  "description": "Session-level superagent for DeepSeek Harness: watch a GitHub repository and wake a session when something needs doing. Credentials never reach the model.",
5
5
  "type": "module",
6
6
  "main": "lib/index.js",