Skip to content

Commit ef11c92

Browse files
committed
Merge remote-tracking branch 'origin/main' into claude/project-thread-j9w929-wt
# Conflicts: # ui/packages/app-shell/src/views/objectViewListRenderer.tsx
2 parents 43221c0 + 1d06026 commit ef11c92

92 files changed

Lines changed: 3818 additions & 656 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
---
2+
'@objectstack/spec': minor
3+
'@objectstack/metadata-protocol': minor
4+
---
5+
6+
fix(metadata-protocol)!: a seed never stores a roll-up (summary) value; the children compute it, and the load says what it dropped
7+
8+
Clause-②: no (narrowing)
9+
Metadata-protocol: narrowed
10+
11+
<!-- adr-0087: registered seed-summary-value-not-stored -->
12+
13+
**BREAKING** for a seed record that supplies a value for a `summary` (roll-up) field, in any seed: a `defineStack({ data })` dataset, `defineSeed`, a `seed` metadata item, or the seed data a package install loads. Every aggregate (`count`, `sum`, `min`, `max`, `avg`) is treated the same, whether or not the field is declared `readonly`.
14+
15+
- FROM: the seed loader writes as the system principal, so the supplied value was stored as written. It stayed wherever no child write came after it: a parent seeded with a total and no children kept the total; a re-seed over existing children wrote it over the computed value; and a keep-current (`upsert`) seed replayed on the next boot stored the computed total on the first load and the supplied one on the second.
16+
- TO: the loader takes every such value out of the record before the replay compare and the write, on insert and on update, and writes the rest of the record. A created row starts the column at its empty-child-list value (`0` for `count` and `sum`, empty for `min`, `max` and `avg`), and the seeded child rows compute it. A matched row keeps the value it holds, so a replay whose only difference is the roll-up writes nothing. A parent seeded with a total and no children now reads `0`.
17+
- Reported, not silent: the load logs one warning per dataset naming the object, the fields and how many values it did not write. A dry run (`validate`) logs the same warning. `success` and `errored` do not move, and the load result gains no key. One row counter does: on a replay (`upsert` or `update`), a matched row whose only difference from the seed record was a roll-up value is now counted `skipped`, with nothing written, where it used to be counted `updated`.
18+
19+
Compatibility note for seed authors: to show a total, seed the child rows it is computed from and leave the summary field out of the parent's seed record. A figure no child rows back is not a roll-up: declare it a `number` or `currency` field. A legacy total that must land as written goes through a historical import (`treatAsHistorical: true`), which is unchanged. Rows an earlier load stored a supplied total on are not rewritten by the loader; the next child write recomputes them. A parent with no child rows gets no such write, and `os migrate summary-nulls` backfills only `NULL` columns, so repair one by hand: insert a child row under it and delete that row again, and the recompute leaves the empty-set value.
20+
21+
Not changed: the engine (`packages/objectql`), which still keeps a value an `isSystem` write sends (the roll-up recompute, the backfill, a historical import); the import and REST doors; and the runtime's basic-insert fallback seeder, which runs only when the seed loader is unavailable or throws.
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
---
2+
'@objectstack/metadata-protocol': patch
3+
---
4+
5+
fix(metadata-protocol)!: an unmanaged install renamed into a `targetNamespace` refuses a package that declares no namespace when its object names all share a prefix other than the derived one, instead of copying them under a second prefix
6+
7+
Clause-②: no (narrowing)
8+
Metadata-protocol: none
9+
10+
<!-- adr-0087: not-required (no-migration-prescription) No key of any schema is added, removed, renamed or re-shaped, and no export changes shape. What moves is the answer the unmanaged install gives one request: a package body with no `namespace`, renamed into a `targetNamespace`, whose object names all begin with one first word that is not the namespace derived from its id. No stored row, registry key or authored value changes, so there is nothing for a migration to rewrite and no tombstone. -->
11+
12+
**BREAKING** for a caller of the unmanaged install (`importUnmanagedPackage`, and `POST /api/v1/marketplace/install-local` with `installMode: 'unmanaged'`) that sends a `targetNamespace` with a package body that declares no `namespace`.
13+
14+
Such a body's namespace is derived from its id (`ai.objectstack.gallery.asset-lifecycle-b` derives `asset_lifecycle_b`), and the rename trusted it: an object named `demoasset_asset`, which carries its real prefix, was copied into `trialdemoasset` as `trialdemoasset_demoasset_asset`, while its view `demoasset_asset_all` kept its name, so one copy held three spellings and nothing said why. Now, when such a body has two or more objects, none carries the derived prefix, and every object name begins with the same first word (`demoasset_`), the copy is refused before the base exists: `400 INVALID_REQUEST`, with one rename-refusal `details.refused` entry per object naming the derived namespace, the common prefix and the missing `namespace` key. Nothing is installed. Two objects sharing a short first word (`purchase_order`, `purchase_item`) are refused the same way, and declaring `namespace` clears it.
15+
16+
A body that declares `namespace` is renamed exactly as before, whatever its names look like. In a namespace-less body, every other case keeps the rename: a single object, objects with no common first word (`purchase_order` beside `asset_owner`), or any object carrying the derived prefix each take the target prefix in front of a name that lacks it (`purchase_order` copies as `trialdemoasset_purchase_order`). Without a `targetNamespace` nothing changes: the save door's prefix rule already refuses those names (`422 NAMESPACE_PREFIX`).
17+
18+
The fix is in the package: declare `namespace` on it, the prefix its object names carry, then install again.
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
---
2+
'@objectstack/skills': patch
3+
---
4+
5+
docs(skills): objects carry a colour from the nine-name palette; an object navigation item draws its object's colour tile
6+
7+
Clause-②: no
8+
Metadata-protocol: none
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
---
2+
'@object-ui/components': patch
3+
'@object-ui/fields': patch
4+
'@object-ui/plugin-grid': patch
5+
'@object-ui/plugin-list': patch
6+
'@object-ui/app-shell': patch
7+
---
8+
9+
feat(grid): on the list page a lookup chip opens its record in the side drawer, and a lookup cell has an edit button
10+
11+
Clause-②: yes (widening)
12+
Metadata-protocol: none
13+
14+
On the console's list page, a single click on a lookup chip (a record of another object, such as a contact's account) now opens that record in the side drawer over the list. This replaces, for lookup chips on that page, the earlier change in this release where a plain click on a lookup chip only selected its cell. The list stays where it was: closing the drawer leaves its scroll position and the selected cell as they were. The drawer's address carries the record and its object (`?recordId=…&recordObject=…`), so a reload keeps it open and Back closes it, as with the name cell's "Open in side panel" icon. A click beside the chips only selects the cell. A cell of several chips opens the chip that was clicked; Ctrl/Cmd+Enter on the selected cell opens the first one in the drawer; Ctrl/Cmd-click still opens the record's page in a new tab.
15+
16+
A lookup cell now draws an edit (pencil) button while the pointer is over it and while it is selected. It opens the cell's editor, as a double-click or Enter does, and it is not drawn when the cell cannot be edited (no permission, a read-only field, a locked record). It takes the place of the open button a selected cell shows.
17+
18+
A chip naming a person (an owner, a creator: a lookup to `sys_user`) keeps the behaviour it had: a single click only selects the cell, and it opens from the open button or Ctrl/Cmd+Enter. Email, phone and URL cells and the name column are unchanged. On a phone every record still opens as its page.
19+
20+
For hosts: `ListView` and `ObjectGrid` take a new runtime prop, `openReferencedRecord(objectName, recordId)`, that opens such a record in the host's place; `GridCellSelection` gains an optional `referenceCells` member (`isReferenceColumn`, `openRecord`), exported with its type `GridReferenceCells` from `@object-ui/components`. A host that passes neither keeps the previous behaviour, where a chip only selects its cell. `ReferencedRecordLink`'s anchor now carries `data-record-object` and `data-record-id`.
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
---
2+
'@object-ui/app-shell': patch
3+
'@object-ui/i18n': patch
4+
---
5+
6+
feat(app-shell): from 768 px up an app draws no top bar; what it carried moves to the sidebar and the content area
7+
8+
Clause-②: no
9+
Metadata-protocol: none
10+
11+
Part of objectstack#36112 (epic #36107). An app page from 768 px up now starts at the window's top:
12+
13+
- **Sidebar head.** The first row is the app's glyph and name, which open a menu that only switches apps (the viewer's apps with the current one checked, Setup among them for the viewers the server serves it to, a search field past eight apps, and 「Add app」 for a workspace admin who may author: build with AI or in Studio, start from a template, the marketplace), with the collapse button beside it. The second row is search (`⌘K`) and the notification bell.
14+
- **Sidebar foot.** The account menu: avatar, name and, in a walled organization, the organization's name; the same entries the avatar menu had (profile, connect an AI assistant, organizations, hidden apps, theme, language, notifications, log out), plus the stage chip on a preview or beta deployment.
15+
- **Content area.** The impersonation, read-rate and storage banners and a lost-connection notice sit at the top of the content, its width.
16+
- **Page header.** While the sidebar is collapsed the page header draws the expand button first; a route with no shell header gets it at the content's top-left corner. The page's button group (#36111) is always on; the `os:shell:page-actions` storage switch is gone.
17+
- `⌘⇧H` goes home from any app page at every width (the app layout installs it, not the bar).
18+
19+
Unchanged: a phone keeps its top bar and bottom bar; an app's docs pages, which mount no sidebar, keep the bar at every width; `/home`, the organization pages and Studio keep their bar; the sidebar's fold below 1416 px and its keep-open choice are as before.
20+
21+
New strings in all 11 locales: `sidebar.collapse`, `sidebar.expand`, `layout.appSwitcher.addApp`.
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
---
2+
'@objectstack/service-analytics': patch
3+
---
4+
5+
fix(service-analytics)!: the dataset query door refuses `=`, `$in` and every other scalar comparison or text operator on a multi-value or JSON field with the data door's `400 INVALID_FILTER`, instead of answering a wrong count
6+
7+
Clause-②: no (narrowing)
8+
Metadata-protocol: none
9+
10+
<!-- adr-0087: not-required (no-migration-prescription) No key of any schema is added, removed, renamed or re-shaped, and no export changes shape. What moves is the answer to a request: a filter the data door already refuses is now refused on the analytics dataset door too, so there is no stored row, registry key or authored value for a migration to rewrite and no tombstone. -->
11+
12+
**BREAKING** for a client of `POST /api/v1/analytics/dataset/query` (and every other caller of the dataset query on the native SQL strategy or the draft preview) whose `runtimeFilter`, dataset `filter` or measure `filter` applies an operator of `JSON_COLUMN_INCOMPATIBLE_OPERATORS` (`@objectstack/core`) — `$eq` or implicit equality, `$ne`, `$in`, `$nin`, `$gt` / `$gte` / `$lt` / `$lte`, `$between`, `$startsWith`, `$endsWith`, `$icontains` — to a field declared `multiple: true`, an inherently multi-value type (`tags`, `multiselect`, `checkboxes`) or a structured-JSON type:
13+
14+
- FROM: the native SQL strategy compared the stored JSON text (`["a","b"]`) against the comparand and answered `200`: `$in` / `$eq` counted no row, `$nin` / `$ne` counted the rows they were asked to exclude, and the orderings and the text operators matched the serialization. The draft preview (`?preview=draft`) gave the same counts over the drafted rows. TO: `400 INVALID_FILTER` before anything runs, in the words `POST /api/v1/data/:object/query` answers, naming the field and the operator, on every dialect. The ObjectQL strategy already answered this. On a datasource whose SQL dialect the host cannot name (memory, MongoDB), the native strategy now declines such a query, so the engine answers it through its own driver.
15+
16+
**Not moved.** `$contains` / `$notContains` (membership), `$null`, `$exists` and `$empty` on such a field, `$eq: null` / `$ne: null` (a null predicate), an empty `$in` / `$nin`, and every operator on a scalar field answer as before.
17+
18+
The fix for a caller: write `{ "FIELD": { "$contains": "a" } }` for membership, an `$or` of `$contains` for any-of, and `$null` / `$empty` for no value.
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
---
2+
'@objectstack/skills': patch
3+
---
4+
5+
Clause-②: no
6+
Metadata-protocol: none
7+
8+
`objectstack-ui` record-page rule: an authored `kind: 'full'` record page is drawn on the desktop full page only. A phone and the side drawer draw the standard page (the object's declarations plus any slotted page), and no key keeps a full page there; a page named in the URL, such as a print page, still draws everywhere. The standard page draws no `record_section` action, so an action that must show on a phone or in the drawer also lists `record_more` in its `locations`. The drawer step now says the drawer always shows the standard page.

‎content/docs/ai/connect-mcp.mdx‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -137,8 +137,8 @@ Clients that read an `mcpServers` map connect the same way. With an API key:
137137
Mint a key from the **Connect an AI Assistant** page in the Console. One page, two
138138
doors — which one you have depends on your permissions:
139139

140-
- **Any signed-in user** — open the avatar menu (top right) → **Connect an AI
141-
Assistant**. It opens the page in the Account app, whose sidebar lists it
140+
- **Any signed-in user** — open the account menu (your name at the foot of the
141+
sidebar; on a phone, the avatar at the top right) → **Connect an AI Assistant**. It opens the page in the Account app, whose sidebar lists it
142142
under **AI Assistant**.
143143
Direct link: `/_console/apps/com.objectstack.account/page/connect_agent`.
144144
- **Platform admins** — **Setup → Overview → Connect an AI Assistant**, at

‎content/docs/data-modeling/fields.mdx‎

Lines changed: 15 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -409,10 +409,21 @@ person who submitted it is not shown the drop. A record created with its value
409409
dropped starts as if no value had been sent: `0`
410410
for `count` and `sum`, empty for `min`, `max` and `avg`, and the next child write
411411
replaces it with the computed value. Under `strictReadonlyWrites` the whole write
412-
is refused. Server code that runs with `isSystem: true` can still write the
413-
column, as it can any read-only column: seed data, package installs and a
414-
historical import (`treatAsHistorical: true`, which only the system principal may
415-
send) keep a pre-computed total, on create and on update. Undoing an ordinary
412+
is refused. Seed data never stores a summary value, and that includes the seed
413+
data a package install loads, since it goes through the same seed loader: a value a
414+
seed record supplies for a summary field is not written, on create or on
415+
update, and the rest of the record is. The summary is computed from the seeded
416+
child records, so a parent seeded with a total and no children shows the
417+
empty-set value (`0` for `count` and `sum`, empty for `min`, `max` and `avg`),
418+
and re-seeding a parent leaves its computed value in place. The load logs one
419+
warning per dataset that names the object, the fields and how many values it
420+
did not write. One degraded path does not go through the seed loader: when the
421+
runtime has no metadata service, or the seed loader throws, it falls back to a
422+
basic insert of the seed records, and that fallback still stores a supplied
423+
summary value. To show a total, seed the child records it sums. Server code that runs with `isSystem: true` can still write the column,
424+
as it can any read-only column: a historical import (`treatAsHistorical: true`,
425+
which only the system principal may send) keeps a pre-computed total, on create
426+
and on update. Undoing an ordinary
416427
import restores the rows through an ordinary update, so a summary value that an
417428
import committed before this rule overwrote is not put back by the undo; it stays
418429
until the next child write recomputes it.

‎content/docs/deployment/install-modes.mdx‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -267,6 +267,7 @@ refusal is answered before the base exists, so nothing is installed:
267267
|:---|:---|
268268
| A `targetNamespace` the namespace rule refuses, or a shared one | `400 INVALID_REQUEST`, naming `targetNamespace` |
269269
| An object whose copy name another object's copy takes (`ticket` beside `crm_ticket`) | `400 INVALID_REQUEST`, naming the object and the rename that clears it |
270+
| A package that declares no `namespace`, with two or more objects whose names all begin with the same first word, not the namespace derived from the package id (`demoasset_asset` and `demoasset_site` in `com.acme.asset-lifecycle`, which derives `asset_lifecycle`; `purchase_order` and `purchase_item` too) | `400 INVALID_REQUEST`, naming each object, the derived namespace and the common prefix; declaring `namespace` on the package clears it |
270271
| A copy name that is not a legal item name, longer than an object's table name may be (63 characters), or longer than an item name may be (255) | `400 INVALID_REQUEST`, naming each item |
271272
| A renamed key that meets a key the item already holds (a permission set granting both `crm_lead` and `acme_lead`) | `400 INVALID_REQUEST`, naming the item and both keys |
272273
| A capability whose copy name another capability of the package declares (`crm.approve` beside `acme.approve`) | `400 INVALID_REQUEST`, naming the capability |

0 commit comments

Comments
 (0)