Skip to content

Commit 3de484d

Browse files
docs(lint): the liveness lint's live-elsewhere example no longer names manifest.runtime (#27650)
<!-- claude-projects-attribution: {"github_login":"marchtian"} --> _Requested by **田騏** · [project thread](https://claude.ai/code/project/chan_01VmuUhXU9SSUzqJYyXSmYSi?thread=cmsg_01VmuUhXU9SSUzqJYyXSmYSiVq7nt6cbmb2bF5FwzGEghX)_ Fixes #27569 Clause-②: no Metadata-protocol: none ## 维护者速读 - **改了什么:** `packages/lint/src/lint-liveness-properties.ts` 里 `live-elsewhere` 判定的两处举例(文档注释和默认提示语)不再点名 `manifest.runtime`,改成通用描述:「本仓零分发、唯一执行者是另一个仓库的门(例如市场发布门),台账行的 `evidence` 指明它」。规则 id、消息、提示语的指令(保留该属性、看台账行的 evidence)都没动。 - **为什么改:** `manifest.runtime` 这行台账在 #27123 之后已是 `live`(本地有加载期分发点),而提示语还把它当作 `live-elsewhere` 的样板,作者读到的与台账相反。今天 `packages/spec/liveness/*.json` 里 `live-elsewhere` 行为零,所以没有现成的真实样板可换,只能改成通用说法。 - **风险与回滚:** 只改注释和一条提示字符串,无行为变化;回滚即 revert 本 PR。`packages/lint/CHANGELOG.md` 未动(发布流程所有)。 - **先看:** `packages/lint/src/lint-liveness-properties.ts` 的 `defaultHint`(`live-elsewhere` 分支)那一个 hunk,再看上面文档注释的 hunk。 - **两分钟验证:** `grep -n "manifest.runtime" packages/lint/src/lint-liveness-properties.ts` 应无命中;`pnpm --filter @objectstack/lint test` 全绿(177 个文件)。 - **需要你做的:** 无,席位落地。 ## What changes `lintLivenessProperties` carried `manifest.runtime` as its worked example of a `live-elsewhere` row in two places: the `describe()` doc comment and the `live-elsewhere` verdict's `defaultHint`. Measured on `main` @ `178b5238`: - `grep -n "manifest.runtime" packages/lint/src/lint-liveness-properties.ts` → 2 hits (L217, L295). - `packages/spec/liveness/manifest.json`, row `runtime`: `"status": "live"`, `"verifiedAt": "2026-10-29"`, `"evidenceScope": "in-repo"`; its `note` opens `ENFORCED AT LOAD SINCE #27123 (ADR-0025 §3.5 M1), AND STILL AT THE CLOUD PUBLISH GATE — so the verdict FLIPPED live-elsewhere → live on local evidence`. - `grep -rc '"status": "live-elsewhere"' packages/spec/liveness/*.json` → 0 rows today (statuses present: live 899, dead 80, planned 30, experimental 1). So there is no real row to swap in, and both places describe the verdict generically instead, as the card's second option allows. The ledger README (`packages/spec/liveness/README.md`, the `live-elsewhere` section) keeps the `manifest.runtime` account as the historical worked example by its own statement, and is not touched. The swap: - Doc comment: the parenthetical now reads "a key with zero local dispatch whose only enforcer is a gate in another repository, a marketplace publish gate for instance, named by the ledger row's `evidence`", followed by its own sentence "No shipped row holds the verdict today; the ledger README keeps the historical worked example."; "That row is not deletable" becomes "Such a row is not deletable". (The first head named "a closed runtime's check" as a second shape; the review's nit 1 removed it, because the README's own rule keeps a key consumed only by the closed runtime at `live`.) - Hint string: `(for \`manifest.runtime\`, the cloud marketplace publish gate)` becomes `(a marketplace publish gate, for instance)`. The sentence around it — "Keep it — nothing reads it when the stack loads here, but a sibling repo enforces it (…); see the ledger row's evidence for the enforcer." — is unchanged. - Rule id `liveness-live-elsewhere-property`, the message `kind` and the hint's instruction are unchanged. No behaviour change. - Changeset `.changeset/27569-liveness-lint-elsewhere-example.md`: `@objectstack/lint` patch (the hint string ships in the package's dist), with the `Clause-②: no` / `Metadata-protocol: none` lines. `packages/lint/CHANGELOG.md` is not edited. ## Tests No test pins the old example text. The existing pins on this verdict still hold and were run: `toContain('sibling repo')`, `toContain('evidence')`, `toContain('keep it')`, `not.toContain('Remove it')`, and the default-hint equality pins (`lint-liveness-properties.test.ts`). The test file's comments that mention `manifest.runtime` describe the history ("until #27123 flipped that row") accurately and are outside the ruling's two places, so they are left as they are. - `pnpm --filter @objectstack/lint test` @ `16006a58` (under `os-verify-lock`): **Test Files 177 passed (177) · Tests 7599 passed | 5 skipped (7604)**, `VERDICT command-exit 0`. - `pnpm --filter @objectstack/lint typecheck` @ `16006a58`: `tsc --noEmit` + `check:test-typecheck` green, `VERDICT command-exit 0`. ## Acceptance notes - The commit's doc comment drops the sentence that `manifest.runtime` was the first row carrying the verdict; that history stays in the ledger README's worked example and in the test file's comments, which this card does not touch. - Out of scope, noted only: `packages/lint/CHANGELOG.md` still carries the old hint sentence in its released entries, which is release-owned text and stays as shipped. ## Verification Local subset, run on the final head `f1d90c65` (the derived list from `node scripts/pm/dispatch-gates.mjs --commands --repo objectstack-ai/objectstack`, 52 commands, each exit code captured to a file before any pipe, then `--ran` reconciliation): - `dispatch-gates --ran`: **52 derived families accounted for — 50 run (all exit 0), 2 NOT-MEASURED** (recorded exit 3, PREREQUISITE NOT MET): `node scripts/check-plugin-teardown-shape.mjs --self-test` (its fixture needs an unshallowed clone; this checkout is shallow) and `pnpm check:dual-build-cjs-loads` (needs the whole `pnpm build`; only the lint, objectql and spec closures were built here). Both are CI's on a full checkout and build. - Among the 50 green: `check:doc-authoring`, `check:nul-bytes`, `check:changeset-no-major`, `check:empty-changeset`, `check:adr-0087-registration`, `check:docs-transcript-drift`, `check:lean-entry-closure`, `check:issue-citations`, `check:published-files`, `check:test-source-alias`, `check:cross-package-test-inputs`. - `pnpm --filter @objectstack/lint test` @ `f1d90c65`: Test Files 177 passed (177), Tests 7604 passed (7604), `VERDICT command-exit 0`. - `pnpm --filter @objectstack/lint typecheck` @ `16006a58` (the only later edits are comment and string text in the same file; the head run of `tsc` is CI's `TypeScript Type Check`): `VERDICT command-exit 0`. - `node scripts/check-commit-card-trailers.mjs --range origin/main..HEAD`: green (no card relation, no model identifier in the trailer pair). - Not run locally, declared to CI: `test:repo` (the vitest `repo` project, `Test Core`), the lint workflow's whole-tree farm, and the dogfood battery (n/a: no `!` in the title and no `(narrowing)` arm). Independent full review record: posted as a comment on this PR (PASS WITH NITS on `16006a58`, nits applied; delta PASS; whole-PR PASS at `f1d90c65`). --- _Generated by [Claude Code](https://claude.ai/code/session_017ihL2dZmutT6YPdL6nSFmM)_ --------- Co-authored-by: Claude <noreply@anthropic.com>
1 parent 5d759b1 commit 3de484d

2 files changed

Lines changed: 22 additions & 9 deletions

File tree

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
---
2+
'@objectstack/lint': patch
3+
---
4+
5+
docs(lint): the liveness lint's `live-elsewhere` worked example no longer names `manifest.runtime`, a `live` row since the boot-time loader began dispatching on the plugin tier
6+
7+
Clause-②: no
8+
Metadata-protocol: none
9+
10+
`lintLivenessProperties` used `manifest.runtime` as its worked example of a `live-elsewhere` row in its doc comment and in the `live-elsewhere` verdict's default hint. That row reads `live` now, so the example taught the opposite of the ledger. Both places describe the verdict generically instead (a key with zero local dispatch whose only enforcer is a gate in another repository, a marketplace publish gate for instance, named by the ledger row's `evidence`), since no shipped row holds the verdict today. The rule, its id and the hint's instruction (keep the property; read the row's evidence for the enforcer) are unchanged.

‎packages/lint/src/lint-liveness-properties.ts‎

Lines changed: 12 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -213,14 +213,17 @@ function isAuthored(value: unknown): boolean {
213213
* `#14057` is the same defect class arriving through a different door, and the
214214
* reason the boundary below is a THROW rather than a fallthrough. #13483 added
215215
* the fifth status to the ledger vocabulary — `live-elsewhere`: dead HERE by
216-
* measurement, genuinely enforced in a sibling repo (first row:
217-
* `manifest.runtime`, whose enforcer is the cloud marketplace publish gate) —
218-
* without teaching this function about it. Falling into `dead` would have said
219-
* "Remove it" about a key whose enforcement is real and remote, i.e. exactly
220-
* the most wrong sentence available: deleting it tears out a live gate's
221-
* input. That row is not deletable, so `live-elsewhere` gets its own branch and
222-
* its own rule id, and its default hint points the author at the ledger row's
223-
* `evidence` — the enforcer's address — rather than at a delete key.
216+
* measurement, genuinely enforced in a sibling repo (a key with zero local
217+
* dispatch whose only enforcer is a gate in another repository, a marketplace
218+
* publish gate for instance, named by the ledger row's `evidence`) — without
219+
* teaching this function about it. No shipped row holds the verdict today;
220+
* the ledger README keeps the historical worked example. Falling into `dead`
221+
* would have said "Remove it" about a key whose enforcement is real and
222+
* remote, i.e. exactly the most wrong sentence available: deleting it tears
223+
* out a live gate's input. Such a row is not deletable, so `live-elsewhere`
224+
* gets its own branch and its own rule id, and its default hint points the
225+
* author at the ledger row's `evidence` — the enforcer's address — rather
226+
* than at a delete key.
224227
*
225228
* Each verdict below also carries its own DEFAULT hint (used when the ledger
226229
* entry has no `authorHint`; the row's `note` is never shown to an author, since
@@ -292,7 +295,7 @@ function describe(entry: LedgerEntry): { kind: string; rule: string; defaultHint
292295
rule: LIVENESS_LIVE_ELSEWHERE_PROPERTY,
293296
defaultHint:
294297
'Keep it — nothing reads it when the stack loads here, but a sibling repo enforces it ' +
295-
"(for `manifest.runtime`, the cloud marketplace publish gate); see the ledger row's " +
298+
"(a marketplace publish gate, for instance); see the ledger row's " +
296299
'evidence for the enforcer.',
297300
};
298301
}

0 commit comments

Comments
 (0)