Repository navigation
Commit a5638b6
docs(qa): seed-mode-matrix scores replace as declared = implemented bare insert (#31203)
<!-- claude-projects-attribution: {"github_login":"os-project-manager"}
-->
_Requested by **Leehom** · [project
thread](https://claude.ai/code/project/chan_01TenzsRopZj4jMbvjX8uz1X?thread=cmsg_01TenzsRopZj4jMbvjX8uz1XCHuoPDSh1whAU4gbrqZ7YX)_
Fixes #31140
Clause-②: no
Metadata-protocol: none
## 维护者速读
- 改了什么:QA 检查清单 `platform-core.seed-mode-matrix` 一项(仅
`docs/qa/platform-checklist/areas/platform-core.json`),把 `replace`
的预期姿态从「声明≠实现(声明删全表再插入,实际裸插入)」改成「声明=实现:只插入、不删任何行」,来源引文改引 `seed.zod.ts`
现有原文;revision 6→7,补一条 history。
- 为什么改:#31099(PR #31135)已把 `SeedMode` 的 `replace`
注释改成加载器的真实行为,清单这一项的姿态和引文因此变假,测试员会按一个已不存在的缺口打分。
- 风险与回滚:纯文档,不动代码、不发布;探针与判定不变(F 存活、G 插入、不得勾选「删除限于本对象」)。回滚即还原本 PR。
- 先看:`docs/qa/platform-checklist/areas/platform-core.json` 中
`acceptance[4].clause` 与 `source[0]` 两处。
- 两分钟验证:`pnpm check:platform-checklist`,预期 `OK — 16 areas, 360 items`;再
`grep -c "Delete ALL"
docs/qa/platform-checklist/areas/platform-core.json`,预期 0。
- 需要你做的:无,席位落地。
## What changes
One checklist item, `platform-core.seed-mode-matrix`, in
`docs/qa/platform-checklist/areas/platform-core.json` (+12 / -6):
- `acceptance[4].clause`: the expected posture is now **declared =
implemented**: `replace` inserts every record with no match and deletes
nothing. It quotes both declarations on main (SeedMode's replace member
and SeedSchema's `mode` description) and the loader arm that does it.
F's survival is the declared behaviour, not a gap to record. The guard
stays: no "replace deletes only its own object's rows" tick, and a
future clear makes the clause stale and owes a scoping proof.
- `source[0]`: the SeedMode citation now quotes text that exists on main
("Insert every record, no match, deleting nothing: for a cache table the
caller cleared") and adds SeedSchema's `mode` description, instead of
the removed delete-all wording.
- Same item, same now-false posture, so re-worded with it: `title`,
`steps[5]` (records F's survival as the declared posture instead of "the
declared-vs-implemented gap") and `variants[3]`.
- `revision` 6 → 7 plus a `history` row, as the checklist README's
Change rule requires for a semantic edit (run records pin the revision
they ran against).
Unchanged: the probe itself (add F by hand, publish a replace seed
declaring only G, F survives, G inserted), `acceptance[4].verify` /
`evidence`, and every other clause.
## Why — the ruling's branch, measured
The order rules: if the spec now describes bare insert, the row states
it as the implemented and declared posture. Read on `origin/main`
658d84f:
- **Spec (declared):** `packages/spec/src/data/seed.zod.ts` L27,
`'replace', // Insert every record, no match, deleting nothing: for a
cache table the caller cleared`; L214-215 in SeedSchema's `mode`
describe: "`replace` does the same and deletes nothing: it is for a
table the caller cleared". `git grep "Delete ALL"` over `packages/`: 0
hits.
- **Loader (implemented):**
`packages/metadata-protocol/src/seed-loader.ts` `writeRecord`, `case
'replace'`: a bare `engine.insert` with the comment "caller should have
cleared the table"; `decideWriteAction` routes `insert` / `replace` /
default to `{ action: 'insert' }`.
- **No clearing caller:** `git grep` for a `replace` mode test or arm
over `packages/**/*.ts` (tests excluded) finds only those two arms and
`packages/cli/src/commands/diff.ts` L81, which words a plan line ("a
replay deletes nothing and inserts these again, so rows already in the
table stay").
So the branch taken is **declared = implemented**: the spec no longer
declares a clear.
## Tests
None owed: a QA ledger JSON, no code or tested behaviour changed, so no
unit test and no ablation (os-dev: docs are not ablated). JSON parses
(`python3 -c "import json; json.load(...)"`); edits were exact-string
replacements asserted to match once each, so the hand formatting is
kept.
## Acceptance notes
- **Surface beyond the clause and citation.** The order named
`acceptance[4]` and `source[0]`; `title`, `steps[5]` and `variants[3]`
of the same item stated the same "declared delete-all, implemented
insert" posture, and the checklist README requires the revision bump and
history row. All in the one file the order names; nothing else touched.
- **Not touched, by rule:** `docs/qa/platform-checklist/FOLLOW-UPS.md`
row K6 still describes replace as declared ≠ implemented ("Delete ALL
records, then insert"). The checker counts FOLLOW-UPS.md as append-only
text (its line-citation limb: "history rows and FOLLOW-UPS.md — counted,
not judged"), so it is history, not a live row. Noted, not filed.
- The history row of revision 1 (2026-08-30) also narrates the old gap;
history rows are append-only and stay as written.
- Bounded by the order: no edit to `packages/spec/**` or the loader.
## Verification
Gate union derived by `node scripts/pm/dispatch-gates.mjs --commands
--repo objectstack-ai/objectstack` (16 families for this diff), run on
head `6c5fe906`, reconciled with `--ran`: "16 derived famil(ies)
accounted for — 16 run, 0 NOT-MEASURED".
<details><summary>16 gates, exit codes captured before any
pipe</summary>
- `node scripts/check-adr-links.mjs` (and `--self-test`): exit 0 / 0
- `node scripts/check-closing-keyword-parity.mjs` (and `--self-test`):
exit 0 / 0
- `node scripts/check-comment-mask-corpus.mjs`: exit 0
- `node scripts/ci/plan-test-core-shards.mjs --self-test`: exit 0
- `pnpm --filter @objectstack/lint run check:doc-formula-expressions`:
first run exit 3 (PREREQUISITE NOT MET: formula and lint not built;
nothing measured), then after `pnpm exec turbo run build
--filter=@objectstack/formula --filter=@objectstack/lint` under the
verify lock (VERDICT command-exit 0), exit 0
- `pnpm check:ci-filter-parity`, `check:cross-package-test-inputs`,
`check:doc-authoring`, `check:driver-memory-census`,
`check:gitlink-declared`, `check:nul-bytes`, `check:refd-timer-probe`,
`check:watch-hint-literal`: exit 0 each
- `pnpm check:platform-checklist`: exit 0, "check-platform-checklist: OK
— 16 areas, 360 items (354 active, 1 planned) … symbol anchors:
1145/1155 resolved … 10 on the named #16898 residual"
</details>
- `node scripts/check-platform-checklist.mjs --changed-from
origin/main`: exit 0 (no symbol anchor targets the changed file).
- `pnpm lint` scoped: no package touched; the root eslint config does
not lint the checklist JSON, so there is nothing to scope it to.
- CI families are read from this PR's check-runs, not re-run here.
`skip-changeset`: `docs/qa/**` ships in no package's `files[]`.
---
_Generated by [Claude
Code](https://claude.ai/code/session_01FEkQ5mfyhgv2EebbRFAVKL)_
Co-authored-by: Claude <noreply@anthropic.com>1 parent b48490e commit a5638b6
1 file changed
Lines changed: 12 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3053 | 3053 | | |
3054 | 3054 | | |
3055 | 3055 | | |
3056 | | - | |
| 3056 | + | |
3057 | 3057 | | |
3058 | 3058 | | |
3059 | | - | |
| 3059 | + | |
3060 | 3060 | | |
3061 | 3061 | | |
3062 | 3062 | | |
| |||
3078 | 3078 | | |
3079 | 3079 | | |
3080 | 3080 | | |
3081 | | - | |
| 3081 | + | |
3082 | 3082 | | |
3083 | 3083 | | |
3084 | 3084 | | |
| |||
3108 | 3108 | | |
3109 | 3109 | | |
3110 | 3110 | | |
3111 | | - | |
| 3111 | + | |
3112 | 3112 | | |
3113 | 3113 | | |
3114 | 3114 | | |
| |||
3128 | 3128 | | |
3129 | 3129 | | |
3130 | 3130 | | |
3131 | | - | |
| 3131 | + | |
3132 | 3132 | | |
3133 | 3133 | | |
3134 | 3134 | | |
| |||
3138 | 3138 | | |
3139 | 3139 | | |
3140 | 3140 | | |
3141 | | - | |
| 3141 | + | |
3142 | 3142 | | |
3143 | 3143 | | |
3144 | 3144 | | |
| |||
3182 | 3182 | | |
3183 | 3183 | | |
3184 | 3184 | | |
| 3185 | + | |
| 3186 | + | |
| 3187 | + | |
| 3188 | + | |
| 3189 | + | |
| 3190 | + | |
3185 | 3191 | | |
3186 | 3192 | | |
3187 | 3193 | | |
| |||
0 commit comments