Repository navigation
fix(dsh): warn at boot when web presets keep native auto-compaction (#1772) - #1777
Conversation
📦 Built Package ArtifactBranch: Option A — Install this exact build (recommended)npm install -g billion-context@0.0.1755-pr.1777.09fbfccThis exact version is immutable and reproducible. The rolling Option B — Download artifact
tar xzf billion-context-pr1777.tgz
npm install -g packageInstall instructions are refreshed on each push. |
16ffafe to
3f96dd6
Compare
[bot] 🏷 PR #1777 reviewed (against original issue #1772). Verdict: mergeable once CI is green on the rebased head (merge stays human-only). Details: ① Original-issue direction (highest weight) — sound. The #1772 root cause was reproduced against dsh 0.2.0-rc.2 sources with a ② Regression review — existing behaviors on touched paths, itemized:
③ Code — follows house conventions: durable channel via ④ Test quality — real teeth: asserts against the actual ⑤ Diff cleanliness — 6 files, single commit, every line on-purpose. Clean. Stale-base fix (done by me): the branch was based on CI: old head Duplicate screening: no other open issue/PR covers this (searched open PRs for dsh compaction; only this one addresses #1772). Note: #1774 is still 404, consistent with what floor 4 of #1772 reported — if that deletion wasn't deliberate, you may want to look into account/platform access. Behavior change (as disclosed): one additive 一句话中文摘要:审核了 PR#1777(#1772「web profile 下禁用 dsh 自动压缩的 patch 静默失效」)——方向正确(根因在上游 dsh patch 引擎够不到 preset 内实例,本 PR 把静默失效变成启动时可见告警并纠正文档过度宣称,功能级关闭留待上游)、wire/config/持久化/压缩行为零回归、测试直接断言日志文件内容有牙、diff 干净;我已把分支 rebase 到最新 master(3f96dd6d)并本地验证 typecheck + 3402 测试 + build 全绿,等 CI 转绿即可合并。 |
[bot] 🏷 CI confirmed green on the rebased head 一句话中文摘要:rebase 后的新 head(3f96dd6d)CI 已全部转绿(13/13),PR#1777 可以合并;等你操作。 |
3f96dd6 to
2bbde11
Compare
What & why
#1772: in profiles whose bundles include
@deepseek-ai/dsh-web-app, the bundleddsh.bundle.patch.ymlentry- id: compaction-basic / config: {auto: false}silently targets the WRONG row — web-app's own host-planecompaction-basicrow, which web-app already disables (disabled: true). The instance that actually runs lives inside an agent preset (preset-standard.config.plugins→compactiongroup) and is unreachable from any patch layer, so dsh's native auto-compaction keeps firing despite the README's "dsh auto-compaction off" claim. The patch executes successfully against the dead row: no error, no warning.Root cause (verified against dsh 0.2.0-rc.2 sources)
@deepseek-ai/dsh-app-boot'sapplyEntryPatchesindexes patch targets with a single pass over top-level rows plus children of TRUE YAML groups (group: truewith array config). A preset row'sconfig.pluginsis plain config data, not a loader group, so its nested rows are never indexed — no patch layer can address them.dsh-compaction-basic'sautois config-only (no env seam). Repro dump (dsh --profile web --dump-config, bundles[dsh-base, dsh-web-app, billion-context]): the top-level row showsdisabled: true / config: {auto: false}labeled "patched by @deepseek-ai/dsh-web-app, billion-context"; all three presets' nestedcompaction-basicrows carry no config →autodefaults to true.No pure-YAML fix exists in this repo: patch
configis whole-replacement, so targetingpreset-standardwould mean duplicating the entire upstream preset tree into our patch file (freezing upstream changes). Suppressing the running instance from the plugin side would require per-session mount observation inside dsh internals — out of proportion.Changes
src/agent/dsh-native.ts): once per process, the plugin reads the boot-providedprofileContext.startedBundles(dynamic inject, best-effort like the [native] runtime-info protocol: plugins report real model config (model / contextWindow / maxOutput) to the proxy #955 llm services; missing service on older builds degrades to no diagnostic) and, when the profile bundles@deepseek-ai/dsh-web-app, logs a one-time[dsh-client]line through the durable channel (persistClientEvent→ bili.log; GUI hosts swallow stderr) stating that dsh native auto-compaction stays enabled in this profile and that ACP compression is unaffected. Silent failure becomes a visible, greppable diagnostic.dsh.bundle.patch.yml禁用自动压缩在 web profile 下静默失效 #1772)", with the mechanism explained in CLIENTS.tests/dsh-native.test.ts): warns exactly once for a web bundle set, stays silent for non-web sets, honors the once-per-process flag across re-applies, and covers the no-inject direct-field ctx shape.Behavior change (flagged per house rules)
NEW additive log line: profiles bundling
@deepseek-ai/dsh-web-appget ONE extra[warn] [v=…] [dsh-client] profile bundles include @deepseek-ai/dsh-web-app …line in the bili state-dir log at boot. No change to wire format, config schema, persistence, or compression behavior; non-web profiles produce nothing new.Not fixed here (upstream)
The functional gap — making it POSSIBLE to disable the preset-nested compaction-basic — belongs to dsh (deepseek-ai/deepseek-harness): the patch language needs preset-scoped addressing (or preset mounts should inherit same-id host-row config, or web-app should propagate its host-plane compaction config into the presets). Filing there awaits owner approval per cross-repo policy; repro materials are ready in the working session.
Addresses #1772 (not auto-closed: the underlying behavioral fix lands upstream).
Pre-flight on rebased head (80b50b7): typecheck clean, 3400 tests / 0 fail (19 gated e2e skips), build OK.