Repository navigation
[PR] fix(storage): Node-upgrade hint on the recurring sidecar-open degrade warn (#3489) - #3531
ranxianglei wants to merge 1 commit into
Conversation
… warn (#3489) Follow-up to #3485 (directives 2+3 of #3338): item B of #3489 names TWO surfaces for the upgrade hint — the diagnostics/web degrade reason (covered by #3485 in runtime-status.ts) AND the recurring '[storage] unified sidecar failed to open ...' warn line (src/storage/shadow.ts) that fires on EVERY boot while degraded. The bootstrap-failure log line #3485 added only fires once per 6h cooldown window, so users normally never saw the hint. The hint is gated on the missing-engine error condition (same marker regex as runtime-status.ts), so corrupt-index.db warns keep their byte-stable recovery instruction; on Nodes that ship node:sqlite (>= 22.5) the suffix is empty and the line is unchanged. Tests: gate x version matrix pin + behavioral warn-line capture (no-engine warn carries exactly the helper's verdict for its own error text; corrupt-index warn byte-identical to pre-change).
📦 Built Package ArtifactBranch: Option A — Install this exact build (recommended)npm install -g billion-context@0.0.4173-pr.3531.363a911This exact version is immutable and reproducible. The rolling Option B — Download artifact
tar xzf billion-context-pr3531.tgz
npm install -g packageInstall instructions are refreshed on each push. |
(ai: vllm-qwen/qwen3.8-27b) 查重: 不重复 —— open PR 中只有 #3531 实现 #3489 item B(sidecar-open warn 的 Node 升级提示),无其他在途工作触碰该 warn 行或该提示机制。 这是本 agent 已完成的 [PR],未重做,按规范核对代码与 CI 后报告。独立复审结论如下(八问):
验证证据(独立重做,非复读 issue):
diff 整洁度:单 commit、2 文件、+83/-2,每行都与目的相关,无空白/重排噪音。 判定:可合。 PR: #3531 |
|
Superseded: #3489 landed the multi-mirror fallback chain for the self-downloaded engine (npmjs → npmmirror …, engine-bootstrap retry ladder), which is the durable fix for the recurring sidecar-open degrade after Node upgrades; the extra hint polish here rides the same code path that now succeeds. Closing as superseded. |
What / why
Post-merge supplement to #3485 (merged
1d4dcfc05, directives 2+3 of #3338). Item B of tracking issue #3489 names TWO surfaces for the Node-upgrade hint:degrade reason(src/storage/runtime-status.ts) — covered by fix(storage): builtin npm+npmmirror mirror fallback + Node upgrade hint for the SQLite engine download (#3338) #3485 ✓[storage] unified sidecar failed to open ...warn line (src/storage/shadow.ts) — missed by fix(storage): builtin npm+npmmirror mirror fallback + Node upgrade hint for the SQLite engine download (#3338) #3485 ✗That warn fires on every boot while degraded (the #3385 logs show 7 occurrences over several days), while the bootstrap-failure log line #3485 added only fires once per 6h cooldown window — so users normally never saw the upgrade hint in their logs. This completes item B's second named surface.
How
sidecarOpenFailHint(errText, nodeVersion?)insrc/storage/shadow.ts: appendsnodeSqliteUpgradeHint()only when the error text matches the missing-engine condition (same/no SQLite engine available/imarker regexruntime-status.tsalready uses); empty suffix for every other failure.Behavior change (disclosed)
The
[storage] unified sidecar failed to open ...warn line gains an ADDITIVE suffix, and only under a narrow condition: running Node < 22.5 AND the open failure is the missing-engine condition. Old → new:Corrupt-index (and any other) failures keep the line byte-identical to before; on Nodes ≥ 22.5 the helper returns
""so the line is unchanged there too. In production the gated branch can only fire when the builtin is absent, so the hint is always actionable when shown.Tests
tests/storage-engine-proofs.test.ts(+2 tests, suite now 14/14):setLogCapture: no-enginemaybeOpenwarn carries exactly the helper's verdict for its own captured error text; corrupt-index warn ends byte-identical to the pre-change line.Local targeted runs green: storage-engine-proofs 14/14, storage-engine-bootstrap + storage-ingest-watermark 43/43,
npm run typecheckclean. Full-suite verdict = CI on this head.Closes #3489 (item A landed via #3485; item B completed here).