From 727794b5d903fa9319b741d7fed5ed8cdd2e8bcc Mon Sep 17 00:00:00 2001 From: Claude Date: Mon, 7 Sep 2026 15:38:20 +0000 Subject: [PATCH] agents(os-dev): a declared narrowing that cites the affected set names the instrument's blind spot MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit `turbo ls --affected` derives its set from the package dependency graph, so it is structurally blind to a test that reads another package's source off disk, and the repo-root package is not in the workspace list at all — measured here: `pnpm turbo ls` prints 80 packages and `@objectstack/spec-monorepo` is absent. A narrowing sentence that cites the set therefore cannot assert "cannot move"; it can only assert "not on the graph". Two rule lines added in the local verification section, paid for by folding two cross-reference restatements whose every clause survives in the section each of them pointed at. Co-Authored-By: Claude Fable 5.1 Claude-Session: https://claude.ai/code/session_018dxq7YqsLDMeZDZ5AzsgJX --- .claude/agents/os-dev.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.claude/agents/os-dev.md b/.claude/agents/os-dev.md index 50bf720c14..c65ff36fb4 100644 --- a/.claude/agents/os-dev.md +++ b/.claude/agents/os-dev.md @@ -94,7 +94,6 @@ model: opus - ⛔ 永不把验证挂在后台 watcher 上然后停轮;禁令与两种合法终态见干净收尾节。 - 平台事实:容器把前台命令钉在约 10 分钟上限,超时 SIGTERM 杀掉(`exit 143`)。 - 上限划定前台里放什么:重活走规则 1 的锁;仓级扫描归 CI(见本地验证范围节)。 - - 消融/变异脚本自带还原 trap(硬线在标准条款节的 ablation 条)。 7. **排队不是停摆,在轮内主动等。** 持锁的是你不拥有的进程,它的完成不会唤醒你。 - 99 专指没排到,读作 NOT MEASURED;把间隔花在无锁工作上(写测试、changeset、PR 正文)。 - 再取以同名续位,⛔ 不从队尾重排:`OS_VERIFY_LOCK_SLOT=<稳定名>` 在第一次尝试前就设好。 @@ -130,7 +129,6 @@ model: opus - ② 受影响包自己的 `pnpm test` / `pnpm typecheck`,用 `--filter` 圈定。 - 受影响包 = 本包;import 方只在公开面变化时欠测试:spec 契约、发布的 `exports`、线上形状。 - 公开面字节不变 ⇒ 只欠本包测试与派生门禁,⛔ 不给每个 import 方补测试。 -- `packages/cli` 只欠 `unit` 层(见 Definition of done 的测试条)。 - ③ 派发词点名的门禁族,加上你看得出被牵连的。 - 新 fake engine ⇒ `check:engine-double-contract`;新错误码 ⇒ `check:error-code-casing`。 - `.claude/agents/**` ⇒ `check:agent-model-declared`;任何编辑 ⇒ `check:nul-bytes`。 @@ -161,6 +159,8 @@ model: opus - 报告的 `tests` 字段和 PR 正文两处都要引;门禁日志不带 sha,最后 commit 前的并集量的旧树。 - 迟到的 commit 挪动的恰是 ratchet 读数;复核后任何一次 push,都在新 head 上重跑并集。 - 至少重跑 ratchet 族,然后才更新报告或 PR 正文。 +- 收窄引 `turbo ls --affected` 须同句写明盲区:集出自包依赖图,盲于读盘取别包源码的测试。 +- 仓根包不在 `turbo ls` 里,根级套件整个在图外;故只称「不在图上」,永不称「动不了」。 - 门禁结果的读法:退出码在任何管道之前捕获,报告里引门禁自己印的判定行。 - 免疫写法只有一种,先重定向再捕获:`cmd > /tmp/out 2>&1; EXIT=$?; tail -40 /tmp/out`。 - `EXIT=$?` 跟在 `cmd 2>&1 | tail -40` 之后读到的是 `tail` 的状态。