dsh-code-server-app 0.3.28 → 0.3.29
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.
|
@@ -62,8 +62,8 @@ let askPanel = null;
|
|
|
62
62
|
let askDialogSupported = false;
|
|
63
63
|
/** 上一份对话流快照(host 只在变化时回传,这里兜住"没变化"的那些轮询)。 */
|
|
64
64
|
let lastThreadSnapshot;
|
|
65
|
-
/**
|
|
66
|
-
let lastThreadRev =
|
|
65
|
+
/** 本扩展**当前持有**的对话流修订号(随请求上报;-1 = 一份都还没有 ⇒ host 必须发). */
|
|
66
|
+
let lastThreadRev = -1;
|
|
67
67
|
/** 扩展根目录(activate 时记下;面板要按它取 webview 产物 URI)。 */
|
|
68
68
|
let extensionRoot = null;
|
|
69
69
|
/** 是否已经确认过 host 端点可达(避免把"IDE 刚起、扩展先加载"误判为断线)。 */
|
|
@@ -412,6 +412,12 @@ async function pollOnce() {
|
|
|
412
412
|
: (result.threadRev !== undefined ? lastThreadSnapshot : undefined);
|
|
413
413
|
if (result.thread !== undefined) lastThreadSnapshot = result.thread;
|
|
414
414
|
if (Number.isSafeInteger(result.threadRev)) lastThreadRev = result.threadRev;
|
|
415
|
+
// 刚开面板、手里还没有任何快照,而 host 说"没变化"(它只看到我们持有 -1)→ 等下一份,别误报
|
|
416
|
+
// "宿主没有对话流能力"(0.3.29)。
|
|
417
|
+
if (result.thread === undefined && lastThreadSnapshot === undefined) {
|
|
418
|
+
refreshAskPanel();
|
|
419
|
+
return;
|
|
420
|
+
}
|
|
415
421
|
if (applySync(askPanel.state, { ...result, thread })) refreshAskPanel();
|
|
416
422
|
}
|
|
417
423
|
}
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "dshcs-editor-bridge",
|
|
3
3
|
"displayName": "DSH Editor Bridge",
|
|
4
4
|
"description": "只读地把编辑器状态(未保存缓冲区、诊断、活动选区)提供给 DSH;右键提问打开 DSH 页面里的悬浮对话对话框(0.2.5;老宿主退回编辑器面板),正文/思考/上下文都用 DSH 官方渲染器,并可就地回答授权请求。由 dsh-code-server-app 插件安装,可禁用。",
|
|
5
|
-
"version": "0.2.
|
|
5
|
+
"version": "0.2.10",
|
|
6
6
|
"publisher": "dsh-code-server-app",
|
|
7
7
|
"license": "MIT",
|
|
8
8
|
"private": true,
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
| react | 18.3.1 | MIT |
|
|
12
12
|
| react-dom | 18.3.1 | MIT |
|
|
13
13
|
|
|
14
|
-
生成时间:2026-09-
|
|
14
|
+
生成时间:2026-09-13T10:00:36.531Z
|
|
15
15
|
渲染器:@deepseek-ai/dsh-client-ui-primitives@0.1.5-rc.2(DSH 部署的界面版本:0.1.5-rc.2)
|
|
16
16
|
设计令牌:@deepseek-ai/dsh-client-ui-theme@0.1.5-rc.2(11 段)
|
|
17
17
|
KaTeX:已打包(公式排版与 DSH 界面一致)
|
package/lib/index.js
CHANGED
|
@@ -1907,10 +1907,12 @@ export async function apply(ctx, config) {
|
|
|
1907
1907
|
const snapshot = bridgeThread.supported()
|
|
1908
1908
|
? bridgeThread.snapshot(watchedSessions())
|
|
1909
1909
|
: { available: false, sessionId: null, cursor: null, rev: 0, entries: [], error: '宿主没有 sessionController.follow(DSH 版本过旧)' };
|
|
1910
|
-
//
|
|
1911
|
-
//
|
|
1912
|
-
|
|
1913
|
-
|
|
1910
|
+
// **按"客户端已经拿到哪一版"决定发不发**(0.3.29 修):0.3.28 比的是宿主自己上次发过的版本,
|
|
1911
|
+
// 于是"面板是后开的"这种情形下宿主认为没变化、什么都不发,面板手里一份快照都没有 ⇒ 旧模型把它
|
|
1912
|
+
// 当成"宿主没有对话流能力"(用户实测到的那条误报)。现在由客户端用 threadRev 声明自己持有的版本;
|
|
1913
|
+
// 不带这个字段的旧扩展一律收整份(不省流量,但绝不误报)。
|
|
1914
|
+
const peerRev = Number.isSafeInteger(body.threadRev) ? body.threadRev : null;
|
|
1915
|
+
const threadChanged = peerRev === null || peerRev !== threadRev || snapshot.available === false;
|
|
1914
1916
|
bridgeThreadRevSent = threadRev;
|
|
1915
1917
|
// 对话流走独立字段:每个会话给有界条目(见 lib/bridge-thread.mjs),
|
|
1916
1918
|
// 授权待决列表也一并回去(面板显示卡片)。
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "dsh-code-server-app",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.29",
|
|
4
4
|
"description": "VS Code (from a code-server release) inside DSH: a right-sidebar tab driven by the plugin's own launcher over the in-process VS Code server (lib/launcher.mjs). Since 0.3.0 the bundle also ships an editor bridge (assets/extensions/dshcs-editor-bridge): a read-only channel between the in-tree VS Code extension host and DSH, giving the agent what only the editor knows (unsaved buffers, language-server diagnostics, the active selection) and letting editor gestures drive the session. Since 0.3.22 the ask panel renders that session's new content with DSH's own Markdown renderer (pinned to the deployed DSH UI version); since 0.3.23 it is a full-width dialog with collapsible thinking rows and can answer approval requests in place — the bridge's only non-read-only route (POST /approve, constrained to pending in-process requests and the outcomes allowed-once/rejected; panel-first for 5 minutes, handed back to the official card the moment the panel closes). The tab claims DSH file addresses (dsh-resource://file/**) by file type (setting claimExtensions), so the product's own produced-file chips, delivered-file previews and inline prose mentions open in the workbench. The IDE is a resident surface moved with Element.moveBefore instead of being remounted, so switching sidebar tabs no longer reloads it. Opening the tab switches the right sidebar to fullscreen by default (setting fullscreenOnOpen). Following a workspace switch is lightweight: the workbench re-navigates with the new ?folder= and the IDE process is not restarted (since 0.2.12). Requires a DSH with the right-sidebar services (sidebarRightTabs/sidebarRight, >= 0.1.5-alpha.1); older DSH versions get a single upgrade notice on the settings page and no other UI. Two serving modes: loopback port (default) or same-origin mount on DSH's own webServer (/code-server, protected by ctx.connection.requestRejection). No code-server Node layer, no argon2, no C++ toolchain.",
|
|
5
5
|
"homepage": "https://github.com/jinsiyu/dsh-code-server-app",
|
|
6
6
|
"repository": {
|
package/vendor/VENDOR.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"vscodeVersion": "1.137.0",
|
|
4
4
|
"productPath": "stable-b11dabdaca0d3369986975be285db92c8795cea5",
|
|
5
5
|
"layout": "vscode-only",
|
|
6
|
-
"preparedAt": "2026-09-
|
|
6
|
+
"preparedAt": "2026-09-13T10:00:35.533Z",
|
|
7
7
|
"source": "registry",
|
|
8
8
|
"node": "v24.21.0",
|
|
9
9
|
"platform": "win32",
|