Repository navigation
fix(core)!: the offboarding hand-over leaves the owner of a controlled_by_parent detail where it is - #35428
Conversation
…'s owner where it is A detail's access follows its master, so its owner_id records who did the work, not who holds it. The assigned-work roster no longer lists it: the count does not report it and the transfer never moves it. The detail's own user fields and every other object's owner are unchanged. Claude-Session: https://claude.ai/code/session_01Utp6CbSphdunq2aJq7ktuY Co-authored-by: Claude <noreply@anthropic.com>
…rule Claude-Session: https://claude.ai/code/session_01Utp6CbSphdunq2aJq7ktuY Co-authored-by: Claude <noreply@anthropic.com>
…ndover-skip-detail-owner
📓 Docs Drift CheckThis PR changes 1 package(s): 17 hand-written doc(s) name something this change touched — list omitted above 15 rows. Re-derive on the tree named below: ⛔ 12 release-owned page(s) also affected — read-only, see AGENTS.md Documentation Guardrails. What this run could not see
Coarse fallback — 41 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 23ecff95c6968b314442eda7324049bf519d02cb && git checkout 23ecff95c6968b314442eda7324049bf519d02cb
# afterwards, rebuild it from the two parents, which stay fetchable
git fetch origin 609b675135f1ea427aff463c551619a83368bcad e8f05ea1e59acccdea833b09fcdac22fa3225949 && git checkout -B drift-repro 609b675135f1ea427aff463c551619a83368bcad && git merge --no-ff e8f05ea1e59acccdea833b09fcdac22fa3225949
node scripts/docs-audit/affected-docs.mjs --json 609b675135f1ea427aff463c551619a83368bcad
|
|
repo:objectstack#5 · os-bill · session_01Utp6CbSphdunq2aJq7ktuY Final head for L1:
|
|
repo:objectstack#5 · os-bill · session_01Utp6CXsZsKmgG1EcKp5bY4 维护者速读
席位核对 — ACCEPT (L1-a) · repo:objectstack#5 · head
|
|
repo:objectstack#5 · os-bill · session_01Utp6CbUb7TcZK1XUAddUmQ Contract reviewServed-tier: ① Derived judgments
② Semver level
③ Boundary flags
④ Design judgmentDoes the narrowing take a declared capability away at the consumer, or make the spec's own refusal real? Neither exactly. The spec refuses nothing here, and the hand-over of a detail's owner was a delivered behaviour, not a declared-and-undelivered one. It is withdrawn on a maintainer ruling: the derived default for owner transfer is off on a Attempts to break it, and what held:
What did not hold: No must-fix. S1 (should-fix) — the narrowing's stated premise is false for one row class ADR-0055 declares, and that class is stranded with no notice on any shipped face.
Nits, none of which changes a verdict above:
Implemented-by: VERDICT: PASS |
…strands, and its remedy A detail row whose master reference is empty, on an optional master, is read and written by its owner and View All / Modify All, not through a master. The docblock, the admin guide and the changeset now say so, with what happens to it after a ban and the by-hand remedy. Clause-② reads no (narrowing): the diff widens nothing. No behaviour change. Claude-Session: https://claude.ai/code/session_01Utp6CbSphdunq2aJq7ktuY Co-authored-by: Claude <noreply@anthropic.com>
|
repo:objectstack#5 · os-bill · session_01Utp6CbSphdunq2aJq7ktuY Final head for delta (L1 + L2):
|
|
repo:objectstack#5 · os-bill · session_01Utp6CXsZsKmgG1EcKp5bY4 维护者速读
席位核对 — ACCEPT (L1-a, delta) · repo:objectstack#5 · head
|
|
repo:objectstack#5 · os-bill · session_01Utp6CbUb7TcZK1XUAddUmQ Contract reviewServed-tier: Delta review from ① Derived judgments
② Semver level
③ Boundary flags
④ Design judgment
No must-fix, no should-fix. Implemented-by: VERDICT: PASS |
|
repo:objectstack#5 · os-bill · session_01Utp6CbSphdunq2aJq7ktuY Landing · area ux-1 · 2026-11-19T11:25Z
Head |
Requested by Bill · project thread
Fixes #35344
Clause-②: no (narrowing) — the hand-over stops counting and moving
owner_idoncontrolled_by_parentdetailsMetadata-protocol: none
Skills-docs: none — no published skill teaches the assigned-work hand-over (
git grep assigned-work -- skillsanswers 0 hits on this head); the admin guide is updated here维护者速读
What changes
userAssignedWorkFields(@objectstack/core) leaves the owner column (owner_id) of an object whosesharingModeliscontrolled_by_parentout of the roster. Both the count (GET .../assigned-work) and the transfer (POST .../assigned-work/transfer) read that roster, so the detail's owner is neither counted nor moved — including a transfer whoseobjectsnames the detail alone.approver, anassignee), andowner_idon every object whosesharingModelisprivate,public_read,public_read_writeor unset.content/docs/permissions/administrator-guide.mdx) says so; patch changeset on@objectstack/corewith the BREAKING banner and an ADR-0087 disposition.Shape shipped: left out, not counted-not-moved. The preferred shape counts the detail's owner rows as
transferable: false. The REST answer already carries that field, so no new public field was needed, but the ban dialog words everytransferable: falserow as "Lists several people, so it cannot be handed over here." That sentence is false for a single-valued owner column. A truthful sentence needs a new translated string in the seven UI locale catalogues, which are outside this claim's file surface. So the rows are left out and the panel is untouched. Counting them belongs with the object-level switch follow-up, where the panel learns a reason.The predicate.
@objectstack/specexports no object-level "is this a detail" predicate. The named one,masterGovernsRowWrites(@objectstack/plugin-security), lives in a package that depends on@objectstack/core, so core cannot import it. The reading is therefore spelled once in this module (accessFollowsMaster). It reads the flat and nested spots the same way the access gates do, so the hand-over treats as a detail exactly the objects whose rows the gates answer through a master. The owner column is matched bySystemFieldName.OWNER_ID.Tests
core: the module's file, the whole package, typecheck (head 3ae0a43)
pnpm --filter @objectstack/core exec vitest run --maxWorkers=2 src/security/user-assigned-work.test.ts→Test Files 1 passed (1) · Tests 19 passed (19)(13 before + 6 new).pnpm --filter @objectstack/core test→Test Files 153 passed (153) · Tests 3632 passed (3632).pnpm --filter @objectstack/core typecheck→ exit 0.pnpm --filter @objectstack/rest exec vitest run --maxWorkers=2 src/user-work-routes.test.ts(serves this module, reads core's rebuiltdist) →Tests 7 passed (7).New pins (
a controlled_by_parent detail keeps its owner in the hand-over):owner_idout and keeps the detail'sapproverand the master'sowner_id.security.sharingModelspot is read as well.private/public_read/public_read_write/ unset keepsowner_id.Ablation (one-shot, fix committed first)
node scripts/ablation-replace.mjs --file packages/core/src/security/user-assigned-work.ts --anchor "if (detail && field === SystemFieldName.OWNER_ID) continue;" --delete -- vitest run src/security/user-assigned-work.test.ts: anchor 1 → 0, blob789aa438f8a9→c90797db9690. Five of the new pins went red. The twin (pin 3) stayed green, as it should. Restored withgit checkout HEAD -- …: the blob is back to789aa438f8a9…, equal to the HEAD blob, andgit diff HEADis empty. The test imports the module by relative path, so there is nodistleg.Acceptance notes
sharingModel(flat or nested) the same way the platform's other access readers do (plugin-security, plugin-sharing, objectql each spell it). Lifting one object-level predicate into@objectstack/spec/datawould let all of them share it. That is an observation, not a filing.master_detaildeclaredrequired: false) row that names no master is read by its owner and by View All. After this change a banned owner's such rows keep that owner, so only View All reads them. This follows the maintainer's derived default (transfer off on a detail). An author who wants those owners moved needs the object-level switch.transferable: true, and the detail's owner rows are no longer in the answer.Verification
Local gates (head 3ae0a43)
node scripts/pm/dispatch-gates.mjs --commandsderived 97 families, all run locally. The--ranreconciliation:✓ 97 derived famil(ies) accounted for. 95 exited 0. Two exited 3 (PREREQUISITE NOT MET, nothing measured), both because packages this diff does not touch have nodist(client-react, the adapters and apps). They are NOT MEASURED locally and left to CI:pnpm --filter @objectstack/spec run check:skill-examplespnpm check:dual-build-cjs-loadsoverlap-checkanswersVERDICT cleanagainstorigin/main. Every repo-wide family,test:repoand the full farm are CI's. The full dogfood battery owed by the(narrowing)arm is reported in the dev report.Fix round (contract review 7006025069)
Prose only, head
26ff98c888; no behaviour change and no new conjunct.S1, the optional-master row class. The module docblock, the administrator guide and the changeset no longer say a detail's access always follows its master. They now name the row class: a detail row whose master reference is empty, on an optional master (
required: false, ADR-0055 as amended). For that row they say:The docblock sentence now reads "On a detail the owner records who did the work, not who holds it". It adds that a row naming its master is reached through that master.
N1.
Clause-②: no (narrowing)in this body and in the changeset (the diff widens nothing). The!, the BREAKING banner and the ADR-0087 marker are unchanged.N2, N3 and N4 go to the follow-up card.
Checks on 26ff98c
pnpm --filter @objectstack/core typecheckexit 0.user-assigned-work.test.ts: Tests 19 passed (19).check:docs, doc-authoring and the rest of the docs set, nul-bytes, issue citations), all exit 0. The derived list is identical to the one on 3ae0a43.overlap-check: VERDICT clean. Not merged withmain(no conflict).🤖 Generated with Claude Code
https://claude.ai/code/session_01Utp6CbSphdunq2aJq7ktuY