dsh-cliproxyapi-pro 1.5.0 → 1.5.1
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 +5 -0
- package/README.en.md +3 -3
- package/README.md +3 -3
- package/lib/client.js +12 -4
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,11 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to this plugin. Versions follow [Semantic Versioning](https://semver.org/).
|
|
4
4
|
|
|
5
|
+
## 1.5.1 — 2026-10-19
|
|
6
|
+
|
|
7
|
+
### Fixed
|
|
8
|
+
- A missing update endpoint (page updated but DSH still running the previous host code) is no longer reported as "invalid version information": 404/405/501 answers now map to a dedicated "update service unavailable" message that names the real cause and says DSH must be restarted, not merely refreshed.
|
|
9
|
+
|
|
5
10
|
## 1.5.0 — 2026-10-19
|
|
6
11
|
|
|
7
12
|
### Added
|
package/README.en.md
CHANGED
|
@@ -49,7 +49,7 @@ The plugin is published on npm as [`dsh-cliproxyapi-pro`](https://www.npmjs.com/
|
|
|
49
49
|
dsh-cliproxyapi-pro
|
|
50
50
|
```
|
|
51
51
|
|
|
52
|
-
To pin a version, write `dsh-cliproxyapi-pro@1.5.
|
|
52
|
+
To pin a version, write `dsh-cliproxyapi-pro@1.5.1`.
|
|
53
53
|
4. Click **Install**. When it finishes, the dialog offers to enable the plugin right away — accept it.
|
|
54
54
|
|
|
55
55
|
> If downloads are slow in mainland China, open **Registry** next to the input and choose **the mainland China mirror**.
|
|
@@ -78,7 +78,7 @@ In **Add plugin**, or as the `plugin_manager` `target`, you can also enter:
|
|
|
78
78
|
|
|
79
79
|
| Source | What to enter |
|
|
80
80
|
|---|---|
|
|
81
|
-
| A released version | `git+https://github.com/TinyBOOOOM/dsh-cliproxyapi-pro.git#v1.5.
|
|
81
|
+
| A released version | `git+https://github.com/TinyBOOOOM/dsh-cliproxyapi-pro.git#v1.5.1` |
|
|
82
82
|
| Latest development version | `git+https://github.com/TinyBOOOOM/dsh-cliproxyapi-pro.git#main` |
|
|
83
83
|
| Offline package | Download [`dsh-cliproxyapi-pro.tgz`](https://github.com/TinyBOOOOM/dsh-cliproxyapi-pro/releases/latest/download/dsh-cliproxyapi-pro.tgz) (always the latest release) and enter its absolute local path |
|
|
84
84
|
| Local source (development) | Absolute path of a cloned repository; installed as a link, so code changes go live when the plugin reloads |
|
|
@@ -327,7 +327,7 @@ Current DSH versions reject replacing an installed plugin while running. To avoi
|
|
|
327
327
|
A channel is usable only after the maintainer publishes its npm dist-tag. Stable is never presented as an unpublished Beta / Dev build. A channel version no newer than the running version does not offer a downgrade download either.
|
|
328
328
|
|
|
329
329
|
**The update card says "update service unavailable" or "network error"?**
|
|
330
|
-
The collapsed row names the actual cause. **Update service unavailable** means the page runs newer client code than the host plugin
|
|
330
|
+
The collapsed row names the actual cause. **Update service unavailable** means the page runs newer client code than the running host plugin: after installing or upgrading, **restart DSH** (refreshing the page or reloading the plugin is not enough). **Network error** means requests to npmjs or the Mainland China mirror failed; switch the download region and check proxies/firewalls. **Channel unpublished** means that channel has no matching release yet. Expand the card for the matching explanation.
|
|
331
331
|
|
|
332
332
|
**Downloaded the update and restarted, but the version did not change?**
|
|
333
333
|
Downloading and verification do not install anything. Exit DSH, run the card's upgrade command, then start it again. Linked installations do not receive that command; update their source manually to keep the link. If a plugin reload clears the download notice, the offline file remains in the profile's `updates` directory.
|
package/README.md
CHANGED
|
@@ -49,7 +49,7 @@
|
|
|
49
49
|
dsh-cliproxyapi-pro
|
|
50
50
|
```
|
|
51
51
|
|
|
52
|
-
需要固定版本时可以写成 `dsh-cliproxyapi-pro@1.5.
|
|
52
|
+
需要固定版本时可以写成 `dsh-cliproxyapi-pro@1.5.1`。
|
|
53
53
|
4. 点击 **安装**,完成后点击 **立即启用**。
|
|
54
54
|
|
|
55
55
|
> 在中国大陆下载慢,可以点输入框旁的 **安装源**,切换到 **中国大陆镜像源**。
|
|
@@ -78,7 +78,7 @@ dsh plugin --profile <profile 名称> add dsh-cliproxyapi-pro
|
|
|
78
78
|
|
|
79
79
|
| 来源 | 填写内容 |
|
|
80
80
|
|---|---|
|
|
81
|
-
| 某个发布版本 | `git+https://github.com/TinyBOOOOM/dsh-cliproxyapi-pro.git#v1.5.
|
|
81
|
+
| 某个发布版本 | `git+https://github.com/TinyBOOOOM/dsh-cliproxyapi-pro.git#v1.5.1` |
|
|
82
82
|
| 最新开发版 | `git+https://github.com/TinyBOOOOM/dsh-cliproxyapi-pro.git#main` |
|
|
83
83
|
| 离线安装包 | 下载 [`dsh-cliproxyapi-pro.tgz`](https://github.com/TinyBOOOOM/dsh-cliproxyapi-pro/releases/latest/download/dsh-cliproxyapi-pro.tgz)(始终是最新版),填写它的本地绝对路径 |
|
|
84
84
|
| 本地源码(开发用) | 克隆后的仓库目录绝对路径;以链接方式安装,改代码后重载插件即生效 |
|
|
@@ -325,7 +325,7 @@ DSH 使用的 pnpm 可能设置了新版本发布后的等待期(`minimumRelea
|
|
|
325
325
|
只有维护者发布对应 npm dist-tag 后才可使用;插件不会把稳定版伪装成 Beta / 开发版。若通道版本不高于当前版本,也不会提供降级下载。
|
|
326
326
|
|
|
327
327
|
**更新卡片显示「更新服务未就绪」或「网络异常」?**
|
|
328
|
-
收起状态会直接给出原因:**更新服务未就绪**
|
|
328
|
+
收起状态会直接给出原因:**更新服务未就绪** 表示页面已是新版,但运行中的插件宿主代码仍是旧版——安装或升级后必须**重启 DSH**(只刷新页面或重载插件不够);**网络异常** 表示本机到 npm 官方源或国内镜像的请求失败,可切换下载区域、检查代理/防火墙后重试;**通道未发布** 则表示该通道还没有对应版本。展开卡片可看到对应说明。
|
|
329
329
|
|
|
330
330
|
**已经下载,重启后为什么版本没变?**
|
|
331
331
|
下载和校验并不安装。应先退出 DSH、执行卡片提供的升级命令,再启动;本地链接安装不提供该命令,保留链接方式需手动更新源码。若重载插件后下载提示消失,离线包仍在 profile 的 `updates` 目录里。
|
package/lib/client.js
CHANGED
|
@@ -131,7 +131,8 @@ window.__ModuleLoader__.load({
|
|
|
131
131
|
updateCompactStatusUnavailable: "更新服务未就绪",
|
|
132
132
|
updateCompactErrorNetwork: "网络异常",
|
|
133
133
|
updateCompactErrorChannel: "通道未发布",
|
|
134
|
-
updateStatusUnavailableHint: "
|
|
134
|
+
updateStatusUnavailableHint: "无法读取更新服务,可能是插件宿主代码尚未重载:重启 DSH(仅刷新页面不够),或检查更新接口是否可用。",
|
|
135
|
+
updateServiceUnavailableError: "更新服务未就绪:当前运行的插件宿主代码仍是旧版,可能尚未重启 DSH。重启 DSH 后重试。",
|
|
135
136
|
updateSubtitle: "仅更新 CLIProxyAPI 插件自身,不更新 CPA 服务或 DSH 宿主。设置修改后立即保存。",
|
|
136
137
|
updateNewVersion: "新版本",
|
|
137
138
|
updateVersionSummary: "当前版本 {current} · 最新版本 {latest}",
|
|
@@ -302,7 +303,8 @@ window.__ModuleLoader__.load({
|
|
|
302
303
|
updateCompactStatusUnavailable: "Update service unavailable",
|
|
303
304
|
updateCompactErrorNetwork: "Network error",
|
|
304
305
|
updateCompactErrorChannel: "Channel unpublished",
|
|
305
|
-
updateStatusUnavailableHint: "Could not reach the update service; the host plugin code may
|
|
306
|
+
updateStatusUnavailableHint: "Could not reach the update service; the running host plugin code may still be the previous version. Restart DSH (refreshing the page is not enough), or check that the update endpoint is registered.",
|
|
307
|
+
updateServiceUnavailableError: "The update service is not ready: the running host plugin code is still the previous version, so DSH may not have been restarted. Restart DSH and retry.",
|
|
306
308
|
updateSubtitle: "Updates this CLIProxyAPI plugin only, not the CPA server or DSH. Changes to update settings are saved immediately.",
|
|
307
309
|
updateNewVersion: "New Version",
|
|
308
310
|
updateVersionSummary: "Current {current} · Latest {latest}",
|
|
@@ -985,10 +987,12 @@ window.__ModuleLoader__.load({
|
|
|
985
987
|
: "dcpa-dot dcpa-dot-idle";
|
|
986
988
|
}
|
|
987
989
|
|
|
990
|
+
const SERVICE_UNAVAILABLE_STATUS = new Set([404, 405, 501]);
|
|
988
991
|
const UPDATE_ERROR_KEYS = {
|
|
989
992
|
"network-error": "updateNetworkError",
|
|
990
993
|
"invalid-metadata": "updateMetadataError",
|
|
991
994
|
"invalid-response": "updateMetadataError",
|
|
995
|
+
"service-unavailable": "updateServiceUnavailableError",
|
|
992
996
|
"channel-unavailable": "updateChannelUnavailable",
|
|
993
997
|
"unavailable-channel": "updateChannelUnavailable",
|
|
994
998
|
"integrity-error": "updateIntegrityError",
|
|
@@ -1039,7 +1043,9 @@ window.__ModuleLoader__.load({
|
|
|
1039
1043
|
body = await res.json();
|
|
1040
1044
|
} catch {
|
|
1041
1045
|
const failure = new Error("Invalid update response");
|
|
1042
|
-
|
|
1046
|
+
// A missing route (host plugin not reloaded) answers 404/405 with no
|
|
1047
|
+
// update payload; that is "service unavailable", not bad metadata.
|
|
1048
|
+
failure.updateCode = !res.ok && SERVICE_UNAVAILABLE_STATUS.has(res.status) ? "service-unavailable" : "invalid-response";
|
|
1043
1049
|
if (!res.ok) failure.httpStatus = res.status;
|
|
1044
1050
|
throw failure;
|
|
1045
1051
|
}
|
|
@@ -1047,7 +1053,8 @@ window.__ModuleLoader__.load({
|
|
|
1047
1053
|
if (!res.ok || body?.ok === false || !validState ||
|
|
1048
1054
|
payload !== undefined && (body.update.error || body.update.errorCode)) {
|
|
1049
1055
|
const failure = new Error("Update request failed");
|
|
1050
|
-
failure.updateCode = body?.errorCode || body?.update?.errorCode ||
|
|
1056
|
+
failure.updateCode = body?.errorCode || body?.update?.errorCode ||
|
|
1057
|
+
(!validState ? (!res.ok && SERVICE_UNAVAILABLE_STATUS.has(res.status) ? "service-unavailable" : "invalid-response") : null);
|
|
1051
1058
|
failure.httpStatus = !res.ok ? res.status : null;
|
|
1052
1059
|
failure.updateState = validState ? body.update : null;
|
|
1053
1060
|
throw failure;
|
|
@@ -1192,6 +1199,7 @@ window.__ModuleLoader__.load({
|
|
|
1192
1199
|
const compactErrorKey = error
|
|
1193
1200
|
? error.source === "status" ? "updateCompactStatusUnavailable" : "updateCompactError"
|
|
1194
1201
|
: failureCode === "network-error" ? "updateCompactErrorNetwork"
|
|
1202
|
+
: failureCode === "service-unavailable" ? "updateCompactStatusUnavailable"
|
|
1195
1203
|
: failureCode === "channel-unavailable" ? "updateCompactErrorChannel"
|
|
1196
1204
|
: "updateCompactError";
|
|
1197
1205
|
const compactText = loading ? t("updateLoading") : downloading ? t("updateDownloading") : checking ? t("updateChecking") :
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "dsh-cliproxyapi-pro",
|
|
3
|
-
"version": "1.5.
|
|
3
|
+
"version": "1.5.1",
|
|
4
4
|
"description": "Auto-discovery CLIProxyAPI provider and management UI for DeepSeek Harness — multiple accounts, dynamic model sync, capability detection, and visual settings.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"dsh",
|