dsh-github-copilot 0.4.0-alpha.63 → 0.4.0-alpha.64

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
@@ -1,5 +1,10 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.4.0-alpha.64 (prepared)
4
+
5
+ - Omit only explicitly empty completed reasoning shells from managed Responses outgoing payloads, without changing durable history, opaque encrypted content, public summaries or tool call/result pairing (#226).
6
+ - Preserve fail-closed handling for partial, unknown and reference-dependent replay. Existing HTTP-408 retry snapshots may reuse the same omitted shell only when the entire original request and retry scope match; no new retry loop or model switch is introduced.
7
+
3
8
  ## 0.4.0-alpha.63 (prepared)
4
9
 
5
10
  - Restore the completed-reply Auto preference and recorded-reason disclosure on official Desktop by reading ChatNodeStore's public iterable `values()` instead of requiring a JavaScript `Map` (#222). Retain Map support and diagnose an unavailable collection once without querying another turn.
package/README.md CHANGED
@@ -98,7 +98,7 @@ The Host reads GitHub's internal quota endpoint using the existing canonical OAu
98
98
 
99
99
  ## Install and sign in
100
100
 
101
- The commands below target the package version `0.4.0-alpha.63`. Versioned URLs describe the intended release artifacts, not proof that publication or local activation has completed; use them only once that Release and its checksums are available. Install into the profile you use (replace `web` when targeting another profile):
101
+ The commands below target the package version `0.4.0-alpha.64`. Versioned URLs describe the intended release artifacts, not proof that publication or local activation has completed; use them only once that Release and its checksums are available. Install into the profile you use (replace `web` when targeting another profile):
102
102
 
103
103
  Before installing/updating, unpack the **checksum-verified** archive into a temporary directory and run its read-only composition preflight (replace all paths with absolute paths for the intended profile):
104
104
 
@@ -111,10 +111,10 @@ Include any launcher patch files with repeated `--patch /absolute/file` argument
111
111
  For a standalone named profile only, the supported CLI command is:
112
112
 
113
113
  ```sh
114
- dsh plugin --profile web add https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.63/dsh-github-copilot-0.4.0-alpha.63.tgz
114
+ dsh plugin --profile web add https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.64/dsh-github-copilot-0.4.0-alpha.64.tgz
115
115
  ```
116
116
 
117
- For Desktop profiles, use Desktop's native package manager with `dsh-github-copilot@0.4.0-alpha.63` after the same preflight and only when registry access is permitted. Desktop reserves its `desktop` profile from CLI management. If registry access is blocked or unavailable, stop; the documented [controlled offline CLI procedure](./docs/npm-distribution.md#controlled-offline-cli-maintenance-for-standalone-profiles) is not a Desktop workaround.
117
+ For Desktop profiles, use Desktop's native package manager with `dsh-github-copilot@0.4.0-alpha.64` after the same preflight and only when registry access is permitted. Desktop reserves its `desktop` profile from CLI management. If registry access is blocked or unavailable, stop; the documented [controlled offline CLI procedure](./docs/npm-distribution.md#controlled-offline-cli-maintenance-for-standalone-profiles) is not a Desktop workaround.
118
118
 
119
119
  Then open the Models UI listed above, find **GitHub Copilot**, select **Sign in**, and complete the GitHub device-code flow. Plugin installation changes the selected profile; activation follows that profile's normal reload/restart policy.
120
120
 
@@ -161,7 +161,7 @@ Agents should treat the browser authorization as a human handoff, not as a token
161
161
  5. Confirm **Signed in** and inspect the automatic discovery result before asking the user to choose a model. Already-signed-in Models opening ensures missing/stale metadata automatically; fresh ready cache makes no request. Use visible **Retry** for errors or **Manage → Refresh models** for an intentional forced update, not routine setup. Status alone does not discover, and login, metadata and successful model calls remain separate evidence.
162
162
  6. Use **Sign out** only when the user explicitly asks to disconnect the account. It deletes the Copilot credential record but preserves route settings.
163
163
 
164
- GitHub Releases and npm are the default distribution channels for each new version, using the same verified tarball. Pin the version and verify the evidence for the channel used: Release `SHA256SUMS`, and npm `dist.integrity` when installing from npm. Install into Desktop profiles only through Desktop's native package manager; the reserved `desktop` profile is not managed by the DSH CLI. After npm publication is verified, the native manager accepts `dsh-github-copilot@0.4.0-alpha.63`, not a URL or file. Controlled offline CLI maintenance is documented for standalone named profiles only, never Desktop-managed profiles. Follow the mandatory search-composition preflight, backup, single-writer and post-install checks; do not bypass a corporate registry ban, disable TLS verification or restart without separate approval. See [distribution and publication requirements](./docs/npm-distribution.md).
164
+ GitHub Releases and npm are the default distribution channels for each new version, using the same verified tarball. Pin the version and verify the evidence for the channel used: Release `SHA256SUMS`, and npm `dist.integrity` when installing from npm. Install into Desktop profiles only through Desktop's native package manager; the reserved `desktop` profile is not managed by the DSH CLI. After npm publication is verified, the native manager accepts `dsh-github-copilot@0.4.0-alpha.64`, not a URL or file. Controlled offline CLI maintenance is documented for standalone named profiles only, never Desktop-managed profiles. Follow the mandatory search-composition preflight, backup, single-writer and post-install checks; do not bypass a corporate registry ban, disable TLS verification or restart without separate approval. See [distribution and publication requirements](./docs/npm-distribution.md).
165
165
 
166
166
  **Desktop package-update and Web-lifecycle boundaries:** the native manager's `restart-required` result for an in-place installed-package upgrade is authoritative and distinct from plugin-bundle removal/re-add behavior. Any disable, removal, or upgrade involving service recomposition (`cordis.patch.yml`, such as the isolated routed web search layer) may leave dependent entries pending until Desktop is fully exited and cold-restarted. If the native manager reports only entries such as `pending (waiting for service: web)` while this plugin already shows **Off**, the requested disabled state has been persisted; cold-restart Desktop instead of repeatedly toggling or reinstalling the plugin. Other errors are not covered by this guidance and must still be investigated.
167
167
 
@@ -358,6 +358,8 @@ There are no credential-token, API-key, model-catalog, or endpoint settings in t
358
358
 
359
359
  ## Migration and troubleshooting
360
360
 
361
+ Managed Responses requests omit a narrowly recognized empty reasoning shell from the outgoing payload: a nonempty item ID, absent/completed status, an explicitly empty summary array, absent/empty content, no encrypted content, and no unknown fields. Stored history remains unchanged. Nonempty summaries, opaque reasoning, partial signatures, reference-only items and unknown fields are never discarded. This prevents empty SDK signatures from blocking otherwise complete conversation replay; it does not recover missing historical content or introduce automatic model switching.
362
+
361
363
  Existing installations must follow the [single-route migration guide](./docs/single-route-migration.md) before removing a native profile. The plugin does not migrate defaults, presets, active sessions or history for you. Old gateway routes and `COPILOT_GITHUB_TOKEN`-style references are not required; review them separately rather than deleting unrelated user configuration.
362
364
 
363
365
  - **No sign-in control:** confirm the package is loaded in the active profile and use the baseline-specific UI above. Do not add a native provider just to reveal login.
@@ -434,8 +436,8 @@ Report the published Release URL, version, tag/commit and verified asset SHA-256
434
436
  `package.json` declares public npm distribution. A release tag must equal `v${package.json.version}`. Versions use standard SemVer prerelease labels (`alpha`, `beta`, or `rc`), each with its matching npm dist-tag; only stable versions use `latest`. The Release workflow performs the frozen install and complete verification gate, packs once (or recovers the original archive on retry), verifies `SHA256SUMS`, publishes the immutable GitHub Release and then publishes those same bytes to npm through OIDC. Either channel failing means delivery is incomplete. First package creation needs an authorized maintainer; staging requires an existing package and is not a first-package bootstrap. Historical releases are not republished.
435
437
 
436
438
  ```sh
437
- curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.63/dsh-github-copilot-0.4.0-alpha.63.tgz
438
- curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.63/SHA256SUMS
439
+ curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.64/dsh-github-copilot-0.4.0-alpha.64.tgz
440
+ curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.64/SHA256SUMS
439
441
  sha256sum --check SHA256SUMS
440
442
  ```
441
443
 
@@ -443,7 +445,7 @@ PowerShell can verify the same two downloaded files with:
443
445
 
444
446
  ```powershell
445
447
  $expected = (Get-Content .\SHA256SUMS).Split()[0]
446
- $actual = (Get-FileHash .\dsh-github-copilot-0.4.0-alpha.63.tgz -Algorithm SHA256).Hash.ToLowerInvariant()
448
+ $actual = (Get-FileHash .\dsh-github-copilot-0.4.0-alpha.64.tgz -Algorithm SHA256).Hash.ToLowerInvariant()
447
449
  if ($actual -cne $expected) { throw 'Release checksum mismatch' }
448
450
  ```
449
451
 
package/README.zh.md CHANGED
@@ -20,7 +20,7 @@
20
20
 
21
21
  截图来自当前构建 Client 的隔离浏览器 fixture,使用合成 Provider。它只证明已发布配置界面的形态,不证明真实凭据、账号权限、搜索成功或当前 Desktop 已加载。
22
22
 
23
- > 当前文档与安装命令对应版本 `0.4.0-alpha.63`。源码、发布制品、已安装版本和实际加载运行时需分别确认;本地升级和中断会话的重启仍需用户批准。
23
+ > 当前文档与安装命令对应版本 `0.4.0-alpha.64`。源码、发布制品、已安装版本和实际加载运行时需分别确认;本地升级和中断会话的重启仍需用户批准。
24
24
 
25
25
  Web search 路由现在优先显示在插件详情页;宿主不支持详情页插槽时才回退到 **设置 → 模型**或独立 Web search section。搜索子 Fiber 仍独立等待 Remote,不影响账号控件和既有搜索安全检查。
26
26
 
@@ -113,10 +113,10 @@ node package/scripts/check-search-composition.mjs --profile-dir /absolute/profil
113
113
  仅对独立的具名 profile,获准且网络可用时,可通过受支持的 CLI 命令安装:
114
114
 
115
115
  ```sh
116
- dsh plugin --profile web add https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.63/dsh-github-copilot-0.4.0-alpha.63.tgz
116
+ dsh plugin --profile web add https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.64/dsh-github-copilot-0.4.0-alpha.64.tgz
117
117
  ```
118
118
 
119
- Desktop profile 请在完成同样的预检后,使用 Desktop 原生包管理器安装 `dsh-github-copilot@0.4.0-alpha.63`。Desktop 保留 `desktop` profile,CLI 不负责管理。若 registry 被公司封禁或不可用,不要更换网络绕行或使用离线 CLI;请停止。[受控离线 CLI 流程](./docs/npm-distribution.md#controlled-offline-cli-maintenance-for-standalone-profiles)仅适用于独立具名 profile,不适用于 Desktop。
119
+ Desktop profile 请在完成同样的预检后,使用 Desktop 原生包管理器安装 `dsh-github-copilot@0.4.0-alpha.64`。Desktop 保留 `desktop` profile,CLI 不负责管理。若 registry 被公司封禁或不可用,不要更换网络绕行或使用离线 CLI;请停止。[受控离线 CLI 流程](./docs/npm-distribution.md#controlled-offline-cli-maintenance-for-standalone-profiles)仅适用于独立具名 profile,不适用于 Desktop。
120
120
 
121
121
  随后打开上表对应的 Models UI,找到 **GitHub Copilot**,点击 **Sign in** 并完成 GitHub device-code 流程。安装会修改指定 profile;是否立即激活取决于该 profile 的常规 reload/restart 策略。
122
122
 
@@ -163,7 +163,7 @@ Agent 应把浏览器授权视为需要用户完成的 handoff,而不是自行
163
163
  5. 确认 **Signed in** 并检查自动发现结果,再请用户选择模型。已登录时打开 Models 会自动确保缺失/过期元数据,新鲜 ready 缓存不发请求。错误可使用 **Retry**,有意强制更新时使用 **Manage → Refresh models**,不作为常规设置步骤。状态读取本身不发现;登录、元数据与真实调用成功是独立证据。
164
164
  6. 只有用户明确要求断开账号时才使用 **Sign out**;它会删除 Copilot credential record,但保留 route settings。
165
165
 
166
- 每个新版本默认同时分发到 GitHub Releases 和 npm,两个渠道使用同一份已验证 tarball。应固定版本并核对所用渠道的证据:Release 的 `SHA256SUMS`;从 npm 安装时另核对 `dist.integrity`。Desktop profile 只能通过原生 Desktop 包管理器安装;获准且 registry 可用时输入 `dsh-github-copilot@0.4.0-alpha.63`,不是 URL 或本地文件。Desktop 保留 `desktop` profile,不能通过 DSH CLI 管理。受控离线 CLI 维护仅适用于独立具名 profile,不得作为 Desktop 安装绕行方案。[双渠道发布与 OIDC 要求](./docs/npm-distribution.md)保持不变。
166
+ 每个新版本默认同时分发到 GitHub Releases 和 npm,两个渠道使用同一份已验证 tarball。应固定版本并核对所用渠道的证据:Release 的 `SHA256SUMS`;从 npm 安装时另核对 `dist.integrity`。Desktop profile 只能通过原生 Desktop 包管理器安装;获准且 registry 可用时输入 `dsh-github-copilot@0.4.0-alpha.64`,不是 URL 或本地文件。Desktop 保留 `desktop` profile,不能通过 DSH CLI 管理。受控离线 CLI 维护仅适用于独立具名 profile,不得作为 Desktop 安装绕行方案。[双渠道发布与 OIDC 要求](./docs/npm-distribution.md)保持不变。
167
167
 
168
168
  **Desktop package 更新与 Web 生命周期边界:**原生 manager 对已安装 package 原位升级返回的 `restart-required` 是权威结果,与移除/重加 plugin bundle 的行为是两个不同问题。涉及服务重编排补丁(`cordis.patch.yml`,如本插件所采用的隔离路由 Web 搜索层)的停用、移除或升级,可能让依赖条目保持 pending,直到完全退出并冷重启 Desktop。若原生 manager 只报告类似 `pending (waiting for service: web)` 的条目,同时本插件已经显示 **Off**,说明请求的停用状态已经落盘;请冷重启 Desktop,不要反复切换或重装插件。其它错误不属于此提示范围,仍需单独排查。
169
169
 
@@ -369,6 +369,8 @@ Copilot Session 如需更宽的文件或命令权限,必须在调用前选择
369
369
 
370
370
  ## 迁移与排障
371
371
 
372
+ 托管 Responses 请求仅从出站 payload 中省略严格识别的空 reasoning 壳:非空条目 ID、缺省或 completed 状态、显式空 summary 数组、缺省或空 content、没有加密内容且没有未知字段。持久化历史不变。非空摘要、不透明推理、残缺签名、纯引用和未知字段均不会被丢弃。这避免空 SDK 签名阻断其余完整历史的重放,但不会恢复缺失的历史内容,也不会引入自动换模型。
373
+
372
374
  旧安装删除原生 profile 前请遵循[单路由迁移指南](./docs/single-route-migration.md#中文操作说明)。插件不会替用户迁移默认模型、preset、活动会话或历史。旧 gateway route 与 `COPILOT_GITHUB_TOKEN` 类 reference 并非必需,应单独审核,不要连带删除无关配置。
373
375
 
374
376
  - **看不到登录控件:**确认新版 package 实际加载在活动 profile,并使用上表对应的 UI;不要为了显示登录卡片而添加原生 provider。
@@ -445,8 +447,8 @@ node scripts/agent.mjs attribution "DeepSeek Harness (DSH)"
445
447
  `package.json` 声明公开 npm 分发。Release tag 必须严格等于 `v${package.json.version}`。预发布使用 `alpha`、`beta` 或 `rc` 及对应 npm dist-tag,只有稳定版使用 `latest`。Release workflow 执行 frozen install 和完整门禁,只打包一次(重试恢复原始归档),验证 `SHA256SUMS`,发布不可变 GitHub Release,再通过 OIDC 将同一份字节发布到 npm。任一渠道失败都表示交付未完成。首次建包须由获准环境中的维护者完成;staging 要求包已存在,不能代替首次建包。不会批量补发历史版本。
446
448
 
447
449
  ```sh
448
- curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.63/dsh-github-copilot-0.4.0-alpha.63.tgz
449
- curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.63/SHA256SUMS
450
+ curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.64/dsh-github-copilot-0.4.0-alpha.64.tgz
451
+ curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.64/SHA256SUMS
450
452
  sha256sum --check SHA256SUMS
451
453
  ```
452
454
 
@@ -454,7 +456,7 @@ PowerShell 可以对已下载的同一组文件执行:
454
456
 
455
457
  ```powershell
456
458
  $expected = (Get-Content .\SHA256SUMS).Split()[0]
457
- $actual = (Get-FileHash .\dsh-github-copilot-0.4.0-alpha.63.tgz -Algorithm SHA256).Hash.ToLowerInvariant()
459
+ $actual = (Get-FileHash .\dsh-github-copilot-0.4.0-alpha.64.tgz -Algorithm SHA256).Hash.ToLowerInvariant()
458
460
  if ($actual -cne $expected) { throw 'Release checksum mismatch' }
459
461
  ```
460
462
 
@@ -8,7 +8,7 @@
8
8
  },
9
9
  "package": {
10
10
  "name": "dsh-github-copilot",
11
- "version": "0.4.0-alpha.63"
11
+ "version": "0.4.0-alpha.64"
12
12
  },
13
13
  "evidence": {
14
14
  "kind": "source-and-synthetic-test-inventory",
@@ -566,7 +566,11 @@
566
566
  ],
567
567
  "tests": [
568
568
  {"file": "tests/preview-provider.spec.ts", "name": "normalizes only wire item IDs after native serialization while preserving durable replay and tool pairing"},
569
- {"file": "tests/preview-provider.spec.ts", "name": "sends identical normalized bytes on the third Core-style attempt after two HTTP 408s"},
569
+ {"file": "tests/preview-provider.spec.ts", "name": "sends identical normalized bytes after two HTTP 408s (empty reasoning: %s)"},
570
+ {"file": "tests/preview-provider.spec.ts", "name": "omits an empty SDK reasoning signature while preserving opaque reasoning and tool pairing"},
571
+ {"file": "tests/responses-replay-compat.spec.ts", "name": "omits only explicitly empty completed reasoning shells without changing history or tool pairing"},
572
+ {"file": "tests/responses-replay-compat.spec.ts", "name": "does not mistake partial, opaque, nonempty or unknown reasoning data for an empty shell"},
573
+ {"file": "tests/responses-replay-compat.spec.ts", "name": "reuses omitted empty shells only from the exact HTTP-408 snapshot"},
570
574
  {"file": "tests/responses-replay-compat.spec.ts", "name": "refuses a new step, session, signal, cold resume, stale entry and concurrent requests"},
571
575
  {"file": "tests/preview-route.spec.ts", "name": "clears only the matching Session retry cache on %s across fresh Core preparations"},
572
576
  {"file": "tests/preview-route.spec.ts", "name": "classifies \"$message\" in a $envelope Responses 401 locally and reuses the same credential without discovery or refresh"},
package/lib/index.js CHANGED
@@ -1646,7 +1646,7 @@ let GitHubCopilotUsageController = (() => {
1646
1646
  //#endregion
1647
1647
  //#region package.json
1648
1648
  var name$1 = "dsh-github-copilot";
1649
- var version = "0.4.0-alpha.63";
1649
+ var version = "0.4.0-alpha.64";
1650
1650
  //#endregion
1651
1651
  //#region lib/types/probe.js
1652
1652
  /**
@@ -5195,9 +5195,20 @@ function isRecord$1(value) {
5195
5195
  function nonemptyString(value) {
5196
5196
  return typeof value === "string" && value.trim().length > 0;
5197
5197
  }
5198
+ function emptyReasoningShell(item) {
5199
+ return item.type === "reasoning" && nonemptyString(item.id) && (item.status === void 0 || item.status === "completed") && Array.isArray(item.summary) && item.summary.length === 0 && (item.content === void 0 || Array.isArray(item.content) && item.content.length === 0) && item.encrypted_content === void 0 && Object.keys(item).every((key) => [
5200
+ "type",
5201
+ "id",
5202
+ "status",
5203
+ "summary",
5204
+ "content",
5205
+ "encrypted_content"
5206
+ ].includes(key));
5207
+ }
5198
5208
  function normalizeItem(item) {
5199
5209
  if (!isRecord$1(item)) throw new CopilotResponsesReplayError("invalid-payload");
5200
5210
  if (item.type === "item_reference") throw new CopilotResponsesReplayError();
5211
+ if (emptyReasoningShell(item)) return void 0;
5201
5212
  if ((item.type === "message" || item.type === void 0) && (item.role === "user" || item.role === "system" || item.role === "developer")) return item;
5202
5213
  if (!Object.hasOwn(item, "id") || item.id === void 0) return item;
5203
5214
  if (!nonemptyString(item.id)) throw new CopilotResponsesReplayError("invalid-payload");
@@ -5217,7 +5228,7 @@ function normalizeCopilotResponsesPayload(payload) {
5217
5228
  for (const item of payload.input) {
5218
5229
  const normalized = normalizeItem(item);
5219
5230
  changed ||= normalized !== item;
5220
- input.push(normalized);
5231
+ if (normalized !== void 0) input.push(normalized);
5221
5232
  }
5222
5233
  return changed ? {
5223
5234
  ...payload,
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "dsh-github-copilot",
3
3
  "description": "DSH companion for GitHub Copilot sign-in, account-aware model profiles, tool compatibility, and provider-hosted search.",
4
- "version": "0.4.0-alpha.63",
4
+ "version": "0.4.0-alpha.64",
5
5
  "publishConfig": {
6
6
  "access": "public",
7
7
  "registry": "https://registry.npmjs.org/",