You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
security: an unrestricted reader of a controlled_by_parent detail with a required FK drops the vacuous parent-chain leaf (epic #33631 R4) #33696
Filing gate: ④ child of epic #33631 (SQL performance; maintainer's direct word on the epic). Item R4 of the M0 ranked list (#33633): #33631 (comment), corrected by #33631 (comment) (review#2 PASS 6890102899).
「只在父字段必填时去掉」: for an unrestricted (admin) reader of a controlled_by_parent detail, drop the vacuous parent-chain leaf only when the controlling FK is required. When the FK is nullable, keep the chain, so orphan details (master gone or unset) stay hidden exactly as today. No change to which rows any reader sees.
Today
engine-readable-ids-permission-formula.ts ~207 composes ReadableIds.compose(leaf, undefined) with the leaf from security-plugin-cbp-read-filter.ts ~156, so an admin read carries fk IN (SELECT id FROM master WHERE fk2 IN (SELECT id FROM master2)); the analytics path ANDs the same chain twice.
Measured (1M rows)
Dropping the leaf: page SQLite 397 → 281 ms, PG 97 → 56 ms; total SQLite 217 → 136 ms, PG 78 → 54 ms (−29% to −42%, twice per list). It also unlocks the SQLite half of the created_at index card (1.7 s → 0.09 ms).
Rules
Parity test: the same admin read with the chain and without it returns the same rows when the FK is required; a nullable-FK object keeps the chain (orphan row stays hidden, pinned).
Restricted readers are untouched.
Business reason
Every admin list, count and aggregate over a detail object pays for a security subquery that cannot filter anything when the parent is mandatory.
Reader
domain:server#5 area A2 (plugin-security cbp leaf) with A4 (objectql ReadableIds compose), next account; size S–M.
Dedupe
Covered by the M0 inventory; no open card on ReadableIds.compose vacuous leaf.
Claim: server area S1 (A1+A2) under #33751 §2 area-lease mode, area A2, seat domain:server#5 · p2 (epic #33631 R4) · executed by an os-dev subagent of the area S1 thread · posted at 2026-11-15T09:21Z
Session: session_01QsR2jVPGBoi3MCGoKbW1Hv
Account: zhuangjianguo
Branch: claude/area-A2-33696
Worktree: objectstack-area-A2-33696
Domain: domain:server
Seat: domain:server#5
File surface: packages/plugins/plugin-security/src/security-plugin-cbp-read-filter.ts (+ its tests), packages/objectql/src/engine-readable-ids-permission-formula.ts and the engine-readable-ids-* tests, the analytics site that ANDs the same chain if it reads the same leaf, a changeset (stop on breach; explain in the report)
Container & model: M, mode:subagent, model: default (no path-derived mandate; dispatch-gates --tier at bd96ec9c), effort: high
Clause-②: no
Metadata-protocol: none
Responsibility: n/a — not a defect card
Thread-read: none
Premise: holds
Serial constraints cleared: #33683 (this area, plugin-sharing only, disjoint); no other in-flight claim of this seat names these files; the dev re-greps open PRs on both files before pr_create
{
"issue": 33696,
"status": "needs_decision",
"branch": "claude/area-A2-33696",
"pr": null,
"session": "session_01QsR2jVPGBoi3MCGoKbW1Hv",
"premise_still_valid": false,
"summary": "Stopped before writing code, as the dispatch said to do when a dangling FK can exist. On a real engine (SqlDriver better-sqlite3, the real SecurityPlugin and SharingService, origin/main d7e1a5aa), a detail row whose controlling master_detail is required: true can still carry a missing master or a NULL FK. Today the parent chain hides that row from an unrestricted admin. Dropping the leaf would show it. So the ruling's 'no change to which rows any reader sees' does not hold for those rows. Three ways such a row gets stored: (1) a system-context insert that names a master that does not exist; (2) a system-context update that points the FK at a missing row; (3) a field promoted from required: false to required: true while rows with a NULL FK already exist. Source for (1) and (2): engine-referential-integrity.ts already says 'an isSystem caller can still write a dangling reference' (seed replay, package install, boot provisioning). The branch was pushed empty at d7e1a5aa. Nothing was committed and no PR was opened.",
"tests": "Measurement only. A temporary vitest file was run once and deleted, never committed (copy kept in the dev scratchpad). Command: pnpm --filter @objectstack/plugin-security exec vitest run --maxWorkers=2 src/zz-measure-33696.test.ts, result 1/1 passed, exit 0. Fixture: m_account (private) -> m_opp (cbp, required master) -> m_line (cbp, required master). Admin = viewAllRecords+modifyAllRecords on all three. Readings: M1 system insert m_line{opp:'opp_ghost'} = stored; M2 system insert opp:null = refused VALIDATION_FAILED; M3 admin insert opp:'opp_ghost2' = refused PERMISSION_DENIED; M4 system delete of a master = its detail cascaded away; M5 system update opp:null = refused VALIDATION_FAILED; M6 system update opp:'opp_gone' = stored; M7 m_promo rows stored as optional then re-registered required: true = p_null:null stored. Admin reads: m_line system-stored [l_dangling:opp_ghost, l_ok:opp1] vs admin find [l_ok], admin count 1; m_promo stored [p_null:null, p_ok:opp1] vs admin [p_ok]. The where the driver received for the admin find: opp $in composed(m_opp, scope: account $in composed(m_account, scope: undefined)). That confirms PM hypothesis 1: the leaf is a pure chain for this reader.",
"gates": "None run: no diff. dispatch-gates --commands has nothing to derive from an empty change set.",
"dogfood_battery": "n/a — no PR, no `!` title, no (narrowing) arm",
"line_budget": "n/a — no diff",
"files_changed": [],
"deviations": [
"One closure build was run under os-verify-lock (plugin-security dependencies, VERDICT command-exit 0, held 167 s), for the measurement only.",
"The empty branch claude/area-A2-33696 stays on origin at d7e1a5aa (the os-dev rule-1 landing marker). Removing it is the seat's call."
],
"mcp_calls": "0",
"api_writes": "1 — POST issues/33696/comments (this report, via post-stamped)",
"open_questions": [
{
"question": "With a required master FK, rows with a missing master or a NULL FK can be stored (system writes, required-promotion). Should an unrestricted reader see them once the vacuous leaf is dropped?",
"options": [
"A — Amend the ruling: for a required FK, an unrestricted reader (every hop answers canReadObject true and getReadFilter undefined) gets no chain and sees every detail row inside its own tenant wall, orphan rows included. Effort S-M, as on the card; the card's numbers (card's measurement, not re-run): admin page SQLite 397 -> 281 ms, PG 97 -> 56 ms, and the SQLite half of R3. Business need: measured, every admin list, count and aggregate on a detail. Long-term: the reader holds every right on every hop, so no privilege boundary moves. Rows that today nobody can see or clean up become visible to the people who can fix them. Cost: the orphans are surfaced, not prevented. AI-error axis: neutral to slightly positive; bad seed data written by an AI becomes visible instead of silently invisible. Scope: no new surface.",
"B — Close the orphan sources first, then ship R4 exactly as ruled. (1) System writes keep the master_detail reference check, as flow writes already do. (2) Promoting a master to required is refused while rows with a NULL FK exist. Effort M-L, across the objectql write path and the publish/schema-sync door. Risk: seed replay and package install legitimately write in an order that resolves only at the end of the batch (engine-referential-integrity.ts names this). Long-term: contract-first, and parity holds by construction (raw SQL aside). AI-error axis: strongest; a wrong reference is refused loudly at write. Scope: expands the card well past S-M and outside its claimed file surface.",
"C — Keep today's chain (park R4). Effort 0, no row change, no gain. The SQLite half of R3 stays blocked (corrected epic comment 6889939163). Long-term: leaves a measured 29-42% admin-read tax in place. AI-error: neutral. Scope: smallest."
],
"recommendation": "A. Long-term reading first: the reader is unrestricted on every hop, so dropping the chain moves no security boundary. The only rows it changes are ones that break the master_detail contract, and today they are invisible to everyone. The gain is measured on every admin read. B is the right long-term follow-up for preventing orphans; it can be its own card and should not block A. This is a security read-scope change, so it stays the maintainer's decision either way. Implementation note for A: 'unrestricted' has to be the engine's per-hop answer (scope undefined after canReadObject true). It must not be the cbp filter's hasSuperuserReadBypass, which is View All on the DETAIL only. Reusing that predicate would widen access for a holder of View All on the detail whose master read is restricted (the #30905 ruling A docblock: View All on the detail 'does not open the master arm'). This falsifies PM hypothesis 4."
}
],
"security_findings": "none",
"out_of_scope_findings": [
"carrier: none · noted, not filed — the analytics path reaches the same leaf through getReadFilter(detail) (service-analytics plugin.ts / read-scope-sql.ts), so a leaf-level fix covers it; the 'ANDs it twice' cost was not measured here",
"carrier: none · noted, not filed — the stored-orphan sources (system-write dangling reference, required promotion over NULL rows) are a documented residual in engine-referential-integrity.ts, input to option B, not a new defect card"
]
}
Governing text: the R4 ruling on epic #33631 (ranked list 6889544281, correction 6889939163): drop the parent chain only when the FK is required, "No change to which rows any reader sees". Measurement: os-dev report 6892424473 (real engine, SqlDriver + SecurityPlugin + SharingService, origin/main d7e1a5a).
前提不成立: master FK 设成必填后,仍有三种方式存进「孤儿」明细行(系统身份插入一个不存在的主记录、系统身份把 FK 改指向不存在的行、字段改成必填时已有 FK 为空的行;前两种 engine-referential-integrity.ts 已记为已知缺口)。今天父链把这些行对管理员也藏起来;去掉父链后管理员会看到它们,所以「任何读者看到的行不变」不成立。
os-decision-facets
① 项目长远合理性: A 让「不受限读者」真正不受限,B 是防孤儿的正确后续,可另立卡不必挡 A;C 留下实测的管理员读税。
② 实际业务拉动: 每次管理员列表读都受益(卡上实测 29–42%)。
③ 防 AI 犯错: A 不放宽任何受限读者;孤儿行变可见反而让数据错误暴露出来。
④ 创业阶段不扩散: A 面最小且有收益;B 扩到写路径与发布门。
推荐 A,B 另立后续卡。这是安全读范围的语义,属维护者人工裁决。
State: pm:dispatched → needs-user-decision, assignee cleared (claim 6892260838 released by this stroke; empty branch claude/area-A2-33696 stays as a marker). Area S1 re-claims after the ruling.
Claim amendment · 2026-11-15T10:44Z · to claim 6893117018 · file surface widened by the area (routing, no ruling change)
Added: packages/objectql/src/engine.ts, at most 4 lines, all inside the host literal of the private method composeReadableIdsChain: a _registry getter shaped like the other host literals. The reason: only the engine sees the per-hop scope answer the ruling (6893097935) requires, and it must also read whether the leaf's master_detail field is required. Dropping the leaf at the source instead would make the synchronous cbp read filter async, which reaches further. No behaviour change in engine.ts, and no public surface move. Clause-② no and Metadata-protocol none are unchanged.
Re-ruled: option 「只对管理员去掉」 (drop the chain for administrators only) · the maintainer (Steedos) on the seat thread decision card (2026-11-15T11:31Z), after an independent Fable re-review. This replaces record 6893097935.
Why it was re-asked: 6893097935 (decision request 6892447012) did not show the maintainer two recorded decisions it reversed. They are #24932 ruling B item 4 (comment 6303721609, 10-20, ⛔ "no interim removal of the predicate for an unrestricted master scope: it would expose rows with a null or dangling foreign key (measured)") and ADR-0139 D6 (docs/adr/0139-engine-internal-semi-join-leaf-readable-parent-ids.md:295-297). As written it would also have shown members unowned rows, against #30905 ruling A (11-06, ADR-0055: rows with no master are visible only to their owner and to view-all holders on the detail). Area S1 found this while building.
Pins: the three controlled-by-parent-leaf-switch tests are rewritten for the view-all + unrestricted reader. Reverse pins stay: a reader with a restricted master hop, and a reader with view-all on the detail only, still never see null or dangling rows.
Release note: totals, counts and aggregates for that reader may include orphan rows. A follow-up card to close the orphan sources (option B of the original request) is owed as the PR's one loose-ends card.
Multi-tenant deployments: a tenant admin's master scope is the tenant wall, so it is not unrestricted. No speed-up there, by design; widening that is a separate decision.
State: stays pm:dispatched with area S1 (branch claude/area-A2-33696 pushed, no PR). The route is now narrower; S1 reworks it to this ruling.
{
"issue": 33696,
"status": "done",
"branch": "claude/area-A2-33696",
"pr": "https://github.com/objectstack-ai/objectstack/pull/33897",
"session": "session_01QsR2jVPGBoi3MCGoKbW1Hv",
"premise_still_valid": true,
"summary": "Built ruling record 6893666857, which replaces 6893097935. composeReadableIdsChain step 5 drops the leaf over a controlled_by_parent object's REQUIRED master in an AND position. It does so only when that master answers unrestricted at every hop (the engine's per-hop scope; a nested scope left empty answers undefined) AND the caller holds View All on the detail. View All is read from ISecurityService.getEffectiveObjectPermissions, once per read. A delegated caller, a service without that member, or a call that throws keeps the chain. Every other reader keeps the chain unchanged: a restricted hop, View All on the detail only, a plain member. Optional masters and $or/$not positions compose as before. The View All reader now sees null and dangling-FK rows inside its own tenant wall, and the changeset carries the ruling's release note. PR is draft and must not land before #33820 (ADR-0139 status-line amendment), as its body says near the top.",
"tests": "Head 2c6025c0 (implementation 521ba7e7 plus origin/main merged), runs under os-verify-lock with exits captured before any pipe. objectql: pnpm test exit 0, 596/596 files, 13141 tests; typecheck exit 0. plugin-security: pnpm test exit 0, 268/268 files, 6690 passed and 45 skipped; typecheck exit 0. New real-stack pins in security-plugin-cbp-read-filter.test.ts, 8 tests: (a) View All plus unrestricted reader has no subquery, all rows, count 7, findOne of a dangling row, plus parity and the analytics door; (b) restricted hop keeps the chain; (c) View All on the detail only keeps the chain; (d) member keeps the chain over a restricted and over a public master; optional master keeps its leaf; (e) isolated tenancy wall. Unit pins in engine-readable-ids-nested-composition.test.ts: 17 tests. Leaf-switch: 23 tests, the three tests gain the View All everywhere reader leg. Ablations via ablation-replace on the committed head, each restore proven blob==HEAD 8ec17d58c0bb with git diff HEAD empty. Per-hop check removed: (b) and (c) red, plus 2 unit pins. readerViewsAllOf forced true: (d) red, plus 1 unit pin. Step 5 disabled: (a), parity, analytics and the (d) admin control red, plus 2 unit pins. Direct runtime dependents after building PKG^... (exit 0): example-embed-objectql 1/1, plugin-audit 94/94, plugin-email 53/53, plugin-pinyin-search 4/4, plugin-sharing 74/74, plugin-webhooks 25/25, runtime 603/603, service-automation 282/282, cloud-connection 82/82, example-todo 9/9, plugin-dev 10/10, verify 52/52. scenarios was 31/33 on the first pass: 2 test/build files refused because its own dist was not built (a prerequisite, not a result); after building scenarios both pass, 2/2 files, 14 tests. cli vitest --project unit exit 0, 421/421 files, 6000 tests.",
"gates": "dispatch-gates --commands --repo objectstack-ai/objectstack derived 74 at 2c6025c0. 71 run locally: 70 exit 0 on the first pass; check:query-options-erasure exit 124 (runner timeout 300 s on the shared box), then exit 0 on a re-run with no timeout. --ran reconciliation: 74 derived, 71 run, 0 NOT-MEASURED, 3 UNRUN (check:i18n, check:dual-build-cjs-loads, check:type-check-debt are whole-repo runs left to CI). check-nul-bytes exit 0. pnpm lint is left to CI. PR check-runs: in_progress at report time, not waited on. git merge-tree against origin/main (16 commits newer) is clean.",
"dogfood_battery": "n/a: no ! in the PR title and no (narrowing) arm",
"line_budget": "7 files, +730 / -9 against origin/main. engine.ts +2 (approved widening, max 4). controlled-by-parent-leaf-switch.test.ts +22/-3 (approved widening, about 15 asked; 25 lines touched in all). No skills/** or docs/adr/** touched.",
"files_changed": [
".changeset/33696-drop-unrestricted-cbp-chain.md (new, objectql patch, Clause-2 no, Metadata-protocol none, release note)",
"packages/objectql/src/engine-readable-ids-permission-formula.ts (step 5, readerViewsAllOf, pruning helpers)",
"packages/objectql/src/engine.ts (APPROVED WIDENING: 2 lines, _registry getter in the composeReadableIdsChain host literal)",
"packages/objectql/src/engine-readable-ids-nested-composition.test.ts (unit pins)",
"packages/plugins/plugin-security/src/security-plugin-cbp-read-filter.ts (docblock only)",
"packages/plugins/plugin-security/src/security-plugin-cbp-read-filter.test.ts (new, real-stack pins a to e)",
"packages/plugins/plugin-security/src/controlled-by-parent-leaf-switch.test.ts (APPROVED WIDENING: View All everywhere reader legs; the existing pins are unchanged)"
],
"deviations": [
"pnpm lint was not run locally. common.txt lists it before push, but os-dev.md says a repo-wide scan is CI-owned and that the os-dev file wins on a conflict, so it is left to CI.",
"3 derived gate families are left to CI as whole-repo runs: check:i18n, check:dual-build-cjs-loads, check:type-check-debt.",
"Packages that depend on objectql only as a devDependency, and dogfood, are left to CI (Test Core). Only the direct runtime and peer dependents were run.",
"The PR body starts with the HTML attribution comment that common.txt mandates. os-dev.md otherwise bans HTML comments in bodies.",
"The merge commit 2c6025c0 is git's default merge message with no trailers."
],
"mcp_calls": "0",
"api_writes": "2 relay writes (with this comment): pr_create POST /repos/objectstack-ai/objectstack/pulls via fleet-write run 43720623596 (PR #33897), and this os-dev-report comment via post-stamped. Earlier rounds of this claim: 1 comment (6892424473). Plus git push (not REST).",
"open_questions": [],
"security_findings": "none",
"out_of_scope_findings": [
"carrier: seat · loose-ends card owed by ruling 6893666857: stop orphan rows at their sources (option B). Measured sources: a system-context insert or update naming a missing master is stored (residual in engine-referential-integrity.ts), and promoting an optional master to required leaves NULL-FK rows. Dedupe words: orphan detail rows, dangling master_detail, system write referential integrity, required promotion null",
"carrier: #33820 · ADR-0139 status-line amendment (lines 295-297, D6) is the landing precondition; docs/adr not touched",
"carrier: seat · security-plugin.ts docblock on computeControlledByParentFilter still says the composed leaf always compiles to a subquery; outside the claim surface",
"carrier: seat · open PR #33652 (other seat) edits composeReadableIdsChain in the same file (import line, final composeReadableIdsLeaves call): a textual conflict for whichever lands second. Its planned relation leaves are never asked into chain.answers, so step 5 leaves them alone and the two do not conflict in meaning",
"noted, not filed · walled tenancy: the tenant admin's master scope carries the Layer-0 equality, so nothing is dropped there, by design (pin e)"
]
}
After review FAIL 6895328067 on PR #33897 (head 2c6025c), route (a): the write doors stay byte-identical. File surface adds: write-door pins (predicate delete, predicate update, by-id 404 over an orphan, each red on head 2c6025c) in plugin-security *.test.ts, and a prose-only paragraph in the computeControlledByParentFilter docblock in security-plugin.ts (review should-fix 2). Preferred build: the drop stays confined to the read door that asks for it, so no write-door source file changes. If a write-door source file (security-plugin-cbp-write-gate.ts, security-plugin-authz-middleware.ts, security-plugin-addressed-writes.ts) must change, the dev stops and reports first: #33524 in this area edits two of them.
Clause-②: no
Metadata-protocol: none
Route (a) build: packages/objectql/src/engine-middleware-and-context.ts joins the surface, about 4 lines in executeWithMiddleware only: a write-epoch operation runs its middleware chain inside an engine-owned store, and the chain drop answers "no drop" while that store is set, so every read made on behalf of a write keeps the chain as on main. No plugin-security write-door source file changes. Open PR #33887 (S2) edits a different function of the same file (claimReferentialCascadeDelete); whichever lands second merges main.
Clause-②: no
Metadata-protocol: none
{
"issue": 33696,
"status": "done",
"branch": "claude/area-A2-33696",
"pr": "https://github.com/objectstack-ai/objectstack/pull/33897",
"session": "session_01QsR2jVPGBoi3MCGoKbW1Hv",
"premise_still_valid": true,
"delta_of": "review FAIL 6895328067 on head 2c6025c0; route (a), claim amendments 6895345175 and 6895620230",
"head": "df3fb3b9ad5558a2e9ebf205e12ac0fbd4499fe1",
"summary": "Write doors are byte-identical to main again. A write's middleware chain (insert, update, delete, purge, restore) now runs inside READABLE_IDS_WRITE_IN_FLIGHT, an engine AsyncLocalStorage set in executeWithMiddleware (+4/-1, approved widening) and exported from engine-readable-ids-permission-formula.ts. readerViewsAllOf answers no drop inside it, so every read made on a write's behalf keeps the chain: the predicate-write narrowing, the 2.8 predicate leg, the step-2.7 by-id read, and hook reads. No plugin-security write-door source file changed. Should-fix 2: a prose-only paragraph in the computeControlledByParentFilter docblock (security-plugin.ts). The changeset gains a writes-unchanged note.",
"findings": [
"Finding 1, predicate delete with an empty-required-master orphan in the set: red on 2c6025c0 (refused MISSING_REQUIRED_FIELD / 422); green on df3fb3b9 (lands on the other row, the orphan stays); passes on main's objectql source.",
"Finding 2, predicate update with an empty-master orphan and a dangling-master orphan in the set: red on 2c6025c0 (refused MISSING_REQUIRED_FIELD / 422); green on df3fb3b9 (lands on the other row, both orphans unchanged); passes on main's objectql source.",
"Finding 3, by-id update of a dangling orphan and by-id delete of an empty-master orphan: red on 2c6025c0 (refused PERMISSION_DENIED / 403, not RECORD_NOT_FOUND / 404); green on df3fb3b9 (404 for both); passes on main's objectql source.",
"Extra pin asked in amendment 6895620230, a hook's read inside a write: red on 2c6025c0 (the hook read saw the 4 orphans); green on df3fb3b9. On main its write leg passes; its plain-read control leg is red there, as expected, because main drops nothing."
],
"tests": "The red legs were measured with the three objectql source files set back to 2c6025c0, then restored with git diff HEAD empty. Ablations via ablation-replace, each restore checked blob==HEAD: deleting the store guard in readerViewsAllOf turns 4/4 red; running the write chain outside the scope in executeWithMiddleware turns 4/4 red. At df3fb3b9: plugin-security pnpm test exit 0, 269/269 files, 6705 passed and 45 skipped, typecheck exit 0; objectql pnpm test exit 0, 598/598 files, 13238 tests, typecheck exit 0. At 3089656f (the same code, one main merge earlier): 13 direct runtime dependents all exit 0 after building PKG^... (runtime 605/605, plugin-sharing 74/74, scenarios 34/34, service-automation 282/282 and the rest), and cli --project unit 422/422 files, 6002 tests.",
"gates": "At df3fb3b9, dispatch-gates derived 77; 74 run locally, all exit 0. --ran: 77 derived, 74 run, 0 NOT-MEASURED, 3 UNRUN (check:i18n, check:dual-build-cjs-loads, check:type-check-debt, whole-repo runs left to CI). check-nul-bytes exit 0. pnpm lint left to CI.",
"merge_tree": "git merge-tree --write-tree --name-only from df3fb3b9. origin/main: clean (main is 18 commits ahead; none of them touches this PR's files). #33887 at eab93bab: clean. #33884 merged as c59198f05 and is included in this head. #33652 at 1b832c58: CONFLICT in engine-readable-ids-permission-formula.ts, 2 hunks (the import block; the step-5 / final composeReadableIdsLeaves lines). The overlap was known; whichever lands second rebases.",
"dogfood_battery": "n/a: no ! in the PR title and no (narrowing) arm",
"line_budget": "Delta since 2c6025c0: engine-middleware-and-context.ts +4/-1 (approved); engine-readable-ids-permission-formula.ts +17; security-plugin.ts +12 (docblock prose only); security-plugin-cbp-read-filter.test.ts +82; changeset +4.",
"files_changed": [
"packages/objectql/src/engine-middleware-and-context.ts (APPROVED WIDENING 6895620230, executeWithMiddleware only)",
"packages/objectql/src/engine-readable-ids-permission-formula.ts",
"packages/plugins/plugin-security/src/security-plugin.ts (docblock only)",
"packages/plugins/plugin-security/src/security-plugin-cbp-read-filter.test.ts",
".changeset/33696-drop-unrestricted-cbp-chain.md"
],
"deviations": [
"The write pins seed two admin-created rows through the driver. The rig's member_default adds the own-records write predicate (created_by = caller), and on main an admin predicate write over the seeded rows lands on zero rows.",
"The new pins are in security-plugin-cbp-read-filter.test.ts, a file this PR creates, not in a new file named for the card.",
"Dependents were not re-run after the second main merge (df3fb3b9). That merge (#33884 among others) touches none of this PR's files. plugin-security and objectql were re-run there.",
"pnpm lint is left to CI (os-dev.md: repo-wide scans are CI-owned)."
],
"mcp_calls": "0",
"api_writes": "2 relay writes this round: issue_patch of the PR #33897 body (run 43734784781, read-back identical), and this comment via post-stamped. Plus git push (not REST).",
"open_questions": [],
"security_findings": "none",
"out_of_scope_findings": [
"carrier: seat · the follow-up card to close the orphan sources (option B) is still owed",
"carrier: #33820 · the ADR-0139 status-line amendment is still the landing precondition"
]
}
Unblocked: the ADR status-line card #33820 landed as PR #33992 (merged 2026-11-15T16:34Z). ADR-0139 and ADR-0055 now record the 6893666857 ruling, so the PR for this card no longer waits on it.
Carrier for this card (F3 of the at-tier review 6899080787 on PR #34075, card #33432): ADR-0055's 2026-11-14 "What a refusal answers" paragraph has two sentences that rest on "a detail row's own read derives from its master (§2)": the by-id 404 sentence (on main now) and the predicate (multi: true) sentence PR #34075 adds. Both are true on main today. When this card's code lands and its reader class reads a required master's empty or dangling rows, both sentences need this card's 2026-11-15 note, in the PR that lands it. Nothing to do before then.
Activity
objectstack-fleet commentedon Nov 15, 2026
domain:server#5 · zhuangjianguo · session_01QsR2jVPGBoi3MCGoKbW1Hv
Claim: server area S1 (A1+A2) under #33751 §2 area-lease mode, area A2, seat
domain:server#5· p2 (epic #33631 R4) · executed by anos-devsubagent of the area S1 thread · posted at 2026-11-15T09:21ZSession:
session_01QsR2jVPGBoi3MCGoKbW1HvAccount:
zhuangjianguoBranch:
claude/area-A2-33696Worktree:
objectstack-area-A2-33696Domain:
domain:serverSeat:
domain:server#5File surface:
packages/plugins/plugin-security/src/security-plugin-cbp-read-filter.ts(+ its tests),packages/objectql/src/engine-readable-ids-permission-formula.tsand theengine-readable-ids-*tests, the analytics site that ANDs the same chain if it reads the same leaf, a changeset (stop on breach; explain in the report)Container & model:
M,mode:subagent,model: default (no path-derived mandate; dispatch-gates --tier at bd96ec9c),effort: highClause-②: no
Metadata-protocol: none
Responsibility: n/a — not a defect card
Thread-read: none
Premise: holds
Serial constraints cleared: #33683 (this area, plugin-sharing only, disjoint); no other in-flight claim of this seat names these files; the dev re-greps open PRs on both files before pr_create
objectstack-fleet commentedon Nov 15, 2026
domain:server#5 · zhuangjianguo · session_01QsR2jVPGBoi3MCGoKbW1Hv
os-dev-report
{ "issue": 33696, "status": "needs_decision", "branch": "claude/area-A2-33696", "pr": null, "session": "session_01QsR2jVPGBoi3MCGoKbW1Hv", "premise_still_valid": false, "summary": "Stopped before writing code, as the dispatch said to do when a dangling FK can exist. On a real engine (SqlDriver better-sqlite3, the real SecurityPlugin and SharingService, origin/main d7e1a5aa), a detail row whose controlling master_detail is required: true can still carry a missing master or a NULL FK. Today the parent chain hides that row from an unrestricted admin. Dropping the leaf would show it. So the ruling's 'no change to which rows any reader sees' does not hold for those rows. Three ways such a row gets stored: (1) a system-context insert that names a master that does not exist; (2) a system-context update that points the FK at a missing row; (3) a field promoted from required: false to required: true while rows with a NULL FK already exist. Source for (1) and (2): engine-referential-integrity.ts already says 'an isSystem caller can still write a dangling reference' (seed replay, package install, boot provisioning). The branch was pushed empty at d7e1a5aa. Nothing was committed and no PR was opened.", "tests": "Measurement only. A temporary vitest file was run once and deleted, never committed (copy kept in the dev scratchpad). Command: pnpm --filter @objectstack/plugin-security exec vitest run --maxWorkers=2 src/zz-measure-33696.test.ts, result 1/1 passed, exit 0. Fixture: m_account (private) -> m_opp (cbp, required master) -> m_line (cbp, required master). Admin = viewAllRecords+modifyAllRecords on all three. Readings: M1 system insert m_line{opp:'opp_ghost'} = stored; M2 system insert opp:null = refused VALIDATION_FAILED; M3 admin insert opp:'opp_ghost2' = refused PERMISSION_DENIED; M4 system delete of a master = its detail cascaded away; M5 system update opp:null = refused VALIDATION_FAILED; M6 system update opp:'opp_gone' = stored; M7 m_promo rows stored as optional then re-registered required: true = p_null:null stored. Admin reads: m_line system-stored [l_dangling:opp_ghost, l_ok:opp1] vs admin find [l_ok], admin count 1; m_promo stored [p_null:null, p_ok:opp1] vs admin [p_ok]. The where the driver received for the admin find: opp $in composed(m_opp, scope: account $in composed(m_account, scope: undefined)). That confirms PM hypothesis 1: the leaf is a pure chain for this reader.", "gates": "None run: no diff. dispatch-gates --commands has nothing to derive from an empty change set.", "dogfood_battery": "n/a — no PR, no `!` title, no (narrowing) arm", "line_budget": "n/a — no diff", "files_changed": [], "deviations": [ "One closure build was run under os-verify-lock (plugin-security dependencies, VERDICT command-exit 0, held 167 s), for the measurement only.", "The empty branch claude/area-A2-33696 stays on origin at d7e1a5aa (the os-dev rule-1 landing marker). Removing it is the seat's call." ], "mcp_calls": "0", "api_writes": "1 — POST issues/33696/comments (this report, via post-stamped)", "open_questions": [ { "question": "With a required master FK, rows with a missing master or a NULL FK can be stored (system writes, required-promotion). Should an unrestricted reader see them once the vacuous leaf is dropped?", "options": [ "A — Amend the ruling: for a required FK, an unrestricted reader (every hop answers canReadObject true and getReadFilter undefined) gets no chain and sees every detail row inside its own tenant wall, orphan rows included. Effort S-M, as on the card; the card's numbers (card's measurement, not re-run): admin page SQLite 397 -> 281 ms, PG 97 -> 56 ms, and the SQLite half of R3. Business need: measured, every admin list, count and aggregate on a detail. Long-term: the reader holds every right on every hop, so no privilege boundary moves. Rows that today nobody can see or clean up become visible to the people who can fix them. Cost: the orphans are surfaced, not prevented. AI-error axis: neutral to slightly positive; bad seed data written by an AI becomes visible instead of silently invisible. Scope: no new surface.", "B — Close the orphan sources first, then ship R4 exactly as ruled. (1) System writes keep the master_detail reference check, as flow writes already do. (2) Promoting a master to required is refused while rows with a NULL FK exist. Effort M-L, across the objectql write path and the publish/schema-sync door. Risk: seed replay and package install legitimately write in an order that resolves only at the end of the batch (engine-referential-integrity.ts names this). Long-term: contract-first, and parity holds by construction (raw SQL aside). AI-error axis: strongest; a wrong reference is refused loudly at write. Scope: expands the card well past S-M and outside its claimed file surface.", "C — Keep today's chain (park R4). Effort 0, no row change, no gain. The SQLite half of R3 stays blocked (corrected epic comment 6889939163). Long-term: leaves a measured 29-42% admin-read tax in place. AI-error: neutral. Scope: smallest." ], "recommendation": "A. Long-term reading first: the reader is unrestricted on every hop, so dropping the chain moves no security boundary. The only rows it changes are ones that break the master_detail contract, and today they are invisible to everyone. The gain is measured on every admin read. B is the right long-term follow-up for preventing orphans; it can be its own card and should not block A. This is a security read-scope change, so it stays the maintainer's decision either way. Implementation note for A: 'unrestricted' has to be the engine's per-hop answer (scope undefined after canReadObject true). It must not be the cbp filter's hasSuperuserReadBypass, which is View All on the DETAIL only. Reusing that predicate would widen access for a holder of View All on the detail whose master read is restricted (the #30905 ruling A docblock: View All on the detail 'does not open the master arm'). This falsifies PM hypothesis 4." } ], "security_findings": "none", "out_of_scope_findings": [ "carrier: none · noted, not filed — the analytics path reaches the same leaf through getReadFilter(detail) (service-analytics plugin.ts / read-scope-sql.ts), so a leaf-level fix covers it; the 'ANDs it twice' cost was not measured here", "carrier: none · noted, not filed — the stored-orphan sources (system-write dangling reference, required promotion over NULL rows) are a documented residual in engine-referential-integrity.ts, input to option B, not a new defect card" ] }objectstack-fleet commentedon Nov 15, 2026
domain:server#5 · zhuangjianguo · session_01QsR2jRsWwTRkuRCyQwvpAG
决策请求 · #33696 (epic #33631 R4) · 2026-11-15T09:38Z
Governing text: the R4 ruling on epic #33631 (ranked list 6889544281, correction 6889939163): drop the parent chain only when the FK is required, "No change to which rows any reader sees". Measurement: os-dev report 6892424473 (real engine, SqlDriver + SecurityPlugin + SharingService, origin/main d7e1a5a).
前提不成立: master FK 设成必填后,仍有三种方式存进「孤儿」明细行(系统身份插入一个不存在的主记录、系统身份把 FK 改指向不存在的行、字段改成必填时已有 FK 为空的行;前两种
engine-referential-integrity.ts已记为已知缺口)。今天父链把这些行对管理员也藏起来;去掉父链后管理员会看到它们,所以「任何读者看到的行不变」不成立。Four facets
os-decision-facets
① 项目长远合理性: A 让「不受限读者」真正不受限,B 是防孤儿的正确后续,可另立卡不必挡 A;C 留下实测的管理员读税。
② 实际业务拉动: 每次管理员列表读都受益(卡上实测 29–42%)。
③ 防 AI 犯错: A 不放宽任何受限读者;孤儿行变可见反而让数据错误暴露出来。
④ 创业阶段不扩散: A 面最小且有收益;B 扩到写路径与发布门。
推荐 A,B 另立后续卡。这是安全读范围的语义,属维护者人工裁决。
State:
pm:dispatched→needs-user-decision, assignee cleared (claim 6892260838 released by this stroke; empty branchclaude/area-A2-33696stays as a marker). Area S1 re-claims after the ruling.Generated by Claude Code
7 remaining items
objectstack-fleet commentedon Nov 15, 2026
domain:server#5 · zhuangjianguo · session_01QsR2jVPGBoi3MCGoKbW1Hv
Claim amendment · 2026-11-15T10:44Z · to claim 6893117018 · file surface widened by the area (routing, no ruling change)
Added:
packages/objectql/src/engine.ts, at most 4 lines, all inside the host literal of the private methodcomposeReadableIdsChain: a_registrygetter shaped like the other host literals. The reason: only the engine sees the per-hop scope answer the ruling (6893097935) requires, and it must also read whether the leaf's master_detail field is required. Dropping the leaf at the source instead would make the synchronous cbp read filter async, which reaches further. No behaviour change in engine.ts, and no public surface move. Clause-② no and Metadata-protocol none are unchanged.objectstack-fleet commentedon Nov 15, 2026
domain:server#5 · zhuangjianguo · session_01QsR2jRsWwTRkuRCyQwvpAG
Re-ruled: option 「只对管理员去掉」 (drop the chain for administrators only) · the maintainer (Steedos) on the seat thread decision card (2026-11-15T11:31Z), after an independent Fable re-review. This replaces record 6893097935.
Why it was re-asked: 6893097935 (decision request 6892447012) did not show the maintainer two recorded decisions it reversed. They are #24932 ruling B item 4 (comment 6303721609, 10-20, ⛔ "no interim removal of the predicate for an unrestricted master scope: it would expose rows with a null or dangling foreign key (measured)") and ADR-0139 D6 (docs/adr/0139-engine-internal-semi-join-leaf-readable-parent-ids.md:295-297). As written it would also have shown members unowned rows, against #30905 ruling A (11-06, ADR-0055: rows with no master are visible only to their owner and to view-all holders on the detail). Area S1 found this while building.
Ruling as it binds this card:
hasSuperuserReadBypass), with a required master FK. That reader sees null and dangling-FK rows inside its own tenant wall, consistent with controlled_by_parent admits an optional master (1/3): spec, lint and the read owner branch: a null-master detail row is readable by its owner only #30905 ruling A. Every other reader, members included, keeps the chain unchanged.State: stays
pm:dispatchedwith area S1 (branch claude/area-A2-33696 pushed, no PR). The route is now narrower; S1 reworks it to this ruling.objectstack-fleet commentedon Nov 15, 2026
domain:server#5 · zhuangjianguo · session_01QsR2jVPGBoi3MCGoKbW1Hv
os-dev-report
{ "issue": 33696, "status": "done", "branch": "claude/area-A2-33696", "pr": "https://github.com/objectstack-ai/objectstack/pull/33897", "session": "session_01QsR2jVPGBoi3MCGoKbW1Hv", "premise_still_valid": true, "summary": "Built ruling record 6893666857, which replaces 6893097935. composeReadableIdsChain step 5 drops the leaf over a controlled_by_parent object's REQUIRED master in an AND position. It does so only when that master answers unrestricted at every hop (the engine's per-hop scope; a nested scope left empty answers undefined) AND the caller holds View All on the detail. View All is read from ISecurityService.getEffectiveObjectPermissions, once per read. A delegated caller, a service without that member, or a call that throws keeps the chain. Every other reader keeps the chain unchanged: a restricted hop, View All on the detail only, a plain member. Optional masters and $or/$not positions compose as before. The View All reader now sees null and dangling-FK rows inside its own tenant wall, and the changeset carries the ruling's release note. PR is draft and must not land before #33820 (ADR-0139 status-line amendment), as its body says near the top.", "tests": "Head 2c6025c0 (implementation 521ba7e7 plus origin/main merged), runs under os-verify-lock with exits captured before any pipe. objectql: pnpm test exit 0, 596/596 files, 13141 tests; typecheck exit 0. plugin-security: pnpm test exit 0, 268/268 files, 6690 passed and 45 skipped; typecheck exit 0. New real-stack pins in security-plugin-cbp-read-filter.test.ts, 8 tests: (a) View All plus unrestricted reader has no subquery, all rows, count 7, findOne of a dangling row, plus parity and the analytics door; (b) restricted hop keeps the chain; (c) View All on the detail only keeps the chain; (d) member keeps the chain over a restricted and over a public master; optional master keeps its leaf; (e) isolated tenancy wall. Unit pins in engine-readable-ids-nested-composition.test.ts: 17 tests. Leaf-switch: 23 tests, the three tests gain the View All everywhere reader leg. Ablations via ablation-replace on the committed head, each restore proven blob==HEAD 8ec17d58c0bb with git diff HEAD empty. Per-hop check removed: (b) and (c) red, plus 2 unit pins. readerViewsAllOf forced true: (d) red, plus 1 unit pin. Step 5 disabled: (a), parity, analytics and the (d) admin control red, plus 2 unit pins. Direct runtime dependents after building PKG^... (exit 0): example-embed-objectql 1/1, plugin-audit 94/94, plugin-email 53/53, plugin-pinyin-search 4/4, plugin-sharing 74/74, plugin-webhooks 25/25, runtime 603/603, service-automation 282/282, cloud-connection 82/82, example-todo 9/9, plugin-dev 10/10, verify 52/52. scenarios was 31/33 on the first pass: 2 test/build files refused because its own dist was not built (a prerequisite, not a result); after building scenarios both pass, 2/2 files, 14 tests. cli vitest --project unit exit 0, 421/421 files, 6000 tests.", "gates": "dispatch-gates --commands --repo objectstack-ai/objectstack derived 74 at 2c6025c0. 71 run locally: 70 exit 0 on the first pass; check:query-options-erasure exit 124 (runner timeout 300 s on the shared box), then exit 0 on a re-run with no timeout. --ran reconciliation: 74 derived, 71 run, 0 NOT-MEASURED, 3 UNRUN (check:i18n, check:dual-build-cjs-loads, check:type-check-debt are whole-repo runs left to CI). check-nul-bytes exit 0. pnpm lint is left to CI. PR check-runs: in_progress at report time, not waited on. git merge-tree against origin/main (16 commits newer) is clean.", "dogfood_battery": "n/a: no ! in the PR title and no (narrowing) arm", "line_budget": "7 files, +730 / -9 against origin/main. engine.ts +2 (approved widening, max 4). controlled-by-parent-leaf-switch.test.ts +22/-3 (approved widening, about 15 asked; 25 lines touched in all). No skills/** or docs/adr/** touched.", "files_changed": [ ".changeset/33696-drop-unrestricted-cbp-chain.md (new, objectql patch, Clause-2 no, Metadata-protocol none, release note)", "packages/objectql/src/engine-readable-ids-permission-formula.ts (step 5, readerViewsAllOf, pruning helpers)", "packages/objectql/src/engine.ts (APPROVED WIDENING: 2 lines, _registry getter in the composeReadableIdsChain host literal)", "packages/objectql/src/engine-readable-ids-nested-composition.test.ts (unit pins)", "packages/plugins/plugin-security/src/security-plugin-cbp-read-filter.ts (docblock only)", "packages/plugins/plugin-security/src/security-plugin-cbp-read-filter.test.ts (new, real-stack pins a to e)", "packages/plugins/plugin-security/src/controlled-by-parent-leaf-switch.test.ts (APPROVED WIDENING: View All everywhere reader legs; the existing pins are unchanged)" ], "deviations": [ "pnpm lint was not run locally. common.txt lists it before push, but os-dev.md says a repo-wide scan is CI-owned and that the os-dev file wins on a conflict, so it is left to CI.", "3 derived gate families are left to CI as whole-repo runs: check:i18n, check:dual-build-cjs-loads, check:type-check-debt.", "Packages that depend on objectql only as a devDependency, and dogfood, are left to CI (Test Core). Only the direct runtime and peer dependents were run.", "The PR body starts with the HTML attribution comment that common.txt mandates. os-dev.md otherwise bans HTML comments in bodies.", "The merge commit 2c6025c0 is git's default merge message with no trailers." ], "mcp_calls": "0", "api_writes": "2 relay writes (with this comment): pr_create POST /repos/objectstack-ai/objectstack/pulls via fleet-write run 43720623596 (PR #33897), and this os-dev-report comment via post-stamped. Earlier rounds of this claim: 1 comment (6892424473). Plus git push (not REST).", "open_questions": [], "security_findings": "none", "out_of_scope_findings": [ "carrier: seat · loose-ends card owed by ruling 6893666857: stop orphan rows at their sources (option B). Measured sources: a system-context insert or update naming a missing master is stored (residual in engine-referential-integrity.ts), and promoting an optional master to required leaves NULL-FK rows. Dedupe words: orphan detail rows, dangling master_detail, system write referential integrity, required promotion null", "carrier: #33820 · ADR-0139 status-line amendment (lines 295-297, D6) is the landing precondition; docs/adr not touched", "carrier: seat · security-plugin.ts docblock on computeControlledByParentFilter still says the composed leaf always compiles to a subquery; outside the claim surface", "carrier: seat · open PR #33652 (other seat) edits composeReadableIdsChain in the same file (import line, final composeReadableIdsLeaves call): a textual conflict for whichever lands second. Its planned relation leaves are never asked into chain.answers, so step 5 leaves them alone and the two do not conflict in meaning", "noted, not filed · walled tenancy: the tenant admin's master scope carries the Layer-0 equality, so nothing is dropped there, by design (pin e)" ] }objectstack-fleet commentedon Nov 15, 2026
domain:server#5 · zhuangjianguo · session_01QsR2jVPGBoi3MCGoKbW1Hv
Claim amendment · #33696 · 2026-11-15T13:53Z
After review FAIL 6895328067 on PR #33897 (head 2c6025c), route (a): the write doors stay byte-identical. File surface adds: write-door pins (predicate delete, predicate update, by-id 404 over an orphan, each red on head 2c6025c) in plugin-security
*.test.ts, and a prose-only paragraph in thecomputeControlledByParentFilterdocblock insecurity-plugin.ts(review should-fix 2). Preferred build: the drop stays confined to the read door that asks for it, so no write-door source file changes. If a write-door source file (security-plugin-cbp-write-gate.ts,security-plugin-authz-middleware.ts,security-plugin-addressed-writes.ts) must change, the dev stops and reports first: #33524 in this area edits two of them.Clause-②: no
Metadata-protocol: none
objectstack-fleet commentedon Nov 15, 2026
domain:server#5 · zhuangjianguo · session_01QsR2jVPGBoi3MCGoKbW1Hv
Claim amendment · #33696 · file surface · 2026-11-15T14:06Z
Route (a) build:
packages/objectql/src/engine-middleware-and-context.tsjoins the surface, about 4 lines inexecuteWithMiddlewareonly: a write-epoch operation runs its middleware chain inside an engine-owned store, and the chain drop answers "no drop" while that store is set, so every read made on behalf of a write keeps the chain as on main. No plugin-security write-door source file changes. Open PR #33887 (S2) edits a different function of the same file (claimReferentialCascadeDelete); whichever lands second merges main.Clause-②: no
Metadata-protocol: none
objectstack-fleet commentedon Nov 15, 2026
domain:server#5 · zhuangjianguo · session_01QsR2jVPGBoi3MCGoKbW1Hv
os-dev-report
{ "issue": 33696, "status": "done", "branch": "claude/area-A2-33696", "pr": "https://github.com/objectstack-ai/objectstack/pull/33897", "session": "session_01QsR2jVPGBoi3MCGoKbW1Hv", "premise_still_valid": true, "delta_of": "review FAIL 6895328067 on head 2c6025c0; route (a), claim amendments 6895345175 and 6895620230", "head": "df3fb3b9ad5558a2e9ebf205e12ac0fbd4499fe1", "summary": "Write doors are byte-identical to main again. A write's middleware chain (insert, update, delete, purge, restore) now runs inside READABLE_IDS_WRITE_IN_FLIGHT, an engine AsyncLocalStorage set in executeWithMiddleware (+4/-1, approved widening) and exported from engine-readable-ids-permission-formula.ts. readerViewsAllOf answers no drop inside it, so every read made on a write's behalf keeps the chain: the predicate-write narrowing, the 2.8 predicate leg, the step-2.7 by-id read, and hook reads. No plugin-security write-door source file changed. Should-fix 2: a prose-only paragraph in the computeControlledByParentFilter docblock (security-plugin.ts). The changeset gains a writes-unchanged note.", "findings": [ "Finding 1, predicate delete with an empty-required-master orphan in the set: red on 2c6025c0 (refused MISSING_REQUIRED_FIELD / 422); green on df3fb3b9 (lands on the other row, the orphan stays); passes on main's objectql source.", "Finding 2, predicate update with an empty-master orphan and a dangling-master orphan in the set: red on 2c6025c0 (refused MISSING_REQUIRED_FIELD / 422); green on df3fb3b9 (lands on the other row, both orphans unchanged); passes on main's objectql source.", "Finding 3, by-id update of a dangling orphan and by-id delete of an empty-master orphan: red on 2c6025c0 (refused PERMISSION_DENIED / 403, not RECORD_NOT_FOUND / 404); green on df3fb3b9 (404 for both); passes on main's objectql source.", "Extra pin asked in amendment 6895620230, a hook's read inside a write: red on 2c6025c0 (the hook read saw the 4 orphans); green on df3fb3b9. On main its write leg passes; its plain-read control leg is red there, as expected, because main drops nothing." ], "tests": "The red legs were measured with the three objectql source files set back to 2c6025c0, then restored with git diff HEAD empty. Ablations via ablation-replace, each restore checked blob==HEAD: deleting the store guard in readerViewsAllOf turns 4/4 red; running the write chain outside the scope in executeWithMiddleware turns 4/4 red. At df3fb3b9: plugin-security pnpm test exit 0, 269/269 files, 6705 passed and 45 skipped, typecheck exit 0; objectql pnpm test exit 0, 598/598 files, 13238 tests, typecheck exit 0. At 3089656f (the same code, one main merge earlier): 13 direct runtime dependents all exit 0 after building PKG^... (runtime 605/605, plugin-sharing 74/74, scenarios 34/34, service-automation 282/282 and the rest), and cli --project unit 422/422 files, 6002 tests.", "gates": "At df3fb3b9, dispatch-gates derived 77; 74 run locally, all exit 0. --ran: 77 derived, 74 run, 0 NOT-MEASURED, 3 UNRUN (check:i18n, check:dual-build-cjs-loads, check:type-check-debt, whole-repo runs left to CI). check-nul-bytes exit 0. pnpm lint left to CI.", "merge_tree": "git merge-tree --write-tree --name-only from df3fb3b9. origin/main: clean (main is 18 commits ahead; none of them touches this PR's files). #33887 at eab93bab: clean. #33884 merged as c59198f05 and is included in this head. #33652 at 1b832c58: CONFLICT in engine-readable-ids-permission-formula.ts, 2 hunks (the import block; the step-5 / final composeReadableIdsLeaves lines). The overlap was known; whichever lands second rebases.", "dogfood_battery": "n/a: no ! in the PR title and no (narrowing) arm", "line_budget": "Delta since 2c6025c0: engine-middleware-and-context.ts +4/-1 (approved); engine-readable-ids-permission-formula.ts +17; security-plugin.ts +12 (docblock prose only); security-plugin-cbp-read-filter.test.ts +82; changeset +4.", "files_changed": [ "packages/objectql/src/engine-middleware-and-context.ts (APPROVED WIDENING 6895620230, executeWithMiddleware only)", "packages/objectql/src/engine-readable-ids-permission-formula.ts", "packages/plugins/plugin-security/src/security-plugin.ts (docblock only)", "packages/plugins/plugin-security/src/security-plugin-cbp-read-filter.test.ts", ".changeset/33696-drop-unrestricted-cbp-chain.md" ], "deviations": [ "The write pins seed two admin-created rows through the driver. The rig's member_default adds the own-records write predicate (created_by = caller), and on main an admin predicate write over the seeded rows lands on zero rows.", "The new pins are in security-plugin-cbp-read-filter.test.ts, a file this PR creates, not in a new file named for the card.", "Dependents were not re-run after the second main merge (df3fb3b9). That merge (#33884 among others) touches none of this PR's files. plugin-security and objectql were re-run there.", "pnpm lint is left to CI (os-dev.md: repo-wide scans are CI-owned)." ], "mcp_calls": "0", "api_writes": "2 relay writes this round: issue_patch of the PR #33897 body (run 43734784781, read-back identical), and this comment via post-stamped. Plus git push (not REST).", "open_questions": [], "security_findings": "none", "out_of_scope_findings": [ "carrier: seat · the follow-up card to close the orphan sources (option B) is still owed", "carrier: #33820 · the ADR-0139 status-line amendment is still the landing precondition" ] }objectstack-fleet commentedon Nov 15, 2026
domain:skills#2 · os-steve · session_01ADHkmRxXmVQ41fqnaTPGAv
Unblocked: the ADR status-line card #33820 landed as PR #33992 (merged 2026-11-15T16:34Z). ADR-0139 and ADR-0055 now record the 6893666857 ruling, so the PR for this card no longer waits on it.
objectstack-fleet commentedon Nov 15, 2026
domain:skills#2 · os-steve · session_01ADHkmRxXmVQ41fqnaTPGAv
Carrier for this card (F3 of the at-tier review 6899080787 on PR #34075, card #33432): ADR-0055's 2026-11-14 "What a refusal answers" paragraph has two sentences that rest on "a detail row's own read derives from its master (§2)": the by-id 404 sentence (on
mainnow) and the predicate (multi: true) sentence PR #34075 adds. Both are true onmaintoday. When this card's code lands and its reader class reads a required master's empty or dangling rows, both sentences need this card's 2026-11-15 note, in the PR that lands it. Nothing to do before then.objectstack-fleet commentedon Nov 15, 2026
domain:server#5 · zhuangjianguo · session_01QsR2jVPGBoi3MCGoKbW1Hv
Landed: PR #33897 merged as 3c2fb32; card closed by its Fixes line.
pm:dispatchedremoved · 2026-11-15T21:56Zdocs(adr): ADR-0139 / ADR-0055 record the view-all unrestricted-reade…
perf(objectql): drop a required master's parent chain for a View All …
feat(driver-sql, driver-turso): schema sync indexes (created_at, id) …
docs(adr-0055,skills-data): wording follow-ups from the writeRequires…