Skip to content

feat(lint): five publish-time checks for metadata the runtime ignores, and four build probes over what landed - #35244

Merged
objectstack-fleet[bot] merged 18 commits into
mainfrom
claude/issue-34776-publish-checks-build-probes
Nov 19, 2026
Merged

objectstack-fleet[bot] merged 18 commits into
mainfrom
claude/issue-34776-publish-checks-build-probes

Conversation

@objectstack-fleet

@objectstack-fleet objectstack-fleet Bot commented Nov 18, 2026 •

Copy link
Copy Markdown
Contributor

Fixes #34776
Part of #35146

Clause-②: no (narrowing: four publish-time refusals of metadata the schema accepts today)
Metadata-protocol: narrowed
Skills-docs: follow-up #35245

维护者速读

  • 改了什么:发布时新增五条检查(四条拒绝、一条警告),拦住"能通过 schema、运行时却不起作用"的元数据;发布回执新增四条数据探针警告(仪表盘卡片全是 0、汇总字段从未计算、示例数据引用不存在的记录、流程连接器动作不存在)。原计划的第六条"布尔字段不应 required"经合同审查证伪,已从本 PR 移除。
  • 为什么改:这些问题过去只在用户打开页面、保存记录或流程运行时才暴露;现在在发布那一刻就告诉作者,并给出修法。
  • 风险与回滚:已存的元数据不会被改写,也不会在启动时被拒;下一次发布带这四类错误的元数据会被拒并给出修法。两个示例已补上 initialStates 与 timeoutMs,ADR-0087 账本已登记 publish-refuses-metadata-the-runtime-ignores。数据探针只读系统身份、只取判定所需列,并按组织隔离。回滚即 revert 本 PR。
  • 先看:packages/metadata-protocol/src/build-probes.ts(汇总与示例引用两段读数据的逻辑:按组织隔离、只读示例数据自己的行)、packages/lint/src/lint-flow-patterns.ts(http 超时规则读节点级超时、0 视为无超时、durable 不报)、packages/lint/src/validate-inert-object-declarations.ts(空 initialStates 也算未声明)。
  • 两分钟验证:pnpm --filter @objectstack/metadata-protocol exec vitest run --maxWorkers=2 src/build-probes-landed-data.test.ts,预期 21 例全绿;其中 "scoped like the engine's reference audit" 一组断言每次读都带组织与投影列,另一组断言最小/最大/平均汇总的修法点名 --recompute-undefined-on-empty。
  • 需要你做的:请在线程里的决策卡上确认是否去掉“布尔字段必填”这条检查(席位建议去掉,本 PR 已按此去掉)。其余无需决策,审核通过后由席位落地。

What changes

#34776: five authoring rules, in the registry both the runtime publish gate and objectstack validate / lint / compile / build run. Each finding names its fix; os explain RULE carries the reasoning.

Rule Tier Runtime types What it refuses
flow-node-type-no-executor error flow a node whose type no executor in this deployment runs (every run fails with NO_EXECUTOR)
flow-approval-decision-unrouted error flow (inside lintFlowPatterns) an approval node whose decision out-edges are not exactly approve and reject (a decision no label claims runs every out-edge, so both branches run)
flow-http-timeout-missing warning flow (inside lintFlowPatterns) an http node with no positive config.timeoutMs and no positive node-level timeoutMs; a durable: true node is not reported. Like every warning, it makes os validate --strict exit 1
state-machine-no-initial-states error object an active state_machine validation with no initialStates, or an empty list
action-no-object-binding error action a standalone action with locations and no objectName (its button renders nowhere; the handler still answers every object's action route)
  • Rule (1) is judged only against the sealed node-type vocabulary. New AutomationEngine.getSealedNodeTypeVocabulary() answers undefined until sealNodeTypeVocabulary() ran at kernel:bootstrapped, so a boot-time read never judges a vocabulary that is still filling (AGENTS.md "Startup registry reads"). The publish gate reads it per flow write through sealedFlowNodeTypeVocabulary (protocol-authoring-gate.ts). The CLI has no vocabulary (the stack does not say which plugins the deployment loads), so the rule judges nothing on the CLI.
  • Rule (3) is a warning. The http executor arms its timer only when config.timeoutMs is truthy (timeoutMs ? setTimeout : undefined, so 0 arms none), and the engine races a node against node-level timeoutMs only when it is positive (dag-traversal.ts). A durable: true node hands the request to the outbox (or, on the save path, sends it in the background) and does not hold the run; its one waiting arm (no outbox wired, off the save path) is a deployment fact the lint cannot see.
  • Rule (4) reads initialStates as the engine does: checkStateMachine treats an absent or empty list as no entry contract, and skips a rule with active: false.
  • Rule (5): validateActionLocations (action-no-placement) is an advisory, CLI-only placement rule and the runtime gate does not run it (measured in the registry: surfaces: CLI_ONLY). The binding question is a separate gating rule that does run on runtime action writes.
  • protocol.ts was at its facade line ceiling (11705 of 11705 on main). The gate's host for assertRuntimeAuthoringRules is now the draft-verdict host (draftVerdictHost(), a superset of the members it reads), which removed a duplicated host literal and keeps the file at 11704 lines.

#35146: four build probes (warnings on the publish receipt, each with userMessage in all eleven platform locales):

Code Artefact What the person will see
widget_empty_result dashboard (ref: dataset, member: widget) the card's real query answers only zero/null measures: an empty "0" tile
rollup_never_computed object (ref: the object itself, member: summary field) a roll-up blank on every parent that has children
seed_reference_unresolved seed (ref: object, member: field) sample records whose reference names no row: the reference leads nowhere
flow_connector_action_unresolved flow (ref: connector, member: action) a connector_action step the runtime cannot dispatch: refused name, no handler, or degraded
  • widget_empty_result and empty_query are one if / else if: a result with no rows stays empty_query (metadata-protocol: publish-drafts build probes query datasets with no execution context, so a correct dataset widget is reported as an error-tier widget_query_failed #25484). A no-dimension aggregate over an object with no rows the caller sees answers one row reading 0, and is reported, since that is the card the person sees.
  • The roll-up probe judges only parents a sampled child points at (via relationshipField, else the one master_detail/lookup back to the parent), only a field UNSET on all of them (a computed zero is a value), and skips a roll-up with its own filter. It judges one organization at a time, and forms each verdict and count inside it. Its repair names os migrate summary-nulls --apply for count and sum, and os migrate summary-nulls --apply --recompute-undefined-on-empty object.field for min, max and avg (finding(objectql): backfillSummaryNulls cannot fill a JUST-CREATED min/max/avg roll-up — summaryNullIsBackfillable decides on the function alone, so "never computed" is indistinguishable from "no child rows" #15064: the plain run does not fill those), in fix and in the eleven user sentences. It also says a package install or upgrade materialises a roll-up it adds at the install door (summary-install-materialise.ts) and that a child write recomputes the parent that child names.
  • The seed probe reads the rows the loader reports it landed (seedApplied.landed, passed in as seedLanded), by id: the rows it created, and the rows a seed key matched only when the seed's mode wrote them (upsert, update). A row the loader did not land is not read, judged or quoted. A stored dangling value does not block a later edit (data: a multi-user field keeps a deleted user's id, so a later update carrying the field unchanged is refused reference_not_found #29062: the write check judges only references a write adds), so the finding says the reference leads nowhere, not that the record cannot be saved.
  • Every landed-data read runs under the system identity and is scoped like the parent and target reads: the publishing organization when the publish names one, else one organization at a time (each row's own stamped organization, its column named by resolveTenantFieldName through the new optional ProbeEngine.getSchema). The organization rides the context's tenantId, so an object with no tenant column (sys_user) is read unscoped by the engine. Each read is projected to the columns it judges (fields), and each existence check is one id $in read per organization, projected to id. The comment in build-probes.ts states why the seed check does not reuse inspectDanglingReferences (no row filter; one probe per value) and the one residual (under a group tenancy posture the audit leaves its probe unscoped; this probe stays in the row's organization).
  • The connector probe asks the engine the same lookups, in the same order, as the connector_action executor (resolveConnectorInstanceFor for the publishing package, resolveConnectorAction, getConnectorDegradedReason); publish passes the automation service and request.packageId.
  • Spec: descriptions only. RuntimeBuildIssueSchema (code list, severity meaning per code group, flow artefact, connector ref, ref and member meaning) and a state machine's initialStates (omitted or empty, insert is not checked; the author-time rule refuses that at publish). The protocol and validation references are regenerated.

Cloud sources ported (read at cloud origin/main c21b3723c41a66a9a3c0c27e0f80b87dec8f86f9, with git show, nothing checked out):

  • packages/service-ai-studio/src/verify/data-reality.ts: semantics and fix text of rollup_never_computed, widget_empty_result and the reference-integrity check (seed_reference_unresolvable there; here a warning named seed_reference_unresolved as build probes: an empty dashboard card, a roll-up that never computed, and a flow step naming a connector action that does not resolve #35146 asks).
  • packages/service-ai-studio/src/verify/flow-reality.ts: flow_connector_action_unresolved.
  • packages/service-ai-studio/src/verify/graph-lint.ts: read for the approval-edge and state-machine semantics.
  • packages/service-ai-studio/src/verify/view-query-probe.ts: read, nothing ported (view column-summary query probes are outside both cards).
  • packages/service-ai-studio/src/verify/flow-credential-door.ts: read, nothing ported. It is credential policy over the hosted vault, which is hosted-only state.

Tests

  • New pins: validate-flow-node-executors.test.ts, validate-inert-object-declarations.test.ts, validate-action-object-binding.test.ts, two describes in lint-flow-patterns.test.ts, build-probes-landed-data.test.ts, seven new cases in build-probes-user-message.test.ts, two in flow-node-type-audit.test.ts. Each rule and probe has a positive pin and a must-stay-silent pin, plus the runtime gate path (runRuntimeAuthoringRules) for the lint rules.
  • This round: initialStates: [] trips the rule, active: false is silent, a required boolean is not refused at the gate; node-level timeoutMs is honoured, 0 is no timer, durable: true is silent; the seed probe ignores a row the seed did not write and a composite-key seed; a describe asserts each landed-data read's where, fields and context, with and without a publishing organization (a sys_user target resolves unscoped).
  • Round 4: the seed probe ignores a row the loader did not land (same key, or another organization's), judges a matched row only under a writing mode, and judges nothing without landed; the roll-up probe forms its verdict and count inside one organization (a child of another organization is not counted); max names --recompute-undefined-on-empty acct.deal_max while sum names the plain run; a negative config.timeoutMs is named as written.
  • Updated fixtures: two http nodes in lint-flow-patterns.test.ts gained timeoutMs; the object-write roster pin in runtime-gate.object-writes.test.ts lists validateInertObjectDeclarations; build-probes.ts is classified not-a-served-read in the security(data, analytics): a lookup target's exposure declaration is not judged when the data door's $expand, or the dataset door's dimension-label pass, reads it — detail withheld pending maintainer #22661 census (second-object-read-exposure.pin.test.ts).

Acceptance notes

  • Premise corrected: field-boolean-required is removed (contract review 6989419029, M1). The card's item 3 reads "A boolean field marked required … The create form then refuses an unchecked switch." On main neither half holds:
    • The form: ui/packages/core/src/validation/required-presence.ts treats false as present (it names cloud#972 as the defect it closed), and the form renderer's isMissingForRequired uses it.
    • The server: FieldSchema.required refuses null; record-validator.ts (isEmptyForRequired) enforces it on a boolean, so the flag guards something real.
    • The platform's own objects carry the shape: sys_webhook.active, sys_job.active, sys_email_template.active, sys_scim_connection_credential.active (each required: true, defaultValue: true), and sys_scim_user.active (required, no default).
    • The cloud graph-lint grades the condition a warning, not an error.
      So the rule would refuse metadata that works. It is gone from the rule, its explanation, its export, its pins, the ADR-0087 entry and the changeset. Fixes #34776 stays: the card's goal is checks for metadata that does nothing at run time, and this item turned out not to be one.
  • Examples (seat answer A, claim amendment 6987471285). The five state machines declare initialStates, and the four showcase http nodes declare timeoutMs: 10000. objectstack build of app-crm and app-showcase raises no finding.
    • crm_lead: ['new'], the field's default and the machine's only root.
    • crm_opportunity: all five stages. The app records deals already won or lost: OpportunityStageHook sets the probability on INSERT for exactly that case, and test/opportunity-stage-hook.test.ts creates closed_won, closed_lost and proposal deals. A narrower list would refuse those creates. Kept as the seat ruled.
    • showcase_account ['prospect'], showcase_project health ['green'], showcase_task ['backlog', 'todo']: each is the field's default (plus todo for a task). These three machines declare events: ['update'], so the server never runs them on create, and the list states the entry without enforcing it. Seat answer B: skipping update-only machines is follow-up lint: state-machine-no-initial-states should not judge update-only machines, where initialStates is inert #35251.
  • ADR-0087 (seat answer A). One notice-only entry, publish-refuses-metadata-the-runtime-ignores (packages/spec/src/migrations/entries/semantic/), now naming four errors and one warning. The changeset carries adr-0087: registered.
  • Draft door (mcp: the open-source draft door — list, read, save and discard metadata drafts, each save answered with the publish verdict #34766): accepted deviation, narrowed. draftPublishJudgement runs the authoring gate, so it carries the five rules' findings. Three probes read what a publish landed, and a draft lands none. flow_connector_action_unresolved reads no landed data, but it is not on the draft door yet: its finding is a build-probe issue (code, fix, userMessage), while the draft judgement answers gate issues (rule, path, hint), and joining them is a shape choice for its own card.
  • Skills text that teaches each trap (not edited here): node types: skills/objectstack-automation/SKILL.md (the plugin node-type table, "no executor for the node type"); approval edges: skills/objectstack-automation/references/state-machines-and-approvals.md (the approve / reject out-edges); http timeout: skills/objectstack-automation/SKILL.md (the http row, "always set timeoutMs"); initialStates: skills/objectstack-data/rules/validation.md; action binding: skills/objectstack-ui/rules/actions.md ("A record button needs a placement").
  • The open seed loader already reports references it could not resolve on seedApplied. seed_reference_unresolved is the check on what actually landed.
  • The Clause-②: line follows claim amendment 6991975639: four refusals (flow-http-timeout-missing is a warning; field-boolean-required is removed). The connector probe on the draft door is follow-up draft door: carry the connector-action probe (flow_connector_action_unresolved) on the draft verdict #35256.

Verification

Round 4: red first, then the fix (at 370c46b)
  • Run against this round's tests, the previous build-probes.ts and lint-flow-patterns.ts (git show HEAD~1) failed: lint 1 of 294 (the negative timeoutMs wording), and build-probes-landed-data.test.ts 8 of 21. The 8 were: a row the loader did not land; a matched row under ignore; no landed; three seed scope cases; the roll-up count across organizations; the max repair. The files were restored with git checkout HEAD --, each blob hash was compared to HEAD, and git diff HEAD was empty.
Round 4 ablations (at 370c46b): six, all red

Each ran through scripts/ablation-replace.mjs (the anchor must hit once and the write is verified on disk), under a trap that restores HEAD. git diff HEAD was empty afterwards.

  • seed-landed-ids: the read by the loader's ids is removed. 2 failed of 21.
  • seed-matched-mode: matched rows are judged under every mode. 1 failed of 21.
  • rollup-sample-scope: the child sample is read unscoped. 2 failed of 21.
  • rollup-organizations: a single unscoped pass. 1 failed of 21.
  • rollup-function: the plain command for every function. 1 failed of 21.
  • http-negative: only 0 is named. 1 failed of 294.
Local runs at 8122905 (main merged at cdb327f through os-regen-merge.sh)
  • @objectstack/dogfood (full battery, narrowing arm): lock VERDICT command-exit 0. Test Files 482 passed, 3 skipped (485). Tests 4092 passed, 68 skipped (4160). The closure was built first with pnpm --filter '@objectstack/dogfood^...' build (VERDICT command-exit 0).
  • @objectstack/lint: 220 files, 9276/9276. Typecheck exit 0.
  • @objectstack/metadata-protocol: 357 files passed, 9 skipped. 23207 tests passed, 45 skipped. Typecheck exit 0.
  • @objectstack/core vitest --project repo: 8 files, 108/108.
  • @objectstack/spec:
    • check:generated --fix regenerated protocol.mdx on the merged tree; every line main added there is present.
    • check:generated on the merged head: all 14 artifacts are up to date.
    • src/migrations: 198/198.
    • Typecheck exit 0.
Gates at 8122905
  • dispatch-gates --ran: 134 derived, 134 run, every one exit 0, 0 NOT-MEASURED.
  • overlap-check: VERDICT clean (exit 0) against main and three open PRs.
Round 3 (e4e9131 to 3cce87c), kept for the record
  • Red first:
    • lint: 6 failed of 299.
    • landed-data: 5 failed of 17.
  • Nine ablations, all red:
    • sm-empty-list
    • sm-inactive
    • http-node-level
    • http-zero
    • http-durable
    • seed-scope
    • rollup-scope
    • seed-own-rows
    • row-organization
  • Dogfood at 7c71a0d: 482 files passed, 3 skipped. 4092 tests passed, 68 skipped.
  • The CLI fixture stack-conversion-record-door.test.ts got a node-level timeoutMs; its run passed 22/22.

🤖 Generated with Claude Code

https://claude.ai/code/session_01JQwxbXGvw43spR79ztEvWt

Claude-Session: https://claude.ai/code/session_01JQwxbXGvw43spR79ztEvWt
Co-authored-by: Claude <noreply@anthropic.com>
widget_empty_result, rollup_never_computed, seed_reference_unresolved and
flow_connector_action_unresolved: warnings on the publish receipt, each with
the person's sentence in eleven locales. The publish passes the automation
engine's connector lookups and its package to the probes.

Claude-Session: https://claude.ai/code/session_01JQwxbXGvw43spR79ztEvWt
Co-authored-by: Claude <noreply@anthropic.com>
…ate transcript counts

The runtime gate's host is the draft verdicts' host (a superset), so the
facade does not grow; the probe tests' find doubles honour any `where`, so
the limit gate can drive them; the CLI transcripts print 73 author-time rules.

Claude-Session: https://claude.ai/code/session_01JQwxbXGvw43spR79ztEvWt
Co-authored-by: Claude <noreply@anthropic.com>
@github-actions github-actions Bot added size/xl documentation Improvements or additions to documentation tests tooling Fix lands in tooling, not a product package — enters pm:queue only with Unblocks: or a named surface labels Nov 18, 2026
@github-actions

github-actions Bot commented Nov 18, 2026 •

Copy link
Copy Markdown
Contributor

📓 Docs Drift Check

This PR changes 4 package(s): @objectstack/lint, @objectstack/metadata-protocol, @objectstack/service-automation, @objectstack/spec, touching 96 documentable anchor(s). ⚠️ 2 changed file(s) yielded no anchor (packages/lint/src/index.ts, packages/metadata-protocol/src/index.ts), so the pages documenting them are NOT COVERED by this run — this is not a clean bill of health for those files.

34 hand-written doc(s) name something this change touched — list omitted above 15 rows. Re-derive on the tree named below: node scripts/docs-audit/affected-docs.mjs --json cdb327fdf0326abbc8f2637af663ad7cf1204c8f.

⛔ 16 release-owned page(s) also affected — read-only, see AGENTS.md Documentation Guardrails.

What this run could not see
  • 2 changed file(s) yielded no anchor (packages/lint/src/index.ts, packages/metadata-protocol/src/index.ts) — pages documenting those are invisible to this run
  • 1 anchor(s) matched too much of the corpus to be a work list: master_detail (literal, 46 pages)
  • 16 name(s) were too generic to anchor anything (single lowercase words)
  • the SDK route bridge reached 65 of 247 client-bound route-ledger rows — the other 182 have no registrar path: tail to select them, so pages documenting THEIR client methods cannot appear above, on this or any run. Of those 182: 0 are remediable by widening that discovery convention (an in-repo file declares the path; the convention did not scan it); 59 are structural — on a ledger where NOT ONE row is declared in-repo, so no discovery change reaches them at any price; 123 are undecided (no in-repo declaration, on a ledger that has other in-repo registrars — absence and an unreadable spelling are not distinguishable here). The rows themselves: node scripts/docs-audit/affected-docs.mjs --bridge-coverage
  • a page that states a rule by its inputs shares no identifier with the emitter that implements the rule, so an emitter-only diff cannot list it — not on this run and not on any run. Measured on fix(driver-sql): emit varchar(maxLength) for a text field a declared index keys on #11430: content/docs/protocol/objectql/types.mdx documents the text-family column mapping by the ObjectQL type names it maps FROM (text / textarea / html) while the diff changed createColumn; it went unlisted, and it was the page that diff falsified, in four places. No shared token exists to detect this on, so a rule your change carries has to be re-read by hand in the pages that restate it.
  • a key NAME is not a key, so the hand re-read the line above prescribes can land on the wrong schema. The same spelling is authorable on one governed type and a [REMOVED] tombstone on another for each of active, aria, joins, objects, template, tools and version (censused on [finding] tools is a key on BOTH AgentSchema (tombstoned, dead) and SkillSchema (live, cloud-attested), so a name-based search attributes skill examples to the agent key — it produced a false stop-the-line alarm on PR #19059 #19093 over the liveness ledger's governed types, top-level keys); nothing in a search result distinguishes the two, so a grep hit on a LIVE example reads as evidence about the DEAD key. Measured on fix(spec): the agent.tools liveness row says dead — it claimed live on a key the schema tombstoned #19059: content/docs/ai/agents.mdx was reported as contradicting the agent.tools tombstone over its tools: example at :161, which is inside the defineSkill({ block opened at :155 — the page was already correct. Settle ownership by PARSING the value against both schemas, never by the name: that literal PASSES SkillSchema, and as an AgentSchema it FAILS at tools with the tombstone prescription. ⛔ These names are not the whole class — a key retired through a .strict() guidance map leaves no tombstone in the walked shape and none of them here (tool.category, live as AIToolDefinition.category).

Coarse fallback — 175 page(s) merely mention a changed package (the pre-#9192 predicate, kept for the deliberately-wide backstop): node scripts/docs-audit/affected-docs.mjs --json cdb327fdf0326abbc8f2637af663ad7cf1204c8f → packageMentionDocs.

Which tree this was computed on

This run read content/docs from 4af2f3e7182fb506fca191707c8298a2794be47d — the merge of head 812290548fa1dce15dc56312877a132ea6fdb278 into base cdb327fdf0326abbc8f2637af663ad7cf1204c8f, which is what actions/checkout gives a pull_request run. Not the PR head.

A worktree cut from an older main holds a different content/docs, so re-deriving there can legitimately return a different list — that is a different tree, not a wrong row. To answer on the same tree:

# while this PR is open — GitHub drops the merge commit once it closes
git fetch origin 4af2f3e7182fb506fca191707c8298a2794be47d && git checkout 4af2f3e7182fb506fca191707c8298a2794be47d
# afterwards, rebuild it from the two parents, which stay fetchable
git fetch origin cdb327fdf0326abbc8f2637af663ad7cf1204c8f 812290548fa1dce15dc56312877a132ea6fdb278 && git checkout -B drift-repro cdb327fdf0326abbc8f2637af663ad7cf1204c8f && git merge --no-ff 812290548fa1dce15dc56312877a132ea6fdb278

node scripts/docs-audit/affected-docs.mjs --json cdb327fdf0326abbc8f2637af663ad7cf1204c8f

⚠️ That checkout carried uncommitted changes, so the commit above does not fully identify what was read.

Advisory only, and a precision-first one (#9192): a page is listed because it names a
symbol, wire route or SDK method this diff touched — not because it mentions a changed
package. Each row says which anchor put it there, so a wrong row is reportable rather than
merely annoying. To re-verify, run the docs-accuracy-audit workflow scoped to these files:
node scripts/docs-audit/affected-docs.mjs cdb327fdf0326abbc8f2637af663ad7cf1204c8f → pass the list as
args.docs, on the commit named under Which tree this was computed on.

… entry for the six refusals

app-crm and app-showcase declare `initialStates` on their five state machines
and `timeoutMs` on the four showcase http nodes, so they raise none of the new
findings. One notice-only ADR-0087 ledger entry,
`publish-refuses-metadata-the-runtime-ignores`, carries the six refusals to the
upgrade guide.

Claude-Session: https://claude.ai/code/session_01JQwxbXGvw43spR79ztEvWt
Co-authored-by: Claude <noreply@anthropic.com>
@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#1 · os-warren · session_01JQwxbXGvw43spR79ztEvWt

Contract-review-claim: session_01JQwxbXGvw43spR79ztEvWt · head e45bb8924006679f9584e30470fe306ed893e450 · 2026-11-18T19:19Z

Contract review (CONTRACT_REVIEW_TIER) of a narrowing: six publish-time refusals of metadata the schema accepts today (#34776), one notice-only ADR-0087 ledger entry, and the RuntimeBuildIssue describes for four new build-probe warnings (#35146). The declarations are Clause-②: no (narrowing), Metadata-protocol: narrowed and Skills-docs: follow-up #35245, per claim amendment 6987471285 and seat note 6988981894. Dev reports are on #34776.

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#1 · os-warren · session_01JQwxbXKtHccbeakAgquNs9

L1 review · REWORK · 2026-11-18T19:29Z

Head: e45bb8924006679f9584e30470fe306ed893e450 (merge base f2078e3674). Read: the whole net diff (38 files), the PR body, claims 6983865455 (#34776) and 6983892347 (#35146), amendment 6987471285, seat note 6988981894 and dev report 6988884686.

Checklist

  • Closing keywords: Fixes #34776 and Fixes #35146. Both cards are completed here. build probes: an empty dashboard card, a roll-up that never computed, and a flow step naming a connector action that does not resolve #35146's draft-door clause is the deviation the amendment accepted: the probes read what landed, whichever door wrote it, and that is where the card's symptom shows. I accept Fixes for it.
  • File surface: every path is inside the two claims and the amendment. That covers the examples (Q1 A) and the ADR-0087 entry 18.publish-refuses-metadata-the-runtime-ignores.ts (Q2 A).
  • Host refactor: draftVerdictHost() carries every member the removed inline host of assertRuntimeAuthoringRules had, plus sealedFlowNodeTypeVocabulary. The two can no longer drift, as the comment says.
  • Changeset, sentence by sentence:
    • Four packages at minor, with Clause-②: no (narrowing …), Metadata-protocol: narrowed and the ADR-0087 registered marker. Right for six new publish refusals.
    • The six rule bullets match the validators and their severities. That includes flow-http-timeout-missing as a warning, and flow-node-type-no-executor judged only against getSealedNodeTypeVocabulary(), which answers undefined before sealing.
    • The four probes are warnings, and the RuntimeBuildIssueSchema describes list them. RunBuildProbesOptions gains automation and packageId.
    • The new exports named are the ones the barrels add.
    • The Skills-docs: line still reads follow-up owed. See R3.
  • Examples: each initialStates matches the field's default and the comment beside it. The opportunity list (every stage) is argued from OpportunityStageHook's insert path. The three update-only machines are declarative only; the seat chose B, and lint: state-machine-no-initial-states should not judge update-only machines, where initialStates is inert #35251 is filed and open. The four timeoutMs: 10000 additions satisfy the new warning.
  • Narrowing battery: dev report 6988884686 pins @objectstack/dogfood to e45bb89240: 481 files and 4082 tests passed, and the closure build is clean.
  • CI on this head: red. Test Core (7/10) failed, and 24 runs are still in progress. See R1.
  • Main since the merge base: no commit on main touches the hand-written files of this diff.
  • Governed check: check-governed-merges --pr 35244: not governed (0 of 38 paths), 1,896 changed lines.

REWORK

  • R1 (CI red): packages/core/src/security/second-object-read-exposure.pin.test.ts (security(data, analytics): a lookup target's exposure declaration is not judged when the data door's $expand, or the dataset door's dimension-label pass, reads it — detail withheld pending maintainer #22661) fails on this head: packages/metadata-protocol/src/build-probes.ts now calls referenceTargetOf (the seed-reference probe, and childForeignKey for the roll-up probe), and the pin's CALLERS does not classify it. Classify it in CALLERS under the class that is true of it, with the reason the pin asks for. The dogfood battery does not run packages/core's test:repo leg, so it could not see this.
  • R2: in the same probes, the sample reads are organisation-scoped (scoped(organizationId)), but the id $in read of the reference target (seed_reference_unresolved) and the parent read (rollup_never_computed) are not. The seed probe claims to find exactly the values the edit form refuses (reference_not_found), and the form judges inside the organisation. Scope both reads as the sample read is scoped, or state in the code, and in the R1 classification, why the unscoped read is the right judge. Add one case for it to build-probes-landed-data.test.ts.
  • R3: the changeset's Skills-docs: line still reads follow-up owed — skills/** traps for the six rules. The card is filed: make it follow-up #35245, as the PR body already says.

These move the head. I will read only the delta, and CI on the new head.

Notes (non-blocking)

  • N1: the contract review (claim 6989008919) is its own record. Its findings, if any, can ride the same fix round.

….ts in the #22661 census

The seed-reference target read and the roll-up parent read are scoped to the
publishing organization like the sample reads beside them, with a pin for
each. `build-probes.ts` calls `referenceTargetOf`, so the second-object read
census classifies it. The changeset names the skills follow-up card.

Claude-Session: https://claude.ai/code/session_01JQwxbXGvw43spR79ztEvWt
Co-authored-by: Claude <noreply@anthropic.com>
@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#1 · os-warren · session_01JQwxbXGvw43spR79ztEvWt

Contract review

Served-tier: CONTRACT_REVIEW_TIER
Head-sha: e45bb8924006679f9584e30470fe306ed893e450
Local-runs: none
Scope: packages/spec/src/api/protocol.zod.ts, packages/spec/src/migrations/entries/semantic/18.publish-refuses-metadata-the-runtime-ignores.ts + packages/lint/src/authoring-rules.ts, packages/lint/src/lint-flow-patterns.ts, packages/lint/src/rule-explanations.ts, packages/lint/src/runtime-gate.ts, packages/lint/src/validate-action-object-binding.ts, packages/lint/src/validate-flow-node-executors.ts, packages/lint/src/validate-inert-object-declarations.ts, packages/metadata-protocol/src/build-probes.ts, packages/metadata-protocol/src/build-probes.user-text.ts, packages/metadata-protocol/src/protocol-authoring-gate.ts, packages/metadata-protocol/src/protocol-history-and-publish.ts, packages/metadata-protocol/src/protocol.ts, packages/metadata-protocol/src/runtime-authoring-gate.ts, packages/services/service-automation/src/engine.ts, examples/app-crm/src/objects/lead.object.ts, examples/app-crm/src/objects/opportunity.object.ts, examples/app-showcase/src/data/objects/account.object.ts, examples/app-showcase/src/data/objects/project.object.ts, examples/app-showcase/src/data/objects/task.object.ts, examples/app-showcase/src/automation/flows/index.ts, examples/app-showcase/src/automation/flows/exchange-rate-sync.flow.ts

First full review of PR #35244 (cards #34776 and #35146). Read: both cards with every comment, ruling 6940528935, claims 6983865455 and 6983892347, amendment 6987471285, seat note 6988981894, the PR body, the net diff against main, and the head's check-runs. Code outside the diff was read at the head to judge the diff: ui/packages/core, ui/packages/components, ui/apps/console, packages/objectql, packages/runtime, packages/services/service-automation, packages/platform-objects, and the cloud sources the PR cites.

① Derived judgments

  • Six publish-time refusals (accept set narrowed at the runtime gate and the CLI).
    • flow-node-type-no-executor: right. It is judged only against the set the engine's own audit uses (knownNodeTypes(): structural types, executors, action descriptors), read live, and only after the seal. getSealedNodeTypeVocabulary() answers undefined until nodeTypeVocabularySealed is set. No CLI path sets flowNodeTypeVocabulary, so the CLI judges nothing. The walk covers region bodies, as unknownNodeTypes does.
    • flow-approval-decision-unrouted: right. APPROVAL_BRANCH_LABELS.approve / .reject are the labels the approval service resumes with, and traverseNext falls back to every out-edge when no edge carries the label. A revise edge and a fault edge do not satisfy or trip the rule. An isDefault edge does not claim approve or reject in the engine, so requiring both labels is correct.
    • flow-http-timeout-missing: warning only, confirmed (severity: 'warning', so it lands in advisories). Two logic gaps: S4.
    • field-boolean-required: wrong. See M1.
    • state-machine-no-initial-states: right as the card rules it, with the gaps in S3.
    • action-no-object-binding: verdict right. Every ACTION_LOCATIONS value is an object surface, and no renderer under ui/ draws an object-less action by location. One reason sentence is false: N1.
  • Published spec (protocol.zod.ts). Describes only; no type, key or accept set moves. The code list (12 codes), the flow artefact, the connector ref and the member sentence each match build-probes.ts at the head. The warning sentence does not: S6.
  • Published spec, not edited. Two describes now disagree with the gate: FieldSchema.required (M1) and initialStates ("Omit to keep the legacy behavior", S3).
  • Public surface, additive, right. @objectstack/lint exports three validators, their finding types and six rule ids; AuthoringRuleContext.flowNodeTypeVocabulary; runRuntimeAuthoringRules and evaluateRuntimeAuthoringGate gain an optional argument; RunBuildProbesOptions.automation / .packageId and ProbeAutomation; AutomationEngine.getSealedNodeTypeVocabulary(); four members on RuntimeBuildIssueCode.
  • Probe severities. All four new probes emit warning. Nothing in them fails a publish: they run after the promotion, and a throw is swallowed (probes = undefined).
  • Docs transcripts 70 to 73. Right: three registry entries were added (two of the six rules live inside lintFlowPatterns, one entry holds two).
  • protocol.ts host. Right. draftVerdictHost() spells the seven members assertRuntimeAuthoringRules reads exactly as the removed literal did (the same two getters, the same delegations). The eight extra members are outside RuntimeRulesHost. The only new read is sealedFlowNodeTypeVocabulary, on a flow write.

② Semver level

  • Changeset: @objectstack/lint, @objectstack/metadata-protocol, @objectstack/service-automation, @objectstack/spec, all minor. The kind is narrowed, which takes at least minor on each package the diff moves. Right.
  • Clause-②: no (narrowing: …) and Metadata-protocol: narrowed are on the PR body and the changeset, same wording. Right for refusals of metadata the schema accepts.
  • adr-0087: registered publish-refuses-metadata-the-runtime-ignores names the id of the entry in the diff. Check Changeset and Lint · CI, release & engine gates are green on the head.
  • The registry, spec-changes and the upgrade guide are generated from the entry file (registry.ts.template); none is committed, so the diff carries no generated output to disagree with it.
  • Changeset prose that does not match the tree: the field-boolean-required line (M1), "routes no decision" (S5), "so the edit form cannot save it" (S2), and Skills-docs: follow-up owed where the PR body says follow-up #35245 (N3).

③ Boundary flags

  • Q1 (examples), seat answer A. Done as answered. crm_opportunity listing all five stages is honest: opportunity.hook.ts runs on beforeInsert, and test/opportunity-stage-hook.test.ts inserts closed_won, closed_lost and proposal. The five stages are every option the stage field has, so the list refuses nothing. See S3. timeoutMs: 10000 is sane: it is the value the rule's own hint names, and the engine has no default.
  • Q2 (ledger), seat answer A. Done. Content findings: M1, S5.
  • Q3 (update-only machines), seat answer B, follow-up lint: state-machine-no-initial-states should not judge update-only machines, where initialStates is inert #35251. Accepted as recorded. Two more inert cases are not carried by lint: state-machine-no-initial-states should not judge update-only machines, where initialStates is inert #35251: S3.
  • Draft-door deviation (build probes: an empty dashboard card, a roll-up that never computed, and a flow step naming a connector action that does not resolve #35146). The stated reason holds for three probes. It does not hold for flow_connector_action_unresolved: that probe reads the flow body and the engine's connector lookups and no landed record, so the draft door could carry it. Escalated to the seat: amend the deviation line or file a follow-up card.
  • Surface breaches the dev declared. Each is covered by amendment 6987471285.
  • Dev account against the tree. The reports say 131 families derived and run with every family at exit 0. The head's Test Core (7/10) is red on a packages/core test:repo pin that names this diff: M2.
  • SQL push-down. The roll-up and seed probes materialise ids in application code (a child sample, then id $in on the parent or target) and read whole rows. The reads are bounded at 50 rows, with one or two reads per roll-up field and per reference column, and no per-record loop. No reason is given for not projecting or pushing the join down: S1.
  • Not measured from this seat. Whether a declarative connector published in the same batch is registered before the connector probe runs. If the reconcile is later, the probe warns once on a step that will work.
  • Out of scope, carried. Skills traps: skills: teach the six publish-time traps that #34776 turns into checks #35245. M1 changes what that card should teach about a required checkbox.

④ Design judgment

M1 (must-fix) — field-boolean-required refuses metadata that works at the head, on a reason the tree contradicts.

  • The rule's reason, in its finding, its explanation, the changeset and the ledger entry: required on a boolean / toggle "guards nothing", and "the record form reads it as must be checked and refuses to save the box unchecked".
  • The form: ui/packages/core/src/validation/required-presence.ts states that false is not absent, names cloud#972 as the defect it closed, and is the predicate the form renderer's required validator calls (ui/packages/components/src/renderers/form/form.tsx, !isMissingForRequired(value)), as does the console FormPage and the wizard. The same renderer seeds an untouched two-state control with false on create. An unchecked required box saves, with or without a defaultValue.
  • The server: FieldSchema.required is published as "an insert must provide a non-null value, and an update may not null it out", and record-validator.ts enforces that on a boolean (isEmptyForRequired: null and absent are empty, false is not). So the flag does guard something: a null written by an API caller or a PATCH.
  • The remedy the rule prescribes (remove required, add defaultValue: false) makes null storable on update. That is a declared capability taken away, not a dead declaration removed.
  • The platform's own objects carry the shape: sys_webhook.active, sys_job.active, sys_email_template.active, sys_scim_connection_credential.active (each required: true, defaultValue: true) and sys_scim_user.active (required: true, no default).
  • The cited source (graph-lint.ts, cloud) grades the same condition a warning.
  • The card's premise for this item ("the create form then refuses an unchecked switch") is no longer true of the tree. That is the seat's to take to the maintainer; the rule cannot ship as an error on it. The ledger entry and the changeset line move with whatever is decided.

M2 (must-fix) — the head's Test Core (7/10) check-run is failure.

  • packages/core test:repo, src/security/second-object-read-exposure.pin.test.ts, "every caller of the reference-target arbiter is classified": packages/metadata-protocol/src/build-probes.ts now calls referenceTargetOf and is not in CALLERS.
  • The pin asks for a classification, and for a read that serves anything of the target to ask the target's exposure first. The answer belongs with S1, which is about the same reads.

S1 (should-fix) — the roll-up and seed probes read under a bare { isSystem: true } context, read whole rows, and quote row values back.

S2 (should-fix) — seed_reference_unresolved states a consequence the engine removed.

S3 (should-fix) — state-machine-no-initial-states accepts a declaration the runtime ignores, and the spec still documents the omission.

  • initialStates: [] passes the rule (!== undefined). checkStateMachine treats an empty list as no contract ("legacy no-op"). The rule's stated purpose is not met, by the shortest edit that silences it.
  • validation.zod.ts still describes the key with "Omit to keep the legacy behavior (no initial-state check on insert)". After this PR an omission is refused at publish.
  • A list naming every option of the field (crm_opportunity, as its hook and tests require) refuses nothing either. Together with update-only machines this is a second and third inert case; lint: state-machine-no-initial-states should not judge update-only machines, where initialStates is inert #35251 names only the first.
  • A machine with active: false is also reported, and never runs.

S4 (should-fix) — flow-http-timeout-missing reads one of the two timeouts and accepts a value that arms none.

  • The engine races every node against node-level timeoutMs (flow.zod.ts:776, the line the card cites; dag-traversal.ts, node.timeoutMs greater than 0). An http node carrying it is warned that an endpoint "holds the run", which is untrue.
  • config.timeoutMs: 0 satisfies the rule, and the executor arms no timer for it (timeoutMs ? setTimeout(…) : undefined).
  • A durable: true node with an outbox does not hold the run either; it is warned the same way.

S5 (should-fix) — the ledger entry misstates the approval failure.

  • Entry reason: "an approval decision with no matching edge routes nowhere". Changeset: "routes no decision".
  • traverseNext: the branch selection is ignored and every out-edge is evaluated. The rule's own finding and explanation say so correctly. The upgrade guide would tell an author the flow stops, when it runs both branches.

S6 (should-fix) — the severity describe is untrue of two of the four codes it lists.

  • It places all four under "what landed reads in a way the person will notice although it may be the truth".
  • flow_connector_action_unresolved reports a step that fails on every run that reaches it (its own message), and seed_reference_unresolved reports a value that names no row. Neither may be the truth. The error sentence beside it ("the published artifact is broken at runtime") describes the connector case better than the sentence it was filed under.
  • "Neither fails the publish" is true.

S7 (should-fix) — rollup_never_computed prescribes a repair that fixes one parent.

  • fix and userMessage: write or edit one child row to recalculate. A child write recomputes the parents that child names, not the N parents the finding counts.
  • message: "a roll-up recalculates only when a child row is written". summary-aggregate.ts lists three writers, and the platform's repair for exactly this state is os migrate summary-nulls --apply; an install door also materialises new roll-ups (summary-install-materialise.ts).
  • The judgement itself is sound: only parents a sampled child points at, only a field unset on all of them, a child with no value in the aggregated field is not counted, a filtered roll-up is skipped, and the foreign key is resolved as the engine resolves it.

Nits:

  • N1 (nit) — action-no-object-binding says a call on an object's action route answers "not found" (finding, explanation, two comments). An object-less declaration owns every route (standaloneActionOwnsRoute, actionHandlerObjectKeys), so the call resolves. The verdict does not depend on the sentence.
  • N2 (nit) — widget_empty_result: the comment says an empty answer to a caller who sees no rows is not reported. That holds for a result with no rows; a no-dimension aggregate answering 0 over an object with no rows is one row and is reported. The fix names the widget's time window and condition, which the probe's selection does not send. It does not duplicate empty_query: the two are one if / else if, and everyMeasureZero is false on an empty result.
  • N3 (nit) — the changeset's Skills-docs: line reads follow-up owed; the PR body reads follow-up #35245.
  • N4 (nit) — ref is described as present "when that is not the artifact itself"; the roll-up finding's ref is the artefact's own object with a member.

Held against the tree and found right: the connector probe asks resolveConnectorInstanceFor, resolveConnectorAction and getConnectorDegradedReason in the executor's order (builtin/connector-nodes.ts), with the publishing package, and a lookup that throws judges nothing. The runtime gate charges a finding on the written item itself and cancels a sibling's, so "the next publish or write is refused, nothing is rewritten, nothing is refused at boot" in the ledger entry is true; a draft save, the package-author channel and migrate-stored are not judged.

Check-runs on the head when this record was written: 72 runs; 46 success, 12 skipped, 1 failure (Test Core (7/10), M2), 13 still in progress (Test Core 1, 9 and 10 of 10; Type Check UI; nine Test UI shards). Green and named in this record's judgments: Check Changeset, Governed Surface Queue Guard, PR-body guards, Spec property liveness, Lint · CI, release & engine gates, Lint · docs & code guards, Build Core, Build Docs, Dogfood Regression Gate.

Implemented-by: claude/issue-34776-publish-checks-build-probes
Reviewed-by: session_01JQwxbXGvw43spR79ztEvWt

VERDICT: FAIL

…oject the landed-data probes, honest consequence texts

- Remove `field-boolean-required` (rule, explanation, export, pins, ledger and
  changeset lines): the form treats `false` as present and the server's
  `required` refuses null, so the flag guards something real.
- `state-machine-no-initial-states`: an empty `initialStates` trips it; an
  `active: false` machine is skipped, as the engine skips it.
- `flow-http-timeout-missing`: a positive node-level `timeoutMs` counts, `0`
  arms no timer, and a `durable: true` node is not reported.
- Build probes: the seed check reads the seed's own rows (by its
  `externalId`), every landed-data read is projected and kept inside an
  organization the way the reference audit keeps its probe, and the
  existence checks stay one `id $in` read per organization.
- Consequence texts: a stored dangling reference no longer claims the record
  cannot be saved; the roll-up repair names `os migrate summary-nulls --apply`
  and the install door; approval and action-binding sentences match the
  engine; `severity`, `ref` and `initialStates` describes restated.

Claude-Session: https://claude.ai/code/session_01JQwxbXGvw43spR79ztEvWt
Co-authored-by: Claude <noreply@anthropic.com>
…timeout

The fixture's `http` node set no timeout, so `flow-http-timeout-missing`
warned on it and `os validate --strict` turned that warning into exit 1 on
the control spelling. The test is about conversion notices, not timeouts:
the node now declares `timeoutMs: 10000`, which the rule honours.

Claude-Session: https://claude.ai/code/session_01JQwxbXGvw43spR79ztEvWt
Co-authored-by: Claude <noreply@anthropic.com>
…-up repair per function

- The seed reference probe reads the rows the loader reports it landed
  (`seedApplied.landed`, passed in as `seedLanded`) by id, instead of
  matching the seed's key across the object: created rows always, matched
  rows only when the seed's mode wrote them.
- The roll-up probe samples children one organization at a time, under the
  same context and tenant column as the parent read, and forms each verdict
  and count inside that organization.
- `rollup_never_computed` names `--recompute-undefined-on-empty object.field`
  for a min, max or avg roll-up, which the plain run does not fill, in its
  fix and in all eleven user sentences.
- Nits: `--strict` exits 1 on the timeout warning (changeset, ledger); the
  changeset's organization sentence matches the code; the seed message drops
  "nothing else will say so"; a non-positive `timeoutMs` is named as written.

Claude-Session: https://claude.ai/code/session_01JQwxbXGvw43spR79ztEvWt
Co-authored-by: Claude <noreply@anthropic.com>
@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#1 · os-warren · session_01JQwxbXGvw43spR79ztEvWt

Contract-review-claim: session_01JQwxbXGvw43spR79ztEvWt · head 812290548fa1dce15dc56312877a132ea6fdb278 · 2026-11-18T23:41Z

Delta contract review (CONTRACT_REVIEW_TIER) of e275c3efac5e95b128dbd2e895c7b24413658e9f..812290548fa1dce15dc56312877a132ea6fdb278, closing S8 and S9 of record 6992699203, plus nits N5–N8. The delta includes a merge of main cdb327fdf0 (#35239 landed) and the regenerated protocol.mdx. Dev report: 6994915932.

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#1 · os-warren · session_01JQwxbXKtHccbeakAgquNs9

L1 review (delta) · ACCEPT · 2026-11-19T00:05Z

Head: 812290548fa1dce15dc56312877a132ea6fdb278 (merge base now cdb327fdf0). I read only the delta from e275c3ef (my delta ACCEPT 6992692922, stamped 2026-11-18T21:51Z). It is one PR commit, 370c46b5ad, plus the merge of main (4be98b6fb8, which brings in #35239) and the regeneration (812290548f). The merge changes none of the PR's hunks. Only the generated protocol.mdx differs, and 812290548f regenerates it. I also read dev report 6994915932 and claim amendment 6992715428.

  • C1: closed. Amendment 6992715428 adds the three paths to the file surface.
  • Seed probe (contract S8): the rows judged are now the loader's own seedApplied.landed ids, read by id, so no row the loader did not land is matched, judged or quoted.
    • Inserted ids are always judged. Matched ids are judged only under upsert or update. The ignore default (SeedMode.default('ignore'), seed.zod.ts) leaves a matched row as its writer left it.
    • The landed shape the probe reads (object, inserted.ids, matched.ids) is SeedAppliedLandedSchema's.
    • protocol-history-and-publish.ts passes seedApplied.landed only when it is present, and absent means no seed reference is probed.
    • The seed-row read is held to the publishing organization when there is one. The target reads keep R2's per-organization scope.
  • Roll-up probe (contract S8): probeOrganizations gives the publishing organization, else each organization a projected read of the child object's tenant column finds, else one unscoped pass for an object with no tenant column. The children and parent reads, the verdict and the count are formed inside one organization. The message says "of one organization" and quotes no organization id or row value. A stamped-null row on an object that has a tenant column is not judged, and the docblock says so.
  • Roll-up repair (contract S9): count and sum name os migrate summary-nulls --apply. min, max and avg name --recompute-undefined-on-empty OBJECT.FIELD, with the finding(objectql): backfillSummaryNulls cannot fill a JUST-CREATED min/max/avg roll-up — summaryNullIsBackfillable decides on the function alone, so "never computed" is indistinguishable from "no child rows" #15064 reason. The person's sentence carries the same split (cause: fills | named) in every locale.
  • http timeout text: any non-positive config.timeoutMs is now named by its value, not only 0. The changeset and the ADR-0087 entry say the warning makes os validate --strict exit 1, which is what CI found on the CLI fixture.
  • Changeset, the changed sentences:
    • The seed_reference_unresolved parenthesis ("a sample record the seed loader landed … names no row in the organization that record belongs to") matches the probe.
    • "RunBuildProbesOptions gains automation, packageId and seedLanded" and "ProbeEngine gains an optional getSchema" match the interfaces.
    • "adds the ProbeAutomation and SeedLandedRows types" matches index.ts, which now exports both. Before this round ProbeAutomation was named in the changeset but missing from the barrel.
    • Clause-②, Metadata-protocol and Skills-docs are unchanged.
  • Narrowing battery: report 6994915932 pins @objectstack/dogfood to this head, 81229054, and it is green. The six ablations of this round are each red.
  • CI on this head: 74 check-runs, 62 success and 12 skipped. None failed, none pending, including with filter=all.
  • Main since the merge base: no commit on main touches a file of this diff, and git merge-tree against origin/main is clean.
  • Governed check: check-governed-merges --pr 35244: not governed (0 of 43 paths), 2,341 changed lines.
  • Contract review: the delta record (claim 6994955622) is its own comment. The seat lands on PASS.

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#1 · os-warren · session_01JQwxbXGvw43spR79ztEvWt

Contract review

Served-tier: CONTRACT_REVIEW_TIER
Head-sha: 812290548fa1dce15dc56312877a132ea6fdb278
Local-runs: none
Scope: packages/spec/src/api/protocol.zod.ts, packages/spec/src/migrations/entries/semantic/18.publish-refuses-metadata-the-runtime-ignores.ts + packages/metadata-protocol/src/build-probes.ts, packages/metadata-protocol/src/build-probes.user-text.ts, packages/metadata-protocol/src/protocol-history-and-publish.ts, packages/metadata-protocol/src/index.ts, packages/lint/src/lint-flow-patterns.ts

Delta review of e275c3efac5e95b128dbd2e895c7b24413658e9f..812290548fa1dce15dc56312877a132ea6fdb278, against PASS record 6992699203 (S8 and S9 open). Read: dev report 6994915932, the PR body, the delta on the PR's own files (commit 370c46b5ad and the regenerated protocol.mdx in 812290548f), and the head's check-runs. The range also merges main at cdb327fdf0 (#35239 and two other PRs); those files are not this PR's and are not judged. Code outside the diff was read at the head to judge the delta: packages/metadata-protocol (the seed loader, seed-applied-landed.ts, applySeedBodies), packages/spec (seed.zod.ts, seed-loader.zod.ts), packages/objectql (summary-backfill.ts, summary-aggregate.ts), packages/cli (migrate summary-nulls).

Closed by this delta, by id:

  • S8: closed (two narrower points are new: S10 and S11)
  • S9: closed
  • N5, N6, N7, N8: fixed

Open on this head: S10 and S11, both should-fix. No must-fix.

① Derived judgments

  • Accept set. Unchanged by this delta: four refusals and one warning.
  • flow-http-timeout-missing text (N8). Right. A numeric config.timeoutMs that arms no timer (0 or negative) is quoted as written; anything else reads "sets no config.timeoutMs". The rule's verdict is unchanged.
  • Public surface. RunBuildProbesOptions gains optional seedLanded. @objectstack/metadata-protocol now exports the ProbeAutomation and SeedLandedRows types. Additive, right. SeedLandedRows is a structural subset of the spec's SeedAppliedLanded entry, so the publish passes seedApplied.landed as it is.
  • Probe verdicts that changed.
    • seed_reference_unresolved now judges only ids in seedApplied.landed. A publish with no landed for the object judges nothing. Right against the loader: landed is built per publish from the loader's own landedIds and insertedIds of the seed bodies this publish applied.
    • rollup_never_computed now reports when ONE organization's sampled parents all read blank. Before, it needed every sampled parent of every organization blank. Right for the reads; the texts that still say "every" are N10.
  • Published spec. This PR's own commits change no packages/spec schema file in this range. The protocol.zod.ts hunks in the range come from the merge of main (feat(metadata-protocol): a refused field removal or type change names the views, forms and dashboard cards that still show the field #35239).
  • protocol.mdx. Carries both PRs' rows. Against main at cdb327fdf0 the file differs only in this PR's nine rows (severity, ref, code, and the type and member rows under them), so every row feat(metadata-protocol): a refused field removal or type change names the views, forms and dashboard cards that still show the field #35239 added is present.

② Semver level

  • Changeset: four packages at minor, kind narrowed. Right, unchanged.
  • Clause-②: no (narrowing: four publish-time refusals of metadata the schema accepts today), Metadata-protocol: narrowed and Skills-docs: follow-up #35245 read the same on the PR body and the changeset.
  • adr-0087: registered publish-refuses-metadata-the-runtime-ignores names the entry in the diff. The entry now says the warning makes os validate --strict exit 1.
  • The changeset's new sentences match the tree: seedLanded, SeedLandedRows, ProbeEngine.getSchema, "the organization that record belongs to". One prose point: N10.

③ Boundary flags

  • Dev open questions. None in report 6994915932.
  • Dev out-of-scope entries. Both are addressed to the seat and repeat my lines in 6992699203: the every-option line for lint: state-machine-no-initial-states should not judge update-only machines, where initialStates is inert #35251, and the skills: teach the six publish-time traps that #34776 turns into checks #35245 title. Still to the seat.
  • SQL push-down.
    • The seed check: one read, id $in the loader's ids (at most 50), projected to id, the reference columns and the organization column; then one id $in read per column and organization, projected to id. No per-record loop. Answered.
    • The roll-up check adds an organization-discovery read: 50 rows of the child object, projected to the organization column alone, then two reads per organization found. The ceiling is 101 reads of at most 50 rows per roll-up field, and the loop stops at the first organization that reads blank. Bounded. The discovery is a row sample where a distinct read could push down, and no reason is given: N11.
  • Dev account against the tree. The report's S8, S9 and N5 to N8 fixes are in the tree as described. Two things the report does not say are in ④ (S10, S11).

④ Design judgment

S10 (should-fix) — after the named repair, a republish under the default seed mode reports nothing, and nothing was repaired.

  • fix: point the column at real records "(in the seed, by a value the loader resolves), or clear it, then republish the seed". userMessage, eleven locales: fix or clear the field in the sample data, then publish again.
  • The default seed mode is ignore. On a replay the loader matches each row it created earlier and leaves it as it is (seed.zod.ts: "insert missing rows, leave existing rows alone"). So the stored value still names no row.
  • On that replay the rows are in landed.matched, not landed.inserted. The probe reads matched rows only under upsert or update, so it reads none and reports nothing.
  • Effect: the first publish warns; the author edits the seed and republishes; the receipt is clean; the records still point at nothing. Before this delta the same replay reported the finding again.
  • Not reading a matched row under ignore is right: the receipt cannot tell a row an earlier load created from another writer's row with the same key. The gap is in the texts. They name a repair that does not change a landed row under ignore, and they do not say the next publish will be silent about those rows.
  • The probe holds the seed's mode, so fix can say what works for it: correct or delete the stored rows, or declare mode: 'upsert'.

S11 (should-fix) — with two seeds of one object in one publish, the matched-row rule is applied per object, not per seed.

  • seedApplied.landed has one entry per object. seedAppliedLanded merges every dataset of the object into one inserted list and one matched list.
  • The probe picks the entry by the seed's object, and reads matched when THIS seed's mode is upsert or update.
  • Case: seed A (ignore) and seed B (upsert) load the same object in one publish. A row that only A's key matched was left as its writer left it. It is in the merged matched list, so B's pass reads and judges it, and its column values can appear in B's finding. The comment's rule (matched rows are read only when the seed's mode wrote them) does not hold there.
  • The comment says the object's landed rows "are judged together". It does not draw this consequence.
  • Second effect of the same shape: each seed of the object emits its own finding over the same rows, so one dangling value is reported once per seed, each under a different artifact.
  • A rule that holds: read matched only when every published seed of the object declares a writing mode, and emit one finding per object and column.
  • Narrower, same family, stated for the record: under upsert or update a matched row's column the seed does not write (columns.FIELD.applyOn: 'create', Seed datasets: extend the import door's applyOn: 'create' (#25577 / PR #25664) to seed-dataset columns — a re-run of an app's seed reverts columns its own jobs wrote #25761, or a column the records do not carry) keeps the value its last writer gave it. The finding quotes it as a value "on the rows the seed landed", which is true, and fix says to correct it "in the seed", which does not reach it.

Held against the tree and found right:

  • S8, seed check.
    • The row read is id $in the ids of landed.inserted (always) and landed.matched (writing modes only). The seed's key is no longer read, so only rows the loader itself landed are read.
    • The modes are the loader's three: ignore, upsert, update. insert and replace are retired (seed: an unkeyed (insert/replace) inline seed is inserted again on every un-walled start, so the first row's person references stay NULL and the dataset duplicates #34613) and refused at load. ignore never writes a matched row; upsert and update do. An absent mode is read as ignore, the spec default and what applySeedBodies applies.
    • With organizationId: null at the call site the row read is by the loader's ids, and each value is judged with the same scope as its own row, as the reference audit does.
    • With a publishing organization, every read carries it.
    • landed is capped at 200 ids per list; the probe takes the first 50.
  • S8, roll-up check.
    • With a publishing organization: one pass, both reads inside it.
    • With none, on an object that has an organization column: the child sample and the parent read are scoped to one organization at a time, like the parent and target reads, and the verdict and count are formed inside that pass.
    • The discovery read is bounded (50 rows), projected to the organization column alone, and nothing it returns reaches a finding.
    • A row stamped with no organization, on an object that has the column, is not judged. Stated in the code.
  • S9.
    • --recompute-undefined-on-empty is the real flag of os migrate summary-nulls (packages/cli/src/commands/migrate/summary-nulls.ts), repeatable, spelled object.field. The key it resolves by is parentObject.summaryField (rollupKey), which is what the probe writes: the published object and the summary field.
    • Named, a min, max or avg column is walked like a count, and every NULL parent whose aggregate is defined is recomputed. With no --object the run walks every registered object, so the named entry resolves.
    • count and sum keep the plain command, which fills them (summaryNullIsBackfillable).
    • fix names the full command with the key. All eleven userMessage texts (en, zh-Hans, zh-Hant, es, ar, fr, pt-BR, ru, de, ja, ko) carry both branches: the plain command for count and sum; the flag, "naming this field", and the sentence that a minimum, maximum or average roll-up is not filled by the plain run.
  • N5. The changeset and the ledger entry both say the warning makes os validate --strict exit 1.
  • N6. The changeset names the record's own organization and ProbeEngine.getSchema.
  • N7. "nothing else will say so" is gone from message; the comment now names the operator's reference audit.
  • N8. See ①.

Nits:

  • N9 (nit) — message says "parent row(s) of one organization" on every path. On the unscoped pass (a child object with no organization column, or an engine without getSchema) the parent read is unscoped too. If the parent object does carry the column, that verdict and count span organizations and the phrase is not true there.
  • N10 (nit) — the roll-up userMessage (eleven locales), the changeset and the PR body's table still say the roll-up is blank on "every" record or parent that has children. The verdict is now one organization's sampled parents.
  • N11 (nit) — the organization discovery samples 50 child rows. If they all belong to one organization, no other organization is judged. ProbeEngine exposes only find, which is likely the reason; the code does not state it.

Check-runs on the head, all complete when read (2026-11-19T00:04Z): 74 runs; 62 success, 12 skipped, 0 failure. Test Core 1 to 10 of 10 and Test UI 1 to 16 of 16 are green. Also green: Check Changeset, Governed Surface Queue Guard, PR-body guards, Spec property liveness, Lint · CI, release & engine gates, Lint · docs & code guards, Type Check · workspace, Type Check · consumer gates, Build Core, Build Docs, Dogfood Regression Gate.

Implemented-by: claude/issue-34776-publish-checks-build-probes
Reviewed-by: session_01JQwxbXGvw43spR79ztEvWt

VERDICT: PASS

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#1 · os-warren · session_01JQwxbXGvw43spR79ztEvWt

Landing · 2026-11-19T00:08Z · head 812290548fa1dce15dc56312877a132ea6fdb278

Probe Reading
L1 L1-a second delta ACCEPT 6995388753 on this head. C1 is closed by claim amendment 6992715428; the battery is pinned to this head and green.
Contract review CONTRACT_REVIEW_TIER delta PASS 6995403690 on this head, closing S8 and S9 of 6992699203 and N5–N8. S10 and S11 (should-fix: the seed-reference repair text under ignore, and two seeds of one object judged as one) and nits N9–N11 are carried on #35258. Tier verified on the reviewing transcript.
CI check-expected-skips --pr 35244 exits 0 with the roster pinned to main's tip: 74 check-runs, 62 success, 12 expected skips, 0 other.
Governed check-governed-merges --pr 35244 reads NOT governed. The PR changes 2,341 lines (+2290/−51), under the 3,000-line threshold.
Base drift K = 0 first-parent commits from base cdb327fdf0 to main.
Declarations @objectstack/lint, @objectstack/metadata-protocol, @objectstack/service-automation and @objectstack/spec minor. Clause-②: no (narrowing), Metadata-protocol: narrowed, Skills-docs: follow-up #35245.

Follow-ups on file: #35245 (skills text), #35251 (update-only state machines), #35256 (connector probe on the draft door), #35258 (this review's open points). The boolean-required check was dropped after its premise was disproved (6989446674); the maintainer's ruling on it is pending.

@objectstack-fleet objectstack-fleet Bot changed the title feat(lint): six publish-time checks for metadata the runtime ignores, and four build probes over what landed feat(lint): five publish-time checks for metadata the runtime ignores, and four build probes over what landed Nov 19, 2026
@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#1 · os-warren · session_01JQwxbXGvw43spR79ztEvWt

Landing · 2026-11-19T00:10Z · head 812290548fa1dce15dc56312877a132ea6fdb278: ready and auto-merge, on the readings in comment 6995442955.

@objectstack-fleet
objectstack-fleet Bot marked this pull request as ready for review November 19, 2026 00:11
@objectstack-fleet
objectstack-fleet Bot added this pull request to the merge queue Nov 19, 2026
Merged via the queue into main with commit f4dbcc2 Nov 19, 2026
79 checks passed
@objectstack-fleet
objectstack-fleet Bot deleted the claude/issue-34776-publish-checks-build-probes branch November 19, 2026 00:38
This was referenced Nov 19, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation protocol:data size/xl tests tooling Fix lands in tooling, not a product package — enters pm:queue only with Unblocks: or a named surface

Projects

None yet

Development

Successfully merging this pull request may close these issues.

lint: six publish-time checks for metadata that passes the schema and does nothing at run time

2 participants