dsh-github-copilot 0.4.0-alpha.116 → 0.4.0-alpha.117
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 +6 -0
- package/README.md +8 -6
- package/README.zh.md +8 -6
- package/deployment-baseline.json +1 -1
- package/lib/client.js +28 -14
- package/lib/client.js.map +1 -1
- package/lib/index.js +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 0.4.0-alpha.117 (prepared)
|
|
4
|
+
|
|
5
|
+
- Separate confirmed Session account selection from quota loading (#337). Preserve correctly attributed quota for follow-mode-only changes without duplicate account or quota reads.
|
|
6
|
+
- Reuse the strict save response, immediately restore account controls and focus, and load a different account's quota independently. Slow or failed quota cannot undo a confirmed save; newer selections and invalidations revoke late responses.
|
|
7
|
+
- Keep continuation consent, post-consent revision reread, native CAS, account isolation and running-turn ownership unchanged. No forced model refresh, Core changes, live calls, installation or restart.
|
|
8
|
+
|
|
3
9
|
## 0.4.0-alpha.116 (prepared)
|
|
4
10
|
|
|
5
11
|
- Add immediate, cross-account High cost marking to existing model-preference rows through strict narrow Remotes and public SettingsForms CAS/readback (#333).
|
package/README.md
CHANGED
|
@@ -23,7 +23,7 @@ Visible Models and Credits resolve missing names for saved accounts without acti
|
|
|
23
23
|
|
|
24
24
|
Adding an account now keeps the device-authorization link, selectable URL, one-time code, Copy code action and Cancel together while authorization is pending. After GitHub authorizes, identity and model verification are shown as a separate phase. Adding never changes the global default; use the existing explicit **Switch** action when ready. Technical diagnostics are secondary, and account/turn identity fallbacks never expose opaque account IDs or infer historical identity from today's settings.
|
|
25
25
|
|
|
26
|
-
**Source candidate: `0.4.0-alpha.
|
|
26
|
+
**Source candidate: `0.4.0-alpha.117` (unreleased). Supported host: official DSH / Windows Desktop `0.2.0-rc.2`.** Earlier DSH pins are historical evidence, not supported installation targets. Publication, profile installation and the version loaded by a running Host are separate states. The versioned commands below are for this candidate after publication, not evidence that its assets exist.
|
|
27
27
|
|
|
28
28
|
## What you can do
|
|
29
29
|
|
|
@@ -80,10 +80,10 @@ Supply any launcher patches with repeated `--patch /absolute/file`. Require `sup
|
|
|
80
80
|
For a **standalone named profile**:
|
|
81
81
|
|
|
82
82
|
```sh
|
|
83
|
-
dsh plugin --profile web add https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.
|
|
83
|
+
dsh plugin --profile web add https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.117/dsh-github-copilot-0.4.0-alpha.117.tgz
|
|
84
84
|
```
|
|
85
85
|
|
|
86
|
-
For **Desktop**, its native package manager accepts `dsh-github-copilot@0.4.0-alpha.
|
|
86
|
+
For **Desktop**, its native package manager accepts `dsh-github-copilot@0.4.0-alpha.117` after publication. Official rc.2's **Desktop-bundled CLI** also supports reserved-profile plugin management; a global/generic `dsh` shim is not equivalent. Qualify the installed entry before use. See [Desktop CLI qualification](./docs/npm-distribution.md#desktop-bundled-cli-on-official-rc2) and the distinct [standalone offline procedure](./docs/npm-distribution.md#controlled-offline-cli-maintenance-for-standalone-profiles). Neither path authorizes registry-policy bypass, peer patches or configuration deletion.
|
|
87
87
|
|
|
88
88
|
After an approved reload/restart:
|
|
89
89
|
|
|
@@ -193,6 +193,8 @@ Configuration is under `github-copilot`. Credentials, endpoint definitions and a
|
|
|
193
193
|
| AUTH, Responses replay-scope or TLS failure | Review [request diagnostics](./docs/model-compatibility-acceptance.md#authentication-replay-and-request-diagnostics) and [usage TLS boundaries](./docs/copilot-usage.md#account-data-boundary). After an exact scope rejection, **Replay recovery** shows the same persistent Session continuation policy: when off, disclose loss and offer **Enable visible-history continuation** or Cancel; when already on, show diagnostic guidance without repeated authorization. No duration or next-turn-only choice. Evidence expiry does not disable the policy. Use native Retry separately; no automatic send/retry or history rewrite, and not a 408 fix. Never reset credentials or disable TLS as an automatic repair. |
|
|
194
194
|
| Hosted search unavailable | Check account/protocol/probe diagnostics; a legacy override stays authoritative until explicitly reset |
|
|
195
195
|
|
|
196
|
+
Confirmed account saves restore controls immediately, independently of quota loading. Changing only follow mode for the same account retains its attributed quota without another read. Switching accounts clears the old quota and loads the new snapshot without blocking further account edits; quota errors do not undo a confirmed selection.
|
|
197
|
+
|
|
196
198
|
The Credits account panel shows the current account and **Switch**. Its dropdown lists only configured accounts, marks the effective account and scrolls long lists internally. **Follow global default** is a separate checkbox: enabling it clears the Session override; disabling it fixes the current account. Choosing any account also fixes it, even if it is today's default. Both actions retain continuation confirmation and revision-checked saving. Account addition belongs only in Models, where one **Manage** disclosure contains account management and shared model preferences. Models retains Add in its dropdown footer without selecting the new account, plus guarded local removal and reauthorization. Neither surface has account search. Exact-ID exclusions are shared across accounts; availability is account-specific. See the [approved experience and interactive mock](./docs/account-management-experience.md).
|
|
197
199
|
|
|
198
200
|
[Visible-history continuation](./docs/session-continuation.md) is configured beside account switching, not permanently above the composer. New unseeded Sessions default on after the feature's first successful activation; existing Sessions and inherited histories remain off unless explicitly authorized. Global defaults affect new Sessions only; Session on/off overrides persist across accounts/restarts until disabled. With continuation off, a different-account switch offers persistent enable, keep off or cancel, without a one-turn mode. Each new enabled turn omits prior encrypted reasoning and embedded summaries, even on the same account; current-turn reasoning, visible messages, tools and disk history remain unchanged. Authorization never auto-sends/retries and is not a quota/context cure. Exact replay failures expose the same policy and require a separate native retry. The pinned Core lacks a public Models deep link; Chat omits the nonfunctional management entry. Full management remains in Settings → Models → GitHub Copilot → Manage.
|
|
@@ -237,14 +239,14 @@ Commit attribution uses `Assisted-by` with the actual tool, never the model prov
|
|
|
237
239
|
GitHub Releases and npm distribute the same original verified tarball. Pin a version; verify Release SHA-256 or npm `dist.integrity`. Never repack an immutable release or move/reuse its tag.
|
|
238
240
|
|
|
239
241
|
```sh
|
|
240
|
-
curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.
|
|
241
|
-
curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.
|
|
242
|
+
curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.117/dsh-github-copilot-0.4.0-alpha.117.tgz
|
|
243
|
+
curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.117/SHA256SUMS
|
|
242
244
|
sha256sum --check SHA256SUMS
|
|
243
245
|
```
|
|
244
246
|
|
|
245
247
|
```powershell
|
|
246
248
|
$expected = (Get-Content .\SHA256SUMS).Split()[0]
|
|
247
|
-
$actual = (Get-FileHash .\dsh-github-copilot-0.4.0-alpha.
|
|
249
|
+
$actual = (Get-FileHash .\dsh-github-copilot-0.4.0-alpha.117.tgz -Algorithm SHA256).Hash.ToLowerInvariant()
|
|
248
250
|
if ($actual -cne $expected) { throw 'Release checksum mismatch' }
|
|
249
251
|
```
|
|
250
252
|
|
package/README.zh.md
CHANGED
|
@@ -21,7 +21,7 @@ Models 和 Chat 共用不透明、随主题适配的账号下拉层;原生菜
|
|
|
21
21
|
|
|
22
22
|
添加账号时,设备授权链接、可选择的网址、一次性授权码、复制授权码和取消操作会同时显示。GitHub 授权完成后,会单独显示身份与可用模型验证阶段。添加账号不会更改全局默认;准备好后仍需显式执行现有的**切换**操作。技术诊断收在次级折叠区;账号/历史 turn 缺少身份时不会暴露不透明账号 ID,也不会根据当前设置推断历史身份。
|
|
23
23
|
|
|
24
|
-
**源码候选版本:`0.4.0-alpha.
|
|
24
|
+
**源码候选版本:`0.4.0-alpha.117`(尚未发布)。支持宿主:官方 DSH / Windows Desktop `0.2.0-rc.2`。** 较早 DSH pin 仅是历史证据,不是当前安装目标。已发布、已安装到 profile、已被运行中的 Host 加载,是三个不同状态。下方带版本的命令适用于候选版本发布后,不代表对应资产已经存在。
|
|
25
25
|
|
|
26
26
|
## 你可以做什么
|
|
27
27
|
|
|
@@ -73,10 +73,10 @@ node package/scripts/check-search-composition.mjs --profile-dir /absolute/profil
|
|
|
73
73
|
**独立具名 profile**:
|
|
74
74
|
|
|
75
75
|
```sh
|
|
76
|
-
dsh plugin --profile web add https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.
|
|
76
|
+
dsh plugin --profile web add https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.117/dsh-github-copilot-0.4.0-alpha.117.tgz
|
|
77
77
|
```
|
|
78
78
|
|
|
79
|
-
**Desktop** 原生包管理器在发布后接受 `dsh-github-copilot@0.4.0-alpha.
|
|
79
|
+
**Desktop** 原生包管理器在发布后接受 `dsh-github-copilot@0.4.0-alpha.117`。官方 rc.2 **Desktop 随附的专属 CLI**也支持管理保留 profile;全局/普通 `dsh` shim 不等价。使用前核验实际安装入口,参见[Desktop CLI 核验](./docs/npm-distribution.md#desktop-bundled-cli-on-official-rc2)及独立的[具名 profile 离线流程](./docs/npm-distribution.md#controlled-offline-cli-maintenance-for-standalone-profiles)。两种路径都不授权绕过包源政策、修改 peer 或删除配置。
|
|
80
80
|
|
|
81
81
|
经批准 reload/restart 后:
|
|
82
82
|
|
|
@@ -186,6 +186,8 @@ HTTP/SSE liveness 默认区分 5 分钟字节 idle 和有界的 10 分钟助手
|
|
|
186
186
|
| AUTH、Responses replay scope 或 TLS 错误 | 查看[请求诊断](./docs/model-compatibility-acceptance.md#authentication-replay-and-request-diagnostics)及[额度 TLS 边界](./docs/copilot-usage.md#account-data-boundary)。精确 scope 拒绝后,**回放恢复**使用同一个持久 Session 降级续聊策略:关闭时说明损失并提供**开启降级续聊**/取消,已开启时只显示诊断,不重复授权。不再选择授权范围或仅下一轮;失败证据过期不会关闭策略。需另行使用原生重试,不自动发送/重试、不改磁盘历史,也不是 408 修复。不自动重置凭据或关闭 TLS。 |
|
|
187
187
|
| Hosted search 不可用 | 检查账号/协议/probe 诊断;旧 override 保留至显式 reset |
|
|
188
188
|
|
|
189
|
+
账号保存确认后立即恢复控件,不等待额度读取。同账号仅改变跟随方式时保留已确认归属的额度,不重复读取;真正换账号时清除旧额度,独立加载新快照,不阻塞后续账号编辑。额度读取失败不会撤销已经确认的账号选择。
|
|
190
|
+
|
|
189
191
|
Credits 账号面板显示当前账号和 **切换**,下拉菜单只列已有账号,为当前实际账号打勾,长列表内部滚动。**跟随全局默认**是独立复选框:开启时清除本会话指定,关闭时固定当前账号;手动选择账号也会固定,即使所选恰好是当前全局默认。两种操作均保持续聊确认和 revision 校验保存。添加账号只留在 Models,其 **管理** 展开账号管理与共享模型偏好,菜单底部添加账号但不自动选中,并保留重新授权与受保护的本地账号移除。两处都没有账号搜索框。按精确模型 ID 共享排除偏好,可用性仍按账号验证。参见[已确认体验与交互 mock](./docs/account-management-experience.md)。
|
|
190
192
|
|
|
191
193
|
[可见历史续聊模式](./docs/session-continuation.md)放在账号切换旁,不再常驻输入框上方。功能首次成功激活后创建的非继承 Session 默认开启;已有 Session、继承历史仍需明确授权。全局默认只影响新 Session,Session 开关跨账号及重启保留,直到关闭。关闭时切换到不同账号,提供持续开启、保持关闭或取消,不再提供仅下一轮模式。启用后的每个新 turn 省略旧加密推理及其内嵌摘要,同账号也适用;当前轮新推理、可见消息、工具记录和磁盘历史不变。授权不自动发送或重试,不解决额度或上下文超限。精确回放失败使用同一个持久策略,用户另行点击原生重试。当前 Core 没有公开 Models 直达 API,Chat 不展示不可用的管理入口;完整管理仍在设置 → 模型 → GitHub Copilot → 管理。
|
|
@@ -230,14 +232,14 @@ Agent 从 `node scripts/agent.mjs describe --json`、`doctor --json`及`plan <ta
|
|
|
230
232
|
GitHub Releases 和 npm 分发同一原始已校验 tarball。固定版本并核验 Release SHA-256 或 npm `dist.integrity`;不重打包不可变 Release、不移动/复用 tag。
|
|
231
233
|
|
|
232
234
|
```sh
|
|
233
|
-
curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.
|
|
234
|
-
curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.
|
|
235
|
+
curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.117/dsh-github-copilot-0.4.0-alpha.117.tgz
|
|
236
|
+
curl -LO https://github.com/cloga/dsh-github-copilot/releases/download/v0.4.0-alpha.117/SHA256SUMS
|
|
235
237
|
sha256sum --check SHA256SUMS
|
|
236
238
|
```
|
|
237
239
|
|
|
238
240
|
```powershell
|
|
239
241
|
$expected = (Get-Content .\SHA256SUMS).Split()[0]
|
|
240
|
-
$actual = (Get-FileHash .\dsh-github-copilot-0.4.0-alpha.
|
|
242
|
+
$actual = (Get-FileHash .\dsh-github-copilot-0.4.0-alpha.117.tgz -Algorithm SHA256).Hash.ToLowerInvariant()
|
|
241
243
|
if ($actual -cne $expected) { throw 'Release checksum mismatch' }
|
|
242
244
|
```
|
|
243
245
|
|
package/deployment-baseline.json
CHANGED
package/lib/client.js
CHANGED
|
@@ -9691,7 +9691,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
9691
9691
|
setChoosingAccount(false);
|
|
9692
9692
|
switchButton.current?.focus();
|
|
9693
9693
|
};
|
|
9694
|
-
const load = (0, react.useCallback)(async (force) => {
|
|
9694
|
+
const load = (0, react.useCallback)(async (force, confirmed) => {
|
|
9695
9695
|
const owner = lifecycle.current;
|
|
9696
9696
|
if (!owner.active || owner.busy || owner.save !== void 0 || accountPresentationChanges.pending() || props.remote === void 0 || document.visibilityState === "hidden") return;
|
|
9697
9697
|
owner.busy = true;
|
|
@@ -9703,8 +9703,14 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
9703
9703
|
const identityOperation = props.accountsRemote === void 0 ? void 0 : (force ? props.accountsRemote.refreshIdentity() : props.accountsRemote.ensureIdentity()).catch(() => void 0);
|
|
9704
9704
|
const [result, identityResult, sessionResult] = await Promise.all([
|
|
9705
9705
|
force ? props.remote.refresh() : props.remote.get(),
|
|
9706
|
-
props.accountsRemote?.get().catch(() => void 0)
|
|
9707
|
-
|
|
9706
|
+
confirmed === void 0 ? props.accountsRemote?.get().catch(() => void 0) : {
|
|
9707
|
+
ok: true,
|
|
9708
|
+
value: confirmed.accounts
|
|
9709
|
+
},
|
|
9710
|
+
confirmed === void 0 ? props.sessionAccount?.get() : {
|
|
9711
|
+
ok: true,
|
|
9712
|
+
value: confirmed
|
|
9713
|
+
}
|
|
9708
9714
|
]);
|
|
9709
9715
|
if (!current()) return;
|
|
9710
9716
|
const sessionView = sessionResult?.ok ? SessionAccountViewSchema.safeParse(sessionResult.value) : void 0;
|
|
@@ -9733,9 +9739,11 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
9733
9739
|
} catch {
|
|
9734
9740
|
if (current()) {
|
|
9735
9741
|
setView(void 0);
|
|
9736
|
-
|
|
9737
|
-
|
|
9738
|
-
|
|
9742
|
+
if (confirmed === void 0) {
|
|
9743
|
+
setAccounts(void 0);
|
|
9744
|
+
setSessionAccount(void 0);
|
|
9745
|
+
setAccountFailed(props.sessionAccount !== void 0);
|
|
9746
|
+
}
|
|
9739
9747
|
setFailed(true);
|
|
9740
9748
|
}
|
|
9741
9749
|
} finally {
|
|
@@ -9804,6 +9812,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
9804
9812
|
const chooseAccount = async (accountId, focus = "switch") => {
|
|
9805
9813
|
const owner = lifecycle.current;
|
|
9806
9814
|
let revision = sessionAccount?.accounts.revision;
|
|
9815
|
+
let quota = view;
|
|
9807
9816
|
if (!owner.active || owner.save !== void 0 || props.sessionAccount === void 0 || revision === void 0) return;
|
|
9808
9817
|
const save = Symbol();
|
|
9809
9818
|
const controller = new AbortController();
|
|
@@ -9834,7 +9843,10 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
9834
9843
|
revision = selection.data.accounts.revision;
|
|
9835
9844
|
setSessionAccount(selection.data);
|
|
9836
9845
|
setAccounts(selection.data.accounts);
|
|
9837
|
-
|
|
9846
|
+
if (quota?.accountId !== selection.data.accountId) {
|
|
9847
|
+
quota = void 0;
|
|
9848
|
+
setView(void 0);
|
|
9849
|
+
}
|
|
9838
9850
|
owner.confirmation = void 0;
|
|
9839
9851
|
setConfirmingAccount(false);
|
|
9840
9852
|
}
|
|
@@ -9850,12 +9862,15 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
9850
9862
|
}
|
|
9851
9863
|
setSessionAccount(parsed.data);
|
|
9852
9864
|
setAccounts(parsed.data.accounts);
|
|
9853
|
-
|
|
9865
|
+
setAccountFailed(false);
|
|
9866
|
+
setFailed(false);
|
|
9867
|
+
const retainedQuota = quota !== void 0 && quota.accountId === parsed.data.accountId && sessionAccount?.accountId === parsed.data.accountId;
|
|
9868
|
+
if (!retainedQuota) setView(void 0);
|
|
9854
9869
|
setChoosingAccount(false);
|
|
9855
9870
|
owner.save = void 0;
|
|
9856
9871
|
setSavingAccount(false);
|
|
9857
|
-
|
|
9858
|
-
if (
|
|
9872
|
+
setRestoreAccountFocus(focus);
|
|
9873
|
+
if (!retainedQuota) load(false, parsed.data);
|
|
9859
9874
|
} catch {
|
|
9860
9875
|
if (owner.active && owner.generation === generation) {
|
|
9861
9876
|
setAccountSaveFailed(true);
|
|
@@ -9874,13 +9889,12 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
9874
9889
|
}
|
|
9875
9890
|
};
|
|
9876
9891
|
(0, react.useLayoutEffect)(() => {
|
|
9877
|
-
if (!open ||
|
|
9892
|
+
if (!open || savingAccount || restoreAccountFocus === void 0) return;
|
|
9878
9893
|
if (restoreAccountFocus === "follow") followCheckbox.current?.focus();
|
|
9879
9894
|
else switchButton.current?.focus();
|
|
9880
9895
|
setRestoreAccountFocus(void 0);
|
|
9881
9896
|
}, [
|
|
9882
9897
|
open,
|
|
9883
|
-
busy,
|
|
9884
9898
|
savingAccount,
|
|
9885
9899
|
restoreAccountFocus
|
|
9886
9900
|
]);
|
|
@@ -10062,7 +10076,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
10062
10076
|
open: choosingAccount,
|
|
10063
10077
|
busy: savingAccount,
|
|
10064
10078
|
maxHeight: 220,
|
|
10065
|
-
disabled: sessionAccount === void 0 || sessionAccount.accounts.revision === void 0 ||
|
|
10079
|
+
disabled: sessionAccount === void 0 || sessionAccount.accounts.revision === void 0 || savingAccount,
|
|
10066
10080
|
onOpenChange: (next) => {
|
|
10067
10081
|
if (!next) collapseAccounts();
|
|
10068
10082
|
else setChoosingAccount(true);
|
|
@@ -10081,7 +10095,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
10081
10095
|
type: "checkbox",
|
|
10082
10096
|
"data-copilot-follow-global": "",
|
|
10083
10097
|
checked: sessionAccount?.source === "global",
|
|
10084
|
-
disabled: sessionAccount === void 0 || sessionAccount.accounts.revision === void 0 ||
|
|
10098
|
+
disabled: sessionAccount === void 0 || sessionAccount.accounts.revision === void 0 || savingAccount,
|
|
10085
10099
|
"aria-describedby": `${id}-follow-hint`,
|
|
10086
10100
|
onChange: (event) => {
|
|
10087
10101
|
const accountId = event.currentTarget.checked ? null : sessionAccount?.accountId;
|