Skip to content

feat: force-update out of critical-defect versions via remote advisories - #1483

Merged
ranxianglei merged 6 commits into
masterfrom
2026-09-27_advisory-force-update
Sep 28, 2026
Merged

ranxianglei merged 6 commits into
masterfrom
2026-09-27_advisory-force-update

Conversation

@ranxianglei

Copy link
Copy Markdown
Owner

Fixes #1481

What it does

Adds a critical-defect advisory mechanism that force-updates an install out of a known-broken version range — even when autoUpdate is off (the core ask of #1481).

Advisory source: a small companion npm package billion-context-advisories, published by CI from this repo's new advisories/ directory (workflow .github/workflows/advisories.yml). It rides the same registry egress/proxy chain as the self-updater's tarball fetches, so it is reachable wherever bili can already update from, and sits in the same trust domain as the code we already auto-install. Escape hatch: "advisoryUrl" / BILI_ADVISORY_URL.

Document shape (validated, schema-pinned):

{ "billionContextAdvisories": { "schema": 1, "updated": "...", "advisories": [
  { "id": "...", "affected": ">=0.1.155 <0.1.158", "target": "0.1.157", "reason": "...", "publishedAt": "..." }
] } }

target is a concrete version and may be older than the running one — rollback semantics for when several consecutive releases are bad.

How it works

  • New module src/advisory.ts: its own watcher loop on the existing 3-minute cadence (BILI_UPDATE_CHECK_INTERVAL_MS-aware), independent of autoUpdate, default ON, opt-out "advisoryCheck": false / BILI_ADVISORY_CHECK=0.
  • Match = semver.satisfies(currentVersion, affected, {includePrerelease:true}). semver is added as an exact-pinned devDependency and bundled at build time — dist/index.js stays dependency-free.
  • On match → forceInstallVersion() (new export in src/update.ts) reuses the updater's full safety chain: cross-process lock, exact-version registry doc resolution, sha-integrity verification, staged extract, backup + verify + rollback, #580 source-checkout refusal, #991 host-managed-lane refusal (refuses in-place overwrite, warns with the owner's sanctioned channel instead), dsh profile bundle refresh, stale-install restart reminder (--auto-restart-on-update).
  • Warning presentation (owner requirement): one-time [advisory] ⚠️ … log line per process/per advisory id; Web UI banner showing the reason plus the exact manual command; GET /__bili/status gains an advisory field (active entry or null).
  • Fail-open by design: an unreachable or malformed advisory source only logs a warning — model traffic is never blocked by it.
  • While an advisory is active, the regular self-update loop defers (the advisory's explicit target wins over "latest"); a manual forced bili update still proceeds.

Behavior changes (intentional, flagged per policy)

  • A new background outbound GET to the npm registry every ~3 min even when auto-update is disabled (that is the point of 搞一个自动强制更新,针对重大bug的版本 #1481; default-on safety net, opt-outs above).
  • /__bili/status response gains an advisory field (additive).
  • New config keys advisoryCheck / advisoryUrl and env vars BILI_ADVISORY_CHECK / BILI_ADVISORY_URL; defaults keep prior behavior for anyone who opts out.
  • While an advisory is active, the regular self-update check is deferred for that cycle (its install would race the forced target).
  • Normal auto-update behavior is unchanged when no advisory matches (existing update-* suites all green).

Pre-flight

  • npm run typecheck — clean
  • npm test — 2897 tests, 0 failures (12 pre-existing gated skips); new tests/advisory.test.ts 14/14: parsing/validation, range matching (incl. prerelease + fail-open), URL resolution, unreachable/malformed-source fail-open, throttle cadence, real-tarball end-to-end force-install (forward + rollback), git-tree and misconfigured-target refusals, regular-loop deferral.
  • npm run build — OK (dist-import-annotations: OK, semver fully inlined)

⚠️ Release sequencing (AGENTS.md §5)

This PR touches src/update.ts (load-bearing updater infra). Per the no-op-release rule: ship a pure version-bump release FIRST, observe a real running install auto-updating OLD→NEW successfully, then merge this. The merge does not have to block on that if the owner prefers, but the feature should not be the first change riding the updated updater path without a proven healthy hop.

Docs: README (en + zh) subsection under Self-update; CONFIGURATION env tables updated.

@github-actions

github-actions Bot commented Sep 27, 2026 •

Copy link
Copy Markdown
Contributor

📦 Built Package Artifact

Branch: 2026-09-27_advisory-force-update (1cc07c1)

Option A — Install this exact build (recommended)

npm install -g billion-context@0.0.1510-pr.1483.dc5ae88

This exact version is immutable and reproducible. The rolling pr tag tracks the newest test build across all PRs.

Option B — Download artifact

  1. Download the artifact from the Actions run
  2. Extract the tarball and install:
tar xzf billion-context-pr1483.tgz
npm install -g package

Install instructions are refreshed on each push.

@ranxianglei

Copy link
Copy Markdown
Owner Author

🤖 Powered by ework · qwen3.8-27b

[bot] 🏷 Reviewing this PR now — pulling branch 2026-09-27_advisory-force-update (80b5407), checking direction against #1481, walking the diff (advisory module, updater integration, status endpoint, tests, CI workflow), then running local verification. Full review to follow in this thread.

@ranxianglei

Copy link
Copy Markdown
Owner Author

🤖 Powered by ework · qwen3.8-27b

[bot] 🏷 Review of PR #1483 (advisory-based force-update, Fixes #1481)

Reviewed the full branch against current master (b371bd04 — base is fresh, linear 2 commits). Findings by review gate:

① Original issue (direction) — PASS. Matches the design ratified in #1481 (「同意 开搞」): remote advisory doc via a companion npm package, independent default-on watcher, force-install to the advisory target with rollback semantics, warning presentation carrying reason + manual instructions, fail-open. It addresses the root cause (no mechanism could reach installs with auto-update off or a broken updater), not a symptom. Trust domain unchanged: same npm registry as the tarballs bili already auto-installs; publishing requires NPM_TOKEN.

② Regression audit — existing behaviors on every touched path:

  • Regular self-update loop with no active advisory: preserved (deferral fires only when advisoryActive(); throttle/lock/install chain untouched)
  • Manual bili update: preserved (force=true bypasses deferral)
  • Stale-install reminder (feat(update): surface stale-install state to the human + opt-in self-restart (#806 §3) #811): preserved (same notifyStaleInstall path post-install)
  • /__bili/status: additive advisory field only; model wire traffic untouched; both compression modes unaffected (update path only)
  • dist/index.js stays dependency-free: verified semver is fully inlined by tsup (zero bare imports in the bundle)
  • One regression found → fixed (commit d1bccbd6, below)

③ Code review — core design is sound (schema-pinned parsing, fail-open everywhere, reused single-writer guards, rollback semantics, restart double-fire guarded by decideAutoRestart cooldown + marker file). Three issues found and fixed directly on the branch:

  1. d1bccbd6 — deferral silently suspended dsh plugin-market installs never auto-update: the refresh chain's only trigger is a global bili self-update #1196 self-heal on host-managed lanes. The deferral check sat above the host-managed branch, so while an advisory was active, refreshDshProfileCopy — the only live update path for dsh profile-bundle installs without a global bili — stopped running until someone manually updated. The deferral now detects managed lanes and still drives their owner-channel refresh; writable installs remain fully deferred. Intentional behavior change: old = regular loop does nothing for host-managed lanes while an advisory is active → new = their owner-channel refresh keeps running (restores the Install-Lane contract "every copy must have a LIVE update path").
  2. 521ceef5 — unbounded log spam + silent failures. The watcher retries every cycle while an entry matches, but refusals (source checkout auto-update overwrites tracked files when run from a git source checkout (findInstallDir resolves to repo root) #580, host-managed lane native模式下自动更新问题需要解决 #991) logged a fresh warning every cycle forever — against the one-time-per-process warning design — and the remaining failure paths (unresolvable target, missing install dir, lock contention, failed install) were silent outside /__bili/status. All refusal/failure sites now log once per process per advisory id+message; lastError strings unchanged.
  3. 1c6b8a0a — advisory publish-gate gaps. CI validated schema + required fields but not semver syntax: a typo'd affected range or target would publish fine and fail open on every client — an ineffective advisory with zero signal anywhere. The gate now runs npm ci and rejects invalid Range/target values before publishing. Also fixed a latent lexicographic version-max bug (process.argv[1] > process.argv[2] string compare breaks once the local placeholder passes 0.0.9 lexicographically) → now semver.gt. Documented multi-match precedence (first listed entry applies) in advisories/README.md.

④ Test validity — the existing 14 tests have real teeth (real-tarball e2e through the full integrity chain, fail-open paths, throttle cadence, deferral). Gaps I closed: added a host-managed (pnpm-store) refusal test — the #991 single-writer contract on the new path had zero coverage — with a warns-once-per-process pin; extended the misconfigured-advisory test to pin dedupe across repeated cycles; strengthened the deferral test to assert the deferral decision itself is logged (its old fixture .git dir never actually exercised the deferral path).

⑤ Diff cleanliness — clean (+910/−8, every line purpose-related; README/CONFIGURATION en+zh in sync).

Nits left unfixed (reported only):

  • Web banner shows the generic npm install -g billion-context@<target> command even on host-managed lanes where that command is wrong (the log warning carries the correct channel). Cosmetic; fixing needs per-lane hint plumbing.
  • autoUpdate: true passed from advisory.ts into forceInstallVersion is unused there (harmless, documents intent).

Local verification on the pushed head: typecheck clean · full suite 2898 tests / 0 failures (12 pre-existing gated skips; +1 new test vs the PR body's count) · build OK with dist confirmed dependency-free. CI on 1c6b8a0a: running (13 checks) — will follow up here with the result.

Merge gate: this PR touches src/update.ts (load-bearing updater) + adds config keys + a new outbound network behavior → human-only merge, not auto-merge eligible. Per AGENTS.md §5, ship a no-op release first, observe a real OLD→NEW auto-update succeed, then merge this one.

修复了 review 中发现的三个问题:advisory 激活期间常规循环的 defer 会挂起托管安装(dsh profile 等)唯一的 #1196 自更新通道(回归,已恢复)、拒绝/失败警告未去重导致每 3 分钟重复刷屏且部分失败路径完全静默、advisory 发布 CI 不校验 semver 语法(拼错的 advisory 会静默失效)外加版本号字典序比较的潜在 bug;均已在 PR 分支直接补了带回归测试的修复,本地全量 2898 测试通过,等 CI 绿后建议先按 §5 发一个 no-op 版本再合并本 PR。

@ranxianglei
ranxianglei force-pushed the 2026-09-27_advisory-force-update branch from 1c6b8a0 to c52f399 Compare September 27, 2026 08:10
@ranxianglei

Copy link
Copy Markdown
Owner Author

🤖 Powered by ework · qwen3.8-27b

[bot] 🏷 CI + rebase update

While waiting on CI, master advanced 44 commits (incl. release v0.1.160), which put the PR in behind state — so I rebased the branch onto current master (30b1574b) and re-ran the full gate on the new head c52f3993:

  • rebase: zero conflicts (the 44 new commits touch stream/loop/server paths; no semantic overlap with the advisory work)
  • local: typecheck clean · 2934 tests / 0 failures (12 pre-existing gated skips) · build OK, dist confirmed dependency-free
  • CI on c52f3993: 13/13 checks green (test matrix ubuntu+windows × node 22/24, e2e, hermetic registry e2e, all four real-client lanes, codex overlay, version-guard, build-artifact)
  • PR state: mergeable_state: clean, base master, 5 commits (original feat + zh-docs + my 3 review fixes)

The branch is ready. Two reminders before merge (both already in my review post): human-only merge, and per AGENTS.md §5 ship a no-op release first — this PR touches src/update.ts, so prove the existing upgrade path end-to-end before the change rides it.

已把分支 rebase 到最新 master(v0.1.160,零冲突)并在本地重跑全部门禁(typecheck + 2934 测试全过 + 构建),新 head c52f3993 上 CI 13/13 全绿、mergeable_state clean,可以合并(记得先按 §5 发 no-op 版本验证升级链路)。

@ranxianglei

Copy link
Copy Markdown
Owner Author

深审收尾:F1/F2 已修(head 84dc8b9)。

F1 — 坏目标兜底零覆盖:tests/advisory.test.ts 新增"unresolvable target (owner typo)"用例——目标版本 registry 上不存在时:安装目录零改动、cannot resolve 9.9.9 on the registry 记入 lastError、每进程只告警一次。变异验证:拔掉 update.ts:1067 的 !doc?.tarball 守卫 → 恰好此用例红,复原 16/16。

F2 — 不可解析目标楔死自更新(reviewer 定性:#1196 frozen-forever 同类):

  • advisoryDeferring():lastError 为 cannot-resolve 时返回 false——cli 把它接到自更新循环的 advisoryActive 门,目标装不上时普通自更新照常跑,不再无限推迟
  • /__bili/status 暴露 advisory.targetFailed;web banner 的逃生命令在此状态回退 @latest(不再是装不上的死命令)
  • CI 发布门(advisories.yml)对每条 entry 先 npm view billion-context@<target> 验存在,坏目标在发布前就被拦下
  • 变异验证:advisoryDeferring 去掉 lastError 条件(楔死回归)→ 同一用例红,复原过

门禁:typecheck ✓ / 全量 2923 过 0 败(12 skip 为既有门控)/ advisory 16/16。非阻塞观察(F3-F10)见 reviewer 报告,F2a 已含在本修复。可合并。

@ranxianglei

Copy link
Copy Markdown
Owner Author

🤖 Powered by ework · qwen3.8-27b

[bot] 🏷 F1/F2 verification at 84dc8b94 — confirmed, independently re-run

Read the full diff and re-ran every gate locally on your head:

  • typecheck clean · advisory suite 16/16 · full suite: 2935 tests / 2923 pass / 0 fail / 12 skip (your 「2923 过」 was the pass count — totals reconcile exactly: my earlier post-rebase baseline 2934 + this commit's 1 new test) · build OK, dist/index.js still zero bare imports (dependency-free invariant holds)
  • CI at 84dc8b94: 9/9 workflow runs SUCCESS (main CI, e2e real-codex, fake-codex, hermetic registry, opencode/dsh/pi lanes, Windows codex overlay, build artifact)

Design assessment — the layering is right. Source-side prevention (CI npm view billion-context@<target> before publish), client-side fail-open (advisoryDeferring() releases the normal loop when the target is uninstallable), UI honesty (targetFailed → banner falls back to @latest). Semantics I checked specifically:

  • cannotResolveTarget() string-matches exactly one error site (cannot resolve %s on the registry, src/update.ts) — no false positives from other failure classes
  • state.lastError clears on a clean check (src/advisory.ts:240), so targetFailed self-heals automatically once the target becomes resolvable
  • Banner visibility (active) and loop gating (advisoryDeferring) are now decoupled on purpose — user keeps seeing the warning while the install stays alive. Correct split.
  • New test has real teeth: disk-untouched + exact lastError string + cannotResolveTarget===true + advisoryDeferring()===false + warns-once across two cycles. Both mutation claims check out as genuine pins (removing the !doc?.tarball guard routes a TypeError into lastError instead of the cannot-resolve string → regex red; removing the lastError condition flips the boolean assert red).

One residual edge (non-blocking, same class as your parked F3–F10): deferral is only released for cannot-resolve failures. A permanently unreachable advisory source with a custom BILI_ADVISORY_URL pointing at a dead host would keep deferring the normal loop (lastError stays ECONNREFUSED, not cannot-resolve). With the default URL this is harmless — it shares the npm registry egress with the updater itself, so both fail together and deferral costs nothing. Worth widening the release condition someday (any persistent lastError after N cycles → release) if custom URLs become common; not worth blocking this PR.

Branch state: master moved +3 commits since your base (cache-ledger #1489/#1490) → GitHub shows behind, but those commits have zero file overlap with this PR and git merge-tree --write-tree origin/master 84dc8b94 reports a clean merge (tree 40fffd50) → mergeable as-is via merge commit. If you'd rather have a linear tip, say the word and I'll rebase + re-push in one pass.

Standing reminders unchanged: human-only merge, and per AGENTS.md §5 ship the no-op release first — this PR rides src/update.ts, so prove the existing upgrade path end-to-end before merging.

已独立复核 F1/F2(读全量 diff + 本地重跑全部门禁:typecheck ✓、advisory 16/16、全量 2935 测试 0 败、构建依赖面不变、CI 9/9 绿),分层方案(发布前拦截 + 客户端 fail-open + UI 诚实降级)语义全部核对无误,与最新 master 零冲突可合并;合并前记得按 §5 先发 no-op 版本验证升级链路。

@ranxianglei

Copy link
Copy Markdown
Owner Author

深审完成(head 84dc8b94a,worktree 实测 + 代码逐行):✅ 可合。六轴全过,且几处"预判式"防护做得比 issue 讨论时还细:

逐轴验证

  1. 信任域/失败开放 ✅ — 伴生包走 registryUrlFor(BILI_UPDATE_REGISTRY/代理出口感知,与 tarball 同路);fetch/parse/install 任一失败 → lastError + 进程内按错误串去重的单次 warn,永不碰模型流量。
  2. native模式下自动更新问题需要解决 #991/dsh plugin-market installs never auto-update: the refresh chain's only trigger is a global bili self-update #1196 交织 ✅ — 这是最容易写错的一处,写对了:普通自更新循环在 advisory 活跃时让位(advisoryActive: advisoryDeferring),但dsh 宿主管理车道仍继续跑 refreshDshProfileCopy——让位的是"写谁",不是"活路"。
  3. F2 楔死防护 ✅ — target 在 registry 上解析不出 → advisoryDeferring()=false → 普通循环恢复,@latest 兜底,不重演 dsh plugin-market installs never auto-update: the refresh chain's only trigger is a global bili self-update #1196。
  4. kill switch ✅ — advisoryCheck(默认开)/BILI_ADVISORY_CHECK=0/BILI_ADVISORY_URL 覆盖;注释明确"只装文件和警告,不碰进程活性"。
  5. 误配置自防 ✅ — advisory 的 target==当前版本(自己标自己)→ 大声报错拒装,不在每周期空转;源码检出 auto-update overwrites tracked files when run from a git source checkout (findInstallDir resolves to repo root) #580 拒绝并给出手动升级命令。
  6. 回滚语义 ✅ — target 可老于当前,复用完整安全链(跨进程锁/备份/校验/回滚)。

测试/门禁:advisory 16/16、update+config 邻域 84/84、cli/auto-update 25/25,CI 12/12 全绿(含 hermetic registry e2e——advisory URL 没有破坏 verdaccio 套件,好信号)。本地 typecheck 一度红是 worktree 符号链接缺新 devDeps(semver+@types/semver 声明齐全在 devDeps+lockfile,tsup 内联,与 acp-kernel 同模式),环境假象非缺陷。

合并前两个流程要求(非代码)

  • 先发 no-op 版本(AGENTS.md §自动更新机制铁律):本 PR 动了 src/update.ts(+134),当前在跑的版本必须先证明自己能升上来,再合这条。
  • 首条 advisory 建议空跑:advisories/package.json 现在是空列表——合并后先发一条 affected 匹配不到任何已发布版本的公告,端到端验证 伴生包→CI 发布→watcher→横幅→恢复 的整链,等真事故再写实的(与 no-op release 同一哲学)。

非阻塞观察:重叠 advisory 按 matched[0] 每周期处理一条(3min 链式推进,可接受);伴生包信任域=npm 凭证(与 updater 同域,已文档化)。

@ranxianglei

Copy link
Copy Markdown
Owner Author

🤖 Powered by ework · qwen3.8-27b

[bot] 🏷 收尾确认 — 同意 ✅ 可合,两个校准点补充

两轮独立审查已收敛到同一结论(我这轮:全量 diff 重读 + 本地门禁重跑 2935/0 败 + CI 9/9 绿 + 对当前 master merge-tree 无冲突;你这轮:六轴 worktree 实测)。技术面无未决项;「typecheck 一度红」确认是 worktree 符号链接的环境假象——我从 lockfile npm ci 后 typecheck 直接干净,semver/@types/semver 声明与内联模式(同 acp-kernel)都正确。

对你提的两条合并前流程要求——完全同意,各补一点:

  1. no-op 先发 — 与我此前每轮提醒一致。顺序不变:发 no-op → 观察到真实的 auto-updated OLD → NEW 日志行 → 再合本 PR。需要时说一声,我来准备 no-op release 分支/PR(version bump only),合并仍归你。
  2. 首条 advisory 空跑 — 好直觉,一个校准:匹配不到任何版本的空跑只验证读链路(伴生包发布 → watcher 拉取 → 解析 → 不匹配 → 横幅保持隐藏 → /__bili/status 的 advisory:null),写链路(force-install 安全链)它碰不到——那一侧由 CI 的 hermetic-registry e2e 真实 tarball 用例兜着。两条合起来才是完整闭环,且不触碰任何真实用户安装。
    • 空跑范围的一个安全细节:务必用永不可能匹配真实未来版本的区间(如 >=999.0.0)。看似无害的 >=0.1.161 <0.1.170 会在某天发版落入区间时开始对所有用户强制安装——空跑变事故。验证完按 advisories/README.md 惯例把条目下线(删条目、留 id 记录),别让它长期挂着。

非阻塞观察收到(重叠 advisory matched[0] 逐周期链式处理、伴生包信任域 = npm 凭证且已文档化)——与我的判断一致,不挡合并。

最终状态:head 84dc8b94,6 commits,CI 全绿,对当前 master 零冲突可直接合。Ready — no-op 先行。

同意 ✅ 可合结论。两点校准:空跑 advisory 只覆盖读链路,写链路由 CI hermetic e2e 兜底,两者合起来才闭环;空跑范围务必用永不匹配真实版本的区间(如 >=999.0.0)并在验证后下线条目。合并顺序不变——no-op 先发、观察到真实升级日志后再合本 PR,需要我准备 no-op release 分支随时说。

ework-agent and others added 6 commits September 28, 2026 17:35
… per process

The advisory watcher retries forceInstallVersion every cycle while an entry
matches. Without dedupe, a persistent refusal (source checkout #580,
host-managed lane #991) logged a fresh warning every cycle forever, and the
remaining failure paths (unresolvable target, missing install dir, lock
contention, failed install) were silent — visible only via /__bili/status
lastError. All refusal/failure sites now log once per process per advisory
id + message; state.lastError strings are unchanged.
…during advisory deferral

While an advisory is active the regular loop defers before it ever reaches
the host-managed branch, so refreshDshProfileCopy (#1196) — the only live
update path for dsh profile bundle installs without a global bili — was
suspended indefinitely until a manual update. The deferral now detects
host-managed lanes and still drives their owner-channel refresh; writable
installs are untouched by the regular loop as before, and forced manual
checks still bypass deferral entirely.
…phic version max

The publish gate checked schema and required fields but not semver syntax,
so a typo'd affected range or target would publish fine and fail open on
every client — an ineffective advisory with no signal anywhere. The gate
now runs npm ci and rejects invalid Range/target values before publishing.
The version-max used string comparison (process.argv[1] > process.argv[2]),
which breaks once the local placeholder passes 0.0.9 lexicographically;
it is now semver.gt. Documented multi-match precedence (first listed entry
applies) in the advisories README.
…p (F1/F2)

F1: the 'cannot resolve <target> on the registry' fail-safe had zero
regression coverage (mutation-verified) — tests/advisory.test.ts now pins
install-untouched + once-per-process warn + lastError.

F2: an advisory whose target doesn't exist (owner typo) set state.active
forever and deferred the normal self-update loop indefinitely (#1196
wedge class), while the web banner offered an uninstallable escape hatch.
- advisoryDeferring(): false while lastError is a cannot-resolve failure —
  cli passes it as the update loop's advisoryActive gate, so the normal
  loop keeps the install alive
- /__bili/status exposes advisory.targetFailed; the web banner falls back
  to @latest when the target failed to resolve
- CI publish gate (advisories.yml) now checks each target exists on npm
  before publishing the companion package
@ranxianglei
ranxianglei force-pushed the 2026-09-27_advisory-force-update branch from 84dc8b9 to 1cc07c1 Compare September 28, 2026 09:46
@ranxianglei ranxianglei mentioned this pull request Sep 28, 2026
@ranxianglei
ranxianglei merged commit 6de711d into master Sep 28, 2026
13 checks passed
ranxianglei added a commit that referenced this pull request Sep 28, 2026
Revert "feat: force-update out of critical-defect versions via remote advisories" (#1483) — re-land after no-op v0.1.166
ranxianglei added a commit that referenced this pull request Sep 28, 2026
Re-land #1483: remote maintenance advisory + force-update (after no-op 0.1.166 validation)
antclt pushed a commit to antclt/billion-context that referenced this pull request Oct 1, 2026
…27_advisory-force-update"

This reverts commit 6de711d, reversing
changes made to 1c60633.
antclt pushed a commit to antclt/billion-context that referenced this pull request Oct 1, 2026
…-27_advisory-force-update"

This reverts commit 44171bf.
ranxianglei pushed a commit that referenced this pull request Oct 1, 2026
…ctor (#1577)

In native/plugin lanes (bili pi, opencode/dsh plugin) the proxy child runs on an ephemeral port with stdio->log fd, so #1483's advisory loud channels -- stderr warn line, Web UI banner, /__bili/status -- are all unreachable by the user. The force-install still works; what was missing was visibility.

Adds three human-facing surfaces for an active instance-level advisory: acp_status + the /acp panel gain an instance-level section (mirrors the #897 UNDECRYPTED TRAFFIC pattern; the /acp line is inserted before PANEL_BOX_FOOTER so the LLM-context stripper still matches, byte-exact when no advisory), and bili doctor gains one advisory line (active reason+manual cmd / none / check-failed unknown). Shared describeAdvisory() wording plus read-only evaluateAdvisories() used by doctor (it runs in its own process with no watcher, so it evaluates against the disk version). No wire/turn injection (visibility only, per non-goal); no new config fields.
@ranxianglei
ranxianglei deleted the 2026-09-27_advisory-force-update branch October 15, 2026 05:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

搞一个自动强制更新,针对重大bug的版本

1 participant