Repository navigation
feat(lint): five publish-time checks for metadata the runtime ignores, and four build probes over what landed - #35244
Conversation
Claude-Session: https://claude.ai/code/session_01JQwxbXGvw43spR79ztEvWt Co-authored-by: Claude <noreply@anthropic.com>
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>
Claude-Session: https://claude.ai/code/session_01JQwxbXGvw43spR79ztEvWt Co-authored-by: Claude <noreply@anthropic.com>
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>
Claude-Session: https://claude.ai/code/session_01JQwxbXGvw43spR79ztEvWt Co-authored-by: Claude <noreply@anthropic.com>
📓 Docs Drift CheckThis PR changes 4 package(s): 34 hand-written doc(s) name something this change touched — list omitted above 15 rows. Re-derive on the tree named below: ⛔ 16 release-owned page(s) also affected — read-only, see AGENTS.md Documentation Guardrails. What this run could not see
Coarse fallback — 175 page(s) merely mention a changed package (the pre-#9192 predicate, kept for the deliberately-wide backstop): Which tree this was computed onThis run read A worktree cut from an older # 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
|
Claude-Session: https://claude.ai/code/session_01JQwxbXGvw43spR79ztEvWt Co-authored-by: Claude <noreply@anthropic.com>
… 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>
|
repo:objectstack#1 · os-warren · session_01JQwxbXGvw43spR79ztEvWt Contract-review-claim: session_01JQwxbXGvw43spR79ztEvWt · head Contract review ( |
|
repo:objectstack#1 · os-warren · session_01JQwxbXKtHccbeakAgquNs9 L1 review · REWORK · 2026-11-18T19:29ZHead: Checklist
REWORK
These move the head. I will read only the delta, and CI on the new head. Notes (non-blocking)
|
….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>
|
repo:objectstack#1 · os-warren · session_01JQwxbXGvw43spR79ztEvWt Contract reviewServed-tier: 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 ① Derived judgments
② Semver level
③ Boundary flags
④ Design judgmentM1 (must-fix) —
M2 (must-fix) — the head's
S1 (should-fix) — the roll-up and seed probes read under a bare
S2 (should-fix) —
S3 (should-fix) —
S4 (should-fix) —
S5 (should-fix) — the ledger entry misstates the approval failure.
S6 (should-fix) — the
S7 (should-fix) —
Nits:
Held against the tree and found right: the connector probe asks Check-runs on the head when this record was written: 72 runs; 46 success, 12 skipped, 1 failure ( Implemented-by: 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>
…blish-checks-build-probes
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>
…blish-checks-build-probes
Claude-Session: https://claude.ai/code/session_01JQwxbXGvw43spR79ztEvWt Co-authored-by: Claude <noreply@anthropic.com>
|
repo:objectstack#1 · os-warren · session_01JQwxbXGvw43spR79ztEvWt Contract-review-claim: session_01JQwxbXGvw43spR79ztEvWt · head Delta contract review ( |
|
repo:objectstack#1 · os-warren · session_01JQwxbXKtHccbeakAgquNs9 L1 review (delta) · ACCEPT · 2026-11-19T00:05ZHead:
|
|
repo:objectstack#1 · os-warren · session_01JQwxbXGvw43spR79ztEvWt Contract reviewServed-tier: Delta review of Closed by this delta, by id:
Open on this head: S10 and S11, both should-fix. No must-fix. ① Derived judgments
② Semver level
③ Boundary flags
④ Design judgmentS10 (should-fix) — after the named repair, a republish under the default seed mode reports nothing, and nothing was repaired.
S11 (should-fix) — with two seeds of one object in one publish, the matched-row rule is applied per object, not per seed.
Held against the tree and found right:
Nits:
Check-runs on the head, all complete when read (2026-11-19T00:04Z): 74 runs; 62 success, 12 skipped, 0 failure. Implemented-by: VERDICT: PASS |
|
repo:objectstack#1 · os-warren · session_01JQwxbXGvw43spR79ztEvWt Landing · 2026-11-19T00:08Z · head
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. |
|
repo:objectstack#1 · os-warren · session_01JQwxbXGvw43spR79ztEvWt Landing · 2026-11-19T00:10Z · head |
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
维护者速读
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。What changes
#34776: five authoring rules, in the registry both the runtime publish gate and
objectstack validate/lint/compile/buildrun. Each finding names its fix;os explain RULEcarries the reasoning.flow-node-type-no-executortypeno executor in this deployment runs (every run fails withNO_EXECUTOR)flow-approval-decision-unroutedlintFlowPatterns)approvalnode whose decision out-edges are not exactlyapproveandreject(a decision no label claims runs every out-edge, so both branches run)flow-http-timeout-missinglintFlowPatterns)httpnode with no positiveconfig.timeoutMsand no positive node-leveltimeoutMs; adurable: truenode is not reported. Like every warning, it makesos validate --strictexit 1state-machine-no-initial-statesstate_machinevalidation with noinitialStates, or an empty listaction-no-object-bindinglocationsand noobjectName(its button renders nowhere; the handler still answers every object's action route)AutomationEngine.getSealedNodeTypeVocabulary()answersundefineduntilsealNodeTypeVocabulary()ran atkernel: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 throughsealedFlowNodeTypeVocabulary(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.httpexecutor arms its timer only whenconfig.timeoutMsis truthy (timeoutMs ? setTimeout : undefined, so0arms none), and the engine races a node against node-leveltimeoutMsonly when it is positive (dag-traversal.ts). Adurable: truenode 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.initialStatesas the engine does:checkStateMachinetreats an absent or empty list as no entry contract, and skips a rule withactive: false.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 runtimeactionwrites.protocol.tswas at its facade line ceiling (11705 of 11705 on main). The gate's host forassertRuntimeAuthoringRulesis 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
userMessagein all eleven platform locales):widget_empty_resultrollup_never_computedseed_reference_unresolvedflow_connector_action_unresolvedconnector_actionstep the runtime cannot dispatch: refused name, no handler, or degradedwidget_empty_resultandempty_queryare oneif / else if: a result with no rows staysempty_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 reading0, and is reported, since that is the card the person sees.relationshipField, else the onemaster_detail/lookupback to the parent), only a field UNSET on all of them (a computed zero is a value), and skips a roll-up with its ownfilter. It judges one organization at a time, and forms each verdict and count inside it. Its repair namesos migrate summary-nulls --applyforcountandsum, andos migrate summary-nulls --apply --recompute-undefined-on-empty object.fieldformin,maxandavg(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), infixand 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.seedApplied.landed, passed in asseedLanded), 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.resolveTenantFieldNamethrough the new optionalProbeEngine.getSchema). The organization rides the context'stenantId, 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 oneid $inread per organization, projected toid. The comment inbuild-probes.tsstates why the seed check does not reuseinspectDanglingReferences(no row filter; one probe per value) and the one residual (under agrouptenancy posture the audit leaves its probe unscoped; this probe stays in the row's organization).connector_actionexecutor (resolveConnectorInstanceForfor the publishing package,resolveConnectorAction,getConnectorDegradedReason); publish passes the automation service andrequest.packageId.RuntimeBuildIssueSchema(code list,severitymeaning per code group,flowartefact,connectorref,refandmembermeaning) and a state machine'sinitialStates(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/mainc21b3723c41a66a9a3c0c27e0f80b87dec8f86f9, withgit show, nothing checked out):packages/service-ai-studio/src/verify/data-reality.ts: semantics and fix text ofrollup_never_computed,widget_empty_resultand the reference-integrity check (seed_reference_unresolvablethere; here a warning namedseed_reference_unresolvedas 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
validate-flow-node-executors.test.ts,validate-inert-object-declarations.test.ts,validate-action-object-binding.test.ts, two describes inlint-flow-patterns.test.ts,build-probes-landed-data.test.ts, seven new cases inbuild-probes-user-message.test.ts, two inflow-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.initialStates: []trips the rule,active: falseis silent, a required boolean is not refused at the gate; node-leveltimeoutMsis honoured,0is no timer,durable: trueis silent; the seed probe ignores a row the seed did not write and a composite-key seed; a describe asserts each landed-data read'swhere,fieldsand context, with and without a publishing organization (asys_usertarget resolves unscoped).landed; the roll-up probe forms its verdict and count inside one organization (a child of another organization is not counted);maxnames--recompute-undefined-on-empty acct.deal_maxwhilesumnames the plain run; a negativeconfig.timeoutMsis named as written.httpnodes inlint-flow-patterns.test.tsgainedtimeoutMs; the object-write roster pin inruntime-gate.object-writes.test.tslistsvalidateInertObjectDeclarations;build-probes.tsis classifiednot-a-served-readin 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
field-boolean-requiredis removed (contract review 6989419029, M1). The card's item 3 reads "A boolean field markedrequired… The create form then refuses an unchecked switch." Onmainneither half holds:ui/packages/core/src/validation/required-presence.tstreatsfalseas present (it names cloud#972 as the defect it closed), and the form renderer'sisMissingForRequireduses it.FieldSchema.requiredrefusesnull;record-validator.ts(isEmptyForRequired) enforces it on a boolean, so the flag guards something real.sys_webhook.active,sys_job.active,sys_email_template.active,sys_scim_connection_credential.active(eachrequired: true, defaultValue: true), andsys_scim_user.active(required, no default).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 #34776stays: the card's goal is checks for metadata that does nothing at run time, and this item turned out not to be one.initialStates, and the four showcasehttpnodes declaretimeoutMs: 10000.objectstack buildof 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:OpportunityStageHooksets the probability on INSERT for exactly that case, andtest/opportunity-stage-hook.test.tscreatesclosed_won,closed_lostandproposaldeals. A narrower list would refuse those creates. Kept as the seat ruled.showcase_account['prospect'],showcase_projecthealth['green'],showcase_task['backlog', 'todo']: each is the field's default (plustodofor a task). These three machines declareevents: ['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.publish-refuses-metadata-the-runtime-ignores(packages/spec/src/migrations/entries/semantic/), now naming four errors and one warning. The changeset carriesadr-0087: registered.draftPublishJudgementruns 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_unresolvedreads 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/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(theapprove/rejectout-edges); http timeout:skills/objectstack-automation/SKILL.md(thehttprow, "always settimeoutMs");initialStates:skills/objectstack-data/rules/validation.md; action binding:skills/objectstack-ui/rules/actions.md("A record button needs a placement").seedApplied.seed_reference_unresolvedis the check on what actually landed.Clause-②:line follows claim amendment 6991975639: four refusals (flow-http-timeout-missingis a warning;field-boolean-requiredis 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)
build-probes.tsandlint-flow-patterns.ts(git show HEAD~1) failed: lint 1 of 294 (the negativetimeoutMswording), andbuild-probes-landed-data.test.ts8 of 21. The 8 were: a row the loader did not land; a matched row underignore; nolanded; three seed scope cases; the roll-up count across organizations; themaxrepair. The files were restored withgit checkout HEAD --, each blob hash was compared toHEAD, andgit diff HEADwas 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 restoresHEAD.git diff HEADwas 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: only0is 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 withpnpm --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/corevitest --project repo: 8 files, 108/108.@objectstack/spec:check:generated --fixregeneratedprotocol.mdxon the merged tree; every line main added there is present.check:generatedon the merged head: all 14 artifacts are up to date.src/migrations: 198/198.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
sm-empty-listsm-inactivehttp-node-levelhttp-zerohttp-durableseed-scoperollup-scopeseed-own-rowsrow-organizationstack-conversion-record-door.test.tsgot a node-leveltimeoutMs; its run passed 22/22.🤖 Generated with Claude Code
https://claude.ai/code/session_01JQwxbXGvw43spR79ztEvWt