Repository navigation
fix(#107): settle-guard activity 收敛到 bus + 漂移门覆盖 §18.11 + CHANGELOG 历史措辞 - #108
Merged
Merged
Conversation
….11 in the drift gate - settle-guard: delete the private reportActivity copy. before_settle/register now call src/core/bus.ts; reportActivity swallows a stale-ctx rejection and returns false, so the settle decision never depends on activity while the guard still disposes the dead generation after answering (0.3.2 fix preserved). Wording unified to bus's literal `N async tasks`. - drift gate: scan §17 + §18 (incl. §18.11) with lower bounds (sections + checks) and self-tests for `时 6 个` → `时 5 个` and `默认 5 个工具` → `默认 6 个工具`; a truncated contract fails too. - CHANGELOG: per-task activity id is a shape constraint, not a visibility promise. - CONTRACT §7: record the convergence (was "known implementation fork") and current bus cites. - report: docs/reports/pi-async-guard-gaps.md (Fixes #107). Verification: typecheck pass; tests 480 / pass 451 / fail 16 / skipped 13 — the 16 failures and 13 skips are the identical pre-existing macOS set from the 474-test baseline (no regression).
27 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #107(条目来源:PR #105 报告
docs/reports/contract-cleanup.md§2 的 3 处实现/文档不一致 + 1 处守卫盲区)交付报告:
docs/reports/pi-async-guard-gaps.md(逐项判据、file:line 证据、变异记录)。四处改动
src/guard/settle-guard.ts不再自带reportActivity(),agent_before_settle/register()都走src/core/bus.ts(一处实现、一个文案)。bus.ts的reportActivity补try/catch,宿主拒写(stale ctx)时吞异常并返回false;守卫先答完当前 settle 边界再dispose()死代——异常不参与、也不改变 settled 判定(0.3.2 自愈保留)。N async tasks(恒复数):bus 是 3 个调用点共享的实现,选它只改守卫count==1一条路径;选守卫单数则要改共享 formatter、波及 TUI/扩展三处。1 async tasks的语法瑕疵记录为已知 cosmetic。tests/f-reminder.test.ts的守卫改为scanToolSurfaceContract(),扫 §17 + §18,断言sections === ["§17","§18"]且checks >= 5;自测覆盖 §18.11时 6 个 → 时 5 个、§17默认 5 个工具 → 6 个工具,以及「丢段 → 下限失败」。旧门对同一漂移文本 13/13 通过(盲区复现),新门红。ui.setActivity、legion 侧依赖上游 #156。验证
npm run typecheck— passnpm test— baseline 474 / 445 pass / 16 fail / 13 skip → after 480 / 451 pass / 16 fail / 13 skip;失败集合逐条相同(本机 macOS 既存失败,CI 是 Ubuntu),新增 6 条测试,无删除/新增 skip。