dsh-auth-remote 0.3.1 → 0.3.2

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 (59) hide show
  1. package/CHANGELOG.md +12 -1
  2. package/CHANGELOG.zh-CN.md +12 -1
  3. package/CONTRIBUTING.md +1 -1
  4. package/CONTRIBUTING.zh-CN.md +1 -1
  5. package/README.md +26 -18
  6. package/README.zh-CN.md +26 -18
  7. package/dist/cli.js +63 -530
  8. package/dist/cli.js.map +4 -4
  9. package/dist/client.js +915 -133
  10. package/dist/client.js.map +3 -3
  11. package/dist/index.js +83 -22
  12. package/dist/index.js.map +3 -3
  13. package/dist/login.css +0 -21
  14. package/dist/login.css.map +2 -2
  15. package/dist/login.js +892 -155
  16. package/dist/login.js.map +3 -3
  17. package/dist/types/adapters/dsh/browser-capability.d.ts.map +1 -1
  18. package/dist/types/adapters/dsh/liveshare.d.ts +4 -0
  19. package/dist/types/adapters/dsh/liveshare.d.ts.map +1 -0
  20. package/dist/types/adapters/dsh/webserver.d.ts +8 -4
  21. package/dist/types/adapters/dsh/webserver.d.ts.map +1 -1
  22. package/dist/types/cli/ipc-client.d.ts.map +1 -1
  23. package/dist/types/cli/messages.d.ts +56 -0
  24. package/dist/types/cli/messages.d.ts.map +1 -0
  25. package/dist/types/cli/profile.d.ts.map +1 -1
  26. package/dist/types/cli/prompt.d.ts.map +1 -1
  27. package/dist/types/index.d.ts.map +1 -1
  28. package/dist/types/shared/i18n.d.ts +878 -105
  29. package/dist/types/shared/i18n.d.ts.map +1 -1
  30. package/dist/types/shared/locales/de.d.ts +145 -0
  31. package/dist/types/shared/locales/de.d.ts.map +1 -0
  32. package/dist/types/shared/locales/en.d.ts +0 -49
  33. package/dist/types/shared/locales/en.d.ts.map +1 -1
  34. package/dist/types/shared/locales/es.d.ts +145 -0
  35. package/dist/types/shared/locales/es.d.ts.map +1 -0
  36. package/dist/types/shared/locales/fr.d.ts +145 -0
  37. package/dist/types/shared/locales/fr.d.ts.map +1 -0
  38. package/dist/types/shared/locales/ja.d.ts +145 -0
  39. package/dist/types/shared/locales/ja.d.ts.map +1 -0
  40. package/dist/types/shared/locales/pt.d.ts +145 -0
  41. package/dist/types/shared/locales/pt.d.ts.map +1 -0
  42. package/dist/types/shared/locales/ru.d.ts +145 -0
  43. package/dist/types/shared/locales/ru.d.ts.map +1 -0
  44. package/dist/types/shared/locales/zh.d.ts +0 -49
  45. package/dist/types/shared/locales/zh.d.ts.map +1 -1
  46. package/docs/deployment.md +19 -13
  47. package/docs/deployment.zh-CN.md +19 -13
  48. package/docs/development.md +39 -28
  49. package/docs/development.zh-CN.md +39 -28
  50. package/docs/legacy-compatibility.md +119 -67
  51. package/docs/legacy-compatibility.zh-CN.md +117 -65
  52. package/docs/releasing.md +11 -11
  53. package/docs/releasing.zh-CN.md +11 -11
  54. package/docs/support-history.md +49 -48
  55. package/docs/support-history.zh-CN.md +49 -48
  56. package/examples/web-profile-auth-remote.patch.yml +1 -1
  57. package/package.json +15 -14
  58. package/dist/types/cli/language.d.ts +0 -14
  59. package/dist/types/cli/language.d.ts.map +0 -1
@@ -2,17 +2,19 @@
2
2
 
3
3
  [简体中文](deployment.zh-CN.md)
4
4
 
5
- This guide targets unpublished plugin candidate `0.3.1` with recommended DSH `0.2.1-rc.4` and default `~/.dsh` data directory. See [README](../README.md#dsh-compatibility) for seven-version support/dates, [history](support-history.md#by-dsh) for old pairs and distribution, and [development](development.md) for source builds.
5
+ This guide targets unpublished plugin candidate `0.3.2` with recommended DSH `0.2.2-alpha.2` and default `~/.dsh` data directory. See [README](../README.md#dsh-compatibility) for eight-version support/dates, [history](support-history.md#by-dsh) for old pairs and distribution, and [development](development.md) for source builds.
6
6
 
7
- The native capabilities below apply to `0.2.1-alpha.3`, `0.2.1-alpha.4`, `0.2.1-alpha.5`, `0.2.1-rc.1`, `0.2.1-rc.2`, `0.2.1-rc.3` and `0.2.1-rc.4`.
7
+ The native capabilities below apply to `0.2.1-alpha.3`, `0.2.1-alpha.4`, `0.2.1-alpha.5`, `0.2.1-rc.1`, `0.2.1-rc.2`, `0.2.1-rc.3`, `0.2.1-rc.4` and `0.2.2-alpha.2`.
8
8
 
9
- ## Minimal installation from npm
9
+ Upstream DSH `0.2.2-alpha.2` itself requires Node `>=24.9.0`; the plugin still declares Node `>=24` and adds no minor-version gate.
10
10
 
11
- `0.3.1` is unpublished. Run the npm installation below only after its [exact distribution record](support-history.md#plugin-0.3.1) confirms publication; during preparation replace the package name with a verified local `./artifacts/dsh-auth-remote-0.3.1.tgz` path. Use the same default `web` profile:
11
+ ## Minimal installation of the candidate archive
12
+
13
+ `0.3.2` is unpublished. Build and verify a local archive using the [development guide](development.md), then install that file. Published `0.3.1` retains its seven-host history and does not include this new-host adaptation; see the [exact distribution record](support-history.md#plugin-0.3.1). Use the same default `web` profile:
12
14
 
13
15
  ```sh
14
16
  dsh --version
15
- dsh plugin --profile web add dsh-auth-remote@0.3.1
17
+ dsh plugin --profile web add ./artifacts/dsh-auth-remote-0.3.2.tgz
16
18
  dsh plugin --profile web list
17
19
  dsh web --no-open --port 13090
18
20
  ```
@@ -21,7 +23,7 @@ Verify the selected DSH version and plugin list. No profile patch is needed for
21
23
 
22
24
  ```sh
23
25
  curl -fsS http://127.0.0.1:13090/auth-remote/ready
24
- dsh plugin --profile web exec dsh-auth-remote init --lang en
26
+ dsh plugin --profile web exec dsh-auth-remote init
25
27
  ```
26
28
 
27
29
  Open the printed root `http://127.0.0.1:13090/`. Anonymous navigation redirects to sign-in; anonymous business APIs are denied. The bundle suppresses native token URLs and automatic browser opening. Keep development and test homes separate from this account profile.
@@ -60,7 +62,7 @@ All plugin fields below belong directly in `auth-remote.config`; there are no al
60
62
  | `port` | CLI `--port`, then file, then `3080`, independently of host. `0` derives the entry only after the actual nonzero port is bound. |
61
63
  | `tlsCert`, `tlsKey` | Supply both file fields or both CLI `--tls-cert`/`--tls-key`; CLI replaces the entire pair, without mixed sources or reading unused file paths. Omit for HTTP. |
62
64
  | `requireTotp` | Defaults to `false`. An unbound account may skip setup; an already bound account still needs its second factor. Set `true` to require TOTP enrollment before access. Explicit true/false settings, existing bindings and backup codes survive upgrades. |
63
- | `manualAccountLogin` | Defaults true. Native Settings writes the profile override; accepted saves immediately affect new authorizations and survive restart without restarting authentication. False preserves admitted attempts and official credentials. All seven have complete regression targets; see README for future admission/APIs. |
65
+ | `manualAccountLogin` | Defaults true. Native Settings writes the profile override; accepted saves immediately affect new authorizations and survive restart without restarting authentication. False preserves admitted attempts and official credentials. All eight have complete regression targets; see README for future admission/APIs. |
64
66
  | `sessionHours` | Fixed default lifetime of 168 hours. Reducing it tightens existing sessions; increasing it does not revive expired sessions. |
65
67
  | `preserveOriginPaths` | Optional canonical segment-prefix paths; default `[]`. Matching routes keep the validated public Host and existing Origin after authentication. The final public origin configures native Connection trust automatically. |
66
68
 
@@ -77,13 +79,13 @@ dsh web --no-open --tls-cert ./tls/dsh.crt --tls-key ./tls/dsh.key
77
79
 
78
80
  Supplying only one CLI flag fails even if the file contains the other half. Missing, unreadable, empty, malformed or mismatched certificate/key material fails startup without an HTTP fallback, and releases listener/admin/storage resources. Choose a certificate valid for the browser hostname; the plugin delegates TLS to the official listener.
79
81
 
80
- All supported versions natively provide `--public-url`, IPv6 and TLS; this candidate removes the older missing-option and unsupported-transport branches.
82
+ All supported versions natively provide `--public-url`, IPv6 and TLS; this candidate retains the native API migration completed in `0.3.1`.
81
83
 
82
- All seven project the final Web URL through model runtime context and `DSH_WEB_URL`; tests still scan all Web sections for duplicate URLs or tokens.
84
+ All eight project the final Web URL through model runtime context and `DSH_WEB_URL`; tests still scan all Web sections for duplicate URLs or tokens.
83
85
 
84
86
  ## Native HTTPS and IPv6
85
87
 
86
- All seven supported versions can use this complete auth row for IPv6 loopback HTTPS with your own certificate/key:
88
+ All eight supported versions can use this complete auth row for IPv6 loopback HTTPS with your own certificate/key:
87
89
 
88
90
  ```yaml
89
91
  - id: auth-remote
@@ -124,7 +126,7 @@ Anonymous GET/HEAD requests to exactly `/manifest.webmanifest`, `/favicon.svg`,
124
126
 
125
127
  Plugin cookies follow the validated external origin and are host-only, HttpOnly and SameSite; HTTPS sets Secure. Native bridge credentials stay server-side and follow the native listener protocol, including HTTPS cookie audience/Secure when a public HTTP proxy fronts native HTTPS. Ports do not isolate browser cookies.
126
128
 
127
- Standard `/api` routes work with `preserveOriginPaths: []`; there is no need to list `/api`. The plugin always declares its finalized native bridge authority in Connection's `trustedHosts`, using the actual bound port (including `--port 0`), so downstream plugins that read this list can recognize the bridge without an extra trusted-host flag. Explicit CLI trusted hosts are merged and deduplicated; they do not expand the outer public-origin policy. Add a prefix only when a downstream route needs the original public Host. The plugin forwards an Origin only when the request supplied one, and preflights and declares the selected public authority for preserved paths. No separate Connection row is needed. Ordinary routes on all seven use the normalized native bind authority and require a full session. Revocation, Connection loss or storage failure closes active uploads, streams and upgrades and withdraws business admission. Readiness does not mean the account is initialized.
129
+ Standard `/api` routes work with `preserveOriginPaths: []`; there is no need to list `/api`. The plugin always declares its finalized native bridge authority in Connection's `trustedHosts`, using the actual bound port (including `--port 0`), so downstream plugins that read this list can recognize the bridge without an extra trusted-host flag. Explicit CLI trusted hosts are merged and deduplicated; they do not expand the outer public-origin policy. Add a prefix only when a downstream route needs the original public Host. The plugin forwards an Origin only when the request supplied one, and preflights and declares the selected public authority for preserved paths. No separate Connection row is needed. Ordinary routes on all eight use the normalized native bind authority and require a full session. Revocation, Connection loss or storage failure closes active uploads, streams and upgrades and withdraws business admission. Readiness does not mean the account is initialized.
128
130
 
129
131
  ## Start and verify the public entry
130
132
 
@@ -137,7 +139,9 @@ Startup prints the actual protocol/address/port and one distinct public root, de
137
139
 
138
140
  ## Backup, recovery and changes
139
141
 
140
- Before upgrading an old deployment to `0.3.1`, stop DSH and back up the authentication directory, profile patch and package/lock files. Keep access private and retain independent `webserver disabled: true`. Upgrade DSH to a listed target first (recommended `0.2.1-rc.4`), then install the plugin and verify readiness, anonymous denial, login and revocation. The six retired hosts cannot install `0.3.1`; do not grant a version-risk exemption. To roll back, stop the service, select an explicit old host (for example `0.2.1-alpha.2`) with last supported plugin `0.2.0`, and restore matching package/lock/patch backups. This migration does not change authentication data format; still check schema when restoring and never overwrite live state.
142
+ Before upgrading an old deployment to `0.3.2`, stop DSH and back up the authentication directory, profile patch and package/lock files. Keep access private and retain independent `webserver disabled: true`. Upgrade DSH to a listed target first (recommended `0.2.2-alpha.2`), then install the plugin and verify readiness, anonymous denial, login and revocation. The six retired hosts cannot install `0.3.2`; do not grant a version-risk exemption. To roll back, stop the service, select an explicit old host (for example `0.2.1-alpha.2`) with last supported plugin `0.2.0`, and restore matching package/lock/patch backups. The six-host retirement happened in published `0.3.1` and is not repeated here. This migration does not change authentication data format; still check schema when restoring and never overwrite live state.
143
+
144
+ These are plugin `0.3.2` behavior changes, independent of DSH retirement: CLI text is fixed English, so remove `--lang` from scripts; JSON fields are unchanged. The standalone login page has no language selector and uses new `dsh-auth-remote-lang` memory, then `navigator.language`, then English. Old `dsh-auth-remote.locale` is ignored, retained and not migrated. Entering DSH remembers only native accepted preferences; signing out keeps them. The eight plugin languages do not expand old DSH native language catalogs.
141
145
 
142
146
  Stop DSH and verify it released the profile lock before copying `~/.dsh/profiles/web/auth-remote/auth-state.json`. Keep the copy in a private directory (0700) with file mode 0600. It contains password hashes, the TOTP secret, backup-code hashes and sessions. Do not copy an in-progress temporary file, overwrite live locked state or commit it. Back up the corresponding profile patch and package/lock files.
143
147
 
@@ -145,4 +149,6 @@ For recovery, stop DSH, check schema/package compatibility, restore with private
145
149
 
146
150
  To change the external entry, replace the one `publicUrl`, update the proxy and restart DSH. Verify the new entry and rejection of the former non-loopback entry, including cookies, redirects, uploads and long connections. Do not temporarily configure both origins in this plugin.
147
151
 
148
- Official DeepSeek authorization on all seven uses the [README manual callback dialog](../README.md#sign-in-to-an-official-deepseek-account). No callback listener or open loopback port is needed on the browser computer. `/auth-remote/account/*` retains the session/origin gate and same-origin JSON POSTs; direct HTTP access to native `/oauth/callback` cannot complete this handoff. No proxy exception, broader paths or cross-site allowance is required.
152
+ Official DeepSeek authorization on all eight uses the [README manual callback dialog](../README.md#sign-in-to-an-official-deepseek-account). No callback listener or open loopback port is needed on the browser computer. `/auth-remote/account/*` retains the session/origin gate and same-origin JSON POSTs; direct HTTP access to native `/oauth/callback` cannot complete this handoff. No proxy exception, broader paths or cross-site allowance is required.
153
+
154
+ Before using LiveShare on DSH `0.2.2-alpha.2`, enable it, configure Relay and sign in as Owner through native DSH setup. This plugin does not enable sharing or rewrite Relay configuration. Viewers receive no administrator identity; plugin sign-out and stopping a share are independent operations. Local protocol stand-ins establish basic compatibility; real Relay/OAuth, visitor models and file-write experience require separate verification. No broader anonymous exception or preserveOriginPaths setting is required.
@@ -2,17 +2,19 @@
2
2
 
3
3
  [English](deployment.md)
4
4
 
5
- 本指南面向未发布插件候选 `0.3.1` 与推荐 DSH `0.2.1-rc.4`,使用默认 `~/.dsh` 数据目录。七版支持/日期见 [README](../README.zh-CN.md#dsh-兼容性),旧组合与分发事实见[历史](support-history.zh-CN.md#by-dsh)。源码构建见[开发指南](development.zh-CN.md)。
5
+ 本指南面向未发布插件候选 `0.3.2` 与推荐 DSH `0.2.2-alpha.2`,使用默认 `~/.dsh` 数据目录。八版支持/日期见 [README](../README.zh-CN.md#dsh-兼容性),旧组合与分发事实见[历史](support-history.zh-CN.md#by-dsh)。源码构建见[开发指南](development.zh-CN.md)。
6
6
 
7
- 下列原生能力适用于 `0.2.1-alpha.3`、`0.2.1-alpha.4`、`0.2.1-alpha.5`、`0.2.1-rc.1`、`0.2.1-rc.2`、`0.2.1-rc.3`、`0.2.1-rc.4`。
7
+ 下列原生能力适用于 `0.2.1-alpha.3`、`0.2.1-alpha.4`、`0.2.1-alpha.5`、`0.2.1-rc.1`、`0.2.1-rc.2`、`0.2.1-rc.3`、`0.2.1-rc.4`、`0.2.2-alpha.2`。
8
8
 
9
- ## 从 npm 最小化安装
9
+ 上游 DSH `0.2.2-alpha.2` 自身要求 Node `>=24.9.0`;插件仍声明 Node `>=24`,不增加小版本拦截。
10
10
 
11
- `0.3.1` 尚未发布;只有[精确分发记录](support-history.zh-CN.md#plugin-0.3.1)确认发布后才运行下方 npm 安装。准备期间用已验证本地归档路径 `./artifacts/dsh-auth-remote-0.3.1.tgz` 替代包名。保持同一默认 `web` profile:
11
+ ## 最小化安装候选归档
12
+
13
+ `0.3.2` 尚未发布。按[开发指南](development.zh-CN.md)构建并验证本地归档后,安装该文件。已发布 `0.3.1` 保留七版历史,不包含本次新版宿主适配;分发事实见[精确历史记录](support-history.zh-CN.md#plugin-0.3.1)。保持同一默认 `web` profile:
12
14
 
13
15
  ```sh
14
16
  dsh --version
15
- dsh plugin --profile web add dsh-auth-remote@0.3.1
17
+ dsh plugin --profile web add ./artifacts/dsh-auth-remote-0.3.2.tgz
16
18
  dsh plugin --profile web list
17
19
  dsh web --no-open --port 13090
18
20
  ```
@@ -21,7 +23,7 @@ dsh web --no-open --port 13090
21
23
 
22
24
  ```sh
23
25
  curl -fsS http://127.0.0.1:13090/auth-remote/ready
24
- dsh plugin --profile web exec dsh-auth-remote init --lang zh
26
+ dsh plugin --profile web exec dsh-auth-remote init
25
27
  ```
26
28
 
27
29
  打开打印的 `http://127.0.0.1:13090/` 根地址。匿名导航跳转登录页,匿名业务 API 被拒绝。bundle 关闭原生 token URL 输出和自动打开浏览器;开发、测试 home 与账号 profile 分开。
@@ -60,7 +62,7 @@ HTTPS 代理入口可把以下条目合并到 `~/.dsh/profiles/web/cordis.patch.
60
62
  | `port` | CLI `--port`、文件、默认 `3080`,与 host 分别覆盖。`0` 在真实非零端口绑定后才生成入口。 |
61
63
  | `tlsCert`、`tlsKey` | 文件字段或 CLI `--tls-cert`/`--tls-key` 必须成对,CLI 整组覆盖,不混来源,不读未采用文件。省略即 HTTP。 |
62
64
  | `requireTotp` | 默认 `false`,未绑定账号可跳过,已绑定账号仍需第二因素;设为 `true` 可强制先完成绑定再访问。升级保留显式 true/false、已有绑定及备用码。 |
63
- | `manualAccountLogin` | 默认 true,原生 Settings 写当前 profile override;保存立即影响新授权且重启保留,不重启认证。false 保留已接纳授权和官方凭据。七版完整回归,未来准入及必要 API 见 README。 |
65
+ | `manualAccountLogin` | 默认 true,原生 Settings 写当前 profile override;保存立即影响新授权且重启保留,不重启认证。false 保留已接纳授权和官方凭据。八版完整回归,未来准入及必要 API 见 README。 |
64
66
  | `sessionHours` | 默认固定 168 小时。缩短会收紧已有会话,放宽不会复活过期会话。 |
65
67
  | `preserveOriginPaths` | 可选的规范路径段前缀,默认 `[]`。匹配路径在认证后保留已验证公网 Host 和已有 Origin;最终公开来源自动配置原生 Connection 信任。 |
66
68
 
@@ -77,13 +79,13 @@ dsh web --no-open --tls-cert ./tls/dsh.crt --tls-key ./tls/dsh.key
77
79
 
78
80
  只给一个 CLI 参数会失败,即使文件提供另一半也不混用。证书/私钥缺失、不可读、空内容、PEM 无效或不匹配时启动失败,不回退 HTTP,并释放监听、管理 socket 和存储资源。证书须对浏览器主机名有效;TLS 由官方监听处理。
79
81
 
80
- 全部支持版本原生提供 `--public-url`、IPv6 和 TLS;本候选已移除旧版未知参数及不支持传输分支。
82
+ 全部支持版本原生提供 `--public-url`、IPv6 和 TLS;本候选沿用已发布 `0.3.1` 完成的原生 API 迁移。
81
83
 
82
- 七版均把最终 Web URL 写入模型 runtime context 与 `DSH_WEB_URL`;测试仍扫描所有 Web 提示段,要求无重复地址或 token。
84
+ 八版均把最终 Web URL 写入模型 runtime context 与 `DSH_WEB_URL`;测试仍扫描所有 Web 提示段,要求无重复地址或 token。
83
85
 
84
86
  ## 原生 HTTPS 与 IPv6
85
87
 
86
- 全部七个支持版本都可合并以下完整认证条目提供 IPv6 回环 HTTPS,使用自己的证书/私钥:
88
+ 全部八个支持版本都可合并以下完整认证条目提供 IPv6 回环 HTTPS,使用自己的证书/私钥:
87
89
 
88
90
  ```yaml
89
91
  - id: auth-remote
@@ -124,7 +126,7 @@ dsh web --no-open --tls-cert ./tls/dsh.crt --tls-key ./tls/dsh.key
124
126
 
125
127
  插件 Cookie 跟随已验证外部来源,限主机、HttpOnly、SameSite,HTTPS 设置 Secure。原生桥接凭据仅保留服务端,跟随原生监听协议;公开 HTTP 代理接入原生 HTTPS 时,其原生 Cookie audience/Secure 仍按 HTTPS。浏览器 Cookie 不通过端口隔离。
126
128
 
127
- 标准 `/api` 路由在 `preserveOriginPaths: []` 下即可工作,无需列 `/api`。插件始终将定稿的原生桥接 authority 登记到 Connection 的 `trustedHosts`,使用实际绑定端口(包含 `--port 0`),读取该列表的下游插件无需额外 trusted-host 参数即可识别桥接地址。显式 CLI trusted hosts 合并去重,不扩大外层公开来源策略。仅在下游需要原始公网 Host 时加入前缀;Origin 仅在请求已有时透传,保留路径预检并登记所选公开 authority。无需单独 Connection 条目。七版普通路径统一使用归一化原生 bind authority,经过完整会话认证。撤销、Connection 丢失或存储故障会关闭活跃上传、流和升级连接,撤回业务准入。ready 不表示账号已初始化。
129
+ 标准 `/api` 路由在 `preserveOriginPaths: []` 下即可工作,无需列 `/api`。插件始终将定稿的原生桥接 authority 登记到 Connection 的 `trustedHosts`,使用实际绑定端口(包含 `--port 0`),读取该列表的下游插件无需额外 trusted-host 参数即可识别桥接地址。显式 CLI trusted hosts 合并去重,不扩大外层公开来源策略。仅在下游需要原始公网 Host 时加入前缀;Origin 仅在请求已有时透传,保留路径预检并登记所选公开 authority。无需单独 Connection 条目。八版普通路径统一使用归一化原生 bind authority,经过完整会话认证。撤销、Connection 丢失或存储故障会关闭活跃上传、流和升级连接,撤回业务准入。ready 不表示账号已初始化。
128
130
 
129
131
  ## 启动并验证公开入口
130
132
 
@@ -137,7 +139,9 @@ dsh web --no-open --tls-cert ./tls/dsh.crt --tls-key ./tls/dsh.key
137
139
 
138
140
  ## 备份、恢复与变更
139
141
 
140
- 升级旧部署到 `0.3.1` 前,停止 DSH 并备份认证目录、profile patch、package/lock;保持入口私有和独立 `webserver disabled: true`。先把宿主升级至所列七版(推荐 `0.2.1-rc.4`),再安装新插件并核对 ready、匿名拒绝、登录及撤销。六个已退役宿主不能安装 `0.3.1`,不要授予版本风险豁免。回退时停服,选择明确旧宿主(例如 `0.2.1-alpha.2`)与最后支持插件 `0.2.0`,恢复匹配的包/锁/patch 备份。此次迁移不改变认证数据格式;恢复时仍核对 schema,禁止覆盖运行中的状态。
142
+ 升级旧部署到 `0.3.2` 前,停止 DSH 并备份认证目录、profile patch、package/lock;保持入口私有和独立 `webserver disabled: true`。先把宿主升级至所列八版(推荐 `0.2.2-alpha.2`),再安装新插件并核对 ready、匿名拒绝、登录及撤销。六个已退役宿主不能安装 `0.3.2`,不要授予版本风险豁免。回退时停服,选择明确旧宿主(例如 `0.2.1-alpha.2`)与最后支持插件 `0.2.0`,恢复匹配的包/锁/patch 备份。六个宿主的退役发生于已发布 `0.3.1`,本次不重复退役。此次迁移不改变认证数据格式;恢复时仍核对 schema,禁止覆盖运行中的状态。
143
+
144
+ 这些是插件 `0.3.2` 自身的行为迁移,与 DSH 退役无关:CLI 固定英语,删除脚本中的 `--lang` 参数;JSON 字段不变。独立登录页不再提供语言选择器,按新 `dsh-auth-remote-lang` 缓存、`navigator.language`、英文选择语言。旧 `dsh-auth-remote.locale` 不读取、不清理、不迁移;进入 DSH 后仅同步原生已接纳的偏好,退出保留。插件八语不会扩充旧 DSH 的原生语言目录。
141
145
 
142
146
  停止 DSH 并确认释放 profile 锁,再复制 `~/.dsh/profiles/web/auth-remote/auth-state.json`。副本目录权限 0700、文件权限 0600;它含密码哈希、TOTP 密钥、备用码哈希和会话。不要复制写入中的临时文件、覆盖运行中持锁状态或提交 Git;同时备份对应 profile patch 和包/锁文件。
143
147
 
@@ -145,4 +149,6 @@ dsh web --no-open --tls-cert ./tls/dsh.crt --tls-key ./tls/dsh.key
145
149
 
146
150
  外部入口变更时,替换唯一 `publicUrl`、更新代理并重启 DSH。检查新入口与旧非回环入口的拒绝,包含 Cookie、重定向、上传和长连接。不要在插件中临时配置两个来源。
147
151
 
148
- 全部七个支持版本的官方 DeepSeek 账号授权使用 [README 的手动回填弹窗](../README.zh-CN.md#登录-deepseek-官方账号)。浏览器电脑无需监听器或开放回环端口。`/auth-remote/account/*` 保持相同会话/来源门禁,只接纳同源 JSON POST;直接 HTTP 访问原生 `/oauth/callback` 不能完成此手动对接。无需代理例外、扩大路径或放宽跨站规则。
152
+ 全部八个支持版本的官方 DeepSeek 账号授权使用 [README 的手动回填弹窗](../README.zh-CN.md#登录-deepseek-官方账号)。浏览器电脑无需监听器或开放回环端口。`/auth-remote/account/*` 保持相同会话/来源门禁,只接纳同源 JSON POST;直接 HTTP 访问原生 `/oauth/callback` 不能完成此手动对接。无需代理例外、扩大路径或放宽跨站规则。
153
+
154
+ 在 DSH `0.2.2-alpha.2` 使用 LiveShare 前,按原生方式启用该功能、配置 Relay 并完成 Owner 登录。本插件不自动启用分享或改写 Relay 配置;查看者不获得管理员身份,插件退出与停止分享是独立操作。本地协议替身只建立基础兼容证据,真实 Relay/OAuth、访客模型及文件写入体验另行验证。无需扩大匿名例外或 preserveOriginPaths。
@@ -2,9 +2,9 @@
2
2
 
3
3
  [简体中文](development.zh-CN.md)
4
4
 
5
- This guide describes seven exact verification targets for unpublished plugin candidate `0.3.1`, defaulting to DSH `0.2.1-rc.4`. Final same-archive evidence belongs to separate, unpackaged execution records; this guide does not certify unfinished candidate verification.
5
+ This guide describes eight exact verification targets for unpublished plugin candidate `0.3.2`, defaulting to DSH `0.2.2-alpha.2`. Final same-archive evidence belongs to separate, unpackaged execution records; declarations and reports are distinct.
6
6
 
7
- Development and the full test suite use Linux (`/proc` is required for the profile lock), Node.js 24+, pnpm 12.5.1, and DSH `0.2.1-rc.4`. Browser tests use Playwright-managed Chromium and a Node HTTP/HTTPS forwarder.
7
+ Development and the full test suite use Linux (`/proc` is required for the profile lock), Node.js 24+, pnpm 12.5.1, and DSH `0.2.2-alpha.2`. DSH `0.2.2-alpha.2` itself requires Node.js `>=24.9.0`; the plugin engine stays `>=24`. Browser tests use Playwright-managed Chromium and a Node HTTP/HTTPS forwarder.
8
8
 
9
9
  ## Set up and check a checkout
10
10
 
@@ -16,7 +16,7 @@ pnpm pack:local
16
16
  pnpm smoke
17
17
  ```
18
18
 
19
- `pnpm check` runs type checking, formatting, build, package/deployment/document checks, then unit, integration, CLI, and browser tests. `pnpm pack:local` writes `artifacts/dsh-auth-remote-0.3.1.tgz` after static checks; it does not publish. `pnpm smoke` installs that archive into an isolated DSH home, starts the pinned DSH runtime briefly, checks readiness, anonymous redirection/denial and an online CLI status, then stops it.
19
+ `pnpm check` runs type checking, formatting, build, package/deployment/document checks, then unit, integration, CLI, and browser tests. `pnpm pack:local` writes `artifacts/dsh-auth-remote-0.3.2.tgz` after static checks; it does not publish. `pnpm smoke` installs that archive into an isolated DSH home, starts the pinned DSH runtime briefly, checks readiness, anonymous redirection/denial and an online CLI status, then stops it.
20
20
 
21
21
  ## Use the isolated development profile
22
22
 
@@ -31,7 +31,7 @@ The scripts manage only `.dev/runtime-<version>` and `.dev/dsh-home` under this
31
31
  For direct inspection, use the same isolated home explicitly:
32
32
 
33
33
  ```sh
34
- DSH_HOME="$PWD/.dev/dsh-home" "$PWD/.dev/runtime-0.2.1-rc.4/node_modules/.bin/dsh" plugin --profile web exec dsh-auth-remote status --json
34
+ DSH_HOME="$PWD/.dev/dsh-home" "$PWD/.dev/runtime-0.2.2-alpha.2/node_modules/.bin/dsh" plugin --profile web exec dsh-auth-remote status --json
35
35
  ```
36
36
 
37
37
  The development home contains test account data. Keep it private and do not commit or copy it into a deployment profile.
@@ -40,7 +40,7 @@ The development home contains test account data. Keep it private and do not comm
40
40
 
41
41
  `pnpm test:unit` covers the auth state machine, TOTP, backup codes, origin policy, translations, storage durability and lock recovery. `pnpm test:integration` exercises real HTTP/WebSocket sockets, native readiness, cookies, origin decisions and revocation. `pnpm test:cli` builds the real archive and tests interactive and noninteractive commands against isolated profiles and Unix sockets. `pnpm test:browser` boots the selected DSH version with temporary profiles and verifies the login and Security & sign-in UI, native settings, workspace, upload/preview, SSE, WebSocket and an HTTPS forwarding chain.
42
42
 
43
- Browser network traffic uses a Node HTTP/HTTPS forwarder. The dedicated self-signed certificate and key under `tests/fixtures/tls/` are test fixtures only; they are never packaged or deployment credentials. Chat uses a local model stub. No real third-party authorization or paid model request is exercised. The default browser is Playwright Chromium; `DSH_TEST_BROWSER` can select a local browser executable, and `DSH_TEST_BIN` can select another binary only if it reports the exact selected version (default `0.2.1-rc.4`).
43
+ Browser network traffic uses a Node HTTP/HTTPS forwarder. The dedicated self-signed certificate and key under `tests/fixtures/tls/` are test fixtures only; they are never packaged or deployment credentials. Chat uses a local model stub. No real third-party authorization or paid model request is exercised. The default browser is Playwright Chromium; `DSH_TEST_BROWSER` can select a local browser executable, and `DSH_TEST_BIN` can select another binary only if it reports the exact selected version (default `0.2.2-alpha.2`).
44
44
 
45
45
  Shared Host environments are allowlisted without real model credentials/endpoints; browser launch removes ambient proxy variables. Before first key entry, `localModelEndpoint` points native llm-deepseek baseURL at a local HTTP stub, without preseeded keys or disabled onboarding. UI cases require zero model calls; proxy chat allows only local chat and native session-title POSTs. Counts are checked at fixture close and unexpected requests fail.
46
46
 
@@ -50,11 +50,11 @@ Before changing compatibility declarations or adaptations, read the [legacy comp
50
50
 
51
51
  Isolated verification installs use pnpm file copies so shared package hardlink metadata changes cannot trigger client hot reloads in another profile.
52
52
 
53
- Current candidate support is in [README](../README.md#dsh-compatibility), release facts in the [bidirectional history](support-history.md), and adaptation evidence in the inventory. Both support policies retain the previous release record and remain unchanged for `0.3.1`; never derive old release claims from the current candidate manifest.
53
+ Current candidate support is in [README](../README.md#dsh-compatibility), release facts in the [bidirectional history](support-history.md), and adaptation evidence in the inventory. Both support policies retain the previous release record and remain unchanged for this `0.3.2` work; never derive old release claims from the current candidate manifest.
54
54
 
55
55
  ## Cross-version verification
56
56
 
57
- The default target is DSH `0.2.1-rc.4`; `DSH_TEST_VERSION` accepts only `0.2.1-alpha.3`, `0.2.1-alpha.4`, `0.2.1-alpha.5`, `0.2.1-rc.1`, `0.2.1-rc.2`, `0.2.1-rc.3`, `0.2.1-rc.4`. Test runtimes live under `.cache/test-runtime/<version>` and development runtimes under `.dev/runtime-<version>`. `DSH_TEST_BIN` must report that exact version. CI keeps seven-version CLI/installation smoke; full runs seven complete browser targets and ordinary uses the selection below. Development types and integration use locked `0.2.1-rc.4` packages. All seven verify the real Loader, model runtime context/`DSH_WEB_URL`, and positive IPv4/IPv6 HTTP/HTTPS security boundaries. Missing native transport support fails instead of skipping.
57
+ The default target is DSH `0.2.2-alpha.2`; `DSH_TEST_VERSION` accepts only `0.2.1-alpha.3`, `0.2.1-alpha.4`, `0.2.1-alpha.5`, `0.2.1-rc.1`, `0.2.1-rc.2`, `0.2.1-rc.3`, `0.2.1-rc.4`, `0.2.2-alpha.2`. Test runtimes live under `.cache/test-runtime/<version>` and development runtimes under `.dev/runtime-<version>`. `DSH_TEST_BIN` must report that exact version. CI keeps eight-version CLI/installation smoke; full runs eight complete browser targets and ordinary uses the selection below. Development types and integration use locked `0.2.2-alpha.2` packages. All eight targets check the real Loader, model runtime context/`DSH_WEB_URL`, and positive IPv4/IPv6 HTTP/HTTPS security boundaries. Missing native transport support fails instead of skipping.
58
58
 
59
59
  ```sh
60
60
  DSH_TEST_VERSION=0.2.1-alpha.3 pnpm test:cli
@@ -69,59 +69,61 @@ DSH_TEST_VERSION=0.2.1-rc.2 pnpm test:cli
69
69
  DSH_TEST_VERSION=0.2.1-rc.2 pnpm test:browser
70
70
  DSH_TEST_VERSION=0.2.1-rc.3 pnpm test:cli
71
71
  DSH_TEST_VERSION=0.2.1-rc.3 pnpm test:browser
72
- DSH_TEST_VERSION=0.2.1-rc.4 pnpm test:cli
73
- DSH_TEST_VERSION=0.2.1-rc.4 pnpm test:browser
72
+ DSH_TEST_VERSION=0.2.2-alpha.2 pnpm test:cli
73
+ DSH_TEST_VERSION=0.2.2-alpha.2 pnpm test:browser
74
+ DSH_TEST_VERSION=0.2.2-alpha.2 pnpm test:cli
75
+ DSH_TEST_VERSION=0.2.2-alpha.2 pnpm test:browser
74
76
  ```
75
77
 
76
78
  Browser tests save light/dark, desktop/narrow-screen screenshots under `.cache/ui-review/<version>` for visual review. Security CSS is installed and removed with the plugin, scopes its selectors to the plugin page, and reads the host's live `--dsw-*` tokens. The standalone login uses a subset of DSH 0.2.0-rc.1 theme tokens and the system color scheme without reading host preferences before authentication.
77
79
 
78
- Official-account tests use a local Platform stand-in with the actual DSH `0.2.1-rc.4` account provider. They check the original redirect URI and PKCE verifier during exchange, rejected state/URL/session combinations, duplicate submissions, cancellation, expiry and retries. Browser coverage checks the instruction-first menu and onboarding dialog, failed loopback navigation followed by paste/confirm, blocked popups, live locale and responsive light/dark layout. These tests do not establish a real official-account authorization session.
80
+ Official-account tests use a local Platform stand-in with the actual DSH `0.2.2-alpha.2` account provider. They check the original redirect URI and PKCE verifier during exchange, rejected state/URL/session combinations, duplicate submissions, cancellation, expiry and retries. Browser coverage checks the instruction-first menu and onboarding dialog, failed loopback navigation followed by paste/confirm, blocked popups, live locale and responsive light/dark layout. These tests do not establish a real official-account authorization session.
79
81
 
80
82
  Core account tests load the exact provider from locked development dependencies, so they do not require a pre-existing CLI runtime cache. Browser tests still exercise the provider installed into each isolated DSH profile.
81
83
 
82
- The temporary account adapter retains capability and live-configuration checks; complete manual-feature regression targets `0.2.1-alpha.3`, `0.2.1-alpha.4`, `0.2.1-alpha.5`, `0.2.1-rc.1`, `0.2.1-rc.2`, `0.2.1-rc.3`, `0.2.1-rc.4`. After global minimum admission the server no longer branches for older hosts; the separately exported helper still checks omitted, invalid and older inputs. Forward admission is not verification. Support or shared host-adapter changes require the same final tgz across all seven CLI, complete browser and smoke runs with `--suite cli --suite browser --suite smoke` per release. Never call rebuilding/repacking wrappers in the consumer loop. The runner restores archive dist, checks SHA-256 per suite and isolates smoke from development profiles. See `DSH-ACCOUNT-001` for public-callback evidence and migration/retirement conditions.
84
+ The temporary account adapter retains capability and live-configuration checks; complete manual-feature regression targets `0.2.1-alpha.3`, `0.2.1-alpha.4`, `0.2.1-alpha.5`, `0.2.1-rc.1`, `0.2.1-rc.2`, `0.2.1-rc.3`, `0.2.1-rc.4`, `0.2.2-alpha.2`. After global minimum admission the server no longer branches for older hosts; the separately exported helper still checks omitted, invalid and older inputs. Forward admission is not verification. Support or shared host-adapter changes require the same final tgz across all eight CLI, complete browser and smoke runs with `--suite cli --suite browser --suite smoke` per release. Never call rebuilding/repacking wrappers in the consumer loop. The runner restores archive dist, checks SHA-256 per suite and isolates smoke from development profiles. See `DSH-ACCOUNT-001` for public-callback evidence and migration/retirement conditions.
83
85
 
84
86
  `live-config.spec.ts` observes the real Loader reference/fiber, auth/store identity, lock, listener and SSE/WebSocket continuity, checks the loaded dependency chain and restarts to verify the profile override. It does not fabricate services. Dialog regression covers cancellation/errors, focus/keyboard, optional/enforced TOTP, one-time code copying and redirect holds after revocation. Task documents, test credentials, profiles, screenshots and generated directories must remain outside the npm archive.
85
87
 
86
- `account-login.spec.ts` exercises real configuration HMR on all seven: an ordinary `sessionHours` change rebuilds the listener, independent Settings writes wait for the native transaction queue, and genuine nesting remains rejected. Isolated plugin code replacement must allow manual sign-in to be enabled again. The transaction probe calls real HMR, replaces no service and is never packaged; see `DSH-HMR-001`. Protected remote profiles independently disable native webserver. On all seven, `startup-compatibility.spec.ts` damages only isolated plugin copies: `0.2.1-alpha.3` uses an incompatible Host peer for Loader skip, the other six an incompatible `engines.dsh`; every version also gets an injected plugin admission range for post-import runtime rejection. Both paths must fail naturally without TCP/HTTP/readiness/WebSocket fallback; upstream and Loader auditing are unchanged.
88
+ `account-login.spec.ts` exercises real configuration HMR on all eight: an ordinary `sessionHours` change rebuilds the listener, independent Settings writes wait for the native transaction queue, and genuine nesting remains rejected. Isolated plugin code replacement must allow manual sign-in to be enabled again. The transaction probe calls real HMR, replaces no service and is never packaged; see `DSH-HMR-001`. Protected remote profiles independently disable native webserver. On all eight, `startup-compatibility.spec.ts` damages only isolated plugin copies: `0.2.1-alpha.3` uses an incompatible Host peer for Loader skip, the other seven an incompatible `engines.dsh`; every version also gets an injected plugin admission range for post-import runtime rejection. Both paths must fail naturally without TCP/HTTP/readiness/WebSocket fallback; upstream and Loader auditing are unchanged.
87
89
 
88
90
  The account preference binding recovers an initial failed read through the native describe mirror’s `ensure()` API. Recovery of an already held namespace uses the explicitly injected `remote.settings` transport and folds the accepted namespace back into that mirror. A sign-in click while the preference is loading waits for the shared read, then uses the latest accepted true/false value; loading does not select the native flow. Browser regression covers initial failure, a temporarily missing namespace and delayed reads for both routing choices.
89
91
 
90
- Native Search/Fetch settings regression on `0.2.1-rc.2`, `0.2.1-rc.3` and `0.2.1-rc.4` covers real settings/credentials selection, failed saves, refresh/restart persistence and anonymous/revoked-session refusal. Endpoints are local and request counts must stay zero. On `0.2.1-rc.3` and `0.2.1-rc.4`, `rc-navigation.spec.ts` checks global/session/right-sidebar More menus, native settings/model selection and refusal after revocation. Market/Creator entries are inspected without installation or external authorization. Public sessions/sessionProjections APIs create a real session empty completed turn to expose native menus; no chat is sent and no snapshot is replaced. Official dynamic `/models` internal semantics are outside the verification claim.
92
+ Native Search/Fetch settings regression on `0.2.1-rc.2`, `0.2.1-rc.3`, `0.2.1-rc.4` and `0.2.2-alpha.2` covers real settings/credentials selection, failed saves, refresh/restart persistence and anonymous/revoked-session refusal. Endpoints are local and request counts must stay zero. On `0.2.1-rc.3`, `0.2.1-rc.4` and `0.2.2-alpha.2`, `rc-navigation.spec.ts` checks global/session/right-sidebar More menus, native settings/model selection and refusal after revocation. Market/Creator entries are inspected without installation or external authorization. Public sessions/sessionProjections APIs create a real session empty completed turn to expose native menus; no chat is sent and no snapshot is replaced. Official dynamic `/models` internal semantics are outside the verification claim.
91
93
 
92
94
  Startup diagnostics use installed exact declarations and explicit lifecycle records, warning once per process/version/state even across configuration/module HMR. The three Alpha releases are legacy from 2026-10-28 with a 14-day window and earliest eligibility 2026-11-11 (Asia/Shanghai); dates never stop service. The six retired versions record last plugin `0.2.0`, retirement release `0.3.1` and preparation date `retiredOn: 2026-10-28`, which is not an actual npm publication timestamp. Mock-clock tests preserve classification after eligibility; real legacy HMR checks process-wide deduplication. API, package identity and security failures still refuse service.
93
95
 
94
- `browser/host-release.spec.ts` fixes six real round trips: `0.2.1-alpha.4` ↔ `0.2.1-alpha.3`, `0.2.1-alpha.5` ↔ `0.2.1-alpha.4`, `0.2.1-rc.1` ↔ `0.2.1-alpha.5`, `0.2.1-rc.2` ↔ `0.2.1-rc.1`, `0.2.1-rc.3` ↔ `0.2.1-rc.2`, and `0.2.1-rc.4` ↔ `0.2.1-rc.3`. Each keeps the page in one temporary profile/port, checks the native release prompt, reloads to verify authentication, the original session and persisted settings, then restores the starting release. Only `0.2.1-alpha.3` lacks release metadata and reads unknown; every other destination must show its actual full version. No upstream source, version or dependency-graph metadata is changed.
96
+ `browser/host-release.spec.ts` fixes seven real round trips: `0.2.1-alpha.4` ↔ `0.2.1-alpha.3`, `0.2.1-alpha.5` ↔ `0.2.1-alpha.4`, `0.2.1-rc.1` ↔ `0.2.1-alpha.5`, `0.2.1-rc.2` ↔ `0.2.1-rc.1`, `0.2.1-rc.3` ↔ `0.2.1-rc.2`, `0.2.1-rc.4` ↔ `0.2.1-rc.3`, and `0.2.2-alpha.2` ↔ `0.2.1-rc.4`. Each keeps the page in one temporary profile/port, checks the native release prompt, reloads to verify authentication, the original session and persisted settings, then restores the starting release. Only `0.2.1-alpha.3` lacks release metadata and reads unknown; every other destination must show its actual full version. No upstream source, version or dependency-graph metadata is changed.
95
97
 
96
98
  ## Consume a fixed archive
97
99
 
98
100
  `pnpm verify:packed` consumes an existing tgz without building or packing. Record its SHA-256 first, then pass the archive, that digest, an exact declared DSH release and one or more suites:
99
101
 
100
102
  ```sh
101
- sha256sum artifacts/dsh-auth-remote-0.3.1.tgz
102
- pnpm verify:packed --archive artifacts/dsh-auth-remote-0.3.1.tgz --sha256 <recorded-sha256> --dsh-version 0.2.1-rc.4 --suite cli --suite browser --suite smoke
103
+ sha256sum artifacts/dsh-auth-remote-0.3.2.tgz
104
+ pnpm verify:packed --archive artifacts/dsh-auth-remote-0.3.2.tgz --sha256 <recorded-sha256> --dsh-version 0.2.2-alpha.2 --suite cli --suite browser --suite smoke
103
105
  ```
104
106
 
105
107
  The consumer validates the package name/version and selected release declaration, stages those exact bytes at the fixed artifact path and restores only the archive's dist. CLI execution and installation comparisons therefore use that dist. It rejects unsafe tar entries, a changed digest, unknown selections, zero actual tests and skipped/cancelled/todo tests. Node's passing placeholder for a test file with no matching cases does not count as a real test. `--test-name-pattern` optionally filters one `cli` or `browser` suite; its report is explicitly partial and includes the files, pattern and actual commands. Fixed specialized suites cannot override their filter/count requirements; every required file must register tests.
106
108
 
107
- | Suite | Selection |
108
- | -------------- | --------------------------------------------------------------------------------------------------------------- |
109
- | `cli` | All CLI test files |
110
- | `browser` | All browser test files |
111
- | `smoke` | Install and briefly boot the archive in a new marked home |
112
- | `theme` | The exact login/security theme and narrow-screen case (one real test) |
113
- | `account` | startup-compatibility, account-login and live-config on `0.2.1-alpha.3` |
114
- | `host-release` | One real round trip on `0.2.1-alpha.4`, `0.2.1-alpha.5`, `0.2.1-rc.1`, `0.2.1-rc.2`, `0.2.1-rc.3`, `0.2.1-rc.4` |
115
- | `rc-bootstrap` | host-release and dsh-bootstrap on `0.2.1-rc.1` (two real tests) |
109
+ | Suite | Selection |
110
+ | -------------- | -------------------------------------------------------------------------------------------------------------------------------- |
111
+ | `cli` | All CLI test files |
112
+ | `browser` | All browser test files |
113
+ | `smoke` | Install and briefly boot the archive in a new marked home |
114
+ | `theme` | The exact login/security theme and narrow-screen case (one real test) |
115
+ | `account` | startup-compatibility, account-login and live-config on `0.2.1-alpha.3` |
116
+ | `host-release` | One real round trip on `0.2.1-alpha.4`, `0.2.1-alpha.5`, `0.2.1-rc.1`, `0.2.1-rc.2`, `0.2.1-rc.3`, `0.2.1-rc.4`, `0.2.2-alpha.2` |
117
+ | `rc-bootstrap` | host-release and dsh-bootstrap on `0.2.1-rc.1` (two real tests) |
116
118
 
117
119
  Consumption is serial within a checkout, enforced by a consumer lock. Each suite checks the input archive, fixed consumer archive and restored dist again. JSON reports and test logs remain under `.cache/verify-packed/`. Smoke creates its marked temporary root directly under `.cache/v-*` to keep the management socket within Linux's pathname limit in the default GitHub checkout. It uses its own runtime/home and `--port 0`; it reads only that child process's announced actual loopback address and checks online CLI status in the same profile. Existing `.dev/dsh-home` and services on 13090 are independent. Only the newly created verification root is removed. `DSH_VERIFY_ROOT` is internal and rejects unmarked, symlinked or external paths; ordinary development commands retain their existing profile and port.
118
120
 
119
121
  ## Independent retired-host refusal verification
120
122
 
121
- `verify-retired.mjs` does not extend `DSH_TEST_VERSION` or the positive matrix. It checks the same candidate/SHA256SUMS and published `0.2.0` integrity, then uses two private old profiles for real CLI rejection/complete rollback and native peer skip of a whole incompatible package. The latter preserves actual old peer resolution, repeatedly confirms no TCP/HTTP/readiness/WebSocket listener, and cleans up processes. All six run once for this migration acceptance; subsequent full/release plans run only `0.2.1-alpha.2`, and ordinary runs none.
123
+ `verify-retired.mjs` does not extend `DSH_TEST_VERSION` or the positive matrix. It checks the same candidate/SHA256SUMS and published `0.2.0` integrity, then uses two private old profiles for real CLI rejection/complete rollback and native peer skip of a whole incompatible package. The latter preserves actual old peer resolution, repeatedly confirms no TCP/HTTP/readiness/WebSocket listener, and cleans up processes. The six-host one-time acceptance belongs to the `0.3.1` migration history. Current full/release plans run only `0.2.1-alpha.2`, and ordinary runs none.
122
124
 
123
125
  ```sh
124
- node scripts/verify-retired.mjs --archive artifacts/dsh-auth-remote-0.3.1.tgz --sha256 <recorded-sha256> --retired-dsh-version 0.2.1-alpha.2
126
+ node scripts/verify-retired.mjs --archive artifacts/dsh-auth-remote-0.3.2.tgz --sha256 <recorded-sha256> --retired-dsh-version 0.2.1-alpha.2
125
127
  ```
126
128
 
127
129
  The six independent negative targets are `0.1.7-rc.1`, `0.1.7-rc.2`, `0.2.0-rc.1`, `0.2.0-rc.2`, `0.2.1-alpha.1` and `0.2.1-alpha.2`. Reports stay separate from positive evidence under `.cache/verify-retired/`.
@@ -130,7 +132,7 @@ The six independent negative targets are `0.1.7-rc.1`, `0.1.7-rc.2`, `0.2.0-rc.1
130
132
 
131
133
  `scripts/ci-plan.mjs` selects ordinary verification only when every changed path is one of `CHANGELOG.md`, `CHANGELOG.zh-CN.md`, `CONTRIBUTING.md`, `CONTRIBUTING.zh-CN.md`, `LICENSE` or `tests/unit/i18n.test.ts`. Any other path selects full verification, including source, shared tests/helpers, package/lock/build scripts, workflows, README, support policies and compatibility inventories. Renames/copies, unknown statuses, empty or incomplete differences and an unexpected/dirty checkout also select full. PR comparison uses the actual event base/head and verifies merge parents; push comparison uses before/after. Missing commit evidence falls back to full.
132
134
 
133
- Manual dispatch, unknown events, every release and the Monday 00:00 UTC schedule use full verification. Every plan keeps seven-version CLI/smoke. Full runs seven complete browser targets plus the independent real negative job on `0.2.1-alpha.2`; ordinary runs no real retired-host negative job. Its browser matrix is fixed:
135
+ Manual dispatch, unknown events, every release and the Monday 00:00 UTC schedule use full verification. Every plan keeps eight-version CLI/smoke. Full runs eight complete browser targets plus the independent real negative job on `0.2.1-alpha.2`; ordinary runs no real retired-host negative job. Its browser matrix is fixed:
134
136
 
135
137
  | Exact DSH release | Ordinary browser selection |
136
138
  | ----------------- | -------------------------- |
@@ -141,5 +143,14 @@ Manual dispatch, unknown events, every release and the Monday 00:00 UTC schedule
141
143
  | `0.2.1-rc.2` | `browser` |
142
144
  | `0.2.1-rc.3` | `browser` |
143
145
  | `0.2.1-rc.4` | `browser` |
146
+ | `0.2.2-alpha.2` | `browser` |
144
147
 
145
148
  The shared workflow validates the exact matrix. Full requires validate, cli-smoke, browser and retired-rejection to succeed; ordinary accepts only the predetermined retired-rejection skip and requires the other three successes. Unknown plans, missing results, failures, cancellations and other skips fail. `CI Verify` also requires plan/producer success; releases use full and inherit the negative gate. Keep fixed-port tests serial per checkout; local parallel jobs require independent source/dist/artifacts/runtime/profile trees, writable node_modules copies and network namespaces. Copy-mode installation avoids shared HMR inode changes.
149
+
150
+ On exact DSH `0.2.2-alpha.2`, `native-transport.spec.ts` compares genuine native asset/fallback bytes and ETags for GET/HEAD/304, rejects anonymous/revoked correct-tag requests, and retains immutable 200 semantics for real bundle/map/chunk artifacts and nonimmutable index behavior. Four real `/api/remote.mux` cases cover native HTTPS/proxy, default/none compression, whole-frame threshold/RSV1, successful ready frames and actual expiry/revocation. The installed native Gateway/ws owns transport and compression.
151
+
152
+ The new-host `account-login.spec.ts` source-HMR fault case preserves the initial instance on import failure, then throws after genuine replacement initialization to prove old/failed resource cleanup and native automatic rollback. It checks real provider fibers, listeners, state-lock nonces, mux closure, persisted authentication, the first restored Settings save and final lock reacquisition. The copied entry uses one canonical file URL and explicit native watch roots; public log export observes warnings without replacing HMR.
153
+
154
+ Browser language tests cover all eight plugin dictionaries, login fallback/memory, native accepted preference vs optimistic edits, delayed/unavailable/failed reads and saves, storage failures and sign-out/revocation persistence. DSH's native language catalog is unchanged. CLI tests require fixed English across environment languages and reject every `--lang` form before profile access; the published `0.2.0` retired fixture keeps its historical Chinese contract.
155
+
156
+ `liveshare.spec.ts` registers only on exact `0.2.2-alpha.2`: real native Host/Owner PKCE/share worker/viewer carriers and stop operations use a local Relay identity/transport stand-in. Viewer clients remain inert for administrator features. Tests do not establish real Relay/OAuth, visitor models or file writes. Partial filtered reports and file placeholders never certify the final eight-host archive.
@@ -2,9 +2,9 @@
2
2
 
3
3
  [English](development.md)
4
4
 
5
- 本指南描述未发布插件候选 `0.3.1` 的七版精确验证目标,默认 DSH `0.2.1-rc.4`。最终同包运行证据另记包外执行记录;本指南不认证尚未完成的候选验证。
5
+ 本指南描述未发布插件候选 `0.3.2` 的八版精确验证目标,默认 DSH `0.2.2-alpha.2`。最终同包运行证据另记包外执行记录;声明与实测报告分开表达。
6
6
 
7
- 开发和完整测试需要 Linux(profile 锁依赖 `/proc`)、Node.js 24+、pnpm 12.5.1,以及 DSH `0.2.1-rc.4`。浏览器测试使用 Playwright 管理的 Chromium 和 Node HTTP/HTTPS 转发器。
7
+ 开发和完整测试需要 Linux(profile 锁依赖 `/proc`)、Node.js 24+、pnpm 12.5.1,以及 DSH `0.2.2-alpha.2`。DSH `0.2.2-alpha.2` 自身要求 Node.js `>=24.9.0`;插件引擎仍为 `>=24`。浏览器测试使用 Playwright 管理的 Chromium 和 Node HTTP/HTTPS 转发器。
8
8
 
9
9
  兼容声明或适配变更前,先阅读 [Legacy 兼容维护清单](legacy-compatibility.zh-CN.md)。共同复核运行时准入、测试目标、CI 和用户声明;适用版本退出支持集合时同次清理专属运行时代码及测试。旧插件配置按自身迁移策略退役,保留共享安全逻辑,并用完整版本号与精确版本证据同步更新中英文清单及两个维度的矩阵。
10
10
 
@@ -18,7 +18,7 @@ pnpm pack:local
18
18
  pnpm smoke
19
19
  ```
20
20
 
21
- `pnpm check` 依次执行类型、格式、构建、包/部署/文档检查,以及单元、集成、CLI 和浏览器测试。`pnpm pack:local` 在静态检查后写出 `artifacts/dsh-auth-remote-0.3.1.tgz`,不会发布。`pnpm smoke` 将包安装到隔离 DSH_HOME,短暂启动固定版本的 DSH,验证就绪、匿名重定向/拒绝和在线 CLI 状态,然后停止。
21
+ `pnpm check` 依次执行类型、格式、构建、包/部署/文档检查,以及单元、集成、CLI 和浏览器测试。`pnpm pack:local` 在静态检查后写出 `artifacts/dsh-auth-remote-0.3.2.tgz`,不会发布。`pnpm smoke` 将包安装到隔离 DSH_HOME,短暂启动固定版本的 DSH,验证就绪、匿名重定向/拒绝和在线 CLI 状态,然后停止。
22
22
 
23
23
  ## 使用隔离开发 profile
24
24
 
@@ -33,7 +33,7 @@ pnpm dev:start
33
33
  直接查看状态时显式使用同一隔离 home:
34
34
 
35
35
  ```sh
36
- DSH_HOME="$PWD/.dev/dsh-home" "$PWD/.dev/runtime-0.2.1-rc.4/node_modules/.bin/dsh" plugin --profile web exec dsh-auth-remote status --json
36
+ DSH_HOME="$PWD/.dev/dsh-home" "$PWD/.dev/runtime-0.2.2-alpha.2/node_modules/.bin/dsh" plugin --profile web exec dsh-auth-remote status --json
37
37
  ```
38
38
 
39
39
  开发 home 可能含测试账号数据,须保持私有,不要提交或复制到部署 profile。
@@ -42,7 +42,7 @@ DSH_HOME="$PWD/.dev/dsh-home" "$PWD/.dev/runtime-0.2.1-rc.4/node_modules/.bin/ds
42
42
 
43
43
  `pnpm test:unit` 覆盖认证状态机、TOTP、备用码、来源策略、翻译、存储持久性和锁恢复。`pnpm test:integration` 使用真实 HTTP/WebSocket socket 验证原生就绪、Cookie、来源判定与撤销。`pnpm test:cli` 构建真实压缩包,并用隔离 profile/Unix socket 验证交互与非交互命令。`pnpm test:browser` 用临时 profile 启动所选的 DSH 版本,验证登录、安全与登录页、原生设置、工作区、上传/预览、SSE、WebSocket 和 HTTPS 转发链。
44
44
 
45
- 浏览器网络链路使用 Node HTTP/HTTPS 转发器。`tests/fixtures/tls/` 下的专用自签证书与私钥仅为测试夹具,不进入安装包,也不是部署凭证。聊天使用本地模型替身;不执行真实第三方授权或付费模型请求。默认浏览器为 Playwright Chromium;`DSH_TEST_BROWSER` 可选择本地浏览器程序,`DSH_TEST_BIN` 仅在报告所选精确版本(默认 `0.2.1-rc.4`)时可替换 DSH 二进制。
45
+ 浏览器网络链路使用 Node HTTP/HTTPS 转发器。`tests/fixtures/tls/` 下的专用自签证书与私钥仅为测试夹具,不进入安装包,也不是部署凭证。聊天使用本地模型替身;不执行真实第三方授权或付费模型请求。默认浏览器为 Playwright Chromium;`DSH_TEST_BROWSER` 可选择本地浏览器程序,`DSH_TEST_BIN` 仅在报告所选精确版本(默认 `0.2.2-alpha.2`)时可替换 DSH 二进制。
46
46
 
47
47
  共享 Host 环境由 allowlist 构造,清除真实模型凭据/endpoint;浏览器清除 ambient 代理变量。`localModelEndpoint` 在首次输入 Key 前把原生 llm-deepseek baseURL 指向本地 HTTP 替身,不预存 Key、不关闭引导。UI 专项要求零模型调用;代理聊天只接纳本地 chat 和原生 session-title 两次 POST。计数在 fixture 关闭时检查,异常请求使测试失败。
48
48
 
@@ -50,11 +50,11 @@ DSH 测试运行时位于 `.cache/test-runtime/<version>`,与源码依赖分
50
50
 
51
51
  隔离验证安装使用 pnpm 的文件复制模式,避免不同 profile 共享包文件的硬链接元数据变化触发 DSH 客户端热重载。
52
52
 
53
- 本候选当前支持见 [README](../README.zh-CN.md#dsh-兼容性),发布事实见[双向历史](support-history.zh-CN.md),适配证据见库存。两份 support-policy 保留前一发布记录,`0.3.1` 本次不修改;不能用当前候选 manifest 推导旧发布声明。
53
+ 本候选当前支持见 [README](../README.zh-CN.md#dsh-兼容性),发布事实见[双向历史](support-history.zh-CN.md),适配证据见库存。两份 support-policy 保留前一发布记录,本次 `0.3.2` 不修改;不能用当前候选 manifest 推导旧发布声明。
54
54
 
55
55
  ## 跨版本验证
56
56
 
57
- 默认测试 DSH `0.2.1-rc.4`;`DSH_TEST_VERSION` 仅可选择 `0.2.1-alpha.3`、`0.2.1-alpha.4`、`0.2.1-alpha.5`、`0.2.1-rc.1`、`0.2.1-rc.2`、`0.2.1-rc.3`、`0.2.1-rc.4`。测试运行时位于 `.cache/test-runtime/<version>`,开发运行时位于 `.dev/runtime-<version>`;`DSH_TEST_BIN` 必须报告所选精确版本。CI 保留七版 CLI/安装 smoke,全量运行七版完整 browser,普通使用下文固定选择。开发类型与集成测试使用锁定的 `0.2.1-rc.4` 包。七版均验证真实 Loader、模型 runtime context/`DSH_WEB_URL` 和 IPv4/IPv6 HTTP/HTTPS 正向安全边界;测试传输不可用时失败,不跳过。
57
+ 默认测试 DSH `0.2.2-alpha.2`;`DSH_TEST_VERSION` 仅可选择 `0.2.1-alpha.3`、`0.2.1-alpha.4`、`0.2.1-alpha.5`、`0.2.1-rc.1`、`0.2.1-rc.2`、`0.2.1-rc.3`、`0.2.1-rc.4`、`0.2.2-alpha.2`。测试运行时位于 `.cache/test-runtime/<version>`,开发运行时位于 `.dev/runtime-<version>`;`DSH_TEST_BIN` 必须报告所选精确版本。CI 保留八版 CLI/安装 smoke,全量运行八版完整 browser,普通使用下文固定选择。开发类型与集成测试使用锁定的 `0.2.2-alpha.2` 包。八版均验证真实 Loader、模型 runtime context/`DSH_WEB_URL` 和 IPv4/IPv6 HTTP/HTTPS 正向安全边界;测试传输不可用时失败,不跳过。
58
58
 
59
59
  ```sh
60
60
  DSH_TEST_VERSION=0.2.1-alpha.3 pnpm test:cli
@@ -69,59 +69,61 @@ DSH_TEST_VERSION=0.2.1-rc.2 pnpm test:cli
69
69
  DSH_TEST_VERSION=0.2.1-rc.2 pnpm test:browser
70
70
  DSH_TEST_VERSION=0.2.1-rc.3 pnpm test:cli
71
71
  DSH_TEST_VERSION=0.2.1-rc.3 pnpm test:browser
72
- DSH_TEST_VERSION=0.2.1-rc.4 pnpm test:cli
73
- DSH_TEST_VERSION=0.2.1-rc.4 pnpm test:browser
72
+ DSH_TEST_VERSION=0.2.2-alpha.2 pnpm test:cli
73
+ DSH_TEST_VERSION=0.2.2-alpha.2 pnpm test:browser
74
+ DSH_TEST_VERSION=0.2.2-alpha.2 pnpm test:cli
75
+ DSH_TEST_VERSION=0.2.2-alpha.2 pnpm test:browser
74
76
  ```
75
77
 
76
78
  浏览器测试把浅色/深色、桌面/窄屏截图保存在 `.cache/ui-review/<version>`,供人工检查。安全页的 CSS 在插件生效时注入、销毁时移除,所有选择器只作用于插件页面,并直接引用宿主 `--dsw-*` 主题变量。独立登录页使用 dsh 0.2.0-rc.1 的主题变量子集并跟随系统配色,不读取登录前不可用的宿主设置。
77
79
 
78
- 官方账号专项测试使用本地平台替身与真实 DSH `0.2.1-rc.4` 账号提供者,验证兑换保留原始 redirect URI 和 PKCE verifier,以及错误 state/URL/会话、重复提交、取消、过期和重试。浏览器覆盖账号菜单与引导中的先说明弹窗、回环导航失败后粘贴确认、弹窗拦截、动态语言与浅深色响应式布局。这些测试不会建立真实官方账号授权。
80
+ 官方账号专项测试使用本地平台替身与真实 DSH `0.2.2-alpha.2` 账号提供者,验证兑换保留原始 redirect URI 和 PKCE verifier,以及错误 state/URL/会话、重复提交、取消、过期和重试。浏览器覆盖账号菜单与引导中的先说明弹窗、回环导航失败后粘贴确认、弹窗拦截、动态语言与浅深色响应式布局。这些测试不会建立真实官方账号授权。
79
81
 
80
82
  账号核心测试从锁定的开发依赖加载精确版本提供者,无需预先存在 CLI 运行时缓存;浏览器测试仍使用隔离 DSH profile 中实际安装的提供者。
81
83
 
82
- 此临时账号适配保留必要能力与动态配置检查;完整手动功能回归覆盖 `0.2.1-alpha.3`、`0.2.1-alpha.4`、`0.2.1-alpha.5`、`0.2.1-rc.1`、`0.2.1-rc.2`、`0.2.1-rc.3`、`0.2.1-rc.4`。全局下限准入后的服务端不再分流旧宿主,独立导出 helper 仍检查缺省、无效和旧版本参数。未来准入不构成已验证声明。支持范围或共享宿主适配变更须用同一最终 tgz 完整运行七版 CLI、browser 与 smoke,逐版执行 `--suite cli --suite browser --suite smoke`;禁止在消费循环调用重建/重打包包装命令。运行器恢复归档 dist、逐 suite 校验 SHA-256,并隔离 smoke 与开发 profile。公网回调、迁移及退役条件见 `DSH-ACCOUNT-001`。
84
+ 此临时账号适配保留必要能力与动态配置检查;完整手动功能回归覆盖 `0.2.1-alpha.3`、`0.2.1-alpha.4`、`0.2.1-alpha.5`、`0.2.1-rc.1`、`0.2.1-rc.2`、`0.2.1-rc.3`、`0.2.1-rc.4`、`0.2.2-alpha.2`。全局下限准入后的服务端不再分流旧宿主,独立导出 helper 仍检查缺省、无效和旧版本参数。未来准入不构成已验证声明。支持范围或共享宿主适配变更须用同一最终 tgz 完整运行八版 CLI、browser 与 smoke,逐版执行 `--suite cli --suite browser --suite smoke`;禁止在消费循环调用重建/重打包包装命令。运行器恢复归档 dist、逐 suite 校验 SHA-256,并隔离 smoke 与开发 profile。公网回调、迁移及退役条件见 `DSH-ACCOUNT-001`。
83
85
 
84
86
  `live-config.spec.ts` 仅观察真实 Loader 的配置引用/fiber、认证/存储实例、锁、监听器及 SSE/WebSocket 连续性,核对实际依赖链并重启验证 profile override;不伪造服务。安全弹窗回归覆盖取消/错误、焦点/键盘、默认及强制 TOTP、一次性备用码复制与会话撤销后跳转保持。任务文档、测试凭证、profile、截图及生成目录不得进入 npm 包。
85
87
 
86
- `account-login.spec.ts` 在七版验证真实原生配置 HMR:修改普通 `sessionHours` 重建监听器,独立 Settings 写入仍等待已有事务,真正嵌套仍被拒绝;隔离插件代码替换后可重新开启手动登录。事务探针调用真实 HMR,不替代服务,不进入 npm 包,最小监听器上下文适配见 `DSH-HMR-001`。受保护远程部署独立禁用原生 webserver。`startup-compatibility.spec.ts` 在七版破坏隔离插件副本:`0.2.1-alpha.3` 用不兼容 Host peer 验证 Loader skip,其余六版用不兼容 `engines.dsh`;各版还注入插件自身准入范围,验证导入后的运行拒绝。两路径均须自行失败且无 TCP/HTTP/readiness/WebSocket 回退,不改上游或 Loader 审计。
88
+ `account-login.spec.ts` 在八版验证真实原生配置 HMR:修改普通 `sessionHours` 重建监听器,独立 Settings 写入仍等待已有事务,真正嵌套仍被拒绝;隔离插件代码替换后可重新开启手动登录。事务探针调用真实 HMR,不替代服务,不进入 npm 包,最小监听器上下文适配见 `DSH-HMR-001`。受保护远程部署独立禁用原生 webserver。`startup-compatibility.spec.ts` 在八版破坏隔离插件副本:`0.2.1-alpha.3` 用不兼容 Host peer 验证 Loader skip,其余七版用不兼容 `engines.dsh`;各版还注入插件自身准入范围,验证导入后的运行拒绝。两路径均须自行失败且无 TCP/HTTP/readiness/WebSocket 回退,不改上游或 Loader 审计。
87
89
 
88
90
  账号配置绑定通过原生 describe 镜像的 `ensure()` API 恢复首次读取失败;已有镜像中的命名空间恢复使用明确注入的 `remote.settings` 传输,并将已接纳值回填到同一镜像。偏好加载期间点击登录会等待共享读取,再按最新接纳的 true/false 值选择入口;加载中不等同于关闭。浏览器回归覆盖首次读取失败、命名空间暂缺,以及两种路由选择的延迟读取。
89
91
 
90
- `0.2.1-rc.2`、`0.2.1-rc.3`、`0.2.1-rc.4` 的原生 Search/Fetch 设置回归覆盖真实设置/凭据域的选择、保存失败和刷新/重启持久化,以及匿名/撤销会话拒绝。全部地址为本地测试地址,请求计数必须为零。`rc-navigation.spec.ts` 在 `0.2.1-rc.3`、`0.2.1-rc.4` 验证全局、会话、右侧栏 More 菜单、原生设置/模型选择及撤销后拒绝;只检查插件市场/Creator 入口可见,不执行安装或外部授权。通过公开 sessions/sessionProjections 构造真实会话的空完成 turn 以展示原生菜单,不发送聊天,不替换快照。官方动态 `/models` 内部语义不在承诺内。
92
+ `0.2.1-rc.2`、`0.2.1-rc.3`、`0.2.1-rc.4`、`0.2.2-alpha.2` 的原生 Search/Fetch 设置回归覆盖真实设置/凭据域的选择、保存失败和刷新/重启持久化,以及匿名/撤销会话拒绝。全部地址为本地测试地址,请求计数必须为零。`rc-navigation.spec.ts` 在 `0.2.1-rc.3`、`0.2.1-rc.4`、`0.2.2-alpha.2` 验证全局、会话、右侧栏 More 菜单、原生设置/模型选择及撤销后拒绝;只检查插件市场/Creator 入口可见,不执行安装或外部授权。通过公开 sessions/sessionProjections 构造真实会话的空完成 turn 以展示原生菜单,不发送聊天,不替换快照。官方动态 `/models` 内部语义不在承诺内。
91
93
 
92
94
  启动维护诊断读取已安装插件的精确声明与显式生命周期记录,同一进程每个精确版本/状态只提示一次,配置/模块 HMR 不重置。三个 Alpha 的 legacy 起算 2026-10-28、14 日窗口、最早资格 2026-11-11(Asia/Shanghai),日期不会停服。六个退役版本记录最后插件 `0.2.0`、退役版本 `0.3.1` 和准备日期 `retiredOn: 2026-10-28`,该日期不是 npm 实际发布时间。单元以模拟时钟确认到期不改变分类;真实 legacy HMR 用例观察同进程去重。必要 API、包身份和安全失败仍拒绝服务。
93
95
 
94
- `browser/host-release.spec.ts` 固定六组真实宿主往返切换:`0.2.1-alpha.4` ↔ `0.2.1-alpha.3`、`0.2.1-alpha.5` ↔ `0.2.1-alpha.4`、`0.2.1-rc.1` ↔ `0.2.1-alpha.5`、`0.2.1-rc.2` ↔ `0.2.1-rc.1`、`0.2.1-rc.3` ↔ `0.2.1-rc.2`、`0.2.1-rc.4` ↔ `0.2.1-rc.3`。同一临时 profile/端口保留页面,检查原生版本提示,刷新后核对认证、原会话和持久设置,再恢复起始版本。只有 `0.2.1-alpha.3` 无 release 元数据并显示未解析;其余目的宿主必须显示真实完整版本。不修改上游源码、版本或依赖图元数据。
96
+ `browser/host-release.spec.ts` 固定七组真实宿主往返切换:`0.2.1-alpha.4` ↔ `0.2.1-alpha.3`、`0.2.1-alpha.5` ↔ `0.2.1-alpha.4`、`0.2.1-rc.1` ↔ `0.2.1-alpha.5`、`0.2.1-rc.2` ↔ `0.2.1-rc.1`、`0.2.1-rc.3` ↔ `0.2.1-rc.2`、`0.2.1-rc.4` ↔ `0.2.1-rc.3`、`0.2.2-alpha.2` ↔ `0.2.1-rc.4`。同一临时 profile/端口保留页面,检查原生版本提示,刷新后核对认证、原会话和持久设置,再恢复起始版本。只有 `0.2.1-alpha.3` 无 release 元数据并显示未解析;其余目的宿主必须显示真实完整版本。不修改上游源码、版本或依赖图元数据。
95
97
 
96
98
  ## 消费固定归档
97
99
 
98
100
  `pnpm verify:packed` 消费已有 tgz,不构建或打包。先记录 SHA-256,再传入归档、该摘要、精确声明的 DSH 版本及一个或多个 suite:
99
101
 
100
102
  ```sh
101
- sha256sum artifacts/dsh-auth-remote-0.3.1.tgz
102
- pnpm verify:packed --archive artifacts/dsh-auth-remote-0.3.1.tgz --sha256 <recorded-sha256> --dsh-version 0.2.1-rc.4 --suite cli --suite browser --suite smoke
103
+ sha256sum artifacts/dsh-auth-remote-0.3.2.tgz
104
+ pnpm verify:packed --archive artifacts/dsh-auth-remote-0.3.2.tgz --sha256 <recorded-sha256> --dsh-version 0.2.2-alpha.2 --suite cli --suite browser --suite smoke
103
105
  ```
104
106
 
105
107
  运行器验证包名/版本及所选宿主声明,将相同字节放到固定制品路径,仅恢复归档中的 dist,因此 CLI 执行与安装比较都使用这份 dist。不安全 tar 条目、摘要变化、未知选择、零真实用例及 skipped/cancelled/todo 用例均失败。Node 对无匹配用例文件产生的通过占位项不计作真实测试。`--test-name-pattern` 可筛选单个 `cli` 或 `browser` suite,报告明确标记为局部,并包含文件、筛选表达式与实际命令。固定专项不能覆盖其筛选/数量要求,每个必需文件均须注册测试。
106
108
 
107
- | Suite | 选择范围 |
108
- | -------------- | ----------------------------------------------------------------------------------------------------------------------- |
109
- | `cli` | 全部 CLI 测试文件 |
110
- | `browser` | 全部浏览器测试文件 |
111
- | `smoke` | 在新建且带标记的 home 中安装并短暂启动归档 |
112
- | `theme` | 精确登录/安全主题与窄屏用例(1 个真实测试) |
113
- | `account` | `0.2.1-alpha.3` 的 startup-compatibility、account-login 与 live-config |
114
- | `host-release` | `0.2.1-alpha.4`、`0.2.1-alpha.5`、`0.2.1-rc.1`、`0.2.1-rc.2`、`0.2.1-rc.3`、`0.2.1-rc.4` 的真实往返切换(1 个真实测试) |
115
- | `rc-bootstrap` | `0.2.1-rc.1` 的 host-release 与 dsh-bootstrap(2 个真实测试) |
109
+ | Suite | 选择范围 |
110
+ | -------------- | ---------------------------------------------------------------------------------------------------------------------------------------- |
111
+ | `cli` | 全部 CLI 测试文件 |
112
+ | `browser` | 全部浏览器测试文件 |
113
+ | `smoke` | 在新建且带标记的 home 中安装并短暂启动归档 |
114
+ | `theme` | 精确登录/安全主题与窄屏用例(1 个真实测试) |
115
+ | `account` | `0.2.1-alpha.3` 的 startup-compatibility、account-login 与 live-config |
116
+ | `host-release` | `0.2.1-alpha.4`、`0.2.1-alpha.5`、`0.2.1-rc.1`、`0.2.1-rc.2`、`0.2.1-rc.3`、`0.2.1-rc.4`、`0.2.2-alpha.2` 的真实往返切换(1 个真实测试) |
117
+ | `rc-bootstrap` | `0.2.1-rc.1` 的 host-release 与 dsh-bootstrap(2 个真实测试) |
116
118
 
117
119
  同一 checkout 的消费以锁保证串行。每个 suite 结束均重新校验输入归档、固定消费归档及恢复的 dist。JSON 报告和测试日志保留在 `.cache/verify-packed/`。smoke 直接在 `.cache/v-*` 新建带内部标记的短目录,确保默认 GitHub 检出路径下的管理 socket 不超过 Linux 路径上限;使用独立 runtime/home,以 `--port 0` 启动,仅读取该子进程公布的实际回环地址,并在相同 profile 检查在线 CLI 状态。既有 `.dev/dsh-home` 和 13090 上的服务保持独立,只清理本次新建的验证根目录。`DSH_VERIFY_ROOT` 是内部入口,拒绝无标记、符号链接及外部路径;普通开发命令保留原有 profile 和端口。
118
120
 
119
121
  ## 独立退役拒绝验证
120
122
 
121
- `verify-retired.mjs` 不扩展 `DSH_TEST_VERSION` 或正向矩阵。它核验同一候选/SHA256SUMS 及已发布 `0.2.0` 的完整性,在两个私有旧 profile 验证真实 CLI 安装拒绝/完整回滚,以及完整不兼容包的原生 peer skip。后一路保留真实旧 peer 解析、连续确认无 TCP/HTTP/readiness/WebSocket 监听并清理进程。六版只在本次迁移最终验收完整运行;后续 full/发布仅运行 `0.2.1-alpha.2`,ordinary 不运行。
123
+ `verify-retired.mjs` 不扩展 `DSH_TEST_VERSION` 或正向矩阵。它核验同一候选/SHA256SUMS 及已发布 `0.2.0` 的完整性,在两个私有旧 profile 验证真实 CLI 安装拒绝/完整回滚,以及完整不兼容包的原生 peer skip。后一路保留真实旧 peer 解析、连续确认无 TCP/HTTP/readiness/WebSocket 监听并清理进程。六版一次性验收属于 `0.3.1` 迁移历史;当前 full/发布仅运行 `0.2.1-alpha.2`,ordinary 不运行。
122
124
 
123
125
  ```sh
124
- node scripts/verify-retired.mjs --archive artifacts/dsh-auth-remote-0.3.1.tgz --sha256 <recorded-sha256> --retired-dsh-version 0.2.1-alpha.2
126
+ node scripts/verify-retired.mjs --archive artifacts/dsh-auth-remote-0.3.2.tgz --sha256 <recorded-sha256> --retired-dsh-version 0.2.1-alpha.2
125
127
  ```
126
128
 
127
129
  六个独立负向目标:`0.1.7-rc.1`、`0.1.7-rc.2`、`0.2.0-rc.1`、`0.2.0-rc.2`、`0.2.1-alpha.1`、`0.2.1-alpha.2`。结果与正向报告分开保存在 `.cache/verify-retired/`。
@@ -130,7 +132,7 @@ node scripts/verify-retired.mjs --archive artifacts/dsh-auth-remote-0.3.1.tgz --
130
132
 
131
133
  `scripts/ci-plan.mjs` 仅在全部变更路径均为 `CHANGELOG.md`、`CHANGELOG.zh-CN.md`、`CONTRIBUTING.md`、`CONTRIBUTING.zh-CN.md`、`LICENSE` 或 `tests/unit/i18n.test.ts` 时选择普通计划。其他任何路径均全量,包括源码、共享测试/helper、package/lock/构建脚本、工作流、README、支持规范与兼容库存。重命名/复制、未知状态、空或不完整差异、异常/有未提交变更的检出也全量。PR 比较真实事件 base/head 并核对合并父提交,push 比较 before/after;缺少提交证据回退全量。
132
134
 
133
- 手动运行、未知事件、每次发布及 UTC 周一 00:00 的定时检查固定 full。所有计划保留七版 CLI/smoke;full 运行七版完整 browser 和 `0.2.1-alpha.2` 独立真实负向任务,ordinary 不运行真实旧宿主负向。普通 browser 固定如下:
135
+ 手动运行、未知事件、每次发布及 UTC 周一 00:00 的定时检查固定 full。所有计划保留八版 CLI/smoke;full 运行八版完整 browser 和 `0.2.1-alpha.2` 独立真实负向任务,ordinary 不运行真实旧宿主负向。普通 browser 固定如下:
134
136
 
135
137
  | 精确 DSH 版本 | 普通 browser 选择 |
136
138
  | --------------- | ----------------- |
@@ -141,5 +143,14 @@ node scripts/verify-retired.mjs --archive artifacts/dsh-auth-remote-0.3.1.tgz --
141
143
  | `0.2.1-rc.2` | `browser` |
142
144
  | `0.2.1-rc.3` | `browser` |
143
145
  | `0.2.1-rc.4` | `browser` |
146
+ | `0.2.2-alpha.2` | `browser` |
144
147
 
145
148
  共享工作流先验证精确矩阵。full 聚合要求 validate、cli-smoke、browser、retired-rejection 全部成功;ordinary 仅接受 retired-rejection 的预定 skipped,其余必须成功。未知 plan、缺失结果、失败/取消或其他 skip 均拒绝。`CI Verify` 还要求 plan/producer 成功,发布固定 full 并继承负向门禁。单 checkout 固定端口测试串行;本地并发需独立源码/dist/制品/runtime/profile、可写 node_modules 副本及网络命名空间,复制安装避免共享 HMR inode 变化。
149
+
150
+ 精确 DSH `0.2.2-alpha.2` 的 `native-transport.spec.ts` 比较真实原生 asset/fallback 文件与 ETag,覆盖 GET/HEAD/304、匿名/撤销携正确 ETag 仍拒绝;真实 bundle/map/chunk 保留 immutable 200,index 不采用 immutable 缓存。四个真实 `/api/remote.mux` 用例覆盖原生 HTTPS/代理、默认/none 压缩、whole-frame 阈值/RSV1、成功 ready 帧和真实到期/撤销;传输和压缩仍由原生 Gateway/ws 实现。
151
+
152
+ 新版 `account-login.spec.ts` 的 source HMR 故障用例在导入失败时保留原实例,再于真实替换实例完成初始化后抛错,验证旧/失败资源清理和原生自动回滚。检查真实 provider fiber、监听器、状态锁 nonce、mux 关闭、认证持久性、恢复后的首次 Settings 保存和最终锁再获取。副本入口使用统一 file URL 与显式原生监听 root;公开日志 exporter 只观测 warn,不替换 HMR。
153
+
154
+ 浏览器语言测试覆盖插件八语、登录回退/记忆、原生已接纳偏好与乐观选择、延迟/不可用/失败读取和保存、存储失败,以及退出/撤销后保留;不改变 DSH 原生语言目录。CLI 在不同环境语言下须固定英语,各种 `--lang` 在 profile 访问前拒绝;退役夹具对已发布 `0.2.0` 保留历史中文合同。
155
+
156
+ `liveshare.spec.ts` 仅在精确 `0.2.2-alpha.2` 注册:真实原生 Host/Owner PKCE/分享 worker/查看页载体和停止操作配本地 Relay 身份/传输替身;viewer 不挂载管理员功能。不宣称真实 Relay/OAuth、访客模型或文件写入已验证。局部筛选报告和文件 placeholder 不认证最终八版归档。