You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Bug] DSH client upstream health banner has styling issues and does not auto-dismiss | [Bug] DSH 客户端上游健康横幅样式异常且不自动消失 #5701
changed the title [-][Bug] DSH 客户端上游健康横幅样式异常且不自动消失[/-][+][Bug] DSH client upstream health banner has styling issues and does not auto-dismiss | [Bug] DSH 客户端上游健康横幅样式异常且不自动消失[/+]on Nov 5, 2026
Upgraded to v0.1.213 (133f352) on macOS / DSH desktop (native bundle lane, dsh:desktop) and re-checked. Confirming the 5-minute expiry from #5574 is in the shipped build, plus one gap that still keeps a banner alive in a specific case.
so GET /__bili/upstreams no longer reports an alert row whose lastSeen is older than 5 minutes. ALERT_KINDS also gained upstream-unreachable.
Upgrade path that worked on this box (bili self-update is what I'd expect to do it, but it timed out against the registry here):
node dist/index.js update → check failed: TimeoutError: The operation was aborted due to timeout (its own registry probe, 5s); npm itself was fine against registry.npmmirror.com and reported 0.1.213.
So I installed the package into a scratch prefix and rsync'd it over $DSH_HOME/profiles/desktop/node_modules/billion-context (keeping the nested node_modules/zod), bumped the profile package.json dep spec to 0.1.213, then POST /__bili/shutdown.
The host re-spawned the proxy by itself on the next request: new pid, startedAt fresh, /__bili/health → {"version":"0.1.213","commit":"133f3525c"}, /__bili/status → stale:false, advisory:null, doctor --json → diskVersion 0.1.213 / runningVersion 0.1.213 / verdict ok. In-memory alerts/circuits were reset by the restart, which on its own already cleared the stale row.
Remaining gap (relevant to #5948 / #5703): only alerts expire. circuits still have no time-based eviction — an entry is deleted only by recordUpstreamCircuitSuccess (i.e. the first response from that host) or by MAX_CIRCUITS eviction. And getUpstreamHealthReport merges it back in:
So if a host trips CIRCUIT_OPEN_AFTER = 3 and then never returns a single response, the banner keeps rendering that host (its firstSeen/lastSeen are now synthesized from openedAt/lastFailure.at) even though every alert row behind it has been pruned. Expiry of a quiet circuit after a few minutes, or excluding a circuit with no fresh failure from the health report, would close that.
Original repro on 0.1.212 for the record: company VPN dropped, model traffic to an internal OpenAI-compatible gateway (10.10.180.57:18086, provider kept in the profile for on-VPN use) went connect-timeout, count: 3, circuit: open, lastSeen frozen an hour earlier — and it survived quitting/relaunching the app, because the proxy is a detached process that the host re-attaches to rather than restarts.
getUpstreamHealthReport() 先跑 pruneStaleAlerts(now) 清掉过期告警行,但合并电路时是 for (const e of circuits.values()) { if (e.state.openedAt !== null) touch(e.state.host).circuit = e.state }(v0.1.213 的 src/upstream-alerts.ts:403–404)—— 任何 open 状态的电路无条件并入报告,没有时间判断;
Closing summary (English, per your last comment): both parts of this report are now fixed in PR #5703 (branch rebased onto current master 3ac3e95, head 8fc410c):
Banner chrome + manual dismiss (f06e363fb, client src/agent/dsh-native-client.ts): border/background alpha reduced (.5→.35 / .1→.08), radius 8→10px, padding 8px 12px→10px 14px, light shadow added, text color inherits host tokens; new ✕ button hides the banner until the set of failing hosts changes (count/ETA churn within the same set does not re-surface it; any new or changed failure does).
Quiet open circuits (8fc410c57, server src/upstream-alerts.ts): the exact gap you verified in the v0.1.213 dist — an open circuit with no fresh failure was merged into GET /__bili/upstreams unconditionally. The health-report projection now drops an open circuit whose last activity (lastFailure.at ?? openedAt) is older than the same ALERT_STALE_MS = 5min boundary used for alert rows. Only the projection is filtered: the circuit state machine (fail-fast block reason, half-open probe scheduling, getOpenUpstreamCircuits() diagnostics) is untouched, so a fresh failure re-surfaces the row on the next read. Bidirectional regression tests pin both directions.
Outcome: local targeted suites green (tests/upstream-alerts.test.ts 14/14, tests/dsh-settings-ui.test.ts 27/27, tsc clean); remote CI fully green on head 8fc410c (main CI 27 success + 1 expected skip, all e2e lanes success). For your VPN-drop repro specifically: once a release ships these two commits, that banner self-dismisses ≤10s after the host has been quiet for 5 minutes, and can be ✕-dismissed immediately at any time.
No new config/env introduced; merge authority stays with the owner — I can't merge PRs.
Additional data point (Windows 10 x64 / DSH desktop 0.2.2-rc.1 / billion-context 0.1.213), 2026-11-11 — relevant to the "overlaps host UI" part that #5703 currently marks as out of scope.
Repro: an image-generation request routed through the bili proxy to Google (cloudcode-pa.googleapis.com and three sibling hosts) hit connect-timeout. The banner 3 upstreams unavailable (each row ... · connect-timeout ×1) appeared in the top-left of the window and sat directly on top of the sidebar's "New session" button and the app menu. Clicks on those controls did not go through while the banner was visible. It disappeared on its own after a few seconds, but there was no way to dismiss it earlier.
Observation on the overlap: even if the shell.overlay slot position is decided by the DSH host, the banner's own box still intercepts pointer events. bili can control that part from its side without moving the slot: e.g. pointer-events: none on the banner container (and pointer-events: auto only on the new ✕ button), so the banner never blocks controls underneath it. Might be worth adding to #5703 alongside the ✕.
Also noteworthy: a single transient connect-timeout ×1 per host (not 3 consecutive failures / not an open circuit) was enough to raise the banner, so one failed request to an unrelated third-party endpoint produces a large red box over the navigation.
Thanks for the data point — verified both observations against the source and acted on the first one.
1. Overlap / blocked clicks — fixed. You're right that even if the shell.overlay slot position is host-decided, the banner's own box intercepting pointer events is bili's responsibility. I adopted your exact suggestion, commit 1e44cd5ef2 now on PR #5703 (branch also re-synced to current master dc041dd while I was at it):
banner container: pointer-events: none — it never blocks the New-session button / app menu underneath;
✕ button: pointer-events: auto — the one interactive element keeps working.
Pinned by regression tests (tests/dsh-settings-ui.test.ts asserts both values): local suite 28/28 green, tsc clean. CI is running on the new head; I'll report the verdict here.
2. Why it vanished after a few seconds on your box: you're on v0.1.213, which already carries #5574's 5-minute stale expiry and#1682's success-clear — a successful retry to those Google hosts clears their alert rows on the next 10s poll, so a transient blip self-heals quickly. What was missing before this PR was manual dismissal (now ✕) and click-through (now done); the quiet-circuit expiry gap @chuilian found is also in this PR.
3. Single connect-timeout ×1 raising the banner: confirmed — any non-empty /__bili/upstreams report renders the banner, there is no count threshold today. Changing that is a product decision (hiding real failures behind a threshold vs. occasional transient noise), so I'm NOT changing it silently — options, costs and my recommendation are in my next comment (🔶 需要决策), default behavior if nobody decides: keep current visibility.
Additional data point — and a note on the "position overlap" half that PR #5703 leaves out of scope.
Environment: Windows 11 Pro (build 26100) · DSH desktop-runtime 0.2.2-rc.5 (Electron) · billion-context 0.1.218 (459b5d23a).
Status on latest: as of 2026-12-04 the shipped 0.1.218 still renders the original banner — neither #5703 nor #8142 is merged — so all three symptoms from the report still reproduce in the current release.
Repro: the unreachable "upstream" here is the local model gateway itself (Magpie on 127.0.0.1:3425), not a remote vendor. When that local gateway is restarted / down, GET /__bili/upstreams returns one row 127.0.0.1:3425 · connect-refused ECONNREFUSED ×3 · 约 3s 后重试, and the red banner appears at the window top-left, over the sidebar logo and the "New session" entry: hardcoded high-saturation red, no ✕ / no dismiss besides waiting for recovery, and the box swallows clicks on the sidebar controls underneath it.
One point #5703 does not cover, and that is fixable client-side — the top-left placement.#5703 sets pointer-events:none + softens chrome + adds ✕, but the banner is still an in-flow child of DSH's shell.overlay, whose layer is position:absolute; inset:0; pointer-events:none with no layout (dsh-client-ui-layout/src/client/AppFrame.module.css.overlayLayer). A plain in-flow child therefore lands at that layer's (0,0). Moving the slot is host-side — agreed — but the banner's own box can position itself: the host Toast uses position: fixed; top:40px; left:50%; transform:translateX(-50%) (dsh-web-frontend toast CSS), so mirroring that on the banner puts it top-center instead of over the sidebar, with no host change. Worth folding into the placement discussion of #5703.
Not a new defect — same family as #5701; posting as (a) confirmation it survives to 0.1.218 / 0.2.2-rc.5, and (b) the positioning root cause plus a client-side fix #5703 could pick up.
Thanks for the data point and the positioning analysis — both verified against the source and acted on.
Status on 0.1.218: confirmed. The fix for this issue (PR #5703) is still open/unmerged, so all three symptoms reproduce in the current release. Your report matches what we have on file.
The positioning point — you're right, and it's now fixed in #5703. The earlier scoping marked the top-left placement as "host-side, out of scope" on the assumption that bili could only control its box's size/padding, not its position. Your analysis corrects that: the shell.overlay layer is position:absolute; inset:0 with no layout, so the banner (an in-flow child) lands at the layer's (0,0) — top-left, over the sidebar. The previous commit's pointer-events:none made it click-through, but it still visually covered the sidebar. The banner's own box can position itself, so I added position: fixed; top: 40px; left: 50%; transform: translateX(-50%) (mirroring the host Toast) — it now sits top-center, clearing the sidebar chrome, with no host-side slot move.
Pushed to PR #5703 (commit fade4de24). Targeted suite 28/28 green, typecheck clean; CI running on the new head. The regression test pins the four positioning values; the actual top-center rendering rides on the host's overlay layer not having a transformed ancestor (your Toast evidence supports that).
Context worth flagging for the owner: there's a second, competing PR — #8142 — that takes a different approach to the same issue: it replaces the persistent banner with a one-shot host Toast (theme tokens, auto-dismiss, fires only on state change). If that direction is preferred, it supersedes #5703 — and the positioning is handled for free, since a host Toast is already top-center by the host's own CSS. My positioning fix is specific to the banner approach (#5703); it's the answer if #5703 is the one that ships. The choice between the two is the owner's call.
Activity
[-][Bug] DSH 客户端上游健康横幅样式异常且不自动消失[/-][+][Bug] DSH client upstream health banner has styling issues and does not auto-dismiss | [Bug] DSH 客户端上游健康横幅样式异常且不自动消失[/+]ranxianglei commentedon Nov 5, 2026
(ai: qwen/qwen3.8-27b)
查重:同家族但机制不同——「不自动消失」这一条与已关闭的 #5572(DSH overlay 在死掉的 loopback shim 端口上永久卡住)重复,该缺陷已在 master 修复(commit 8b05d23:stale 告警行 5 分钟后过期,Closes #5572),但修复落在 v0.1.212 之后、尚未发版;「样式硬编码红」「无关闭按钮」「与宿主 UI 重叠」是本帖新增的面,未在其他 issue/PR 覆盖。无在途 [PR] 针对本帖,开一个修复 PR。
标签:bug / dsh / scope/ui / p3(体验瑕疵,不影响可用性;永久卡死的场景已由 #5572 的修复覆盖,待随下一版本发布)
版本先行核对(你报的是 bili 0.1.212,我按 v0.1.212 tag 的代码验证了机制):
upstreamBanner()在upstreams[]为空时返回 null(src/agent/dsh-native-client.ts的if (rows.length === 0) return null),服务端在上一次对同一 host 的请求成功后会清除该 host 的告警行([Feature] Web UI 主动提示上游连接失败(全局 banner),而不是只埋日志 #1682)。所以「上游恢复且有流量经过它」时横幅会在 ~10s 内消失。真正卡死的路径是:那个端口永久死了(典型:loopback provider shim 重载后换了新的临时端口)——旧端口永远不会再成功,成功清除路径永远触发不了,而告警行当时没有 TTL,于是永久钉住。这就是 [DSH] Upstream-down overlay sticks forever on a dead loopback shim port (×1, circuit null, no TTL/dismiss) #5572,master 已修(5 分钟 stale 过期;仍在持续失败的 host 每次失败都会刷新时间戳,不会误过期)。你看到的connect-refused ×1、count 停在 1 正是这个形状。升级到包含该修复的下一个版本即可,不需要额外的 25s 强制超时——强制超时反而会把真实持续中的故障藏掉,和告警语义冲突。rgba(217,63,11,0.5)边框 +rgba(217,63,11,0.1)背景。本 PR 改软:降饱和、圆角 10px、内边距 10px 14px、轻微阴影;文字颜色继续继承宿主 token(不新加硬编码色值,避免再制造主题冲突)。shell.overlay槽位在宿主窗口里的落位由 DSH desktop-runtime 的渲染层决定,bili 只能控制自己内容盒的尺寸与内边距,无法从 bili 侧移动槽位坐标。若下个版本里重叠仍在,需要在 dsh 宿主侧调整 overlay 层布局——这条我不在本仓修,留给你判断是否转 dsh 侧处理。接下来:基于当前 master 开分支实现 2+3,定向测试过 CI 后回贴 PR 链接。
ranxianglei commentedon Nov 5, 2026
(ai: qwen/qwen3.8-27b)
修复完成,PR 已开:#5703
标签:bug / dsh / p3 / scope/ui(样式与交互缺陷,有绕行——等恢复即消失,不影响功能与数据)。
按八问逐项回答:
shell.overlay槽位的摆放属于 DSH desktop-runtime 宿主侧,bili 只能控制自己的盒子,本仓库范围外(首条评论已说明)。/__bili/upstreams、10s 轮询节奏、slot 注册方式均未变。测试证据:定向
node --import tsx --test tests/dsh-settings-ui.test.ts→ 27/27 通过(含新增 #5701 回归钉:柔化后的样式值、点击 ✕ 关闭、计数抖动不重新弹出、故障集合变化重新出现);typecheck 干净。全量回归以 CI 为准(刚推送,check 还在排队)。结论:可合(待 CI 绿 + 人工合并)。另外提醒:「恢复后仍不消失」的症状,升级到下一个发布版本即解决(该版本包含 #5572 的 5 分钟过期修复);本 PR 解决的是样式与手动关闭。
ranxianglei commentedon Nov 5, 2026
(ai: qwen/qwen3.8-27b)
CI 结果跟进(PR https://github.com/ranxianglei/billion-context/pull/5703):
tests/issue2419-dsh-skill-catalog.test.ts(「stamps the guard onto the effective config」)、tests/issue2817-crosswire-persona-fold.test.ts、tests/issue5403-watermark-fastpath.test.ts(「[Bug][dsh] Plugin lane performs a full re-parse and resends the entire body every round (81 MiB → hundreds of MB AST), w | [Bug][dsh] plugin 车道每轮全量解析重发 body(81 MiB→数百 MB AST)是 #5403 OOM 的生产者:用水位线断言替换逐条复核,服务端只解析新增尾段 #5418 A/B byte-equality + residency band」)。0aace2f20),三个测试在本地逐一复现同样失败;本 PR 只动src/agent/dsh-native-client.ts的横幅 UI + 一个测试文件,不触碰这三个测试涉及的 skill catalog guard、persona session key、watermark fastpath 路径。本 PR 自身的定向验证保持绿(dsh-settings-ui 27/27 + typecheck)。待哨兵在 ci-fixes 收敛这 3 个 master 红测试后,重跑即绿。代码侧无其他待办。
ranxianglei commentedon Nov 5, 2026
(ai: vllm-qwen/qwen3.8-27b)
你的 bisect 与哨兵车道一致:同一 first-bad commit 01fcc5d。修复方向决策现已落档——A(test-only 回归钉对齐,把 commit 文档化的残留钉成契约)已在 ci-fixes 实现并经 PR #5718 收敛(待 owner 合并);B(收窄谓词使合法 main turn 1 不再命中 side lane)升级为决策请求 #5720(p1,[no-dispatch],含三选项代价对比与推荐);C(回滚)不推荐(重新暴露 #5656 锚点窃取洞,p1 级)。完整八问报告在 #4599。另:你的坏钉清单漏了
tests/issue2419-dsh-skill-catalog.test.ts(BLOCKED-ref 断言同样失败,本地复现确认),同一修复已覆盖。chuilian commentedon Nov 8, 2026
补充一个 macOS / DSH desktop 的数据点(0.1.212,同一现象,不是 Windows shim 场景):
http://10.10.x.x:18086/v1(仅 VPN 内可达),VPN 掉线时出现connect-timeout。/__bili/upstreams记录:firstSeen2026-11-08 18:12:13、lastSeen18:15:33(Asia/Shanghai),到 19:15 横幅仍显示 —— 后续没有任何新请求打向该 host,lastSeen一直停在一小时前。alerts在常驻代理进程内(本例 PID 3195,其/__bili/health的startedAt是前一天 22:37),宿主重启只是ensureProxyRunning重新 attach 到同一进程,不重建内存状态。所以"重启客户端/宿主"对这类残留无效。clearUpstreamAlertsForHost+recordUpstreamCircuitSuccess),符合设计。对照 #5574:0.1.213 的 5 分钟过期清理应该能覆盖这个场景,我会升级后复验并在本 issue 回报结果。
另外单开了一个 feature request #5948,请求一个彻底不渲染的开关(
__BILI__.upstreamBanner === false/dsh.upstreamBanner: false),与本 issue 的"过期/关闭"是互补关系而非重复。chuilian commentedon Nov 8, 2026
Upgraded to v0.1.213 (133f352) on macOS / DSH desktop (native bundle lane,
dsh:desktop) and re-checked. Confirming the 5-minute expiry from #5574 is in the shipped build, plus one gap that still keeps a banner alive in a specific case.Verified in
dist/index.js(0.1.213, not 0.1.212):so
GET /__bili/upstreamsno longer reports an alert row whoselastSeenis older than 5 minutes.ALERT_KINDSalso gainedupstream-unreachable.Upgrade path that worked on this box (
biliself-update is what I'd expect to do it, but it timed out against the registry here):node dist/index.js update→check failed: TimeoutError: The operation was aborted due to timeout(its own registry probe, 5s); npm itself was fine againstregistry.npmmirror.comand reported 0.1.213.$DSH_HOME/profiles/desktop/node_modules/billion-context(keeping the nestednode_modules/zod), bumped the profilepackage.jsondep spec to0.1.213, thenPOST /__bili/shutdown.startedAtfresh,/__bili/health→{"version":"0.1.213","commit":"133f3525c"},/__bili/status→stale:false, advisory:null,doctor --json→diskVersion 0.1.213 / runningVersion 0.1.213 / verdict ok. In-memoryalerts/circuitswere reset by the restart, which on its own already cleared the stale row.Remaining gap (relevant to #5948 / #5703): only
alertsexpire.circuitsstill have no time-based eviction — an entry is deleted only byrecordUpstreamCircuitSuccess(i.e. the first response from that host) or byMAX_CIRCUITSeviction. AndgetUpstreamHealthReportmerges it back in:So if a host trips
CIRCUIT_OPEN_AFTER = 3and then never returns a single response, the banner keeps rendering that host (itsfirstSeen/lastSeenare now synthesized fromopenedAt/lastFailure.at) even though every alert row behind it has been pruned. Expiry of a quiet circuit after a few minutes, or excluding a circuit with no fresh failure from the health report, would close that.Original repro on 0.1.212 for the record: company VPN dropped, model traffic to an internal OpenAI-compatible gateway (
10.10.180.57:18086, provider kept in the profile for on-VPN use) wentconnect-timeout,count: 3,circuit: open,lastSeenfrozen an hour earlier — and it survived quitting/relaunching the app, because the proxy is a detached process that the host re-attaches to rather than restarts.ranxianglei commentedon Nov 8, 2026
(ai: qwen/qwen3.8-27b)
谢谢 macOS 数据点和 v0.1.213 的逐行验证。我对着 v0.1.213 源码(133f3525c)核了一遍:你的判断成立 —— 只有
alerts有 5 分钟过期,circuits没有:getUpstreamHealthReport()先跑pruneStaleAlerts(now)清掉过期告警行,但合并电路时是for (const e of circuits.values()) { if (e.state.openedAt !== null) touch(e.state.host).circuit = e.state }(v0.1.213 的 src/upstream-alerts.ts:403–404)—— 任何 open 状态的电路无条件并入报告,没有时间判断;recordUpstreamCircuitSuccess),或被MAX_CIRCUITS=32上限挤出。所以你撞到的「连续 3 次失败 tripped open、之后这个 host 再没有任何请求」的场景,会永远在/__bili/upstreams里渲染该行(firstSeen/lastSeen由openedAt/lastFailure.at合成)。这和本 issue 是同一症状族(「横幅不消失」),只是数据来源不同(circuits vs alerts),按仓库「一个 issue 一个 PR」的惯例我把它并入现有 PR #5703 处理,不另开单。修法沿用 #5574 确立的纪律:在报告投影里做惰性过滤 —— open 电路若最近一次活动(
lastFailure.at,无则openedAt)超过同一个ALERT_STALE_MS=5min边界,就从健康报告中排除;不动电路状态机本身(流量回来再失败会立即重新出现;fail-fast / half-open probe 行为完全不变)。配双向回归测试(安静超时 → 从报告消失;仍在持续失败 → 保持显示)。两个附带说明:
node dist/index.js update对 registry 探测 5s 超时 —— 看起来是你机器本地的网络路径问题(npm 走 npmmirror 正常),与本缺陷无关,这里不展开。修完推到 PR 后我在本线程再报一次。
fix(dsh): soften upstream banner chrome + ✕ dismiss until the failing…
fix(upstreams): expire quiet open circuits in the health-report proje…
ranxianglei commentedon Nov 8, 2026
(ai: qwen/qwen3.8-27b)
你指出的电路缺口已修好并推到 PR #5703(分支同时 rebase 到了最新 master 3ac3e95)。修法在
src/upstream-alerts.ts的getUpstreamHealthReport():open 电路若最近一次活动(lastFailure.at,无则openedAt)超过与告警行同一个ALERT_STALE_MS=5min边界,就从/__bili/upstreams报告中排除 —— 沿用 #5574 确立的「读投影点惰性过滤」纪律;电路状态机本身不动(upstreamCircuitBlockReasonfail-fast、half-open probe 调度、getOpenUpstreamCircuits()诊断面全部照旧),流量回来再失败会在下一次读取时立刻重新出现。配了双向回归测试:安静超时 → 从报告消失但状态机里仍在;持续失败 → 永不老化。本地定向验证:tests/upstream-alerts.test.ts 14/14、tests/dsh-settings-ui.test.ts 27/27、tsc --noEmit clean。全量回归交给这个 head 上的 CI(上一轮红是 master 继承性失败,证据在 #4599;master 此后已走过 v0.1.213,含 P2 修复批,这轮可能直接绿)。
结构化八问
getOpenUpstreamCircuits()诊断面有意保持全量可见(诊断看事实、横幅看当下);dsh-settings-ui 既有 pin(Circuit-open 502 keeps an opaque error string, and connect-refused alerts never reach the host GUI | [Bug][dsh] 熔断/连接失败时客户端只见常量 "acp-proxy failure":detail/upstreamFailure/alerts 全都没到用户眼前 #4254 注册等)全过。无语义漂移、无 fail-fast 变吞错。判定:待本 head CI 转绿即可合并;人工评审重点建议放 commit 2 的边界选择(投影过滤 vs 状态机驱逐 —— 选前者因请求路径零风险、新故障可即时恢复可见)。
PR:#5703
ranxianglei commentedon Nov 8, 2026
(ai: qwen/qwen3.8-27b)
CI 状态补报:head 8fc410c 的 30 项 check 里非测试项已全部绿(static-gates ubuntu+windows、mysql-contract、test-import-graph、lock-sync、plan),11 个测试分片仍在跑(已 ~35 分钟,Windows 分片排队偏慢属正常区间),目前 0 失败。转绿即达可合并状态;若出红,按 #4599 流程先核继承性再定位。
ranxianglei commentedon Nov 8, 2026
(ai: qwen/qwen3.8-27b)
CI 结论:全绿。head 8fc410c 上主 CI 28 个 job = 27 success + 1 skipped(red-signal 哨兵,无失败时按预期跳过),各 e2e 车道全部 success。上一轮的 3 个继承红(issue2419 / issue2817 / issue5403)已在 v0.1.213 之后的 45 个提交里被上游修掉,rebase 后自然转绿,无需动 ci-fixes;结论已同步到 #4599。
PR 已达可合并状态,两个 commit:
f06e363fb— DSH 横幅 chrome 降饱和 + ✕ 关闭(失败集合变化才重新出现)8fc410c57—/__bili/upstreams投影里过期安静 open 电路(5 分钟同一边界,只过滤投影、不动熔断状态机)合并权在 owner,我不代合:#5703
@chuilian 升级验证路径:下个 release 带上这两个 commit 后,你那个「VPN 断开 → 内部网关 circuit open → 之后无流量」的场景下,横幅会在安静满 5 分钟后 ≤10 秒内自行消失,且随时可 ✕ 手动关掉。
ranxianglei commentedon Nov 8, 2026
(ai: qwen/qwen3.8-27b)
Closing summary (English, per your last comment): both parts of this report are now fixed in PR #5703 (branch rebased onto current master 3ac3e95, head 8fc410c):
f06e363fb, clientsrc/agent/dsh-native-client.ts): border/background alpha reduced (.5→.35 / .1→.08), radius 8→10px, padding 8px 12px→10px 14px, light shadow added, text color inherits host tokens; new ✕ button hides the banner until the set of failing hosts changes (count/ETA churn within the same set does not re-surface it; any new or changed failure does).8fc410c57, serversrc/upstream-alerts.ts): the exact gap you verified in the v0.1.213 dist — an open circuit with no fresh failure was merged intoGET /__bili/upstreamsunconditionally. The health-report projection now drops an open circuit whose last activity (lastFailure.at??openedAt) is older than the sameALERT_STALE_MS = 5minboundary used for alert rows. Only the projection is filtered: the circuit state machine (fail-fast block reason, half-open probe scheduling,getOpenUpstreamCircuits()diagnostics) is untouched, so a fresh failure re-surfaces the row on the next read. Bidirectional regression tests pin both directions.Outcome: local targeted suites green (tests/upstream-alerts.test.ts 14/14, tests/dsh-settings-ui.test.ts 27/27, tsc clean); remote CI fully green on head 8fc410c (main CI 27 success + 1 expected skip, all e2e lanes success). For your VPN-drop repro specifically: once a release ships these two commits, that banner self-dismisses ≤10s after the host has been quiet for 5 minutes, and can be ✕-dismissed immediately at any time.
No new config/env introduced; merge authority stays with the owner — I can't merge PRs.
LEIHAOY commentedon Nov 11, 2026
Additional data point (Windows 10 x64 / DSH desktop 0.2.2-rc.1 / billion-context 0.1.213), 2026-11-11 — relevant to the "overlaps host UI" part that #5703 currently marks as out of scope.
Repro: an image-generation request routed through the bili proxy to Google (
cloudcode-pa.googleapis.comand three sibling hosts) hitconnect-timeout. The banner3 upstreams unavailable(each row... · connect-timeout ×1) appeared in the top-left of the window and sat directly on top of the sidebar's "New session" button and the app menu. Clicks on those controls did not go through while the banner was visible. It disappeared on its own after a few seconds, but there was no way to dismiss it earlier.Observation on the overlap: even if the
shell.overlayslot position is decided by the DSH host, the banner's own box still intercepts pointer events. bili can control that part from its side without moving the slot: e.g.pointer-events: noneon the banner container (andpointer-events: autoonly on the new ✕ button), so the banner never blocks controls underneath it. Might be worth adding to #5703 alongside the ✕.Also noteworthy: a single transient
connect-timeout ×1per host (not 3 consecutive failures / not an open circuit) was enough to raise the banner, so one failed request to an unrelated third-party endpoint produces a large red box over the navigation.补充数据点(中文摘要):Windows + DSH 桌面版 0.2.2-rc.1 + bili 0.1.213。生图请求经 bili 转发到 Google,4 个域名连接超时,"3 个上游不可用"横幅出现在窗口左上角,盖住侧栏"新会话"按钮和应用菜单,横幅可见期间无法点击下方控件,数秒后自行消失,期间无法手动关闭。建议:即使槽位位置由 DSH 宿主决定,bili 仍可让横幅容器
pointer-events: none、仅让 ✕ 按钮pointer-events: auto,这样不会挡住下方控件。另外,单次connect-timeout ×1(未触发熔断)就会弹出横幅。fix(dsh): make the upstream banner click-through except its ✕ button (#…
ranxianglei commentedon Nov 11, 2026
(ai: qwen/qwen3.8-27b)
Thanks for the data point — verified both observations against the source and acted on the first one.
1. Overlap / blocked clicks — fixed. You're right that even if the
shell.overlayslot position is host-decided, the banner's own box intercepting pointer events is bili's responsibility. I adopted your exact suggestion, commit1e44cd5ef2now on PR #5703 (branch also re-synced to current master dc041dd while I was at it):pointer-events: none— it never blocks the New-session button / app menu underneath;pointer-events: auto— the one interactive element keeps working.Pinned by regression tests (tests/dsh-settings-ui.test.ts asserts both values): local suite 28/28 green, tsc clean. CI is running on the new head; I'll report the verdict here.
2. Why it vanished after a few seconds on your box: you're on v0.1.213, which already carries #5574's 5-minute stale expiry and #1682's success-clear — a successful retry to those Google hosts clears their alert rows on the next 10s poll, so a transient blip self-heals quickly. What was missing before this PR was manual dismissal (now ✕) and click-through (now done); the quiet-circuit expiry gap @chuilian found is also in this PR.
3. Single
connect-timeout ×1raising the banner: confirmed — any non-empty/__bili/upstreamsreport renders the banner, there is no count threshold today. Changing that is a product decision (hiding real failures behind a threshold vs. occasional transient noise), so I'm NOT changing it silently — options, costs and my recommendation are in my next comment (🔶 需要决策), default behavior if nobody decides: keep current visibility.ranxianglei commentedon Nov 11, 2026
🔶 需要决策
背景一句话:@LEIHAOY 的新数据点确认「单个 host 一次 connect-timeout ×1(未触发熔断)就让 DSH 左上角弹出大横幅盖住导航」;横幅自身的三个痛点(高饱和样式 / 无法关闭 / 挡住点击)PR #5703 已修,但「单次瞬时故障是否该弹横幅」目前是写死的「有行就显示」,属产品判断。
待决问题:上游健康横幅的显示条件是否要加阈值?
选项(各带代价):
/__bili/upstreams。代价:同 B,且影响该端点的所有消费方(含诊断面),回退更难。我的推荐 + 不决定的默认行为:推荐 A——本 PR 之后横幅柔和、可关、不挡操作且 5 分钟内自消,剩余成本有界;而把真实故障藏进阈值可能掩盖真宕机(可用性信号优先于视觉安静)。若发版后噪音投诉持续,再转 B(客户端侧、可逆),不必动服务端。不决定的默认行为 = A:本 PR 只带 chrome / ✕ / click-through / 电路过期四项变更,不含任何阈值逻辑。
结构化八问
upstreamBanner()加单一判定(任一 circuit open 或行数 ≥N)+ 双向测试钉住。ci: re-run after adding Closes ranxianglei#5701 to the PR body
YOIMIYA66 commentedon Dec 4, 2026
(ai: workbuddy/kimi-k3.1-pro)
Additional data point — and a note on the "position overlap" half that PR #5703 leaves out of scope.
Environment: Windows 11 Pro (build 26100) · DSH desktop-runtime
0.2.2-rc.5(Electron) · billion-context0.1.218(459b5d23a).Status on latest: as of 2026-12-04 the shipped
0.1.218still renders the original banner — neither #5703 nor #8142 is merged — so all three symptoms from the report still reproduce in the current release.Repro: the unreachable "upstream" here is the local model gateway itself (Magpie on
127.0.0.1:3425), not a remote vendor. When that local gateway is restarted / down,GET /__bili/upstreamsreturns one row127.0.0.1:3425 · connect-refused ECONNREFUSED ×3 · 约 3s 后重试, and the red banner appears at the window top-left, over the sidebar logo and the "New session" entry: hardcoded high-saturation red, no ✕ / no dismiss besides waiting for recovery, and the box swallows clicks on the sidebar controls underneath it.One point #5703 does not cover, and that is fixable client-side — the top-left placement. #5703 sets
pointer-events:none+ softens chrome + adds ✕, but the banner is still an in-flow child of DSH'sshell.overlay, whose layer isposition:absolute; inset:0; pointer-events:nonewith no layout (dsh-client-ui-layout/src/client/AppFrame.module.css.overlayLayer). A plain in-flow child therefore lands at that layer's(0,0). Moving the slot is host-side — agreed — but the banner's own box can position itself: the host Toast usesposition: fixed; top:40px; left:50%; transform:translateX(-50%)(dsh-web-frontendtoast CSS), so mirroring that on the banner puts it top-center instead of over the sidebar, with no host change. Worth folding into the placement discussion of #5703.Not a new defect — same family as #5701; posting as (a) confirmation it survives to
0.1.218/0.2.2-rc.5, and (b) the positioning root cause plus a client-side fix #5703 could pick up.中文摘要: Windows 11 + DSH 0.2.2-rc.5 + bili 0.1.218 复现。此处「上游」是本机模型网关(Magpie 127.0.0.1:3425)本身,网关重启/掉线时弹
connect-refused ×3横幅,落在左上角盖住侧栏 logo 与「新会话」,硬编码红、无 ✕、挡住下方点击。补充:#5703 只做了 pointer-events/柔化/✕,没处理左上角位置;而位置客户端可自解 —— DSH 的 shell.overlay 层是无布局的 absolute inset:0,普通子节点自然落到 (0,0);给横幅自身加 position:fixed;top:40px;left:50%;translateX(-50%)(与宿主 Toast 一致)即可居中,无需改宿主。属 #5701 同族,非新缺陷。fix(dsh): pin the upstream banner top-center (fixed) so it clears the…
ranxianglei commentedon Dec 4, 2026
(ai: vllm-qwen/qwen3.8-27b)
Thanks for the data point and the positioning analysis — both verified against the source and acted on.
Status on 0.1.218: confirmed. The fix for this issue (PR #5703) is still open/unmerged, so all three symptoms reproduce in the current release. Your report matches what we have on file.
The positioning point — you're right, and it's now fixed in #5703. The earlier scoping marked the top-left placement as "host-side, out of scope" on the assumption that bili could only control its box's size/padding, not its position. Your analysis corrects that: the
shell.overlaylayer isposition:absolute; inset:0with no layout, so the banner (an in-flow child) lands at the layer's(0,0)— top-left, over the sidebar. The previous commit'spointer-events:nonemade it click-through, but it still visually covered the sidebar. The banner's own box can position itself, so I addedposition: fixed; top: 40px; left: 50%; transform: translateX(-50%)(mirroring the host Toast) — it now sits top-center, clearing the sidebar chrome, with no host-side slot move.Pushed to PR #5703 (commit
fade4de24). Targeted suite 28/28 green, typecheck clean; CI running on the new head. The regression test pins the four positioning values; the actual top-center rendering rides on the host's overlay layer not having a transformed ancestor (your Toast evidence supports that).Context worth flagging for the owner: there's a second, competing PR — #8142 — that takes a different approach to the same issue: it replaces the persistent banner with a one-shot host Toast (theme tokens, auto-dismiss, fires only on state change). If that direction is preferred, it supersedes #5703 — and the positioning is handled for free, since a host Toast is already top-center by the host's own CSS. My positioning fix is specific to the banner approach (#5703); it's the answer if #5703 is the one that ships. The choice between the two is the owner's call.
结构化八问
pointer-events:none让它可穿透点击,但视觉上仍覆盖侧栏。shell.overlay层是position:absolute; inset:0无布局,普通 in-flow 子节点自然落到该层 (0,0)(左上角)。此前误判为「槽位坐标由宿主决定、bili 无法控制」;实际横幅自身盒子可用position:fixed自我定位,无需改宿主。position:fixed; top:40px; left:50%; transform:translateX(-50%)(与宿主 Toast 一致),从左上角移到顶部居中,无需改宿主槽位。判定:可合(待 CI 绿 + 人工合并);合并权在 owner。