Repository navigation
Commit 7873a05
docs(governed): ADR-0087, AGENTS.md and the retirement playbook describe the D4 projections and the migration registry as main builds them (#22796)
Fixes #22667
Clause-②: no
Three governed texts still described `packages/spec/spec-changes.json`,
the protocol upgrade guide and
`packages/spec/src/migrations/registry.ts` as committed files with a
regeneration lap. On `main` none of the three is committed. This PR
restates 12 sites as `main` now builds them (11 at the first head, site
12 in patch round 1 below). No code, gate, script or published file
changes.
Dispatched by `/pm-dispatch skills` seat 2 (PM session
`session_011u73oxZ5X95qrARPTeoU6v`, claim `6106319581`), executed in the
same session. Tree read: `origin/main` `a2e94c2a05`. The diff is
measured from that base, and every gate below ran on head `bd6337b8b`.
## What `main` does (measured before editing)
| Fact | Evidence on `a2e94c2a05` |
|---|---|
| Neither projection is committed | `git ls-files
packages/spec/spec-changes.json packages/spec/protocol-upgrade-guide.md
content/docs/protocol-upgrade` prints nothing. `.gitignore` lists all
three paths. |
| Neither projection has a `merge=os-regen` route | `grep -n os-regen
.gitattributes` shows 16 routed paths, and neither projection is one of
them. |
| The guide's copy and route went at #22483 | `514bf3c101` (PR #22556)
deletes `docs/protocol-upgrade-guide.md merge=os-regen` and reduces that
file to a pointer stub. |
| `spec-changes.json`'s copy and route went at #22485 | `46064dfa03` (PR
#22638) deletes the file and `packages/spec/spec-changes.json
merge=os-regen`. |
| `registry.ts` is generated and not committed | `.gitignore` lists it.
`registry.ts.template` is tracked (`ed1de8c2db`, PR #22706) and holds
`STEP18_RATIONALE`, `const step18` and the earlier steps'
`conversionIds` / `rationale`. |
| `gen:migration-registry` exists; `check:migration-registry` does not |
`packages/spec/package.json` scripts. `check-generated.ts` files
`gen:migration-registry` under `UNGATED_GENERATORS`, and its gate was
retired with the committed copy. |
| The two projection checks still exist and never report stale |
`check:spec-changes` / `check:upgrade-guide` run `--check`: they
generate in memory, read nothing on disk, and exit 1 only when
generation fails (`lib/projection-cli.ts`). |
All five commits named above pass `git merge-base --is-ancestor` against
HEAD with exit 0. A positive answer needs no control leg.
## The 11 sites (location, then before and after)
| # | Location (base line) | Before | After |
|---|---|---|---|
| 1 | ADR-0087 `:3` Status | "which says what has landed and which cards
carry the rest" | "which says what is generated where and where each
part landed" |
| 2 | ADR-0087 `:207`-`:208` (2026-08-06 note) | "`spec-changes.json` is
deliberately unsharded" | "was left deliberately unsharded … That call
was about merging its committed copy, which #22485 deleted (PR #22638)"
|
| 3 | ADR-0087 `:258`-`:273` (D4 note) | "The ruled end state, and the
cards that still carry it … #22485, which lands last … Until #22485
lands the committed copies stay in the tree" | "The ruled end state,
landed": #22483 as `514bf3c101` (PR #22556), #22485 as `46064dfa03` (PR
#22638). No committed copy remains, and a registry entry's PR
regenerates neither projection. |
| 4 | ADR-0087 `:283`-`:284` | "which #22485 removes" | "which #22485
removed" |
| 5 | ADR-0087 `:431`-`:432` (P2 bullet) | "is ruled to become a pointer
stub … which #22483 carries" | "became a pointer stub … the docs site's
per-major pages (#22483, PR #22556)" |
| 6 | ADR-0087 `:438`-`:442` (P2 amendment) | "Those copies stay in the
tree until #22485 deletes them … what #22483 and #22485 still carry" |
"Those copies are gone … generate in memory and compare nothing … where
each part landed" |
| 7 | AGENTS.md `:706` | "**eight** checked-in generated artifacts" |
"**six**" |
| 8 | AGENTS.md `:717` (regenerate table) | ADR-0087 row: regenerate
with `gen:spec-changes`, `gen:upgrade-guide` | Gates: the same two, in
memory, red only when the registries do not project. Regenerate: nothing
to commit; `gen:migration-registry` (install, build and test run it too)
writes the gitignored `registry.ts`. |
| 9 | playbook `:213`-`:216` (D3 step) | "在
`packages/spec/src/migrations/registry.ts`" | "在
`packages/spec/src/migrations/registry.ts.template`(`registry.ts` 由
`gen:migration-registry` 从它与 `entries/` 整文件生成并被 git 忽略,在 `registry.ts`
里手改不会进提交)", which is the wording proposed in `6100582202` |
| 10 | playbook `:260` |
"`gen:spec-changes`、`gen:upgrade-guide`、`gen:api-surface`、`gen:docs`。" |
"`gen:api-surface`、`gen:docs`;新条目跑 `gen:migration-registry`;D4
投影不提交,本地不重生成。" |
| 11 | playbook `:335`-`:337` | "只改 conversion 的 `summary` 也会过期 …
所以纯散文改动也要 `gen:spec-changes` + `gen:upgrade-guide`" | "只改 conversion 的
`summary` 不欠重生成。它逐字进两条 D4 投影,都不提交;PR 渲染其 diff。" |
The card lists sites 2, 3, 4 and 6 to 11, with site 9 coming from
`6100582202`. The dispatch's same-class sweep of ADR-0087 found sites 1
and 5, which describe unlanded work in the same way. The verbatim ruling
quotation at ADR-0087 `:219`-`:220` is unchanged, and so is ADR-0120
`:459`-`:460`, which triage ruled to be history. The PR contains nothing
beyond these 11 sites: `git diff --stat a2e94c2 HEAD` shows 3 files,
+37 / -31.
How site 7's count was measured: the table's "Gate that fails" column
names eight gates, and six of them still guard tracked artifacts.
- `check:docs`: `content/docs/references/` (225 tracked files)
- `check:api-surface`: `packages/spec/api-surface/` (19)
- `check:authorable-surface`: `packages/spec/authorable-surface/` (14),
plus `json-schema.manifest/` (14)
- `check:skill-docs`: `skills/README.md`,
`content/docs/ai/skills-reference.mdx`
- `check:skill-refs`: `skills/*/references/_index.md` (9)
- `check:react-blocks`:
`skills/objectstack-ui/references/react-blocks.md`
`check:spec-changes` and `check:upgrade-guide` are the other two, and
their projections have 0 tracked files.
Site 8 differs from the card. The card proposed
`check:migration-registry`, but PR #22706 (`ed1de8c2db`) removed that
gate after the card was filed. The row therefore names the two gates
that do exist and states that there is nothing to commit.
Site 11 differs from the card too. No committed artifact carries a
conversion's `summary` any more. It is read only by the two in-memory
projections (`spec-changes.ts` `to`, `build-upgrade-guide.ts` table
rows) and by their rendered PR diff. A summary-only edit therefore owes
no regeneration.
## Line budget
- `AGENTS.md`: 1108 lines before and 1108 after, with net 0 on the two
edited lines. Ratchet line: `✓ check-skill-line-ratchet: AGENTS.md is
1108 lines (ceiling 1116; headroom 8).` The widest table row is 768
bytes (pin 768).
- `.claude/skills/spec-property-retirement/SKILL.md`: 337 lines before
and 337 after. Ratchet line: `✓ check-skill-line-ratchet:
.claude/skills/spec-property-retirement/SKILL.md is 337 lines (ceiling
337; headroom 0).` Site 9 adds +2 lines for its new parenthetical. Site
11 pays for them with -2 lines by deleting the false regenerate
instruction. That is a content deletion, not a re-wrap. Site 10 swaps
one line for one line. Every new line is at most 120 bytes (largest
119). Breaks fall only where the ratchet's own `breakLegal` allows one.
- ADR-0087 carries no ceiling (+27 / -21).
## Gates
The gate list came from `node scripts/pm/dispatch-gates.mjs --commands
--repo objectstack-ai/objectstack` with no paths: 31 commands derived
from the merge base `a2e94c2a0`. All 31 exited 0 on head `bd6337b8b`.
`dispatch-gates --ran` reports: `✓ dispatch-gates --ran: 31 derived
famil(ies) accounted for — 31 run, 0 NOT-MEASURED (a DERIVED zero — all
31 recorded an exit code and none of them is 3).`
The first run of `pnpm --filter @objectstack/lint run
check:doc-formula-expressions` refused with exit 3 (PREREQUISITE NOT
MET: `@objectstack/formula` and `@objectstack/lint` were unbuilt). I
built both under the verify lock (`VERDICT command-exit 0`) and re-ran
it: exit 0.
Gates the dispatch named, with their verdict lines:
- `check-adr-0087-registration --base origin/main`: "this PR adds no
declared-breaking changeset". Its `--self-test` passes 463 assertions.
- `check:adr-anchors`: OK (64 anchored files, 43489 citations resolve).
- `check-adr-links`: 725 relative link destinations resolve.
- `check-adr-symbol-anchors`: 2309 anchors across 142 records resolve.
- `check:pm-governed-prose`: 2 surfaces name all 6 governed surfaces.
- `check:pm-governed-merges`: passes.
- `check:pm-skill-ratchet`: the two lines above.
- `check:skill-frame-sync`: coherent.
- `check:pm-prior-rulings`: 155 cases pass.
- `check:future-spec-major`: passes.
- `check:docs-audit-scope`: in sync.
- `check:doc-authoring`: clean.
- `check:pm-skill-id-lint`: 34 files clean.
- `check:nul-bytes`: OK (10817 files, no raw control bytes).
- `check-ci-filter-parity`: OK.
The diff touches no package, so no package build or test is owed. CI
runs the rest.
Changeset: none. The diff touches only `docs/adr/**`, `.claude/**` and
the private root's `AGENTS.md`, and no package's `files[]` ships any of
them. The PR therefore takes `skip-changeset`.
## Acceptance notes
- AGENTS.md section "Touched `packages/spec`?" still says "Two
generators have **no** gate at all — `gen:openapi` and `gen:sbom`".
`check:generated --reconcile-only` on this tree prints "3 ungated
generators", because `gen:migration-registry` joined the list at PR
#22706. It is the same family as this card, but it lies outside the
AGENTS.md lines this claim declared, so it is not edited here and goes
back to the seat.
- The same section's "All of them live in one job — `TypeScript Type
Check` … runs its gates **sequentially**" predates this card. Five of
the six gates run in `Type Check · source gates`, and
`check:api-surface` runs in `Type Check · consumer gates`. Both lanes
sit behind the required `TypeScript Type Check` aggregate. Noted only.
- ADR-0120 `:459`-`:460` and `:560` record what that PR ran, and stay
untouched as history.
## Patch round 1 (written by the PM seat from the diff on `origin` and
the dev's report; head `6cb0d8ecd`)
- **Site 12 — AGENTS.md base `:761`–`:762`, the same "Touched
`packages/spec`?" section.** Before: "Two generators have **no** gate at
all — `gen:openapi` and `gen:sbom`. Nothing verifies their output is
current; the wrapper reports that each run rather than staying silent."
After: "Three generators have **no** gate at all. Nothing verifies
`gen:openapi` and `gen:sbom` are current, and `gen:migration-registry`
writes gitignored output that install, build and test regenerate; the
wrapper reports all three each run rather than staying silent."
Evidence: `packages/spec/scripts/check-generated.ts` lists
`gen:migration-registry` under `UNGATED_GENERATORS` since PR #22706
(`ed1de8c2db`), and `pnpm --filter @objectstack/spec check:generated
--reconcile-only` prints "3 ungated generators". The claim's AGENTS.md
surface was widened to the whole section on the card (comment
6106593221) before the edit.
- Incremental diff `bd6337b8b..6cb0d8e`: `AGENTS.md` +3/−2, nothing
else. Whole PR against base `a2e94c2a05`: 3 files, +40/−33.
- Line budget after the patch: `AGENTS.md` 1109 lines (ceiling 1116;
headroom 7), +1 for the sentence's third line; the playbook and ADR-0087
are unchanged from the first head.
- The first Acceptance note below is resolved by this round; the other
two stand.
## 维护者速读(草稿)
**改了什么**:三份给 agent 读的受管文本是 ADR-0087 的 D4 进度注、AGENTS.md「改了
`packages/spec` 要重生成什么」一节和属性退役 playbook。里面还有句子把
`spec-changes.json`、升级指南和迁移注册表 `registry.ts` 当作提交在仓里的文件来写。本 PR 把这 12 处改成
main 现在的样子:两条投影只在发布或文档构建时生成,PR 上只在内存里生成并展示 diff;`registry.ts`
在安装和构建时由模板加条目文件生成,不提交。改动只有文字,不碰代码、门禁和发布内容。
**为什么改**:旧句子会让下一个改 spec 迁移的 agent 去跑一圈已经不存在的重生成。本周已有三个 dev
重生成后又回退。旧句子还会让人把 step-18 的说明手改进一个不会被提交的生成文件,改动在下一次构建时静默丢失。
**风险与代价(含回滚)**:不发布任何包,不改任何门禁或脚本。ADR-0087 里维护者裁决的逐字引文没有动。回滚就是 revert 这一个
PR。代价是 playbook 删掉了一条已失效的陷阱说明(3 行压成 1 行),用来抵付新增的模板说明,行数棘轮不变。
**席位意见**:
**你要做的**:看一遍上面的 11 项清单和补丁轮 1 的第 12 项。同意就给一个 APPROVED review,落地由席位来做。
---------
Co-authored-by: Claude <noreply@anthropic.com>1 parent 322ff1e commit 7873a05
3 files changed
Lines changed: 40 additions & 33 deletions
File tree
- .claude/skills/spec-property-retirement
- docs/adr
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
210 | 210 | | |
211 | 211 | | |
212 | 212 | | |
213 | | - | |
214 | | - | |
215 | | - | |
216 | | - | |
| 213 | + | |
| 214 | + | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
| 218 | + | |
217 | 219 | | |
218 | 220 | | |
219 | 221 | | |
| |||
257 | 259 | | |
258 | 260 | | |
259 | 261 | | |
260 | | - | |
| 262 | + | |
261 | 263 | | |
262 | 264 | | |
263 | 265 | | |
| |||
332 | 334 | | |
333 | 335 | | |
334 | 336 | | |
335 | | - | |
336 | | - | |
337 | | - | |
| 337 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
703 | 703 | | |
704 | 704 | | |
705 | 705 | | |
706 | | - | |
| 706 | + | |
707 | 707 | | |
708 | 708 | | |
709 | 709 | | |
| |||
714 | 714 | | |
715 | 715 | | |
716 | 716 | | |
717 | | - | |
| 717 | + | |
718 | 718 | | |
719 | 719 | | |
720 | 720 | | |
| |||
758 | 758 | | |
759 | 759 | | |
760 | 760 | | |
761 | | - | |
762 | | - | |
| 761 | + | |
| 762 | + | |
| 763 | + | |
763 | 764 | | |
764 | 765 | | |
765 | 766 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | | - | |
| 3 | + | |
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
| |||
205 | 205 | | |
206 | 206 | | |
207 | 207 | | |
208 | | - | |
| 208 | + | |
| 209 | + | |
| 210 | + | |
209 | 211 | | |
210 | 212 | | |
211 | 213 | | |
| |||
255 | 257 | | |
256 | 258 | | |
257 | 259 | | |
258 | | - | |
259 | | - | |
| 260 | + | |
| 261 | + | |
| 262 | + | |
260 | 263 | | |
261 | | - | |
262 | | - | |
263 | | - | |
264 | | - | |
265 | | - | |
266 | | - | |
| 264 | + | |
| 265 | + | |
| 266 | + | |
| 267 | + | |
| 268 | + | |
| 269 | + | |
| 270 | + | |
267 | 271 | | |
268 | | - | |
269 | | - | |
270 | | - | |
271 | | - | |
| 272 | + | |
| 273 | + | |
| 274 | + | |
| 275 | + | |
| 276 | + | |
272 | 277 | | |
273 | 278 | | |
274 | 279 | | |
| |||
281 | 286 | | |
282 | 287 | | |
283 | 288 | | |
284 | | - | |
| 289 | + | |
285 | 290 | | |
286 | 291 | | |
287 | 292 | | |
| |||
428 | 433 | | |
429 | 434 | | |
430 | 435 | | |
431 | | - | |
432 | | - | |
| 436 | + | |
| 437 | + | |
433 | 438 | | |
434 | 439 | | |
435 | 440 | | |
436 | 441 | | |
437 | 442 | | |
438 | 443 | | |
439 | | - | |
440 | | - | |
441 | | - | |
442 | | - | |
| 444 | + | |
| 445 | + | |
| 446 | + | |
| 447 | + | |
| 448 | + | |
443 | 449 | | |
444 | 450 | | |
445 | 451 | | |
| |||
0 commit comments