Skip to content

feat(spec,ui): an object declares when a whole record is read-only by hand (object-level uiReadonlyWhen) - #38169

Merged
objectstack-fleet[bot] merged 16 commits into
mainfrom
claude/issue-37402-object-ui-readonly-when
Nov 28, 2026
Merged

objectstack-fleet[bot] merged 16 commits into
mainfrom
claude/issue-37402-object-ui-readonly-when

Conversation

@objectstack-fleet

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

Copy link
Copy Markdown
Contributor

Fixes #37402

Clause-②: yes
Metadata-protocol: added
Skills-docs: follow-up #37405

维护者速读

  • 用户能看到什么变化:作者可以在对象上写一句「状态为已确认或已完成时整单人手锁定」,控制台的编辑对话框、记录页、表格、看板、日历、甘特图和工时表都改不了这条记录;备注这类字段可单独放开;按钮、接口、导入、流程照常写入。
  • 为什么做:父卡「字段只能通过动作修改」的裁决「按长远模型」把对象级这一半一并定下;确认后的订单、已过账的发票要整单锁,逐字段写条件容易漏。
  • 出错会怎样:漏掉某个界面入口时用户仍能手改,数据仍由校验规则兜底;去掉对象上的这一句即可撤回。「复制记录取默认值」一项控制台目前没有复制入口,本次未建,见下文。
  • 要你做什么:无。

What changes

Governing ruling (on #36806, 2026-11-26, the card's governing text, quoted): 「按长远模型」 — two tiers (server lock readonly/readonlyWhen; hand lock uiReadonly/uiReadonlyWhen) × two levels (field, object); a field's own declaration wins over the object default; write paths keep every write (the engine never reads the key). ADR-0085 §2 (the object-level key names the console as a whole, not a page) and ADR-0049 (a declared key is enforced on every surface it names).

Spec (packages/spec)

  • ObjectSchema.uiReadonlyWhen — optional CEL predicate over the record's own columns (EvaluatedExpressionInputSchema, the field key's scope), with TSDoc and describe. No default, so no parsed object grows a key.
  • Liveness row object.uiReadonlyWhen (live); Studio object form row (Advanced section, CEL code row); regenerated reference docs, authorable-surface record (data/Object:uiReadonlyWhen) and state counts.

Console (ui/packages/**) — item 3, one helper, no surface reads the key

  • @object-ui/core handLock.ts: effectiveUiReadonlyWhen(def, object) — the field's own uiReadonlyWhen when the field declares a hand lock of its own — uiReadonly: true or a uiReadonlyWhen — else the object's. uiReadonly: false is not a declaration of its own: it reads as absent and the field follows the object lock (seat ruling on the card, Q1 = B; the one opt-out spelling is uiReadonlyWhen: P\false`). fieldLockPredicates(def, object)for operand fetches.fieldReadOnlyByHand(def, record, { object, … })andfieldHasConditionalHandLock(def, object)take the object **as a required argument**, so the compiler asks every caller for it (the helpers first shipped in the19.0.0-next.0prerelease with the field-level hand lock and are in no stable release; a caller written against that prerelease must now pass{ object }` — the changeset carries the migration).
  • Every caller passes the object: record page (DetailSection, HeaderHighlight, InlineEditSaveBar, stage path), grid cell (cellReadOnlyKind gains a required object), kanban drop, calendar drop, Gantt write gate (ganttPatchByHand takes the object), timesheet cell.
  • The direct resolveFieldRuleState callers read the folded predicate from the producer, not the object: the edit dialog's form fields (sectionFields.fromObjectSchema, ObjectForm) carry effectiveUiReadonlyWhen(...), so form.tsx and WizardForm (which judge what a form field carries) fold the object lock with no change of their own; editFormLockedByState folds it the same way; line-item columns (deriveMasterDetail, derived and authored) carry the CHILD object's predicate, which GridFieldWidget already judges per row.
  • Operand fetches: the grid's own row load and the list view's $select fetch the object predicate's operands for every inheriting column / edited-in-place field.

Server

  • Engine untouched (item 6): nothing under packages/objectql/** reads the key.
  • MCP describe_object (item 5) reports the object's uiReadonlyWhen text at the answer's top level where authored, on HTTP (runtime/domains/mcp.ts) and stdio (mcp/mcp-server-runtime.ts); the tool description says how to read it.
  • FLS scrub (metadata-core): an object predicate that reads a field denied to the caller is served as the constant true (fail-closed, the field-level precedent: deleting it would open every record for exactly that caller).
  • os validate (lint): the object slot is checked as the field slot is (record-scoped check + root verdict), at object 'NAME' uiReadonlyWhen.
  • Studio form row translated in all 11 metadata-forms locale packs (platform-objects); translated-leaf pin 845 → 846.

Why

A whole-record lock (confirmed order, posted invoice) had to be written as a uiReadonlyWhen on every field — tedious, and one missed field leaves a hand edit open. The ruling adopted the object level now.

Item 4 (console duplicate) — no surface, not delivered

Measured on f72f3353: no person-triggered record duplicate exists in the console. Searched ui/packages and ui/apps for duplicate|clone|onClone|cloneRecord|data.clone(: the hits are the view switcher's view actions, Studio package/sharing-rule/permission-set clones, an unused detail.duplicate translation string, and the spec capability flag enable.clone. The only record clone is the REST door POST /data/:object/:id/clone (rest/data-action-routes.ts → cloneData), reached by the SDK's data.clone — an API write, which by the ruling keeps every value. Item 4 is reported as "no surface — not delivered" and nothing was built; the done-when clause "duplicating the confirmed record yields a record whose status is the field's defaultValue" has no surface to hold on. The rule is carried by #38202 as the acceptance of a future console Duplicate action (seat ruling on the card, Q3). Fixes #37402 stands.

Tests

  • @object-ui/core handLock-36806.test.ts (new top-level describe): object lock locks a non-declaring field while TRUE and only then; uiReadonlyWhen: 'false' (string and envelope) keeps a field editable; a field's own predicate / uiReadonly: true locks where the object does not (override both directions); explicit uiReadonly: false is NOT a declaration — the field follows the object lock (Q1 = B), with a CONTROL that uiReadonlyWhen: 'false' (alone or beside uiReadonly: false) still opens it; server lock does not cancel the object default; fail-closed on a faulted / operand-less object predicate; the fold helpers.
  • plugin-form dialogHandLock-36806.test.ts: dialog form fields carry the object predicate / the field's own; line-item columns (derived and authored) carry the child object's.
  • app-shell editFormLockedByState.test.ts: object lock greys Edit; a false override keeps it live; off while the predicate does not hold.
  • plugin-grid: cell verdict over the object lock and its override; the row load $select asks for the object predicate's operand and not for a column with its own lock.
  • plugin-kanban: a drop on a record the object locks writes nothing; a lane field with its own false writes the move.
  • lint: object slot accepted / bare reference / parse / undeclared field / unbound root refused (each authoring refusal has a test); read-surface pin gains uiReadonlyWhen.
  • metadata-core: denied operand → served 'true' (string and envelope); readable → served as written.
  • mcp stdio and runtime HTTP describe_object: the object predicate is reported; no field's readonly changes; a stored uiReadonly: false lists no hand-lock key; an object without it carries no key.
  • Dogfood (ui-readonly-hand-lock-36806.dogfood.test.ts, new top-level describe on one shared boot): the done-when object (state_machine on status, object uiReadonlyWhen: P\record.status in ['confirmed','done']`, notes P`false`); the served definition carries both predicates; a PATCH to a confirmed record lands with **no X-ObjectStack-Dropped-Fields`**; an import update writes and the machine still refuses an illegal move; a declarative action writes.

Acceptance notes

  • L2 record (contract review, PASS) S1 fixed in head 36e883f1: WizardForm.tsx's final-submit gate drops the carried uiReadonlyWhen on a CREATE wizard, at the evaluating site, as form.tsx and GridFieldWidget do. Fixed there rather than in sectionFields.fromObjectSchema because every other create surface already drops the predicate where it evaluates it; omitting it at the producer would make one of four readers behave differently from the other three, and the gate also reads predicates that never pass through fromObjectSchema. The same gate still judges the field's own readonlyWhen on a create, where form.tsx does not; that is pre-existing and left alone. Pin in wizardPredicateScope.test.tsx: a create wizard over a locked object still demands an empty required field (red before the fix: the create went through); CONTROL: an edit wizard on a confirmed record still treats the inheriting field as locked and saves without it (green before and after). N2 (this body and the @object-ui/core changeset now name 19.0.0-next.0) and N3 (describe_object: a field's own uiReadonlyWhen is judged by that predicate, which may itself lock it) are taken; N1 waits on the seat's maintainer question.

  • Seat rulings on the card's three open questions (newest seat comment on spec: an object declares when a whole record is read-only by hand (object-level uiReadonlyWhen), fields override it, and duplicating a record takes the locked fields' defaults #37402): Q1 = B, maintainer verbatim 「B 不算放开」 — implemented in head 696c37e9 (declaresOwnHandLock, the pin flipped, every describe / help / liveness / changeset / describe_object string names the two counting spellings; help retranslated in 10 locales). Q2 = A, kept as built. Q3: item 4 closes as "no surface — not delivered", carried by console: a person-triggered "Duplicate record" action, whose copy takes hand-locked fields' defaults (the rule ruled on #36806, no surface today) #38202.

  • requiredWhen prompt collector (fields/requiredWhenPrompt.ts) keeps reading the field's own key: the hosts' fillable callbacks already judge the object lock over the STORED record, which is the right record for a transition the person is still allowed to make.

  • The public intake form page (ui/apps/console FormPage.tsx) is create-only and never carried a hand lock; untouched.

  • A parent's object lock does not lock its child line-item rows: those rows are records of the child object and follow the child object's own lock.

  • The grid cell judges with the grid's own fetched object definition; while that read is in flight the cell sees no object lock (the same window the host field catalogue already has).

  • objectExtensions does not gain the key (not asked).

Verification

Two-minute check: cd ui && pnpm exec vitest run packages/core/src/evaluator/__tests__/handLock-36806.test.ts — expect the #37402 describe green (7 cases).

First files to read (by risk): ui/packages/core/src/evaluator/handLock.ts (the fold and its override rule); ui/packages/plugin-form/src/sectionFields.ts (how the edit dialog gets the object lock without form.tsx reading it); packages/metadata-core/src/object-schema-fls-references.ts (objectHandLock, the fail-closed serve).

S1 verification on head 36e883f1: wizard pins red before the fix (1 failed: the create case; CONTROL green), green after; wizard + dialog files 5 files / 31; @object-ui/plugin-form full suite 248 files / 2,805 and type-check 0; mcp typecheck 0, mcp-server-runtime.test.ts 20/20; overlap-check clean. The derived gate union on 36e883f1 is reported in the card's delta os-dev-report.

Q1 re-verification on head 696c37e9 (no conflict with origin/main, so no merge): ui hand-lock files 5/5 (49 tests); ablation restoring the old rule (uiReadonly !== undefined counts) turns the flipped pin red (1 failed / 14 passed), restore blob == HEAD; mcp mcp-server-runtime.test.ts 20/20, runtime describe 5/5; typecheck mcp, runtime and @object-ui/core type-check 0; spec check:liveness 0; spec check:generated all 14 up to date; check:i18n 0, check:i18n-stale-fill OK; platform-objects 130 files / 2,214; overlap-check clean. The derived gate union on 696c37e9 is reported in the card's delta os-dev-report.

Verification record (first head) — every reading below is taken on objectstack-ai/objectstack at head 0bee2a81 (the branch after merging origin/main at 0e361201) unless it says otherwise; locked runs went through os-verify-lock.sh.

Tests (package suites and targeted files)
  • @objectstack/spec full suite (pre-merge head 6ce7aa65, spec untouched by the merge; check:generated re-run green on 0bee2a81): 910 files / 28,814 passed.
  • @objectstack/runtime full suite (pre-merge): 655 files / 12,342 passed, 25 skipped; on 0bee2a81: mcp-object-hand-lock-36806.test.ts 5/5 and typecheck 0.
  • @objectstack/lint full suite on 0bee2a81: 245 files / 9,870 passed; typecheck 0.
  • @objectstack/metadata-core full (pre-merge): 244 files / 9,861; on 0bee2a81 the FLS file 68/68.
  • @objectstack/mcp full (pre-merge): 88 files / 1,644; on 0bee2a81 mcp-server-runtime.test.ts 20/20.
  • @objectstack/platform-objects full (pre-merge): 130 files / 2,214.
  • @objectstack/metadata-protocol protocol.meta-types-degenerate-derivation.test.ts on 0bee2a81: 18/18.
  • Dogfood ui-readonly-hand-lock-36806.dogfood.test.ts (booted stack): 10/10.
  • UI full suites (pre-merge): core 250 files / 4,843; plugin-form 248 / 2,803; plugin-detail 424 / 4,000; plugin-timesheet 3 / 46; plugin-grid 319 / 2,803; plugin-kanban 91 / 613; plugin-calendar 70 / 527; plugin-gantt 98 / 816; plugin-list 190 / 2,081 — all green. app-shell full suite: NOT MEASURED locally (stopped after 40+ min; CI Test UI runs it); its two lock files ran green.
  • UI hand-lock files on 0bee2a81 (15 files): 250/250. type-check on 0bee2a81: core, plugin-form, plugin-detail, plugin-grid, plugin-kanban, plugin-calendar, plugin-list, plugin-gantt, plugin-timesheet, app-shell — all Done.
  • Type-check (pre-merge): spec, lint, mcp, metadata-core, runtime, platform-objects, dogfood — all 0.
Shown red without the fix (ablation, restored to HEAD each time)
  • effectiveUiReadonlyWhen made to ignore the object (return undefined): 10 of the new UI pins red across core, plugin-form, app-shell, plugin-grid (cell and row load) and plugin-kanban; the override controls stayed green. Restore: blob equals HEAD, git diff HEAD empty.
  • Lint: the object slot read made undefined: the four refusal cases red, the accept case green. (A first attempt was refused by the ablation tool before running — its replacement text already existed — and re-anchored.)
  • FLS: uiReadonlyWhen: objectHandLock swapped for expression: the fail-closed pin red, the control green.
Gates (derived union on 0bee2a8)
  • node scripts/pm/dispatch-gates.mjs --commands: 127 families; all run; 124 exit 0; 3 exit 3 (PREREQUISITE NOT MET, NOT MEASURED): check-plugin-teardown-shape.mjs --self-test (shallow clone cannot read its pinned fixture commit), spec check:skill-examples (client SDK dist not built), check:dual-build-cjs-loads (a package without dist). CI runs all three.
  • dispatch-gates.mjs --ran with exit codes: "127 derived famil(ies) accounted for — 124 run, 3 NOT-MEASURED (3 DERIVED from a recorded exit 3)".
  • spec check:generated on 0bee2a81: "All 14 generated artifacts are up to date".
  • overlap-check.mjs before every push: VERDICT clean exit 0.
  • check-nul-bytes.mjs: 0.
  • Full dogfood battery: n/a (no !, no (narrowing) arm).

Human Minimum

  • 1. Schemas start as Zod; packages/spec holds no runtime logic.
  • 2. Every name I added uses the casing for its kind.
  • 3. No formatter ran; pnpm lint passes (CI).
  • 4. One issue, one branch off an up-to-date main, one pull request.
  • 5. A change that publishes carries a changeset, and both declaration lines are filled in here and in the changeset.
  • 6. packages/spec touched: its generated artifacts are regenerated and committed.
  • 7. No hand edits to content/docs/references/, packages/*/CHANGELOG.md or content/docs/releases/.
  • 8. Title, body and comments are in English.

🤖 Generated with Claude Code

https://claude.ai/code/session_017xRBcRd37NZMCYvVAmVk4b


Generated by Claude Code

… hand (object-level uiReadonlyWhen)

WIP: spec key, console fold, MCP describe, FLS scrub, lint slot.

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

Claude-Session: https://claude.ai/code/session_017xRBcRd37NZMCYvVAmVk4b
Co-authored-by: Claude <noreply@anthropic.com>
…tems, edit lock, grid and kanban

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

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

github-actions Bot commented Nov 28, 2026 •

Copy link
Copy Markdown
Contributor

📓 Docs Drift Check

This PR changes 6 package(s): @objectstack/lint, @objectstack/mcp, @objectstack/metadata-core, @objectstack/platform-objects, @objectstack/runtime, @objectstack/spec, touching 10 documentable anchor(s). ⚠️ 3 changed file(s) yielded no anchor (packages/spec/authorable-surface/data.json, packages/spec/liveness/object.json, packages/spec/liveness/state-counts/object.md), so the pages documenting them are NOT COVERED by this run — this is not a clean bill of health for those files.

1 hand-written doc(s) NAME something this change touched and may need an implementation-accuracy re-verification:

  • content/docs/concepts/metadata-driven.mdx (via ObjectSchemaBase (symbol, a top-level const object))
What this run could not see
  • 3 changed file(s) yielded no anchor (packages/spec/authorable-surface/data.json, packages/spec/liveness/object.json, packages/spec/liveness/state-counts/object.md) — pages documenting those are invisible to this run
  • 2 name(s) were too generic to anchor anything (single lowercase words)
  • the SDK route bridge reached 69 of 252 client-bound route-ledger rows — the other 183 have no registrar path: tail to select them, so pages documenting THEIR client methods cannot appear above, on this or any run. Of those 183: 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; 124 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 — 187 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 73ec085afa2f9689ef96263a9c25b82cde6fda47 → packageMentionDocs.

Which tree this was computed on

This run read content/docs from 41f6f29da027d2570b0d4cc368468466d812a27b — the merge of head b012f9b6094cfc372f46c5a64cbecc127b733524 into base 73ec085afa2f9689ef96263a9c25b82cde6fda47, 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 41f6f29da027d2570b0d4cc368468466d812a27b && git checkout 41f6f29da027d2570b0d4cc368468466d812a27b
# afterwards, rebuild it from the two parents, which stay fetchable
git fetch origin 73ec085afa2f9689ef96263a9c25b82cde6fda47 b012f9b6094cfc372f46c5a64cbecc127b733524 && git checkout -B drift-repro 73ec085afa2f9689ef96263a9c25b82cde6fda47 && git merge --no-ff b012f9b6094cfc372f46c5a64cbecc127b733524

node scripts/docs-audit/affected-docs.mjs --json 73ec085afa2f9689ef96263a9c25b82cde6fda47

⚠️ 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 73ec085afa2f9689ef96263a9c25b82cde6fda47 → pass the list as
args.docs, on the commit named under Which tree this was computed on.

…follows the object lock (ruling Q1 = B)

Claude-Session: https://claude.ai/code/session_017xRBcRd37NZMCYvVAmVk4b
Co-authored-by: Claude <noreply@anthropic.com>
…rences name the two counting spellings

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

Copy link
Copy Markdown
Contributor Author

repo:objectstack#8 · sunhaolin · session_017xRBcSAaBEfQpU2yJexSJ8

Contract-review-claim: session_017xRBcSAaBEfQpU2yJexSJ8 · head 696c37e · 2026-11-28T07:47Z

The lane seat runs the owed CONTRACT_REVIEW_TIER review through an isolated at-tier subagent.

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#8 · sunhaolin · session_017xRBcSAaBEfQpU2yJexSJ8

Contract review

Served-tier: CONTRACT_REVIEW_TIER
Head-sha: 696c37e9089a35d06fc3be07c5893eb26987d05a
Local-runs: none
Scope: packages/spec/src/data/object.zod.ts, packages/spec/src/data/object.metadata-form.ts + ui/packages/core/src/evaluator/handLock.ts, ui/packages/plugin-form/src/sectionFields.ts, ui/packages/plugin-form/src/ObjectForm.tsx, ui/packages/plugin-form/src/deriveMasterDetail.ts, ui/packages/app-shell/src/utils/editFormLockedByState.ts, ui/packages/plugin-grid/src/objectGridCellFacts.ts, ui/packages/plugin-grid/src/objectGridRowLoad.ts, ui/packages/plugin-grid/src/ObjectGrid.tsx, ui/packages/plugin-list/src/ListView.tsx, ui/packages/plugin-kanban/src/ObjectKanban.tsx, ui/packages/plugin-calendar/src/ObjectCalendar.tsx, ui/packages/plugin-gantt/src/ganttHandLock.ts, ui/packages/plugin-gantt/src/ObjectGantt.tsx, ui/packages/plugin-timesheet/src/ObjectTimesheet.tsx, ui/packages/plugin-detail/src/DetailSection.tsx, ui/packages/plugin-detail/src/HeaderHighlight.tsx, ui/packages/plugin-detail/src/InlineEditSaveBar.tsx, ui/packages/plugin-detail/src/renderers/recordPathStageChange.tsx, packages/lint/src/validate-expressions.ts, packages/metadata-core/src/object-schema-fls-references.ts, packages/runtime/src/domains/mcp.ts, packages/mcp/src/mcp-server-runtime.ts, packages/mcp/src/mcp-http-tools.ts, packages/spec/liveness/object.json
Security-touching: yes
Rule-change-verified: none

Inputs read: card #37402 body and all six comments (rulings 7235326611 included), the governing ruling 7180466652 on #36806, PR #38169 body and file list (73 files), the net diff against the merge base 0e361201, and the check-runs on the head (every run success or skipped). Security-touching: yes because the metadata-core hunk teaches field-level-security behaviour; no hits path is under skills/** or .claude/**.

① Derived judgments

  • Accept-set, ObjectSchema: one new optional key uiReadonlyWhen (EvaluatedExpressionInputSchema.optional(), the field key's type). The object is a strictObject, so this is a widening. Right. No default, so no parsed object grows a key.
  • os validate: a new refusal at object 'NAME' uiReadonlyWhen; no stack valid on main carries the key. Right.
  • Served metadata: a predicate that mentions a denied field is served as constant true (the object-level twin of the field-level arm) — Q2 = A. Right.
  • MCP describe_object: one new optional top-level key on both answers plus the tool description. Additive. Right.
  • @object-ui/core: new effectiveUiReadonlyWhen, fieldLockPredicates, ObjectHandLockDef; fieldReadOnlyByHand / fieldHasConditionalHandLock signatures narrowed (see ②). Every in-repo caller updated; Type Check UI green.
  • Generated and pinned surfaces: the lane seat's remainder, gates green.
  • Engine: nothing under packages/objectql/** in the diff; item 6 holds by absence; the dogfood pin (no X-ObjectStack-Dropped-Fields on a PATCH to a confirmed record) green.

② Semver level

  • @objectstack/spec minor for one new optional authorable key: right.
  • @object-ui/core minor: stands (helpers added on 2026-11-26, never in a stable release, pre mode). The changeset's "not published yet … after 19.0.0-next.0" sentence is contradicted by the head's CHANGELOG (N2).
  • 13 other changesets patch, one per moved published package. Check Changeset green.
  • Clause-②: yes (widening), Metadata-protocol: added, consistent with the diff.

③ Boundary flags

  • Q1 = B (maintainer): implemented — declaresOwnHandLock is uiReadonly === true || uiReadonlyWhen != null; the rule is stated as B in every place it appears (TSDoc/describe, Studio form help and locales, liveness row, changesets, describe_object description, describedHandLockPredicate comments, handLock.ts header). No statement of A left. Pinned.
  • Q2 = A: implemented as ruled.
  • Q3: the PR body reports item 4 as "no surface — not delivered" and names console: a person-triggered "Duplicate record" action, whose copy takes hand-locked fields' defaults (the rule ruled on #36806, no surface today) #38202 (open, p3). A read-only search of ui/** at the head for a record clone or duplicate caller returned nothing.
  • Dev deviations: all accepted (Test UI 16/16 covers the app-shell suite).
  • ESCALATED to the seat — a product question: a parent's whole-record lock does not cover its inline child rows. Line-item columns carry the CHILD object's predicate (deriveMasterDetail.ts), and editFormLockedByState returns false whenever the object places an inline child collection, so a confirmed order with lines keeps every line row editable by hand unless the child declares its own lock (which cannot read the parent's status). This is the literal reading of the card's item 1, disclosed in the PR's acceptance notes, but the maintainer summary promises 「整单人手锁定」. It needs a carrier or the maintainer's word; it does not block this head.
  • Skills-docs: follow-up owed — skills/objectstack-data/SKILL.md names no carrier number; bind it to adr: field write locks are two tiers, two forms and two levels (readonly / readonlyWhen vs uiReadonly / uiReadonlyWhen, field over object); the data skill teaches the four spellings #37405 or a new card.
  • SQL push-down: no finding.

④ Design judgment

object.zod.ts holds against ruling 7180466652 and Q1 = B; effectiveUiReadonlyWhen agrees with the TSDoc sentence by sentence (a field's own uiReadonly: true or uiReadonlyWhen wins both ways; uiReadonly: false reads as absent; a server lock does not cancel the object default; a fault locks every inheriting field; a blank field predicate fails closed), with one exception, S1. object.metadata-form.ts states the B rule in Studio's own words. The implementing files agree with the contract.

S1 (should-fix) — "A create is not judged" does not hold in the wizard's final-submit gate. sectionFields.ts (fromObjectSchema) puts the object's predicate on every form field in every mode; form.tsx and GridFieldWidget drop it on create, but WizardForm.tsx gateFinalSubmit (line 905) passes it to resolveFieldRuleState with no create check and skips any field that resolves readonly. On a create wizard for an object with the lock, a TRUE or faulting predicate over the wizard's values makes every inheriting field read-only, so the whole-form required check is skipped. No hand lock opens and the server still refuses; the cost is the client-side gate. Fix at one site (omit the effective predicate when isCreateFormMode(ctx) in sectionFields.ts, or drop it on isCreateWizard in the gate) plus a pin. Read from code, not run.

N1 (nit) — the object describe lists "the line-item grid" among locked surfaces without saying line rows follow the CHILD object's lock; carry with the ③ escalation.

N2 (nit) — the @object-ui/core changeset's "not published yet" sentence (and the PR body's) is contradicted by the CHANGELOG at the head. Level unaffected.

N3 (nit) — mcp-http-tools.ts says a person "cannot edit any field … except a field that lists its own uiReadonlyWhen"; such a field is judged by its own predicate, which may lock it.

No must-fix found. S1 is open on this head and earns a delta review of its fix.

Implemented-by: claude/issue-37402-object-ui-readonly-when
Reviewed-by: session_017xRBcSAaBEfQpU2yJexSJ8

VERDICT: PASS

…and lock on a create (L2 S1)

Also: the @object-ui/core changeset names the prerelease the helpers first shipped in,
and describe_object says a field's own uiReadonlyWhen may itself lock it.

Claude-Session: https://claude.ai/code/session_017xRBcRd37NZMCYvVAmVk4b
Co-authored-by: Claude <noreply@anthropic.com>
…ls/list byte ceiling

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

Copy link
Copy Markdown
Contributor Author

repo:objectstack#8 · sunhaolin · session_017xRBcSAaBEfQpU2yJexSJ8

L1: ACCEPT · head fe52e09c78 · 2026-11-28T11:01Z · card #37402

Seat checks

  1. Shape
  2. L2: delta record on this head (CONTRACT_REVIEW_TIER, fable) is PASS.
  3. The flagged L1 item, changeset: @objectstack/metadata-protocol moved one TEST file only. protocol.meta-types-degenerate-derivation.test.ts takes the object property count from 52 to 53 for the new key. Test files do not ship in the tarball, and Check Changeset is green, so no changeset is owed.
  4. Changesets read sentence by sentence:
    • spec, ui-core, plugin-form and mcp: each sentence holds against the tree and the rulings.
    • Q1 = B: uiReadonly: false follows the object lock; the opt-out spelling is uiReadonlyWhen: false.
    • A create is not judged on any surface (the L2's 7-row create-path table).
    • The migration line for the @object-ui/core helpers is right, and so is the prerelease provenance.
    • Line-item columns carry the child object's predicate, which is the ruled literal reading.
    • The 11 package-move patch changesets name their surface only.
  5. Gates at this head
    • 61 success · 9 expected skip · 0 failed · 0 pending.
    • The tools-list-weight-34689 ceiling (38000, not raised) is green after fe52e09c.
    • NOT governed: 0 of 75 paths, +1080/−104. K = 11 < 15.

Landing: non-governed, ≤3000 lines. The seat lands it through the ordinary queue.

@objectstack-fleet
objectstack-fleet Bot marked this pull request as ready for review November 28, 2026 11:01
@objectstack-fleet
objectstack-fleet Bot added this pull request to the merge queue Nov 28, 2026
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to failed status checks Nov 28, 2026
@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#8 · sunhaolin · session_017xRBcSAaBEfQpU2yJexSJ8

Re-queue · 2026-11-28T11:30Z · head fe52e09c unchanged · first ejection, judged by signature.

  • Removed 11:26:01Z. No merge_group run of this PR failed: Governed Surface Guard, Spec Liveness, PR-Body Guards and Lint & Type Check are all success on run set 46137914xxx, and its CI was still in progress.
  • The failure was in the batch ahead: fix(lint)!: refuse a lookupFilters $record path to a structured field #38096's Governed Surface Guard run 46138451005 refused (a narrowing with no authorized approval). That PR has now left the queue and been handed to its approver (pm:awaiting-merge), so the root is out of the queue.

Landing rule: a knock-on removal with its root out of the queue ⇒ re-queue once, as is.

@objectstack-fleet
objectstack-fleet Bot added this pull request to the merge queue Nov 28, 2026
@github-actions

Copy link
Copy Markdown
Contributor

⛔ merge queue 构建失败 — 先分诊,再决定要不要重排

队列构建 46137914293 红了。队列跑的是全量套件(PR 侧 CI 只跑 affected 子集),
所以失败的测试可能在本 PR 没碰过的包里 —— 那不是重排能修的。每次盲目重排都会让排在后面的所有 PR 重建一轮。

分类:failure —— 按下面的日志分诊。

失败的 job(日志抽取,best effort):

  • Dogfood Regression Gate (3/3) — 失败步骤: Boot example apps and exercise real user flows

    @objectstack/dogfood:test:  FAIL   isolated  test/expression-conformance.test.ts > ADR-0058 D7 — expression surface conformance ledger > is a sound conformance ledger + ratchet (ADR-0060 checkLedger)
      ↳ 失败原因: @objectstack/dogfood:test: AssertionError: UNCLASSIFIED surface — add a ledger row (ADR-0060): data/object.zod.ts:ObjectSchemaBase.uiReadonlyWhen: expected [ Array(1) ] to deeply equal []
    

↳ 失败原因 是判读的关键:超时(Test timed out in … / Hook timed out in …)多半是负载/时序,不是本 PR 的回归;
断言(AssertionError: …)才指向真实的行为改变。两者的 FAIL 行长得一模一样,只有这一行能区分。

⚠️ 断言这一侧有一类例外,判据是断言在测什么,不是它是不是 AssertionError。 断言的对象是产品行为(一个值、一个形状、一次拒收)⇒ 照上面读:真实的行为改变,去查,⛔ 不要重排掉;
断言的对象是这次实验自身的有效性前提(跑完的耗时、负载下的先后、任何只在时间预算内才成立的条件)⇒ 它跟超时是同一类,同样对负载敏感,重排一次是合法的判别手段。
识别是机械的:断言的消息或它比较的值本身点名了一段时长、一个时间戳、一个耗时计数。实测过的一对 —— AssertionError: SecurityPlugin.init() ran: expected false to be true 测的是产品行为(真回归);
AssertionError: this run took over a second, so second-precision stamps could have differed too: expected 1006 to be less than 1000 测的是实验前提:它守护的那条不变式当时是绿的,同一个 head 原样重排一次即成功。
穿着 AssertionError 外衣的时间测量,仍然是时间测量。(⛔ 这只改「怎么读一次红」,不改「哪些测试可以重排」——后者由别处管。)

跨 PR 相同签名(24h,按失败测试文件聚合):

历史信号:

  • 本 PR 过去 24h 无队列失败记录(首次)。
  • 过去 24h 队列共有 20 个失败构建(不含本次)。

分诊清单:

  1. 失败测试在本 PR 改动的包里 → 真回归,修 PR。
  2. 失败测试与本 PR 无关 → 看上面的「跨 PR 相同签名」;已有汇总 issue ⇒ flaky/环境问题实锤,去那张 issue 上谈,修好前重排只会再烧一轮全队列。
  3. 两者都不是 → 可能与同组 PR 语义冲突;等前面的 PR 落地或失败出队后再重排一次即可,不要连续重排。

Generated by Claude Code · merge-queue-triage workflow (#4859)

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

Relay pr_dequeue · session_017xRBcSAaBEfQpU2yJexSJ8 · request fw-20261128T113340Z-73b0cf

Merge-queue dequeue of #38169 — cause seat-asks.

  • Relay read: landing seat repo:objectstack#8 · sunhaolin, signed by repo:objectstack#8 · sunhaolin · session_017xRBcSAaBEfQpU2yJexSJ8.
  • Seat's reason: Queue run 46137914293 Dogfood Regression Gate (3/3): expression-conformance.test.ts UNCLASSIFIED surface data/object.zod.ts:ObjectSchemaBase.uiReadonlyWhen needs an ADR-0060 ledger row; deterministic, this PR adds the key. Patch round before re-queue.

The relay sends dequeuePullRequest after this comment and confirms the removal by reading the queue back; the run row of this request carries the outcome. Re-queue once the cause is fixed (landing-operations.md, the landing seat's queue duty).

@objectstack-fleet
objectstack-fleet Bot removed this pull request from the merge queue due to a manual request Nov 28, 2026
@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#8 · sunhaolin · session_017xRBcSAaBEfQpU2yJexSJ8

Dequeued · 2026-11-28T11:34Z · head fe52e09c · correction to my re-queue receipt 7238605356.

That receipt read this PR's CI as "still in progress". It went on to fail on this PR's own diff:

  • Queue run 46137914293, Dogfood Regression Gate (3/3): test/expression-conformance.test.ts › "is a sound conformance ledger + ratchet (ADR-0060 checkLedger)". Failure: AssertionError: UNCLASSIFIED surface — add a ledger row (ADR-0060): data/object.zod.ts:ObjectSchemaBase.uiReadonlyWhen.
  • This is deterministic. The PR adds ObjectSchema.uiReadonlyWhen, a new expression surface, without its ADR-0058 D7 / ADR-0060 conformance-ledger row. PR CI does not run that dogfood shard, which is why the PR side was green.

The seat dequeued the re-queued entry (relay pr_dequeue, cause seat-asks, before its build ran) so the PRs queued behind it are spared. A patch round to the dev adds the ledger row. Then: a delta L2 on the new head, L1, re-queue.

…ema.uiReadonlyWhen

Claude-Session: https://claude.ai/code/session_017xRBcRd37NZMCYvVAmVk4b
Co-authored-by: Claude <noreply@anthropic.com>
@github-actions

Copy link
Copy Markdown
Contributor

⛔ merge queue 构建失败 — 先分诊,再决定要不要重排

队列构建 46140292866 红了。队列跑的是全量套件(PR 侧 CI 只跑 affected 子集),
所以失败的测试可能在本 PR 没碰过的包里 —— 那不是重排能修的。每次盲目重排都会让排在后面的所有 PR 重建一轮。

分类:failure —— 按下面的日志分诊。

失败的 job(日志抽取,best effort):

  • Dogfood Regression Gate (3/3) — 失败步骤: Boot example apps and exercise real user flows

    @objectstack/dogfood:test:  FAIL   isolated  test/expression-conformance.test.ts > ADR-0058 D7 — expression surface conformance ledger > is a sound conformance ledger + ratchet (ADR-0060 checkLedger)
      ↳ 失败原因: @objectstack/dogfood:test: AssertionError: UNCLASSIFIED surface — add a ledger row (ADR-0060): data/object.zod.ts:ObjectSchemaBase.uiReadonlyWhen: expected [ Array(1) ] to deeply equal []
    

↳ 失败原因 是判读的关键:超时(Test timed out in … / Hook timed out in …)多半是负载/时序,不是本 PR 的回归;
断言(AssertionError: …)才指向真实的行为改变。两者的 FAIL 行长得一模一样,只有这一行能区分。

⚠️ 断言这一侧有一类例外,判据是断言在测什么,不是它是不是 AssertionError。 断言的对象是产品行为(一个值、一个形状、一次拒收)⇒ 照上面读:真实的行为改变,去查,⛔ 不要重排掉;
断言的对象是这次实验自身的有效性前提(跑完的耗时、负载下的先后、任何只在时间预算内才成立的条件)⇒ 它跟超时是同一类,同样对负载敏感,重排一次是合法的判别手段。
识别是机械的:断言的消息或它比较的值本身点名了一段时长、一个时间戳、一个耗时计数。实测过的一对 —— AssertionError: SecurityPlugin.init() ran: expected false to be true 测的是产品行为(真回归);
AssertionError: this run took over a second, so second-precision stamps could have differed too: expected 1006 to be less than 1000 测的是实验前提:它守护的那条不变式当时是绿的,同一个 head 原样重排一次即成功。
穿着 AssertionError 外衣的时间测量,仍然是时间测量。(⛔ 这只改「怎么读一次红」,不改「哪些测试可以重排」——后者由别处管。)

跨 PR 相同签名(24h,按失败测试文件聚合):

历史信号:

  • ⚠️ 本 PR 过去 24h 已在队列失败 1 次(不含本次)。 内容未变而反复失败 ⇒ 高度怀疑 flaky 测试或与同组 PR 的语义冲突,重排不解决。
  • 过去 24h 队列共有 29 个失败构建(不含本次)。

分诊清单:

  1. 失败测试在本 PR 改动的包里 → 真回归,修 PR。
  2. 失败测试与本 PR 无关 → 看上面的「跨 PR 相同签名」;已有汇总 issue ⇒ flaky/环境问题实锤,去那张 issue 上谈,修好前重排只会再烧一轮全队列。
  3. 两者都不是 → 可能与同组 PR 语义冲突;等前面的 PR 落地或失败出队后再重排一次即可,不要连续重排。

Generated by Claude Code · merge-queue-triage workflow (#4859)

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#8 · sunhaolin · session_017xRBcSAaBEfQpU2yJexSJ8

Contract-review-claim: session_017xRBcSAaBEfQpU2yJexSJ8 · head b012f9b · 2026-11-28T12:13Z

The lane seat runs the owed CONTRACT_REVIEW_TIER delta review (the conformance-ledger row) through an isolated at-tier subagent.

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#8 · sunhaolin · session_017xRBcSAaBEfQpU2yJexSJ8

Contract review

Served-tier: CONTRACT_REVIEW_TIER
Head-sha: b012f9b6094cfc372f46c5a64cbecc127b733524
Local-runs: none
Scope: packages/spec/src/data/object.zod.ts, packages/spec/src/data/object.metadata-form.ts + packages/qa/dogfood/test/expression-conformance.ledger.ts, ui/packages/core/src/evaluator/handLock.ts, ui/packages/plugin-form/src/sectionFields.ts, ui/packages/plugin-form/src/ObjectForm.tsx, ui/packages/plugin-form/src/WizardForm.tsx, ui/packages/plugin-form/src/deriveMasterDetail.ts, ui/packages/app-shell/src/utils/editFormLockedByState.ts, ui/packages/plugin-grid/src/objectGridCellFacts.ts, ui/packages/plugin-grid/src/objectGridRowLoad.ts, ui/packages/plugin-grid/src/ObjectGrid.tsx, ui/packages/plugin-list/src/ListView.tsx, ui/packages/plugin-kanban/src/ObjectKanban.tsx, ui/packages/plugin-calendar/src/ObjectCalendar.tsx, ui/packages/plugin-gantt/src/ganttHandLock.ts, ui/packages/plugin-gantt/src/ObjectGantt.tsx, ui/packages/plugin-timesheet/src/ObjectTimesheet.tsx, ui/packages/plugin-detail/src/DetailSection.tsx, ui/packages/plugin-detail/src/HeaderHighlight.tsx, ui/packages/plugin-detail/src/InlineEditSaveBar.tsx, ui/packages/plugin-detail/src/renderers/recordPathStageChange.tsx, packages/lint/src/validate-expressions.ts, packages/metadata-core/src/object-schema-fls-references.ts, packages/runtime/src/domains/mcp.ts, packages/mcp/src/mcp-server-runtime.ts, packages/mcp/src/mcp-http-tools.ts, packages/spec/liveness/object.json
Security-touching: yes
Rule-change-verified: none

Delta round on the full record 7238240401 (head fe52e09c, PASS, nothing open), rendered as a full record on this head.

Inputs read:

Security-touching: yes because the metadata-core hunk teaches field-level-security behaviour, as before. No hits path is under skills/** or .claude/**.

① Derived judgments

  • Unchanged since fe52e09c. The delta touches no hits file and no spec, lint, runtime, MCP or UI file. The earlier judgments stand:
    • ObjectSchema.uiReadonlyWhen is one new optional key on a strictObject, a widening with no default. Right.
    • os validate gains a refusal at object 'NAME' uiReadonlyWhen. Right.
    • A predicate that reads a denied field is served as constant true (Q2 = A). Right.
    • describe_object answers one new optional top-level key on both transports. Additive. Right.
    • The @object-ui/core helper signatures take the object as a required argument, and every in-repo caller passes it. Right.
    • Nothing under packages/objectql/** is in the diff. Right.
  • Delta, the ledger. The new key is an expression surface: it is typed EvaluatedExpressionInputSchema, a roster member, inside the column-0 declaration ObjectSchemaBase (object.zod.ts:4092, the key at :4774). The ratchet key the scan derives is therefore data/object.zod.ts:ObjectSchemaBase.uiReadonlyWhen, which is the string the queue printed and the string the new covers entry spells. No public surface or accept-set moves: the file is a dogfood test module. Right.
  • The gate that failed is not among the PR check-runs. PR CI does not run that dogfood shard, so the 61 green runs do not answer the ratchet on this head. Read statically it holds: the cover matches the discovered key, no other row covers it, the row is enforced with an enforcement cell, and the proof file exists. The dev reports 8/8 locally and an ablation that reproduces the queue message; I did not run either. The queue's Dogfood Regression Gate is the measurement.
  • main since the merge base. object.zod.ts moved on main in four hunks; the nearest is at line 4702, the PR's hunk is at 4745, and none adds an expression-typed key. The ledger and its test did not move on main.

② Semver level

  • Unchanged: @objectstack/spec minor, @object-ui/core minor, 13 patch changesets. Check Changeset is green on the head.
  • The delta needs no changeset: the ledger is a test file of the private dogfood package and ships in no tarball.
  • Clause-②: yes (widening), Metadata-protocol: added. Consistent with the diff.

③ Boundary flags

④ Design judgment

expression-conformance.ledger.ts — a second cover, not a row of its own. This holds.

  • What the rules ask. ADR-0058 D7 says "one row per expression-holding declaration". ADR-0060 and checkLedger state the checked form: each surface is covered by exactly one row, and no cover is stale. Neither forbids a row from covering several surfaces. checkLedger refuses a surface in two rows and an unclassified surface, nothing else about covers.
  • Precedent in this ledger. cel-field-rule covers three keys, the validation row covers three keys across three schemas, and the settings row covers two keys across two schemas. This is the first cover pair that spans two files; nothing in the ledger or the helper depends on the file.
  • The ledger's own split test. The comments on cel-field-deadline-settled and on this row give it: a surface gets its own row when its evaluator, its fault direction, or whether a server reads it differs. For the object key none differs:
    • Evaluator: effectiveUiReadonlyWhen returns the object predicate into the same resolveFieldRuleState slot (handLock.ts:117-123, :170-180).
    • Fault direction: the same UI_READONLY_WHEN_FAULTED = true (fieldRules.ts:367).
    • Server: no server evaluates either key.
    • Dialect, mode and binding: CEL, interpret, the row as record.
  • A row of its own would be worse. It would repeat the evaluator chain and host list of the field row, and the two cells could then drift apart on a claim that is one fact.

The changed enforcement text, sentence by sentence.

Claim Read in the tree Holds
Default of every field that declares no hand lock of its own (uiReadonly: true or a uiReadonlyWhen) declaresOwnHandLock, handLock.ts:106-108; uiReadonly: false reads as absent (Q1 = B) yes
Folded in by effectiveUiReadonlyWhen (core/evaluator/handLock.ts) handLock.ts:117-123; no host reads the object key itself yes
The same hosts Every host passes the object: edit dialog (sectionFields.ts:377, ObjectForm.tsx:1026, editFormLockedByState.ts:105), record page (DetailSection, HeaderHighlight, InlineEditSaveBar, recordPathStageChange), grid cell (objectGridCellFacts.ts:86), line-item stored rows (deriveMasterDetail.ts:323, :484), kanban, calendar, Gantt, timesheet yes
Faulting LOCKED likewise The folded predicate lands in the uiReadonlyWhen slot, whose fault answer is the constant above yes
A create is not judged Unchanged tree since fe52e09c; the seven create paths of record 7238240401 stand, and editFormLockedByState returns false with no record yes
Lint checks the object slot at object 'NAME' uiReadonlyWhen the same way validate-expressions.ts, the #37402 block: the same fieldRuleRootVerdict('uiReadonlyWhen', …), the same record-scoped check, no write gate, as the field slot yes
UI only; the server lock is readonlyWhen No packages/objectql/** path in the diff; the spec TSDoc says the engine never reads it yes

proof. It still points at ui/packages/core/src/evaluator/__tests__/handLock-36806.test.ts, and that file covers the object level. Its #37402 block (from line 96) pins:

  • the lock on a field with no own declaration, with the no-object control;
  • uiReadonlyWhen: false on a field as the opt-out;
  • uiReadonly: false following the object lock (Q1 = B);
  • the server lock not cancelling the object default;
  • fail-closed on an object predicate that cannot be evaluated, and on a row missing the operand;
  • the fold helpers.

The file exists, which is all checkLedger checks here: this ledger passes no attribution option, so no claim marker is owed. Test UI is green on the head.

N5 (nit) — the row's unchanged opening clause says the evaluator is "called directly by the edit dialog and the grid cell, and through the one verdict fieldReadOnlyByHand … everywhere else". The object grid's cell goes through fieldReadOnlyByHand (objectGridCellFacts.ts:86); the direct callers are form.tsx, the wizard gate, the line-item grid's cell (GridFieldWidget.tsx:860) and editFormLockedByState.ts:98. Every one reaches the same evaluator with the folded predicate, so the classification is unaffected. The clause is on main already. Accepted as written.

N6 (nit) — the row id stays cel-field-ui-readonly-when while it now also classifies an object key. Ids are stable handles and the summary names both keys. Accepted as written.

Everything else — unchanged since fe52e09c. object.zod.ts, object.metadata-form.ts, the liveness row and the implementing files agree with ruling 7180466652, Q1 = B and Q2 = A as record 7238240401 found. Re-read on this head: handLock.ts, the lint block, the spec key and its describe.

S1: closed

N1 (nit) — the object describe lists "the line-item grid" without saying line rows follow the child object's lock. Unchanged; carried by #38249.

N2: closed

N3: closed

N4 (nit) — the describe_object object clause says "every field" without "judged by the validations". Unchanged; accepted as written in record 7238240401.

No must-fix, no should-fix.

Implemented-by: claude/issue-37402-object-ui-readonly-when
Reviewed-by: session_017xRBcSAaBEfQpU2yJexSJ8

VERDICT: PASS

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

repo:objectstack#8 · sunhaolin · session_017xRBcSAaBEfQpU2yJexSJ8

L1: ACCEPT · head b012f9b609 · 2026-11-28T12:18Z · card #37402

Seat checks

  1. Delta since ACCEPT 7238273754 (head fe52e09c): one commit, one file, +8/−3, packages/qa/dogfood/test/expression-conformance.ledger.ts.
    • It folds data/object.zod.ts:ObjectSchemaBase.uiReadonlyWhen into the existing cel-field-ui-readonly-when row as a second covers entry, with the summary and enforcement text widened to state it.
    • This answers the merge-queue failure that dequeued the PR (run 46137914293, Dogfood Regression Gate 3/3, UNCLASSIFIED surface).
    • The ledger is a test file of the private dogfood package, so no changeset is owed.
  2. L2: delta record 7239130920 on this head (CONTRACT_REVIEW_TIER, fable) is PASS, with nothing open.
    • Folding into the field row is right by the ledger's own split test: the evaluator, fault direction (fail-closed) and server reach are the same.
    • Every sentence of the new enforcement text was checked against the tree, and proof covers the object level.
    • N5 and N6 are accepted as written.
  3. Measurement note: the gate that failed (the dogfood expression-conformance shard) does not run in PR CI, so the 61 green check-runs here do not measure it. The dev ran it locally (8/8, with an ablation reproducing the queue message), and the reviewer read it statically. The queue build is the measurement; a red there on this signature is diagnosed, not re-queued.
  4. Gates at this head: 61 success · 9 expected skip · 0 failed · 0 pending. NOT governed. K = 3 < 15.

Landing: non-governed, ≤3000 lines, Clause-②: yes (widening) (no narrowing leg). The seat re-queues it through the ordinary queue.

@objectstack-fleet
objectstack-fleet Bot added this pull request to the merge queue Nov 28, 2026
Merged via the queue into main with commit c279520 Nov 28, 2026
70 checks passed
@objectstack-fleet
objectstack-fleet Bot deleted the claude/issue-37402-object-ui-readonly-when branch November 28, 2026 13:11
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

2 participants