dsh-github-copilot 0.4.0-alpha.77 → 0.4.0-alpha.78
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/AGENTS.md +2 -1
- package/CHANGELOG.md +6 -0
- package/README.md +9 -9
- package/README.zh.md +9 -9
- package/deployment-baseline.json +6 -2
- package/lib/client.js +40 -7
- package/lib/client.js.map +1 -1
- package/lib/index.js +89 -78
- package/lib/remote.js +21 -1
- package/lib/types/authorization-controller.d.ts +1 -0
- package/lib/types/auto-model-host.d.ts +1 -0
- package/lib/types/model-exclusions.d.ts +8 -0
- package/lib/types/remote.d.ts +22 -1
- package/package.json +1 -1
package/AGENTS.md
CHANGED
|
@@ -147,6 +147,7 @@ These pins document compatibility evidence. They do not authorize creating anoth
|
|
|
147
147
|
- Client activation: package metadata injects DSH remotes and Models UI; `./client` mounts `./remote`.
|
|
148
148
|
- Provider headers: rc.1 validates configured headers through Fetch and reuses Host-owned headers during model discovery.
|
|
149
149
|
- Remote results: the nine ordinary authorization/model-preference methods retain the Zod v4 `GitHubCopilotAuthorizationView` strict codec required by rc.2 and accepted by rc.1. The tenth no-argument `migrationStatus()` method has a separate strict `GitHubCopilotMigrationStatus` codec; it does not change the ordinary auth contract.
|
|
150
|
+
- Single-model saves use the additive `setModelExcluded(modelId, excluded)` Remote with an independent strict `GitHubCopilotModelPreferencesView` result. Preserve the ten existing descriptor identities/codecs. Do not read credentials, discover models or enumerate Sessions on this mutation path; confirm native CAS persistence before returning.
|
|
150
151
|
|
|
151
152
|
When upgrading DSH or pi-ai, inspect the exact tagged public exports and update the baseline, compatibility guard, tests, and docs together. Apply the **official-first policy**: compare each customization's purpose against exact official source/contracts, classify complete/partial/unverified support, choose retain/migrate/retire, and record the remaining gap plus a concrete retirement trigger. Unverified parity is not evidence of absence. Prefer official behavior only after configuration/data migration, safety and runtime acceptance are reviewed; remove redundant paths and their obsolete tests without losing user-visible acceptance coverage. The current comparison is [official-first alpha.2](./docs/official-first-016-alpha2.md).
|
|
152
153
|
|
|
@@ -249,7 +250,7 @@ same turn only and never replays inference. See #249.
|
|
|
249
250
|
|
|
250
251
|
Parent-model following uses the profile-wide `github-copilot.followParentModel` switch (default false), with a single control in the plugin-detail page (#234). Never require per-session enrollment for the ordinary experience. Preserve legacy `parentModelFollow` bindings independently, including when the broad switch is off. `src/parent-model-follow.ts` and the Auto Host integration use public projections and per-turn scoped routing, never descriptor/history/default writes. Child-owned explicit selections win; enabling authorizes replacement of creation-time route snapshots, not removal of later picker history. Only supported native spawn children and managed Copilot parents participate; roots, other providers, fork descriptors and historical dedicated policies remain native. Missing eligible parent evidence fails explicitly. Settings changes preserve admitted turns, and Client saves use one path-level CAS without credentials/discovery. See `docs/parent-model-follow.md` for requirements/mockup and `docs/automatic-model-routing.md` for exact-source evidence.
|
|
251
252
|
|
|
252
|
-
Model preferences must survive the Client's owned-field projection before strict decoding. `excludedModelIds` is a hidden volatile Config leaf, read via `readInlineConfig`; exercise native SettingsForms CAS, fiber preservation and restart persistence, not only map-backed settings mocks. Missing preference
|
|
253
|
+
Model preferences must survive the Client's owned-field projection before strict decoding. `excludedModelIds` is a hidden volatile Config leaf, read via `readInlineConfig`; exercise native SettingsForms CAS, fiber preservation and restart persistence, not only map-backed settings mocks. Missing preference settings leave model rows read-only with named diagnostics and status-only Retry. Unknown exclusion state is not an empty exclusion set. Discovery diagnostics stay in a separate Manage disclosure. Selected models are excludable without scanning Sessions/defaults; the legacy `lockedModelIds` wire leaf stays empty. Check exclusion at new-turn admission through public `agent/request`, preserving only the same Session/turn/model and exact native request signal for subsequent steps/retries. Clear admission on `turn/end`. Direct/unbound requests and new turns remain excluded; never rewrite selections/history or switch models silently. Account/token/metadata/cancellation guards remain independent and revocable.
|
|
253
254
|
|
|
254
255
|
Capture the traced `remote.githubCopilot` namespace once per account UI registration, shared by provider/footer/section renders. Native namespace property reads create fresh proxy identities; rereading during parent renders resets the mounted account controller and can block exclusion changes on redundant status/discovery work. Actual registration teardown and credential/connection invalidation retain their existing safety semantics.
|
|
255
256
|
|
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 0.4.0-alpha.78 (prepared)
|
|
4
|
+
|
|
5
|
+
- Optimize individual Exclude/Restore saves with a strict preferences-only Remote response, avoiding credential/account-status reads and live-session scans (#252). Keep single-row immediate persistence, CAS conflicts, invalidation and failure recovery; no batch UI.
|
|
6
|
+
- Permit exclusion of selected models without rewriting Session/default selections. Preserve already admitted native turns through tool steps and retries, reject excluded models on new turns, and retain account/token/metadata/cancellation guards.
|
|
7
|
+
- Native configuration serialization, file locks and Loader synchronization still gate save completion; no live latency threshold or loaded Desktop upgrade is claimed.
|
|
8
|
+
|
|
3
9
|
## 0.4.0-alpha.77 (prepared)
|
|
4
10
|
|
|
5
11
|
- Resolve automatic compaction pressure and Auto recovery availability from the initiating Agent's preset through the existing public service lookup (#248), including Desktop's isolated compaction groups.
|
package/README.md
CHANGED
|
@@ -106,7 +106,7 @@ The Host reads GitHub's internal quota endpoint using the existing canonical OAu
|
|
|
106
106
|
|
|
107
107
|
## Install and sign in
|
|
108
108
|
|
|
109
|
-
The commands below target the package version `0.4.0-alpha.
|
|
109
|
+
The commands below target the package version `0.4.0-alpha.78`. 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):
|
|
110
110
|
|
|
111
111
|
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):
|
|
112
112
|
|
|
@@ -119,10 +119,10 @@ Include any launcher patch files with repeated `--patch /absolute/file` argument
|
|
|
119
119
|
For a standalone named profile only, the supported CLI command is:
|
|
120
120
|
|
|
121
121
|
```sh
|
|
122
|
-
dsh plugin --profile web add https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.
|
|
122
|
+
dsh plugin --profile web add https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.78/dsh-github-copilot-0.4.0-alpha.78.tgz
|
|
123
123
|
```
|
|
124
124
|
|
|
125
|
-
For Desktop profiles, use Desktop's native package manager with `dsh-github-copilot@0.4.0-alpha.
|
|
125
|
+
For Desktop profiles, use Desktop's native package manager with `dsh-github-copilot@0.4.0-alpha.78` 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.
|
|
126
126
|
|
|
127
127
|
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.
|
|
128
128
|
|
|
@@ -132,9 +132,9 @@ Then open the Models UI listed above, find **GitHub Copilot**, select **Sign in*
|
|
|
132
132
|
2. Select **Sign in with GitHub**. The authorization area expands automatically with a prominent one-time code, **Open GitHub verification page**, **Copy code**, and **Cancel sign-in**. No extra **Manage** click is needed. Recognized Desktop v1 hosts use their existing same-window external-navigation handoff to the system browser instead of a popup; web hosts retain a new tab. If nothing opens, select and copy the displayed verification address into your browser. The plugin cannot confirm that the system browser opened.
|
|
133
133
|
3. Copy the code, open the verification link, and complete authorization in your own GitHub browser session. Copy success/failure is announced accessibly; manual copying remains available. Never paste a GitHub token into DSH.
|
|
134
134
|
4. DSH polls only while authorization is in flight. Successful explicit **Start sign-in** (the **Sign in with GitHub** button), including a UI account switch, forces exactly one bounded discovery after immediate or polled success. The code and verification link clear, the automatic authorization area closes, and the account shows **Signed in** and **Manage**. Manually opened details stay open; cancellation clears the old code. Failures show only a safe stage diagnostic: `COPILOT_AUTHORIZATION_BEGIN_FAILED` means authorization did not complete; `COPILOT_ROUTE_REPAIR_FAILED` means authorization completed but local route repair failed. A failed begin can also show a fixed **latest observed milestone** (`AUTHORIZATION_REQUESTED`, `INTERACTION_PROMPT_OBSERVED`, or `INTERACTION_NOTICE_OBSERVED`). It reports only progress observed through the public interaction callbacks, not the failing operation or a credential commit. The latter route-repair code retains authentication and directs you to **Manage → Repair model configuration**. These codes and milestones do not explain or resolve the underlying sign-in failure; raw provider details are never displayed or logged.
|
|
135
|
-
5. Choose an accepted model under **GitHub Copilot** (stable route ID `github-copilot-preview`). Normal opening/use maintains metadata without requiring **Refresh models**. **Manage → Model preferences** provides search, **All / Enabled / Excluded** filters, and immediate **Exclude/Restore** actions. Excluded exact IDs disappear from the managed picker and
|
|
135
|
+
5. Choose an accepted model under **GitHub Copilot** (stable route ID `github-copilot-preview`). Normal opening/use maintains metadata without requiring **Refresh models**. **Manage → Model preferences** provides search, **All / Enabled / Excluded** filters, and immediate single-model **Exclude/Restore** actions. Excluded exact IDs disappear from the managed picker and new Auto pools; temporarily absent excluded IDs remain restorable. A selected model can be excluded: already admitted native turns keep their model through tool steps and retries, while new turns cannot use it. A fixed selection is not automatically replaced; select another model before its next turn. Exclusion-driven parent renders retain the mounted account controller and metadata without restarting status checks or model discovery. No exclusion rewrites history, changes selection, or mutates account entitlement. **Discovery details** contains metadata diagnostics separately from the model controls. Legacy configuration diagnostics and explicit repair remain available when needed, and the [migration guide](./docs/single-route-migration.md) remains in the documentation.
|
|
136
136
|
|
|
137
|
-
If preferences cannot be read, available account rows remain visible but read-only. Unknown exclusion status is not shown as enabled.
|
|
137
|
+
If preferences cannot be read, available account rows remain visible but read-only. Unknown exclusion status is not shown as enabled. Named diagnostics distinguish unavailable/invalid settings; **Retry** reads Host status only, without refreshing OAuth or discovering models. Failed writes retain the last confirmed state. Individual saves return only strict model preferences, without scanning sessions or reading credentials/full account status. Exclusions use native live, hidden Config fields and path-level settings CAS, so saving does not remount the plugin. Native configuration queue, file-lock and Loader synchronization may still delay confirmation; no optimistic success is shown before persistence completes. Account model discovery alone does not prove that preference settings or model transport are working.
|
|
138
138
|
|
|
139
139
|
### Auto model routing
|
|
140
140
|
|
|
@@ -175,7 +175,7 @@ Agents should treat the browser authorization as a human handoff, not as a token
|
|
|
175
175
|
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.
|
|
176
176
|
6. Use **Sign out** only when the user explicitly asks to disconnect the account. It deletes the Copilot credential record but preserves route settings.
|
|
177
177
|
|
|
178
|
-
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.
|
|
178
|
+
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.78`, 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).
|
|
179
179
|
|
|
180
180
|
**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.
|
|
181
181
|
|
|
@@ -454,8 +454,8 @@ Report the published Release URL, version, tag/commit and verified asset SHA-256
|
|
|
454
454
|
`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.
|
|
455
455
|
|
|
456
456
|
```sh
|
|
457
|
-
curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.
|
|
458
|
-
curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.
|
|
457
|
+
curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.78/dsh-github-copilot-0.4.0-alpha.78.tgz
|
|
458
|
+
curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.78/SHA256SUMS
|
|
459
459
|
sha256sum --check SHA256SUMS
|
|
460
460
|
```
|
|
461
461
|
|
|
@@ -463,7 +463,7 @@ PowerShell can verify the same two downloaded files with:
|
|
|
463
463
|
|
|
464
464
|
```powershell
|
|
465
465
|
$expected = (Get-Content .\SHA256SUMS).Split()[0]
|
|
466
|
-
$actual = (Get-FileHash .\dsh-github-copilot-0.4.0-alpha.
|
|
466
|
+
$actual = (Get-FileHash .\dsh-github-copilot-0.4.0-alpha.78.tgz -Algorithm SHA256).Hash.ToLowerInvariant()
|
|
467
467
|
if ($actual -cne $expected) { throw 'Release checksum mismatch' }
|
|
468
468
|
```
|
|
469
469
|
|
package/README.zh.md
CHANGED
|
@@ -26,7 +26,7 @@ Core 管理。详见[图片兼容性与限制](./docs/image-input-compatibility.
|
|
|
26
26
|
|
|
27
27
|
截图来自当前构建 Client 的隔离浏览器 fixture,使用合成 Provider。它只证明已发布配置界面的形态,不证明真实凭据、账号权限、搜索成功或当前 Desktop 已加载。
|
|
28
28
|
|
|
29
|
-
> 当前文档与安装命令对应版本 `0.4.0-alpha.
|
|
29
|
+
> 当前文档与安装命令对应版本 `0.4.0-alpha.78`。源码、发布制品、已安装版本和实际加载运行时需分别确认;本地升级和中断会话的重启仍需用户批准。
|
|
30
30
|
|
|
31
31
|
Web search 路由现在优先显示在插件详情页;宿主不支持详情页插槽时才回退到 **设置 → 模型**或独立 Web search section。搜索子 Fiber 仍独立等待 Remote,不影响账号控件和既有搜索安全检查。
|
|
32
32
|
|
|
@@ -121,10 +121,10 @@ node package/scripts/check-search-composition.mjs --profile-dir /absolute/profil
|
|
|
121
121
|
仅对独立的具名 profile,获准且网络可用时,可通过受支持的 CLI 命令安装:
|
|
122
122
|
|
|
123
123
|
```sh
|
|
124
|
-
dsh plugin --profile web add https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.
|
|
124
|
+
dsh plugin --profile web add https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.78/dsh-github-copilot-0.4.0-alpha.78.tgz
|
|
125
125
|
```
|
|
126
126
|
|
|
127
|
-
Desktop profile 请在完成同样的预检后,使用 Desktop 原生包管理器安装 `dsh-github-copilot@0.4.0-alpha.
|
|
127
|
+
Desktop profile 请在完成同样的预检后,使用 Desktop 原生包管理器安装 `dsh-github-copilot@0.4.0-alpha.78`。Desktop 保留 `desktop` profile,CLI 不负责管理。若 registry 被公司封禁或不可用,不要更换网络绕行或使用离线 CLI;请停止。[受控离线 CLI 流程](./docs/npm-distribution.md#controlled-offline-cli-maintenance-for-standalone-profiles)仅适用于独立具名 profile,不适用于 Desktop。
|
|
128
128
|
|
|
129
129
|
随后打开上表对应的 Models UI,找到 **GitHub Copilot**,点击 **Sign in** 并完成 GitHub device-code 流程。安装会修改指定 profile;是否立即激活取决于该 profile 的常规 reload/restart 策略。
|
|
130
130
|
|
|
@@ -134,9 +134,9 @@ Desktop profile 请在完成同样的预检后,使用 Desktop 原生包管理
|
|
|
134
134
|
2. 点击 **Sign in with GitHub** 后,验证码区域自动展开,提供醒目的一次性验证码、**Open GitHub verification page**、**Copy code** 和 **Cancel sign-in**。不需要再点一次 **Manage**。识别到 Desktop v1 宿主时,通过现有的同窗口外部导航处理交给系统浏览器,不依赖弹出窗口;网页版仍打开新标签页。如果没有打开,可选中并复制界面显示的验证网址到浏览器。插件无法确认系统浏览器是否已打开。
|
|
135
135
|
3. 复制验证码,打开验证链接,在自己的 GitHub 浏览器会话中完成授权。复制成功/失败均有可访问的反馈;手工复制仍可用。不要把 GitHub token 粘贴到 DSH。
|
|
136
136
|
4. DSH 只在授权进行中轮询。显式 **Start sign-in**(**Sign in with GitHub** 按钮,包括界面切换账号)成功后,无论立即返回还是轮询观察到成功,都只强制执行一次有界发现。验证码和验证链接清除,自动授权区域收起,账号显示 **Signed in、Manage**。手动打开的详情保持展开;取消清除旧验证码。失败仅显示安全的阶段诊断:`COPILOT_AUTHORIZATION_BEGIN_FAILED` 表示授权流程未完成;`COPILOT_ROUTE_REPAIR_FAILED` 表示授权已完成但本地路由修复失败。begin 失败还可以显示固定的“最近观察到的里程碑” (`AUTHORIZATION_REQUESTED`、`INTERACTION_PROMPT_OBSERVED` 或 `INTERACTION_NOTICE_OBSERVED`);它只表示公开 interaction callback 已观察到的进度,不代表失败操作或 credential commit。后者会保留认证,并提示前往 **Manage → Repair model configuration**。这些代码和里程碑不解释或解决底层登录失败,原始 provider 详情不会显示或记录。
|
|
137
|
-
5. 在 **GitHub Copilot** 分组选择接受的模型(稳定路由 ID 为 `github-copilot-preview`)。正常打开/使用会自动维护元数据,无需手动 **Refresh models**。**Manage → Model preferences** 提供搜索、**All / Enabled / Excluded**
|
|
137
|
+
5. 在 **GitHub Copilot** 分组选择接受的模型(稳定路由 ID 为 `github-copilot-preview`)。正常打开/使用会自动维护元数据,无需手动 **Refresh models**。**Manage → Model preferences** 提供搜索、**All / Enabled / Excluded** 筛选,以及逐个立即保存的 **Exclude/Restore** 操作;被排除的精确 ID 会退出托管 picker 与新 turn 的 Auto 候选,暂时不在账号元数据中的排除 ID 仍可恢复。已经选中的模型也可以排除:已准入的原生 turn 在后续工具步骤及重试中保留原模型,新 turn 不得再使用它。固定选择不会自动替换,需要在下一 turn 前另选模型。排除触发父级重绘时,保留已挂载的账号控制器及元数据,不重新启动状态检查或模型发现。排除不会改写历史、切换选择或修改账号权限。发现说明及能力警告收纳在独立的 **Discovery details** 中。
|
|
138
138
|
|
|
139
|
-
|
|
139
|
+
偏好读取失败时,已有账号模型仍以只读列表显示,未知排除状态不会伪装成已启用。明确的诊断码区分设置不可用与设置无效;**Retry** 仅重读 Host 状态,不刷新 OAuth 或发现模型。保存失败保留最后确认的状态。单次保存仅返回严格校验的模型偏好,不扫描会话、不读取凭据或完整账号状态。排除设置使用原生动态隐藏 Config 字段及路径级 CAS,保存无需重新挂载插件。原生配置队列、文件锁及 Loader 同步仍可能延迟确认;实际持久化完成前不会显示保存成功。账号模型发现成功不等于偏好设置或模型调用已正常工作。
|
|
140
140
|
|
|
141
141
|
### Auto 模型路由
|
|
142
142
|
|
|
@@ -177,7 +177,7 @@ Agent 应把浏览器授权视为需要用户完成的 handoff,而不是自行
|
|
|
177
177
|
5. 确认 **Signed in** 并检查自动发现结果,再请用户选择模型。已登录时打开 Models 会自动确保缺失/过期元数据,新鲜 ready 缓存不发请求。错误可使用 **Retry**,有意强制更新时使用 **Manage → Refresh models**,不作为常规设置步骤。状态读取本身不发现;登录、元数据与真实调用成功是独立证据。
|
|
178
178
|
6. 只有用户明确要求断开账号时才使用 **Sign out**;它会删除 Copilot credential record,但保留 route settings。
|
|
179
179
|
|
|
180
|
-
每个新版本默认同时分发到 GitHub Releases 和 npm,两个渠道使用同一份已验证 tarball。应固定版本并核对所用渠道的证据:Release 的 `SHA256SUMS`;从 npm 安装时另核对 `dist.integrity`。Desktop profile 只能通过原生 Desktop 包管理器安装;获准且 registry 可用时输入 `dsh-github-copilot@0.4.0-alpha.
|
|
180
|
+
每个新版本默认同时分发到 GitHub Releases 和 npm,两个渠道使用同一份已验证 tarball。应固定版本并核对所用渠道的证据:Release 的 `SHA256SUMS`;从 npm 安装时另核对 `dist.integrity`。Desktop profile 只能通过原生 Desktop 包管理器安装;获准且 registry 可用时输入 `dsh-github-copilot@0.4.0-alpha.78`,不是 URL 或本地文件。Desktop 保留 `desktop` profile,不能通过 DSH CLI 管理。受控离线 CLI 维护仅适用于独立具名 profile,不得作为 Desktop 安装绕行方案。[双渠道发布与 OIDC 要求](./docs/npm-distribution.md)保持不变。
|
|
181
181
|
|
|
182
182
|
**Desktop package 更新与 Web 生命周期边界:**原生 manager 对已安装 package 原位升级返回的 `restart-required` 是权威结果,与移除/重加 plugin bundle 的行为是两个不同问题。涉及服务重编排补丁(`cordis.patch.yml`,如本插件所采用的隔离路由 Web 搜索层)的停用、移除或升级,可能让依赖条目保持 pending,直到完全退出并冷重启 Desktop。若原生 manager 只报告类似 `pending (waiting for service: web)` 的条目,同时本插件已经显示 **Off**,说明请求的停用状态已经落盘;请冷重启 Desktop,不要反复切换或重装插件。其它错误不属于此提示范围,仍需单独排查。
|
|
183
183
|
|
|
@@ -465,8 +465,8 @@ node scripts/agent.mjs attribution "DeepSeek Harness (DSH)"
|
|
|
465
465
|
`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 要求包已存在,不能代替首次建包。不会批量补发历史版本。
|
|
466
466
|
|
|
467
467
|
```sh
|
|
468
|
-
curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.
|
|
469
|
-
curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.
|
|
468
|
+
curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.78/dsh-github-copilot-0.4.0-alpha.78.tgz
|
|
469
|
+
curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.78/SHA256SUMS
|
|
470
470
|
sha256sum --check SHA256SUMS
|
|
471
471
|
```
|
|
472
472
|
|
|
@@ -474,7 +474,7 @@ PowerShell 可以对已下载的同一组文件执行:
|
|
|
474
474
|
|
|
475
475
|
```powershell
|
|
476
476
|
$expected = (Get-Content .\SHA256SUMS).Split()[0]
|
|
477
|
-
$actual = (Get-FileHash .\dsh-github-copilot-0.4.0-alpha.
|
|
477
|
+
$actual = (Get-FileHash .\dsh-github-copilot-0.4.0-alpha.78.tgz -Algorithm SHA256).Hash.ToLowerInvariant()
|
|
478
478
|
if ($actual -cne $expected) { throw 'Release checksum mismatch' }
|
|
479
479
|
```
|
|
480
480
|
|
package/deployment-baseline.json
CHANGED
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
},
|
|
9
9
|
"package": {
|
|
10
10
|
"name": "dsh-github-copilot",
|
|
11
|
-
"version": "0.4.0-alpha.
|
|
11
|
+
"version": "0.4.0-alpha.78"
|
|
12
12
|
},
|
|
13
13
|
"evidence": {
|
|
14
14
|
"kind": "source-and-synthetic-test-inventory",
|
|
@@ -223,7 +223,7 @@
|
|
|
223
223
|
"desktopPackageSet": "installed-descriptor-audited",
|
|
224
224
|
"managedProviderValidation": "synthetic-tagged-source-runtime",
|
|
225
225
|
"resolvedProfileDiagnostics": "plugin-owned-empty-modelErrors",
|
|
226
|
-
"runtimeTests": ["tests/preview-route.spec.ts", "tests/published-core.spec.ts", "tests/single-route.spec.ts", "tests/search-routing.spec.ts", "tests/routed-web.spec.ts", "tests/deepseek-search-fallback.spec.ts", "tests/tool-schema-compat.spec.ts", "tests/fixtures/alpha2-contracts-core.fixture.ts", "tests/fixtures/compaction-pressure-core.fixture.ts", "tests/remote-codec.spec.ts", "tests/dual-model-projection.spec.ts", "tests/fixtures/scoped-compaction-core.fixture.ts", "tests/fixtures/session-context-core.fixture.ts", "tests/fixtures/remote-core.fixture.ts"]
|
|
226
|
+
"runtimeTests": ["tests/preview-route.spec.ts", "tests/published-core.spec.ts", "tests/single-route.spec.ts", "tests/search-routing.spec.ts", "tests/routed-web.spec.ts", "tests/deepseek-search-fallback.spec.ts", "tests/tool-schema-compat.spec.ts", "tests/fixtures/alpha2-contracts-core.fixture.ts", "tests/fixtures/compaction-pressure-core.fixture.ts", "tests/remote-codec.spec.ts", "tests/dual-model-projection.spec.ts", "tests/fixtures/scoped-compaction-core.fixture.ts", "tests/fixtures/model-exclusions-core.fixture.ts", "tests/fixtures/session-context-core.fixture.ts", "tests/fixtures/remote-core.fixture.ts"]
|
|
227
227
|
}
|
|
228
228
|
],
|
|
229
229
|
"packages": [
|
|
@@ -549,6 +549,8 @@
|
|
|
549
549
|
{"file": "src/preview-route.ts", "marker": "modelErrors: new Map<string, string>()"},
|
|
550
550
|
{"file": "src/preview-route.ts", "marker": "ctx.llm.registerAdapter"},
|
|
551
551
|
{"file": "src/preview-route.ts", "marker": "createAccountModelSource"},
|
|
552
|
+
{"file": "src/model-exclusions.ts", "marker": "class ModelExclusionTurns"},
|
|
553
|
+
{"file": "src/remote.ts", "marker": "githubCopilot.setModelExcluded"},
|
|
552
554
|
{"file": "src/preview-provider.ts", "marker": "native.streamSimple"},
|
|
553
555
|
{"file": "src/request-body-timeout.ts", "marker": "COPILOT_REQUEST_BODY_TIMEOUT"},
|
|
554
556
|
{"file": "src/response-error-body.ts", "marker": "readResponseErrorJson"},
|
|
@@ -562,6 +564,8 @@
|
|
|
562
564
|
{"file": "tests/inline/apply.spec.ts", "name": "delegates Anthropic in-band system authority before probing at position %s"},
|
|
563
565
|
{"file": "tests/preview-route.spec.ts", "name": "discovers mixed and unseen account models without model-name routing rules"},
|
|
564
566
|
{"file": "tests/preview-route.spec.ts", "name": "uses unmodified stock LlmRuntime preparation and leaves canonical model registration alone"},
|
|
567
|
+
{"file": "tests/fixtures/model-exclusions-core.fixture.ts", "name": "keeps native tool steps in an admitted turn after exclusion and enforces exclusion on the next turn (%s)"},
|
|
568
|
+
{"file": "tests/authorization-controller.spec.ts", "name": "answers a narrow single-model save without reading credentials or enumerating sessions"},
|
|
565
569
|
{"file": "tests/preview-route.spec.ts", "name": "replays opaque reasoning and tool-call identities through the native adapter on a second turn"},
|
|
566
570
|
{"file": "tests/preview-route.spec.ts", "name": "enriches only a verified 408 while preserving native failure classification and retry ownership"},
|
|
567
571
|
{"file": "tests/preview-provider.spec.ts", "name": "observes verified %s timeout without changing bytes, Response, native retries or credential ownership"},
|
package/lib/client.js
CHANGED
|
@@ -5791,6 +5791,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
5791
5791
|
]).optional()
|
|
5792
5792
|
}).strict();
|
|
5793
5793
|
const result = strictRemoteCodec(GITHUB_COPILOT_AUTHORIZATION_VIEW_TYPE_SYMBOL, GitHubCopilotAuthorizationViewSchema);
|
|
5794
|
+
const GitHubCopilotModelPreferencesViewSchema = GitHubCopilotAuthorizationViewSchema.shape.modelPreferences.unwrap();
|
|
5794
5795
|
const GITHUB_COPILOT_MIGRATION_STATUS_TYPE_SYMBOL = "dsh-github-copilot#GitHubCopilotMigrationStatus";
|
|
5795
5796
|
const selectionSchema = object({
|
|
5796
5797
|
provider: string().min(1).max(512),
|
|
@@ -5871,6 +5872,25 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
5871
5872
|
}],
|
|
5872
5873
|
result
|
|
5873
5874
|
})),
|
|
5875
|
+
{
|
|
5876
|
+
id: "dsh-github-copilot:githubCopilot.setModelExcluded",
|
|
5877
|
+
service: "githubCopilotAuthorization",
|
|
5878
|
+
namespace: "githubCopilot",
|
|
5879
|
+
method: "setModelExcluded",
|
|
5880
|
+
invocation: direct,
|
|
5881
|
+
parameters: [{
|
|
5882
|
+
name: "modelId",
|
|
5883
|
+
wire: "modelId",
|
|
5884
|
+
source: "json",
|
|
5885
|
+
codec: strictRemoteCodec("dsh-github-copilot#GitHubCopilotModelId", string().min(1).max(512))
|
|
5886
|
+
}, {
|
|
5887
|
+
name: "excluded",
|
|
5888
|
+
wire: "excluded",
|
|
5889
|
+
source: "json",
|
|
5890
|
+
codec: strictRemoteCodec("dsh-github-copilot#GitHubCopilotModelExcluded", boolean())
|
|
5891
|
+
}],
|
|
5892
|
+
result: strictRemoteCodec("dsh-github-copilot#GitHubCopilotModelPreferencesView", GitHubCopilotModelPreferencesViewSchema)
|
|
5893
|
+
},
|
|
5874
5894
|
{
|
|
5875
5895
|
id: "dsh-github-copilot:githubCopilot.migrationStatus",
|
|
5876
5896
|
service: "githubCopilotAuthorization",
|
|
@@ -8288,7 +8308,6 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
8288
8308
|
const available = models?.models ?? [];
|
|
8289
8309
|
const settingsKnown = preferences !== void 0 && preferences.revision !== void 0;
|
|
8290
8310
|
const excluded = new Set(preferences?.excludedModelIds ?? []);
|
|
8291
|
-
const locked = new Set(preferences?.lockedModelIds ?? []);
|
|
8292
8311
|
const diagnostic = error ?? preferences?.error ?? (preferences === void 0 ? "COPILOT_MODEL_PREFERENCES_UNAVAILABLE" : void 0);
|
|
8293
8312
|
const writable = preferences?.writable === true && settingsKnown;
|
|
8294
8313
|
const rows = [...available.map((model) => ({
|
|
@@ -8313,7 +8332,23 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
8313
8332
|
setError(void 0);
|
|
8314
8333
|
setErrorModel(modelId);
|
|
8315
8334
|
try {
|
|
8316
|
-
|
|
8335
|
+
if (modelId !== void 0) {
|
|
8336
|
+
const result = await props.remote.setModelExcluded(modelId, !restore);
|
|
8337
|
+
if (!current()) return;
|
|
8338
|
+
if (!result.ok) {
|
|
8339
|
+
setError("COPILOT_MODEL_EXCLUSION_SAVE_FAILED");
|
|
8340
|
+
return;
|
|
8341
|
+
}
|
|
8342
|
+
const parsed = GitHubCopilotModelPreferencesViewSchema.safeParse(result.value);
|
|
8343
|
+
if (!parsed.success) {
|
|
8344
|
+
setError("COPILOT_MODEL_PREFERENCES_UNAVAILABLE");
|
|
8345
|
+
return;
|
|
8346
|
+
}
|
|
8347
|
+
setPreferences(parsed.data);
|
|
8348
|
+
setError(parsed.data.error);
|
|
8349
|
+
return;
|
|
8350
|
+
}
|
|
8351
|
+
const result = await props.remote.status();
|
|
8317
8352
|
if (!current()) return;
|
|
8318
8353
|
if (!result.ok) {
|
|
8319
8354
|
setError("COPILOT_MODEL_EXCLUSION_SAVE_FAILED");
|
|
@@ -8345,7 +8380,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
8345
8380
|
return (0, react.createElement)("details", { "data-dsh-github-copilot-model-preferences": true }, (0, react.createElement)("summary", null, settingsKnown ? `Model preferences · ${visibleCount} enabled · ${excluded.size} excluded` : "Model preferences · Read-only"), (0, react.createElement)("p", { style: {
|
|
8346
8381
|
fontSize: "14px",
|
|
8347
8382
|
marginBlock: "12px"
|
|
8348
|
-
} }, "Excluded models disappear from the managed picker and
|
|
8383
|
+
} }, "Excluded models disappear from the managed picker and cannot start a new turn, including Auto. An admitted turn keeps its model. Fixed selections are not changed; select another model before the next turn. Restoring a model does not select it."), diagnostic === void 0 ? null : (0, react.createElement)("div", {
|
|
8349
8384
|
role: "alert",
|
|
8350
8385
|
"data-dsh-github-copilot-model-preferences-error": true,
|
|
8351
8386
|
style: {
|
|
@@ -8408,8 +8443,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
8408
8443
|
}
|
|
8409
8444
|
}, filtered.map((model) => {
|
|
8410
8445
|
const isExcluded = excluded.has(model.id);
|
|
8411
|
-
const
|
|
8412
|
-
const disabled = !writable || busyModel !== void 0 || !isExcluded && isLocked;
|
|
8446
|
+
const disabled = !writable || busyModel !== void 0;
|
|
8413
8447
|
return (0, react.createElement)("li", {
|
|
8414
8448
|
key: model.id,
|
|
8415
8449
|
style: {
|
|
@@ -8424,7 +8458,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
8424
8458
|
minWidth: 0,
|
|
8425
8459
|
overflowWrap: "anywhere",
|
|
8426
8460
|
fontSize: "14px"
|
|
8427
|
-
} }, (0, react.createElement)("strong", null, model.name), (0, react.createElement)("br"), (0, react.createElement)("code", null, model.id), (0, react.createElement)("span", null, !settingsKnown ? " · Exclusion status unknown" : isExcluded ? " · Excluded" : " · Enabled"), model.available ? null : (0, react.createElement)("span", null, " · Temporarily absent from account metadata"),
|
|
8461
|
+
} }, (0, react.createElement)("strong", null, model.name), (0, react.createElement)("br"), (0, react.createElement)("code", null, model.id), (0, react.createElement)("span", null, !settingsKnown ? " · Exclusion status unknown" : isExcluded ? " · Excluded" : " · Enabled"), model.available ? null : (0, react.createElement)("span", null, " · Temporarily absent from account metadata"), errorModel === model.id && error !== void 0 ? (0, react.createElement)("span", {
|
|
8428
8462
|
role: "status",
|
|
8429
8463
|
style: {
|
|
8430
8464
|
display: "block",
|
|
@@ -8440,7 +8474,6 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
8440
8474
|
disabled,
|
|
8441
8475
|
"aria-label": `${isExcluded ? "Restore" : "Exclude"} ${model.name}`,
|
|
8442
8476
|
onClick: () => update(model.id, isExcluded),
|
|
8443
|
-
title: !isExcluded && isLocked ? "Select another fixed model before excluding this one." : void 0,
|
|
8444
8477
|
"data-dsh-github-copilot-model-action": isExcluded ? "restore" : "exclude",
|
|
8445
8478
|
"data-model-id": model.id
|
|
8446
8479
|
}, busyModel === model.id ? "Saving…" : isExcluded ? "Restore" : "Exclude"));
|