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
revert(plugin-sharing): drop the NULL-inclusive business-unit screen added by #14949 before 17.3 is cut; keep the strict member screen (ADR-0131 D8) #15030
⛔ Do not add any other NULL arm, and do not touch SqlDriver.applyTenantScope.
Acceptance
git grep -n 'organization_id: null' -- packages/plugins/plugin-sharing/src returns no non-test hit; memberScope still strict and pinned; plugin-sharing suite green; the revert commit is shown NOT to be an ancestor of @objectstack/account@17.2.0 (positive control: one 17.2.0 commit IS).
Filed on the maintainer's ruling (2026-09-04, live chat: 「接受你的建议」on the post-17.2 audit under #13564 / ADR-0131).⚠️ Must land before the 17.3 tag.
业务一句话
#14949(修 #14547)把 driver 那条「本组织的行,或者没标签的行」放行规则在共享规则服务里又抄了一份(
business-unit-graph.ts的orgScope改成$or: [{organization_id: X}, {organization_id: null}])。这正是 ADR-0131 要退役的形状(同一谓词两处实现,#10103 的病根),而且它还没发布。发版前把这一半退回去;同一 PR 里成员表用严格等式那一半是对的,保留。Scope
packages/plugins/plugin-sharing/src/business-unit-graph.ts, restoreorgScopeto the strict equality it had before e560b4d ({ ...filter, organization_id: this.organizationId }); delete the docblock that argues for the NULL-inclusive unit screen. KeepmemberScope(strict, fix(plugin-sharing): a seeded business unit is a usable sharing-rule recipient, and its members are tenant-screened #14949's second half) and every test that pins it.business-unit-graph.test.ts/recipient-width.test.tscases that pin the NULL-inclusive unit screen: a seeded unit withorganization_id = NULLis not a usable recipient for an org-stamped rule in 17.x — the same behaviour 17.2.0 ships — and the test names Sharing rules with a business-unit recipient silently grant nothing when the unit row has organization_id = NULL #14547 as the open defect it reproduces.patch: "17.3 does not ship the NULL-inclusive business-unit screen added after 17.2.0; Sharing rules with a business-unit recipient silently grant nothing when the unit row has organization_id = NULL #14547 remains as in 17.2.0 and is fixed structurally in v18 (ADR-0131 C1: the Default Organization exists before application seed datasets load, and the seed loader stampssys_business_unitseeds)".sys_exemption + first-boot ordering, owned by ADR-0131 C1 on the v18 line.⛔ Do not add any other NULL arm, and do not touch
SqlDriver.applyTenantScope.Acceptance
git grep -n 'organization_id: null' -- packages/plugins/plugin-sharing/srcreturns no non-test hit;memberScopestill strict and pinned; plugin-sharing suite green; the revert commit is shown NOT to be an ancestor of@objectstack/account@17.2.0(positive control: one 17.2.0 commit IS).Refs: #14949 · #14547 · #10103 (cause 1) · ADR-0131 (PR #14976) D3 / D8 / D14 · #13564.