Repository navigation
[PR] fix: warn when compress-block keys sit inert on a provider route root | 路由根上的 compress 块键静默无效时补告警 - #3680
ranxianglei wants to merge 5 commits into
Conversation
📦 Built Package ArtifactBranch: Option A — Install this exact build (recommended)npm install -g billion-context@0.0.4597-pr.3680.c463a7fThis exact version is immutable and reproducible. The rolling Option B — Download artifact
tar xzf billion-context-pr3680.tgz
npm install -g packageInstall instructions are refreshed on each push. |
(ai: vllm-qwen/qwen3.8-27b) 查重: 不重复。 这是 #3675 的修复 PR( 标签: bug + scope/wiring + p2(缺陷类——配置键静默无效属可观测性缺陷;provider 路由解析属协议接线/外部 API 边界;能用但有明显坑、需绕行挪进 开始独立审核(拉分支、读 diff、定向测试、CI 状态),结论按八问随后给出。 |
|
红了 |
(ai: vllm-qwen/qwen3.8-27b) 红了已定位,正在修。一句话:这个 PR 新增的告警函数在源码里比 处置:修守卫脚本的提取锚点(锚定到 |
…3680) The route-root warning added in this PR references COMPRESS_SETTING_FIELDS before its declaration. scripts/config-surface-guard.mjs located the field list at the FIRST mention of the name and stopped at the first closing bracket, so it scanned the new warning's template literal and extracted one empty string -> phantom leaf 'compress., ' -> config-surface-guard job red + tests/config-surface-guard.test.ts red in every shard carrying it. extractStringSet now anchors on 'const <name> = new Set([' and matches the closing bracket string-aware. Regression test pins the use-before-declaration + bracketed-template shape.
(ai: vllm-qwen/qwen3.8-27b) 审核完成。先交代处置过程:你 ping「红了」后定位到的是本 PR 引入的一个 CI 工具链缺陷(非产品代码),已修复并推到分支( 八问
CI 红处置(你 ping 的那次)
剩余红(均非本 PR 引入,已有跟踪,不再重复立项)
审核中另发现(已单独立项 #3876)
判定:代码与测试本身可合——方向、回归清单、测试有效性、diff 整洁度(两文件 +99/-0,外加本次 CI 修复 commit,每行都在目的内)均已独立复核。合并时机等 #3871 解除 master 静态门禁、CI 转绿之后;合并由你操作。 |
|
(ai: vllm-qwen/qwen3.8-27b) 给本分支加了一个 commit: 背景:分析 #3876 时发现,本分支路由根警告所用的识别集合 两边携带的是同一行集合修改,任意合并顺序都能干净合并。 |
Commit 66219d4 added externalSummary to COMPRESS_SETTING_FIELDS on this branch; the config-surface guard then fails HERE (leaf compress.externalSummary lacks a seed entry) until #3880's seed lands on master - i.e. merge order mattered: merging this PR first would have put a NEW red on master's own config-surface-guard. This mirrors #3880's exact seed entry (byte-identical, so either PR may merge first and the duplicate is a clean no-op) plus the generator output for it (5 added lines, 0 removed), making this branch self-contained green for both config-surface-guard and docs-sync once the pre-existing master static-gate red (#3870/#3871) clears.
Commit 66219d4 added externalSummary to COMPRESS_SETTING_FIELDS on this branch; the config-surface guard then fails HERE (leaf compress.externalSummary lacks a seed entry) until #3880's seed lands on master - i.e. merge order mattered: merging this PR first would have put a NEW red on master's own config-surface-guard. This mirrors #3880's exact seed entry (byte-identical, so either PR may merge first and the duplicate is a clean no-op) plus the generator output for it (5 added lines, 0 removed), making this branch self-contained green for both config-surface-guard and docs-sync once the pre-existing master static-gate red (#3870/#3871) clears.
(ai: vllm-qwen/qwen3.8-27b) 收到(同一通知重复转发了三次,只回一次)。 对 66219d4 的复核
处置:已推
|
Closes #3675
What
modelContextLimit/outputHeadroomMaxPct— and in general every compress-block key — written on a provider ROUTE ROOT (providers."https://…": { modelContextLimit: … }, or a named entry) was silently dropped byparseRouteEntry: no effect, no warning. This adds the missing load-time warning so misplaced keys surface instead of sitting dead.Behavior change (old → new)
[acp-config] providers."<key>" carries compress-block keys [ … ] at the route root — they are inert there (move them under providers."<key>".compress to apply)warning per key-set signature, deduped across reloads via the existingwarnNamedProviderOnce.Scope notes
COMPRESS_SETTING_FIELDS(the full compress-block field set, kept in sync withparseCompressSettings) — the two keys named in modelContextLimit / outputHeadroomMaxPct on the provider route root are silently ineffective (inert keys, zero warnings) | provider 路由根上的 modelContextLimit / outputHeadroomMaxPct 静默无效(惰性键、零告警) #3675 are included; every member is inert at a route root today, and none may be added toparseRouteEntry's whitelist while this warning exists (invariant documented at the function).baseUrl/api) are skipped: their parser already rejects unknown root fields loudly (parseNamedProviderRecipethrows → chain disabled with a warning), so a second signal would only add noise.bindbranch on purpose: these keys are inert even on validly bound aliases —parseRouteEntrynever parses them, so the fold onto the target lane cannot carry them.Tests
New regression tests in
tests/named-provider-bind.test.ts: URL route root warns once naming both keys + the.compresshint while the route still parses; bound alias stays inert through the fold and warns; lonely named entry (previously zero warnings) now warns; dialing recipe produces no duplicate loadRoutes warning; reload dedup holds. Targeted suites green locally: named-provider-bind 16/16, issue1815/provider-protocol/compat-drop/compat-roles/issue2260 58/58; typecheck clean. Full-suite verdict from CI.CI-fix follow-up commit (
7e36cb9)First push red: the new warning references
COMPRESS_SETTING_FIELDSbefore its declaration, andscripts/config-surface-guard.mjslocated the field list at the FIRST mention of the name — landing inside this PR's warning template literal and extracting a phantom empty leaf (compress.,), failing the config-surface-guard job and its mirrored test in three shards. That commit re-anchors the guard'sextractStringSeton the Set initializer and adds a regression test. Pure CI tooling — no product-code change.