Skip to content

Commit bfc1d99

Browse files
committed
docs(adr): ADR-0150 child A records the children's rulings; ADR-0048 §5 lint bullet, ADR-0129 and ADR-0130 cross-references
ADR-0048: §5's authoring-lint bullet is rewritten in place for what naming/namespace-prefix reports since child P; a dated note under §3.4 says its duplicate sentence still holds. ADR-0129: a cross-reference to ADR-0150 under D4. ADR-0130: one dated note under D1 (ruling N1). ADR-0150: D2 shareable namespaces, D3 (c) and caller-less references, D4 owner-less functions, TL;DR 7 and the execution plan's covered-types paragraph. The picklist-references.ts comment points at ADR-0150 D3. No code changes. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01QsR2jUkMujHycV1pMLHL8h
1 parent 732def5 commit bfc1d99

5 files changed

Lines changed: 104 additions & 25 deletions

‎docs/adr/0048-cross-package-metadata-collision.md‎

Lines changed: 38 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# ADR-0048: Cross-package metadata collision — package-id identity, namespace install gate, package-scoped resolution
22

3-
**Status**: Revised (2026-06-13) — supersedes the original *per-item collision detection* framing. The runtime guard shipped under the original proposal is **retained as a same-package authoring backstop**; the strategic direction for the app-marketplace era is revised below. · **Superseded in part by [ADR-0146](./0146-studio-designs-setup-administers-one-editor-per-item-paired-customize-package.md)** (2026-10-31) — §3.3's sentence that a context-free read "is best-effort: it returns the first match": a read of a name a code package ships has an owner — that package, or the declared override its paired `<base>.custom` publishes — and a same-named item of a package outside that closure is served only under its own address (ADR-0146 D8); and §3.4's coexistence "by construction", for a base's dependency closure only: the paired `<base>.custom`'s item bearing a base item's name is a declared override or is refused at publish — declare or rename — and any other dependent package's item bearing a base item's name is refused at publish — rename; only the pair declares (ADR-0146 D2, ruled 2026-10-31 on #28364 and #28390). Packages with no dependency relation keep §3.3 and §3.4 as written; qualify-to-cross, the same-package overwrite and the 2026-10-08 addendum stand. · **Amended** (2026-11-07, [#30794](https://github.com/objectstack-ai/objectstack/issues/30794)): §3.5 — rename-on-install ships for **unmanaged** copies, through the one rename engine `duplicatePackage` applies; a managed install is never renamed and §3.2 stands for it as written. See the dated note under §3.5. · **Amended by [ADR-0150](./0150-behavioural-metadata-addressed-by-package-objects-keep-the-literal-prefix.md)** (proposed 2026-11-08): the 2026-11-06 addendum's one-holder refusal retires type by type as each type's readers carry the package; it stays for platform-requested bare names and, as ruled (ADR-0150 Q2 = A, record [`6724050556`](https://github.com/objectstack-ai/objectstack/issues/31527#issuecomment-6724050556) on #31527), for positions. This line takes effect when ADR-0150 is accepted.
3+
**Status**: Revised (2026-06-13) — supersedes the original *per-item collision detection* framing. The runtime guard shipped under the original proposal is **retained as a same-package authoring backstop**; the strategic direction for the app-marketplace era is revised below. · **Superseded in part by [ADR-0146](./0146-studio-designs-setup-administers-one-editor-per-item-paired-customize-package.md)** (2026-10-31) — §3.3's sentence that a context-free read "is best-effort: it returns the first match": a read of a name a code package ships has an owner — that package, or the declared override its paired `<base>.custom` publishes — and a same-named item of a package outside that closure is served only under its own address (ADR-0146 D8); and §3.4's coexistence "by construction", for a base's dependency closure only: the paired `<base>.custom`'s item bearing a base item's name is a declared override or is refused at publish — declare or rename — and any other dependent package's item bearing a base item's name is refused at publish — rename; only the pair declares (ADR-0146 D2, ruled 2026-10-31 on #28364 and #28390). Packages with no dependency relation keep §3.3 and §3.4 as written; qualify-to-cross, the same-package overwrite and the 2026-10-08 addendum stand. · **Amended** (2026-11-07, [#30794](https://github.com/objectstack-ai/objectstack/issues/30794)): §3.5 — rename-on-install ships for **unmanaged** copies, through the one rename engine `duplicatePackage` applies; a managed install is never renamed and §3.2 stands for it as written. See the dated note under §3.5. · **Amended by [ADR-0150](./0150-behavioural-metadata-addressed-by-package-objects-keep-the-literal-prefix.md)** (proposed 2026-11-08): the 2026-11-06 addendum's one-holder refusal retires type by type as each type's readers carry the package; it stays for platform-requested bare names and, as ruled (ADR-0150 Q2 = A, record [`6724050556`](https://github.com/objectstack-ai/objectstack/issues/31527#issuecomment-6724050556) on #31527), for positions. This line takes effect when ADR-0150 is accepted. · **Amended** (2026-11-09, [#31685](https://github.com/objectstack-ai/objectstack/issues/31685)): §5's authoring-lint bullet, rewritten in place — since ADR-0150 child P ([#31669](https://github.com/objectstack-ai/objectstack/issues/31669)) the bare-name finding of `naming/namespace-prefix` judges only capabilities and positions, and the refusal #30806 phase 3 was to add is withdrawn. §3.4's lint sentence stands as written; see the dated note under §3.4.
44
**Deciders**: ObjectStack Protocol Architects
55
**Builds on**: [ADR-0003](./0003-package-as-first-class-citizen.md) (package as first-class citizen), [ADR-0005](./0005-metadata-customization-overlay.md) (artifact vs runtime overlay precedence), [ADR-0008](./0008-metadata-repository-and-change-log.md) (metadata repository, `MetaRef` identity), [ADR-0010](./0010-metadata-protection-model.md) (package provenance / `_packageId` stamping)
66
**Consumers**: `@objectstack/objectql` (`SchemaRegistry.registerItem`, `ObjectQL.registerApp`, install path), `@objectstack/console` / `objectui` (routing + metadata resolution), package authors, CLI/CI install path, the app marketplace registry.
@@ -290,6 +290,15 @@ package — stays covered by the `naming/namespace-prefix` lint in `os lint`.
290290
> action bound to an object. See
291291
> [Addendum (2026-11-06)](#addendum-2026-11-06-bare-names-resolved-without-a-package-hold-one-package--34-narrowed).
292292
293+
> **Note (2026-11-09, [#31685](https://github.com/objectstack-ai/objectstack/issues/31685)) — the
294+
> lint sentence above still holds.** [ADR-0150](./0150-behavioural-metadata-addressed-by-package-objects-keep-the-literal-prefix.md)
295+
> child P ([#31669](https://github.com/objectstack-ai/objectstack/issues/31669)) retired the
296+
> rule's bare-name finding for the types ADR-0150 D1 puts in buckets 2–4, and kept the finding
297+
> this section relies on (ADR-0150 D9): two items of one type that land on one registry key
298+
> inside one package — among its apps, pages, dashboards, flows, actions (per `objectName`),
299+
> reports and datasets (`DUPLICATE_KEYED_TYPES`, `packages/cli/src/commands/lint.ts`) — are
300+
> still reported. What the rule covers now is in §5.
301+
293302
### 3.5 Namespace rename-on-install is deferred (non-goal)
294303

295304
Renaming a colliding namespace on install would require rewriting **every**
@@ -381,25 +390,34 @@ alias is optional and out of scope for the phases below.
381390
Status legend: **[done]** shipped · **[proposed]** not yet built ·
382391
**[deferred]** out of scope here.
383392

384-
- **[done]** Authoring lint: `naming/namespace-prefix` in `os lint` warns on
385-
every bare package-authored top-level name in every manifest collection of a
386-
package that declares `manifest.namespace` (a package without one is not
387-
judged), and gives the rename as its `fix` (ruling C on #30798, #30804). It
388-
does not judge objects (`defineStack` refuses those), views (named for their
389-
object), docs (`docs/namespace-prefix`), extensions, translation bundles,
390-
fields, `functions`, or an item that declares `overrides`. A name carries the
391-
namespace when it is the namespace itself (the namespace-named app per
392-
ADR-0019), starts with `<ns>_`, is a dotted `<ns>.<short>` name, the
393-
capability shape (maintainer ruling 2026-11-06T11:08Z, recorded in
394-
[#30804 comment 6683456244](https://github.com/objectstack-ai/objectstack/issues/30804#issuecomment-6683456244)),
395-
or starts with `sys_`. The permission set `guest_portal` is exempt, because
396-
the public form doors request it by that bare name (ADR-0138; maintainer
397-
ruling 2026-11-06T14:57Z, recorded in
398-
[#30804 comment 6687835712](https://github.com/objectstack-ai/objectstack/issues/30804#issuecomment-6687835712);
399-
`PLATFORM_REQUESTED_BARE_NAMES`). The rule also reports a name declared
400-
twice in one package among its apps, pages, dashboards, flows, actions (per
401-
`objectName`), reports and datasets. It is warning-only; the refusal is
402-
phase 3 of the same ruling (#30806).
393+
- **[done]** Authoring lint: `naming/namespace-prefix` in `os lint` reports two
394+
warning-only findings over the declarations of one package (amended in place
395+
2026-11-09, [#31685](https://github.com/objectstack-ai/objectstack/issues/31685), after
396+
ADR-0150 child P, [#31669](https://github.com/objectstack-ai/objectstack/issues/31669)).
397+
- **The duplicate finding** (§3.4, kept by ADR-0150 D9): a name declared twice in one
398+
package among its apps, pages, dashboards, flows, actions (per `objectName`), reports
399+
and datasets (`DUPLICATE_KEYED_TYPES`). It asks for a distinct name, never for a prefix.
400+
- **The bare-name finding** judges only the collections whose names keep the literal
401+
prefix (`PREFIX_JUDGED_COLLECTIONS`): capabilities, spelled `NS.SHORT` (ADR-0150 D1
402+
bucket 1; maintainer ruling 2026-11-06T11:08Z, recorded in
403+
[#30804 comment 6683456244](https://github.com/objectstack-ai/objectstack/issues/30804#issuecomment-6683456244)),
404+
and positions, one slot per name in the environment (ADR-0150 D7). It judges a package
405+
that declares `manifest.namespace`, and gives the rename as its `fix`. A name carries
406+
the namespace when it is the namespace itself, starts with `<ns>_`, is a dotted
407+
`<ns>.<short>` name, or starts with `sys_`; an item that declares `overrides` is not
408+
judged.
409+
- **Every other type keeps its short name.** ADR-0150 identifies buckets 2–4 by
410+
(package, name) (D1), so child P retired the warning that asked for `<ns>_<short>`
411+
there (D9), and a name already prefixed stays valid. The permission set `guest_portal`,
412+
exempted by ruling 2026-11-06T14:57Z
413+
([#30804 comment 6687835712](https://github.com/objectstack-ai/objectstack/issues/30804#issuecomment-6687835712);
414+
`PLATFORM_REQUESTED_BARE_NAMES`), is no longer judged at all: permission sets are
415+
bucket 2.
416+
- **No refusal follows.** Phase 3 of ruling C on #30798 (#30806), which was to turn the
417+
bare-name finding into a refusal at `defineStack` and the save door, is withdrawn
418+
(maintainer ruling A 「转向包寻址」, recorded in
419+
[#30806 comment 6721941146](https://github.com/objectstack-ai/objectstack/issues/30806#issuecomment-6721941146);
420+
ADR-0150's status line).
403421
- **[done] Phase 1 — install-time namespace gate.** `NamespaceConflictError` +
404422
the gate in `SchemaRegistry.installPackage` (refuses a package whose
405423
`manifest.namespace` is already owned by a different installed package;

‎docs/adr/0129-object-name-is-the-canonical-id.md‎

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,11 @@ convoy with #12786). This ADR **records an already-enforced, platform-wide decis
55
changes no shipped behavior. The contract below has been enforced since the parse path was
66
closed by #4001 and is restated by Prime Directive #6 in `AGENTS.md` — what was missing was
77
the decision record itself, and that absence is what produced the phantom citation this ADR
8-
closes (see § History).
8+
closes (see § History). · **Cross-referenced by
9+
[ADR-0150](./0150-behavioural-metadata-addressed-by-package-objects-keep-the-literal-prefix.md)**
10+
(2026-11-09, [#31685](https://github.com/objectstack-ai/objectstack/issues/31685)): objects keep this
11+
record's literal prefix unchanged, and behavioural metadata is addressed by (package, name) instead
12+
of carrying it. See the dated note under D4.
913
**Deciders**: ObjectStack maintainer (2026-08-29), recording a contract in force since #4001.
1014
**Relates to**: [ADR-0028](./0028-metadata-naming-and-namespace-isolation.md) (the **Deferred
1115
target model** pointing the opposite way — reconciled in D4 below),
@@ -82,6 +86,19 @@ design, this ADR is the enforced present. **Until 0028's recorded re-open trigge
8286
this ADR is the governing record of object naming.** If 0028 is ever adopted, the adopting
8387
work must supersede this record explicitly (Prime Directive #13) — never drift past it.
8488

89+
> **Note (2026-11-09, [#31685](https://github.com/objectstack-ai/objectstack/issues/31685)) — ADR-0028
90+
> is re-opened for the behavioural tier only, and this record stays the governing record of object
91+
> naming.** [ADR-0150](./0150-behavioural-metadata-addressed-by-package-objects-keep-the-literal-prefix.md)
92+
> (accepted by the maintainer's merge of #31586) supersedes ADR-0028 D1 and D3 in part, for the
93+
> behavioural and presentation types of its buckets 2–4. Objects are its bucket 1, with fields,
94+
> object extensions, views, capabilities, docs and an api's path: they keep the literal prefix, for
95+
> the reason D1 here gives (the name is the table name, read by consumers the platform does not
96+
> control; ADR-0150 D1). Nothing in D1–D3 changes. What ADR-0150 does not take is ruling C on #30798's
97+
> extension of D2's literal prefix to every package-authored name: phase 3 of that ruling (#30806),
98+
> which was to amend this record so, is withdrawn (maintainer ruling A 「转向包寻址」, recorded in
99+
> [#30806 comment 6721941146](https://github.com/objectstack-ai/objectstack/issues/30806#issuecomment-6721941146)).
100+
> A flow, an action, a page or a tool keeps a short name, and the platform carries its package.
101+
85102
---
86103

87104
## History — why this record exists

‎docs/adr/0130-release-artifact-as-co-ownership-boundary.md‎

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -174,6 +174,20 @@ A release artifact MAY carry N package manifests. Everything inside one artifact
174174
one file and installed in one act. That joint delivery **is** the ownership proof; nothing else
175175
needs to assert it.
176176

177+
> **Note (2026-11-09, [#31685](https://github.com/objectstack-ai/objectstack/issues/31685)) — what
178+
> co-ownership does not decide: how a reference between two packages of one artifact resolves.**
179+
> The CLI's picklist-reference check and the post-seal install judge read the paragraph above as
180+
> letting a package resolve a list a sibling package of the same artifact owns, with no declared
181+
> dependency (`packages/cli/src/utils/picklist-references.ts`). That allowance narrows to declared
182+
> dependencies: a bare reference resolves from the referring package's own items, then the unique
183+
> holder in its declared dependency closure (ADR-0141, plus `sys`), else it is refused naming every
184+
> candidate ([ADR-0150](./0150-behavioural-metadata-addressed-by-package-objects-keep-the-literal-prefix.md)
185+
> D3). A sibling in the same artifact is in that closure only when the referring package's manifest
186+
> declares it, and the author's fix is that one `dependencies` entry. Maintainer ruling N1 on
187+
> #31678, recorded in
188+
> [#31678 comment 6729820123](https://github.com/objectstack-ai/objectstack/issues/31678#issuecomment-6729820123).
189+
> D1's co-ownership claim, and the install gate it corrects, are unchanged.
190+
177191
Therefore the install gate's criterion is corrected from *"is this the same package id?"* to
178192
*"are these co-owners within one artifact?"*. This is not a new permission being granted; it is
179193
an existing check being asked the question it was always meant to ask. The 2026-08-06 ruling

0 commit comments

Comments
 (0)