Skip to content

release v0.1.190 - #2581

Merged
ranxianglei merged 3 commits into
masterfrom
2026-10-10_release-v0.1.190
Oct 10, 2026
Merged

ranxianglei merged 3 commits into
masterfrom
2026-10-10_release-v0.1.190

Conversation

@github-actions

Copy link
Copy Markdown
Contributor

Auto-fallback from the one-click release workflow: direct push to master was blocked by branch protection. Merging this PR publishes via the standard release.yml flow.

Changes since v0.1.189

@github-actions

github-actions Bot commented Oct 10, 2026 •

Copy link
Copy Markdown
Contributor Author

📦 Built Package Artifact

Branch: 2026-10-10_release-v0.1.190 (30e679e)

Option A — Install this exact build (recommended)

npm install -g billion-context@0.0.2813-pr.2581.ff9a63c

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-pr2581.tgz
npm install -g package

Install instructions are refreshed on each push.

@ranxianglei

Copy link
Copy Markdown
Owner

🤖 Powered by ework · qwen3.8-27b

📦 release v0.1.190 — 版本区间回归审计结论

审计范围: v0.1.189(4d5dab9) → cfcf8dc29(release tip = master + 1 个 bump commit),123 files、+8895/−1092、97 content commits。按 §2b 以整窗合并视角逐段通读(非逐分支、未开子 agent 拼结论),高危域(自动更新/dsh/lockfile/网络代理/安装)逐行精读。bump commit 本身纯净(version-only:package.json 0.1.189→0.1.190 + package-lock 两行)。

结构化八问

1. 是什么问题:这是发布 PR,不是单点缺陷——聚合 v0.1.189 以来约 60 项独立修复/特性。本审做的是「上一版本以来的全部变更」回归审计。

2. 什么原因导致(本窗变更的性质):一整套机制级根因修复,各自锚定具体事故——dsh 持久态保护(#2419/#2446/#2447/#2481)、external-summary autoFold(#2326/#2484/#2494)、fold 位置身份(#2480/#2487)、网络/代理健壮性(#2484/#2491/#2493/#2496/#2502)、anthropic thinking 签名安全(#2501)、安装就绪门禁(#2471)、非 ASCII 头守卫(#2455)。

3. 影响范围与严重程度:无用户可见破坏。多数改动是双重 opt-in 或证据白名单门控(autoFold 需 enabled:true 且 autoFold:true;透明截断仅 pi;dsh 持久守卫仅 dsh lane),默认用户零影响。常开改动均为「安全方向的严格改进」(#2490 死探守卫、#2558 图片计费、#2494 流式探测)。多项修复消除的是此前会永久砖掉会话的场景(anthropic 未签名 thinking 中毒、非 ASCII model id 本地抛错杀死整轮、dsh 折叠丢失持久态)。

4. 怎么修复的:机制层、治本不堵漏——kernel 新增加法钩子 Config.isMessageProtected(unset=字节级不变)承载宿主声明的持久态保护;thinking 块「持有到首个负载 delta 才下发」让截断前签名缺失对客户端不可见;fold 调和引入位置身份(Pass0 按序认领 churned id)+ reuse-by-id 快路径;UTF-8 字节数学的死探守卫(窗口×7.5 与 2MB 双闸,CJK 感知);autoFold fail-open + 10min 退避;KDD#9 证据白名单做透明截断;跨 lane 统一 ASCII 头闸门(asciiHeaderValue / hermes _stampable_header_value);防御式 install gate。

5. 是否有回归问题:未发现回归。逐项过既有行为:

6. 是否破坏缓存:净正向。#2558 修图片在 usage 基线下的重复计费(解除 clamp 饥饿);#2499 恢复客户端自管 session 折叠后前缀写回 cache;#2326 first-sight 批量排空把前缀重付从 2.29×/tok 压到 0.032×/tok(~70×);pi-subagents #2546 修 delegate 通知掉出 cache。未引入任何缓存/重试/增量游标/去重键失效;fold-reconcile 的 reuse-by-id 反而增强了 fold 状态复用。

7. 是否改了设计方向:无架构转向。全部扩展现有机制(kernel 钩子、证据白名单、三级 config 级联、exit-matrix 契约账本);fetch-chain/index.ts 是从 native-intercept.ts(−228 行)抽出成独立可测模块,纯组织性。

8. 是否引入了新的配置:是,2 个可选字段挂在既有 compress.externalSummary 下——autoFold?: boolean(默认 false)、autoFoldTargetTokens?: int [8192,10000000](engaged 时默认半窗)。两者默认关 → 零迁移影响。已在 CONFIGURATION.md(en+zh,1108–1119)+ CHANGELOG 完整记录;website 结构化 compress.yaml 本就未收录整个 externalSummary 块(既有现状,非本次引入),docs-coverage 门绿。

重大行为变更清单(旧→新 + 原因,Deliverables 第 4 条)

  1. dsh压缩与bili压缩冲突 #2490 死探守卫(常开):core 文本字节 > max(2MB, 窗口×7.5)的 payload 由「转发后必 400」改为直接 502 fail-fast + 字节数学提示。严格更优(此前也是 400)。
  2. 输出预算裁剪把图像token计了两遍,usage级基线已含图像,ctx.imageTokens又被加一次 #2558 图片计费(常开):output-clamp 输入估算的图片成本改为只加到 local-est 臂(usage 基线已含图片,不再重复计)。有 usage 基线的含图会话 clamp 更宽松(修饥饿)。
  3. preflight summarization defaults to non-streaming upstream that requires streaming returns HTTP 400 and is not auto-detected, causing a fail-fast 502 instead of compression #2494 流式探测(常开):非流式摘要的任何 400 触发一次性 SSE 探测(旧:仅认 "stream…true" 措辞);排除 Google wire 与已识别的 max_output_tokens 参数拒绝。自愈面扩大。
  4. [bug] anthropic 线盲重取(#413/#1455)把没签名的 thinking 块交给客户端:下一轮 400 "thinking.signature: Field required",Claude Code 随即永久剥掉全部历史 thinking #2501 未签名 thinking(anthropic 插件模式):thinking start 持有到首个负载 delta;签名上游上未签名块一旦上 wire 即拦 re-fetch,客户端丢弃整次失败尝试而非持久化毒块。修「下一轮 replay 被拒 → Claude Code 永久剥离全部历史 thinking」。
  5. [Pi/Windows] 偶发 Responses 流截断:长间隔/TTL 重读标记后几轮内报错的两次观察(因果待确认) #2563 透明截断(仅 pi):pi 宿主插件会话收到裸流切断(不合成帧)交由其原生 transient 分类器重试;其余 agent 不变(保持 in-band 信号)。证据白名单,dsh/opencode/codex 待流量证据再扩。
  6. [bug] 模型 id 含中文时 x-bili-plugin-model 触发 undici ByteString 异常,整轮请求发不出去(7 文件 8 处写入点,pi/omp/opencode/dsh) #2455 非 ASCII model 头(opencode-v2 + hermes):非 ASCII model id 不再写入 x-bili-plugin-model(跳过 → proxy 回退 body model),旧值会本地抛 TypeError 杀死整轮/hermes 截断出非法头。
  7. [OpenCode v2] 压缩后底栏仍约 90%,上游 input 只有约 2.6 万(#590 未覆盖 OpenCode) #2491 OpenCode V2 WS:拦截面从 openai+azure 扩到任意 /responses WS 端点(自定义 OpenAI 兼容 provider 之前 WS 下静默不压缩)。azure 头帽处理仍在服务端 responses-ws 出口。
  8. [bug] anthropic 线 proxy 模式:压缩回合的 round-2 重建丢失客户端 cache_control,折叠后下一条请求只能命中 system 前缀 #2499 anthropic 客户端 cache_control:round-2 重建回退用客户端自采的 message 级 cache_control 断点(旧:丢弃)→ 客户端自管 session 折叠后前缀能写入 cache。
  9. [bug] Claude Code 的 WebSearch 子请求被当成主对话:nudge 基准被搜索的 usage 重锚,导致提前折叠;每次搜索还被注入 bili 工具 #2500 Claude Code WebSearch 子请求:纯 server-tool(web_search_/web_fetch_ 带日期后缀、单消息、无 client tool)的工具调用走 side passthrough(不注入、不重锚主会话 nudge 基线)。
  10. 超窗拒答以 5xx 返回时出现探测死循环;外部摘要链路三处静默/上限问题(含文件:行号与本地验证) #2484 5xx overflow 标记:inspectContextOverflow 增查 5xx(标记匹配仍是硬闸,泛化 5xx 不误判);relay 加 overflow-arm 守卫防本地估计降级上游已证的 5xx 上限。
  11. [Bug] Web UI 将 pi-context-inspector 历史误报与 unannounced-rewrite 合并为已确认压缩冲突 #2545 冲突台账分层:诊断严重度重分 NEUTRAL/CONFIRMED/UNCONFIRMED,未确认信号永不升级为「移除另一压缩器」指令,只读 viewer 归零计。仅诊断措辞,不改压缩行为。
  12. pi-subagents acp_delegate completion notifications are injected via pi's request-local context event, so they vanish from later requests and break stateful upstream sessions #2546:delegate 完成通知经 sendUserMessage(steer) 跨请求持久化(旧:单请求即丢,掉 cache + 剥离模型历史)。
  13. install gate Git-source installs produce an unloadable package: no dist/ at install time, silent success, dead dsh bundle #2471:消费方 git-source 安装在 prepare 阶段响亮失败(点名支持的装法);dev checkout(.git 可自建)与已发布包不受影响。
  14. 版本串带 commit:status 面板/manifest/fetchProxyVersion/stale 提示追加 build commit(纯展示,文档声明无消费者解析)。
  15. [kernel] first-sight-mass 消化期连发小折重复重付尾部(单发大折可省约 70x) #2326 first-sight 排空提示:仅在 [first-sight mass] 消化期替换 nudge 引导文案为「一次批量排空」,非消化期与旧 staged 路径字节一致;无新配置面。

次要观察(非阻塞,记录备查)

  • dsh runtime-context 快照长期累积会 pin 住若干条极小的受保护消息(有界、无害,最新快照语义上取代旧的)。
  • fetchProxyVersion 现返回 version (commit);若未来外部消费者对其做严格解析需注意(当前文档声明仅展示/liveness 用)。
  • website compress.yaml 未收录 externalSummary 块(既有现状,后续可补 parity,非本窗引入)。

判定

可合(mergeable)。 整窗无回归、无缓存破坏、无设计转向;高危域逐行核实,KDD#10 合规;新增配置默认关且文档齐备;CI 在 rebased head cfcf8dc29 全绿(test×4 矩阵 + docs-sync/docs-coverage/unused-exports + hermetic registry e2e + codex/dsh/opencode/pi/OpenCode-V2 WS/real-image billing/persona-continuity 各 lane 全 success),PR mergeable:true。按流程由人工合并触发 CI 发布。

@ranxianglei

Copy link
Copy Markdown
Owner

🤖 Powered by ework · qwen3.8-27b

🔁 本 issue 已在本会话完成审计,结论见上方楼层(comment id 27328):release v0.1.190 版本区间回归审计可合(mergeable)——整窗无回归、无缓存破坏、无设计转向,KDD#10 合规,新增配置默认关且文档齐备,CI 在 rebased head cfcf8dc29 全绿。自该结论后无新用户输入、无修改要求、无 CI 失败报告,故不重复贴全文。合并由人工触发(流程规定 agent 不合并)。如需我针对某一项深入或做改动,请在本线程明确指示。

@ranxianglei

Copy link
Copy Markdown
Owner

双重配置是啥 ?是否可以修复?

@ranxianglei

Copy link
Copy Markdown
Owner

🤖 Powered by ework · qwen3.8-27b

@Dog 指的是我在审计里说的 autoFold 双重 opt-in——compress.externalSummary 下的两个开关要同时为真才生效:

"externalSummary": {
  "enabled": true,          // ① 打开外部摘要链
  "autoFold": true,         // ② 该链的“主动增长折叠”子模式
  "autoFoldTargetTokens": 40000
}

①和②各管什么(不是重复开关):

  • enabled: true = 打开外部摘要链:压缩摘要交给单独配置的模型产出,响应式——溢出窗口时才触发。
  • autoFold: true = 该链的一个子模式:转发前主动把会话折到 autoFoldTargetTokens(默认半窗),模型因此看不到 nudge、也不花 thinking token 起草压缩计划。

为什么要“双重”: autoFold 不是独立功能,它复用链的零模型折叠引擎,链不开它就无从运行。所以依赖真实存在,这是有意设计且已写进文档(CONFIGURATION.md:1119 “it only takes effect while the chain itself is enabled”)。不是 bug、不是冗余;合并成一个开关反而会把「响应式溢出压缩」和「主动增长折叠」两种行为混为一谈,我不建议。

唯一真正的体验瑕疵(可修): 若只写了 autoFold: true 却忘了 enabled: true,解析在 !enabled 处就提前返回(src/external-summary-settings.ts:124/210),autoFold 被静默忽略——不报错、不警告,用户以为开了其实没开。

修法(属 config 面,按项目规则由你拍板):

  • (A,推荐)warn-once:检测到 autoFold 已设但 enabled 未开时打一条一次性警告,把静默失效显性化。零语义变更、最安全。
  • (B)隐式启用:把 autoFold: true 视为隐含 enabled: true。更省事,但改变了字段语义(一个字段带出“启用父级”的副作用),需明确批准。

我的建议是走 (A)。本 release PR 已是 version-bump-only 且审计完成,不在这里夹带改动——如果你认可方向,我另起一个小 PR(引用本线程)实现 (A);或你倾向 (B)/维持现状,告诉我即可。

@ranxianglei

Copy link
Copy Markdown
Owner

本pr改 改不完不能发布

autoFold/autoFoldTargetTokens are parsed only after the chain's enabled gate,
so setting them without "enabled": true was dropped silently — the most likely
misconfiguration of the double opt-in went unnoticed. Both parsers now log a
one-time warning per distinct knob-set instead of no-oping invisibly.
Diagnostic only: behavior is unchanged (a valid "enabled": true chain emits
nothing; a broken/absent chain still resolves to enabled:false), and no config
or env surface is added. CONFIGURATION.md (+zh) and CHANGELOG updated.

Directed as a release blocker in PR #2581 (v0.1.190).
@ranxianglei

Copy link
Copy Markdown
Owner

🤖 Powered by ework · qwen3.8-27b

已在 release 分支修好并推送(commit ddba1b9dd,基于 cfcf8dc29 release v0.1.190),PR #2581 的 head 已随之更新,CI 将重跑。本地定向验证:typecheck 干净 + tests/external-summary-settings.test.ts 41/41 通过(含新增回归用例)。

按八问:

  1. 是什么问题:compress.externalSummary.autoFold / autoFoldTargetTokens 是双重开关,但两个解析器都在 enabled 门禁之后才读取它们——链未启用(或省略 enabled)时设置这两个旋钮会被静默丢弃,无任何报错或警告。这是最容易踩的误配,却完全无感知。
  2. 什么原因:解析顺序——if (!enabled) return {enabled:false,…} 的早退发生在 parseAutoFold() 之前,disabled 路径根本不读 autoFold,配置值无声消失(非校验失败、非生效,而是直接忽略)。
  3. 影响范围与严重程度:仅影响「设了 autoFold 却没设 "enabled": true」的用户;现象是自动折叠静默不生效(回落到经典 nudge),功能本身可用。属可发现性/体验缺陷,无数据损坏、无崩溃;默认用户不受影响(默认即 off)。
  4. 怎么修复:在两个解析器的 disabled 早退分支各加一条一次性诊断警告 [external-summary] … set but "enabled" is not true — the chain is off …,按旋钮组合去重、每进程每种组合只报一次。纯诊断,零行为变更。(另评估过「让 autoFold 隐含启用」的方案:它在目标缺失时会触发 parseCompressSettings 丢弃整个 compress 段、把自定义 prompts 打回默认的副作用,风险不对等,故弃用。)
  5. 是否回归:无。合法配置("enabled": true + autoFold)不进早退分支、零新增日志;broken/absent 链仍解析为 enabled: false;既有测试(含 {enabled:false, autoFold:"junk"} 早退用例)全绿。高危模式逐项过:无语义漂移、无 fail-fast 变吞错、无阈值/时序/输出格式变化。
  6. 是否破坏缓存:不涉及——纯配置解析期的一次性日志,不触碰 wire/缓存/重试/游标。
  7. 是否改设计方向:不涉及——架构/边界/数据流原样,仍是双重显式 opt-in。
  8. 是否引入新配置:不涉及——无新 env/字段/默认值,只多一条日志;CONFIGURATION.md(中英)+ CHANGELOG 已同步说明该警告。

判定:可合。合并即由 release.yml 发布 v0.1.190(我这边不执行 merge,需你手动合并 #2581 )。CI 若转红我会跟进。

可选后续(选项 B):若你更想彻底去掉第二个开关(让 autoFold: true 隐含启用),那属于配置语义变更,我可以作为 follow-up commit 补进本 PR——实现上需在「目标缺失时降级为 disabled+warn 而非抛错」以保住向后兼容。要做就说一声。

@ranxianglei

Copy link
Copy Markdown
Owner

Release review: v0.1.190 (4d5dab98..8e7bb129, 97 commits / 123 files / +8892−1089)

Reviewed the cumulative diff (not per-commit) with four parallel deep-review slices (launcher refactor, external-summary autoFold + #2490, dsh/native family, transport/proxy) plus a local verification pass on the PR head.

Verdict: ✅ mergeable — 0 MAJOR, a handful of MINOR forward-fix items

Sensitive areas (auto-update / dsh)

MINOR findings (forward-fix candidates, none blocking)

  1. Nudge suppression never disarmed when growth folding is — src/server.ts:2390–2397 + the four prepares. For windows ≤8192, the codex lane below ~10K, or explicit autoFoldTargetTokens ≥ overflowTarget, growthArmed goes false but autoFoldEngaged stays true, and both backoff arm sites require growthArmed — session left with neither growth folding nor nudges (overflow preflight still works). Rare, no data loss.
  2. Calibration straddle skips backoff arm — src/server.ts:2792–2806. Fits-branch gates on the uncalibrated estimate while the forward requires the calibrated payload to fit; with k̂>1 straddling the limit a dead external chain is re-attempted every turn with a guaranteed-400 forward. Bounded (traffic flows, no 502 loop).
  3. dsh压缩与bili压缩冲突 #2490 ledger floor never decays; surrender branch re-opens the incident one size up — src/server/budget.ts:243–244 returns undefined (no clamp) when cap < 1024, i.e. a refused replay ≥ ~window tokens forwards the raw max_tokens again; and dshCompactionRefusedBytes (src/server/handle.ts:1491) is write-only metadata, so the floor persists until session eviction. Deliberate and test-pinned (tests/issue2490-ledger-floor-doomed-probe.test.ts:236–240), but it is the same incident class at larger magnitude.
  4. [omp-native] fetch recovery that lands on the same healthy origin is treated as give-up: BILLION_CONTEXT_PROXY is deleted for the whole process #2496 retry widening: disturbed Request body — src/agent/native-intercept.ts:~625–630 now retries same-origin blips (again!==undefined instead of again!==deadOrigin — correct fix), but for Request-object inputs with stream bodies the first failed send can leave the body disturbed; makeTarget(retried) re-sends an empty/EOF body. Pre-existing for new-origin retry; this widens exposure. String/URL + init.body unaffected.
  5. THEORETICAL recursion in fetch-chain — src/agent/fetch-chain/index.ts:118: the pi-marker early-return at depth 1 is not wrapped in dispatchDepth.run(2, …) (unlike the anchor jump at :124). Not reachable today (real pi-web-access captures the base fetch at install); worth a one-line hardening comment.
  6. opencode-v2 conditional tools latch too early — src/agent/opencode-v2.ts:441–449: toolDeltaReady=true latches before registration settles and the registration promise rejection is swallowed (.catch(()=>{})); a rejected ctx.tool.transform leaves acp_retrieve/acp_rule permanently unregistered until host restart — no retry, no log.
  7. launcher addStaticHosts truthiness guard — src/launcher.ts:424: if (host && …) drops empty-string hosts for qwen (previously pushed ""). Unreachable today (constants have no empties; user paths are nonEmpty()-gated). The refactor is otherwise behavior-preserving — verified with a 7,248-case differential harness (912 discoverRoutes + 6,336 resolveClientCommand across the fixture matrix × 3 platforms): 0 output diffs, 0 exception-path diffs.
  8. dsh-native-client cosmetics — theme poll onTheme callback without a !cancelled gate (benign post-unmount no-op on React ≥18) and mid-session theme flip forces an iframe reload. Durable guards protect every historical runtime-context snapshot forever (deliberate; supersede wording is model-side).
  9. Transport slice — 0 MAJOR; byte-identical retry/cache-busting audit found none (truncation re-fetch correctly reuses roundBody bytes, src/loop/core.ts:726–729); MINORs on [bug] Windows 系统代理的绕过列表不认 127.* 这类星号写法:本机和局域网上游也被送进系统代理 #2502 leading-* wildcard semantics, [bug] Claude Code 的 WebSearch 子请求被当成主对话:nudge 基准被搜索的 usage 重锚,导致提前折叠;每次搜索还被注入 bili 工具 #2500 side-request passthrough, opencode stale manifest pinning.

Local verification (PR head cfcf8dc2, rebuilt kernel)

  • update suites (self-refresh / converge / desktop-inplace / tarball / integrity / host-guard): 40/40
  • dsh family + autofold + dsh压缩与bili压缩冲突 #2490 + issue2446/2481/2447/2419 + settings-ui: 37/37 (5 initial failures were environmental — BILI_PROVIDER_REWRITES from my own session's proxy flips planNativeDsh to off; env -u → green)
  • e2e-native-dsh 2/2 · release canary 1/1 · fold-reconcile family + identity-proof + compress-success-tail + external-summary-autofold 89/89 · dist-ready 8/8 · kernel message-protection 6/6
  • Live TEST A (bili pi @ 0.1.190): real model-initiated compress — shrink 53% (~129034/244483 tok), post-fold answers correctly recalled facts from both the compressed range and the live window; cache hit 76% after fold.
  • Live TEST B (dsh headless @ 0.1.190, plugin-spawned proxy): real compress — 6 ranges, shrink 79% (~45156/57219 tok), 6 blocks, usage 52174 → 9% of 229376, session continued cleanly to FINISHED.

CI on the PR head: 26 success + 4 skipped (release lane, tag-only) — consistent with the above.

@ranxianglei

Copy link
Copy Markdown
Owner

🤖 Powered by ework · qwen3.8-27b

收到,谢谢这份独立全量审(四切片 + 本地实测 A/B + canary,很扎实)。结论一致:可合。

我那笔已在位且与你的 9 条正交:autoFold 双重开关警告修复 ddba1b9dd(在你审的 head cfcf8dc2 之上),只动 src/external-summary-settings.ts 的解析期诊断,不碰 server.ts / budget.ts / native-intercept / fetch-chain / opencode-v2 / launcher / dsh-native-client。该提交 CI 已绿:33 success + 4 skipped(release-lane/tag-only),与你的 cfcf8dc 基线一致。

对这 9 条(你标 none blocking)我的建议:

要我现在就开这 5 个 issue 吗?还是你自己分诊 / 或挑其中几条先在本 PR 修掉?给个方向我就动手。

(合并仍需你手动:#2581 )

ranxianglei pushed a commit that referenced this pull request Oct 10, 2026
- nudge suppression: growthFoldingArmed() gates autoFoldEngaged so a
  degenerate growth config (sub-MIN window, target clamped to the
  window) no longer silently swallows every classic nudge; applies to
  all four prepare lanes, responses lane honors the codex intercept bar
- calibration straddle: a growth-armed zero-progress preflight with
  estimate < limit <= calibrated now arms the auto-fold cooldown too
  (was: skip the arm, re-fire the trigger every turn with a guaranteed
  400 forward)
- #2496: a Request-object input whose body was disturbed by the failed
  send fails with the original error — no retry, no respawn, no direct
  degrade (new Request(target, input) would throw 'Body is unusable')
- #1662: pi-marker re-entry at depth 1 now dispatchDepth.run(2) like
  the anchor jump, bounding marker-wrapper chain growth
- #2443: opencode conditional-tool registration rejections surface and
  re-arm the retry cadence instead of latching toolDeltaReady early
- dsh-native-client: onTheme gated on !cancelled

Deferred MINORs tracked in #2602.
@ranxianglei

Copy link
Copy Markdown
Owner

Follow-up on the review MINORs — all six actionable findings are fixed in this PR (0fbf761, on top of ddba1b9); the three deferred ones are now tracked in #2602.

Fixed in this PR

# Finding Fix
1 Degenerate growth configs silently suppressed classic nudges New growthFoldingArmed() gate: autoFoldEngaged now only suppresses when growth folding can actually fire (enabled + autoFold + effective target < overflow). Applied to all four prepare lanes; the responses lane passes the codex intercept bar (limit × CODEX_COMPACT_HEALTH_RATIO) as the overflow. A sub-8K window or a target clamped to the window no longer eats every nudge.
2 Calibration straddle (estimate < limit <= calibrated) skipped the auto-fold backoff arm The zero-progress branch arms the cooldown on growthArmed alone; the straddle case now backs off instead of re-firing the trigger every turn with a guaranteed-400 forward. The forwarded request's 400 still arms overflow-shrink with real evidence.
4 #2496 retry could re-send a disturbed Request body A Request input whose body was consumed by the failed send now rejects with the original error before any recovery — no retry, no respawn, no direct degrade (previously new Request(target, input) would throw a confusing "Body is unusable" or send an empty body).
5 pi-marker re-entry at depth 1 bypassed dispatchDepth The marker early-return now wraps in dispatchDepth.run(2, …) like the anchor jump, bounding re-wrap growth from marker wrappers that re-read globalThis.fetch dynamically.
6 #2443 opencode conditional-tool registration rejections were swallowed and toolDeltaReady latched early Readiness now latches only when the transform registration settles; a rejection logs and re-arms the retry cadence, so the next routed request re-probes.
8 onTheme fired after client cancellation Gated on !cancelled.

Regression coverage

  • tests/external-summary-autofold.test.ts: growthFoldingArmed truth table (degenerate window, clamped targets, codex bar) + two e2e tests proving classic nudges fire on degenerate growth configs (sub-MIN window; explicit target == window).
  • tests/native-intercept.test.ts: disturbed-body two-phase test — original error surfaces, dispatches: ["self"], 0 respawns, 0 give-ups; an intact body still retries with byte-identical body bytes.
  • Existing suites re-run green: autofold 7/7, native-intercept 47/47, preflight ×11 + codex-compact-e2e + external-summary ×4 = 162/162, tsc clean. (opencode-v2 ×3 and launcher ×5 failures reproduce on the pre-fix base — environment (session proxy ports), not this change.)

Deferred → #2602

#3 ledger floor never decays / cap<1024 surrender (deliberate, test-pinned), #7 addStaticHosts ""-host guard (unreachable today), #9 transport trio (informational).

@ranxianglei

Copy link
Copy Markdown
Owner

🤖 Powered by ework · qwen3.8-27b

独立核对完成,内容与追踪都到位:

分支栈(顺序正确):cfcf8dc29(release bump)→ ddba1b9d(我的 autoFold 双重开关警告修复)→ 0fbf7614(六条 actionable MINORs,作者 ework-agent)。

diff 范围与你列的 6 条一一对应(12 files / +315 −16):

#2602 已建、OPEN、正确跟踪三条 defer(ledger floor 不衰减+cap<1024 surrender / addStaticHosts 空串 host / transport trio),带链回本 review;已被认领后续处理。

CI(0fbf7614):27 success / 4 skipped / 8 in-progress,目前 0 失败——还在收尾,全绿我会再确认一句。

结论:代码与追踪都齐了,等 CI 全绿即可由你手动合并(我这边不 merge):#2581

@ranxianglei

Copy link
Copy Markdown
Owner

ci 失败了看看为啥

- nudge suppression: growthFoldingArmed() gates autoFoldEngaged so a
  degenerate growth config (sub-MIN window, target clamped to the
  window) no longer silently swallows every classic nudge; applies to
  all four prepare lanes, responses lane honors the codex intercept bar
- calibration straddle: a growth-armed zero-progress preflight with
  estimate < limit <= calibrated now arms the auto-fold cooldown too
  (was: skip the arm, re-fire the trigger every turn with a guaranteed
  400 forward)
- #2496: a Request-object input whose body was disturbed by the failed
  send fails with the original error — no retry, no respawn, no direct
  degrade (new Request(target, input) would throw 'Body is unusable')
- #1662: pi-marker re-entry at depth 1 now dispatchDepth.run(2) like
  the anchor jump, bounding marker-wrapper chain growth
- #2443: opencode conditional-tool registration rejections surface and
  re-arm the retry cadence instead of latching toolDeltaReady early
- dsh-native-client: onTheme gated on !cancelled

Deferred MINORs tracked in #2602.
@ranxianglei
ranxianglei force-pushed the 2026-10-10_release-v0.1.190 branch from 0fbf761 to 30e679e Compare October 10, 2026 05:46
@ranxianglei

Copy link
Copy Markdown
Owner

Correction — fix #5 withdrawn, commit amended (new head 30e679e2)

The pi-marker depth-1 change listed in my previous comment broke CI: tests/native-intercept-selfheal.test.ts "pi-web-access: preserve an older proxy wrapper and still truncate unknown history beneath it" failed with RangeError: Maximum call stack size exceeded on all three test matrix jobs (ubuntu-22, ubuntu-24, windows-24 — everything else green).

  • Reproduced locally, reverted src/agent/fetch-chain/index.ts to the pre-fix code (byte-identical to ddba1b9), selfheal suite back to 17/17, native-intercept 47/47, tsc clean.
  • Root cause of the regression: the depth-1 retention on the __piWebAccessProxyFetch branch is intentional (DSH0.1.7-rc.2中billion-context与dsh-codex-subscription的冲突? #1662). The same depth-1 entry still runs the oldest-live-anchor jump that truncates unknown wrapper history; wrapping the branch in dispatchDepth.run(2, …) removes that truncation on re-entry, so a marker wrapper that re-enters a bili link through unknown wrappers recurses forever.
  • The original MINOR feat: persistent + namespaced sessions, multi-tenant session isolation, stream robustness #5 concern (unbounded re-wrap growth via marker wrappers that dynamically re-read globalThis.fetch) is already bounded by that same anchor jump — no fix needed. The review finding was over-cautious.

Effective fix set in 30e679e2 (11 files, +314/−15): #1 suppression gate (growthFoldingArmed, all four prepare lanes + codex bar), #2 straddle backoff arm, #4 disturbed-body guard, #6 opencode conditional-tool rejection handling, #8 onTheme cancellation gate. Deferred #3/#7/#9 → #2602.

@ranxianglei

Copy link
Copy Markdown
Owner

🤖 Powered by ework · qwen3.8-27b

独立核对确认,30e679e2 干净:

结论:修正到位,等 CI 全绿即可手动合并(我这边不 merge):#2581

@ranxianglei
ranxianglei merged commit e1cd9e1 into master Oct 10, 2026
39 checks passed
@ranxianglei

Copy link
Copy Markdown
Owner

🤖 Powered by ework · qwen3.8-27b

✅ CI 全绿(30e679e2):35 success / 4 skipped(release-lane/tag-only)/ 0 失败,之前红的 ubuntu-22/24 + windows-24 三个 test job 全部转绿。

结论:修正到位、fetch-chain 已还原、五条修复回归测试齐、CI 全窗通过 —— 可合。请手动合并 #2581 (我这边不 merge)。合并即由 release.yml 发布 v0.1.190。

ranxianglei added a commit that referenced this pull request Oct 10, 2026
…indings-2581

docs(#2602): pin deferred MINOR intents from the v0.1.190 release review (#2581)
@ranxianglei
ranxianglei deleted the 2026-10-10_release-v0.1.190 branch October 15, 2026 05:33
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.

1 participant