Skip to content

Commit dd6a802

Browse files
Merge branch 'main' into claude/project-thread-1jep1s
2 parents 9e0f2cd + d8b2295 commit dd6a802

163 files changed

Lines changed: 8843 additions & 6072 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: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
---
2+
'@object-ui/app-shell': patch
3+
---
4+
5+
perf(app-shell): Home's navigation roster gate asks the objects it requires in one `GET /meta/object?names=a,b,c` request, instead of one by-name read per object
6+
7+
Clause-②: no
8+
Metadata-protocol: none
9+
10+
Outside an app (Home, whose activity feeds gate every app's navigation), the runtime-capability gate for `requiresObject` entries read each required object by name, one `GET /meta/object/NAME` per name (eight on app-crm). It now asks the names it has not asked yet in one `?names=` request (`meta.getItems('object', { names })`). A name the answer leaves out is treated as not registered, exactly as a by-name `404` was, so its entry stays hidden. A request that gets no answer leaves every name unanswered, so each entry shows, as when a by-name read failed. A refresh asks the same names again in one request. Inside an app nothing changes: the gate still reads the union by name, so the record form keeps sharing those reads with the data adapter's cache. Under the draft preview the gate also keeps the by-name reads.
Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
---
2+
'@object-ui/console': patch
3+
'@object-ui/i18n': patch
4+
---
5+
6+
feat(console)!: an administrator's first-run checklist on Home replaces the currency and time zone dialog, and a country typed by name is saved as its code (#30206)
7+
8+
Clause-②: yes (narrowing) — the published `@object-ui/i18n` packs (all ten) drop the `console.workspaceTimezonePrompt.*` keys, which had no reader outside the removed dialog. The widening half: new console i18n keys `console.firstRunChecklist.*` and `console.settingsView.invalidFormat` / `.invalidFormatHelp` / `.invalidFormatPick` (all ten packs).
9+
Metadata-protocol: none
10+
11+
<!-- adr-0087: not-required (runtime-interface-only ui/packages/i18n/src/locales/en.ts#TranslationKeys) the key type of the console's own translation catalogue: no Zod schema, no spec declaration and no stored metadata reads it, so the compiler is the channel that reaches every caller -->
12+
13+
The dialog that asked for the system timezone and default currency opened over the first page an administrator visited, before anything needed a currency, and once covered the toast that said how to share an invitation. It is gone. The same questions, and the other things a new workspace needs, are now rows of a checklist at the top of Home (`/home`):
14+
15+
1. **Organization name**: done once the organization no longer carries the name the platform gave it ("Default Organization"). Links to Setup → Organization.
16+
2. **Default language and country**, 3. **System timezone**, 4. **Default currency**: done once the setting is set (for language, country and timezone, set by someone rather than left at the platform default; for the currency, which has no default, holding any value). Each opens in place with the Settings page's own fields, pre-filled from the browser: language, country and currency from the browser's first language (so `zh-CN` offers 中文, China and CNY together), the timezone from the browser's zone. Nothing is written until the row's Confirm, which saves through the Settings page's own `PUT /api/settings/localization`.
17+
5. **Email delivery**: done once mail can deliver (a provider other than `log`, a From address, and a host for SMTP). Shown only to a session that may write mail. Links to Setup → Mail Delivery.
18+
6. **Invite colleagues**: done once there is a second member or a pending invitation. Links to Setup → Users.
19+
20+
Each row's state is read from the real setting every time, never from a click. The checklist is shown only to a session that may write `localization`; a member sees nothing, and a member's Home sends no settings namespace read. It draws nothing once every row is done, and its close button hides it for that administrator in that workspace on that device, writing nothing to the server. The rules the dialog was built on still hold: the browser's zone and currency are never written without the administrator's Confirm, and an unset currency stays on the list until it is set.
21+
22+
**BREAKING** (`@object-ui/i18n`, TypeScript only): the exported `TranslationKeys` (`typeof en`) loses the 14 `console.workspaceTimezonePrompt.*` keys, in all ten packs (ar, de, en, es, fr, ja, ko, pt, ru, zh). A `t()` call that names one still compiles, since its key is a `string`, and reads the key back. Nothing replaces them one for one; the fix is to delete the reference.
23+
24+
| Removed key | Replacement |
25+
|:---|:---|
26+
| `console.workspaceTimezonePrompt.title`, `.description`, `.laterHint`, `.decline`, `.confirm`, `.saved`, `.notNow` | none: the dialog is retired; the timezone is a row of `console.firstRunChecklist` (`.timezone.*`) |
27+
| `console.workspaceTimezonePrompt.currencyTitle`, `.currencyDescription`, `.currencyConfirm`, `.currencySaved` | none: the currency is a row of `console.firstRunChecklist` (`.currency.*`) |
28+
| `console.workspaceTimezonePrompt.bothTitle`, `.bothConfirm`, `.bothSaved` | none: the checklist confirms each row on its own |
29+
30+
Typing a country's name into a country picker now saves its code: 「中国」 typed into 默认国家, whose option reads 「中国 (CN)」, saves `CN` instead of being refused by the server's two-letter format check. Only a name exactly one option carries counts; any other text is sent as typed, as before. When the server does refuse a value for its format (`invalid_format`), the Settings page and the checklist now say so in the reader's language, naming the setting by its label: "Choose a value for Default country from the list." for a picker, and "Gateway model is not in a valid format. Use provider/model." (with the field's own help line) for a typed field. Every other refusal keeps the server's sentence.
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
---
2+
'@objectstack/metadata-protocol': patch
3+
'@objectstack/spec': patch
4+
---
5+
6+
refactor(metadata-protocol): `findData` hands its body to its facet
7+
8+
Clause-②: no
9+
Metadata-protocol: none
10+
11+
- `ObjectStackProtocolImplementation#findData` keeps its signature and docblock on the class and delegates in one line to `ProtocolDataCrudFacet`, which now holds the body, moved unchanged. The built `index.d.ts` and `index.d.cts` are byte-equal before and after, and no behaviour changes. Nothing to do on upgrade.
12+
- `getDiscovery` stays on the class: its body reads `typeof this.searchAll === 'function'`, which a forwarded host method would always answer true. The move tool now refuses a method read as a value.
13+
- `@objectstack/spec`'s published liveness ledger (`liveness/query.json`) cites `findData` at its new file.
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
---
2+
'@object-ui/data-objectstack': patch
3+
'@object-ui/plugin-designer': patch
4+
'@object-ui/app-shell': patch
5+
---
6+
7+
fix(plugin-designer): the fields page and the objects page save an object as its author wrote it, not as the console is served it
8+
9+
Clause-②: yes
10+
Metadata-protocol: none
11+
12+
`MetadataFieldsPage` took its edit base from the item read and `MetadataObjectsPage` from the list read. The server translates both for the console's `Accept-Language` and fills both with the platform's injected columns (`owner_id` and the rest), and both pages spread that served object back as the save body. In a Chinese console one field relabel or one description edit therefore stored every other label of the object in Chinese, and the injected columns as authored fields. Both pages now build the save body on the object as authored, `overlay ?? code` from the layered read (`GET /meta/object/:name/layers`, served untranslated). The fields page shows and edits the authored fields. The objects page keeps showing the listed object as served and writes back only the keys the edit changed. When the layered read holds neither layer, the fields page says the object was not found and the objects page saves nothing and says why.
13+
14+
`@object-ui/data-objectstack` now exports the reading itself, `authoredBuffer`, `authoredPublished` and `editsAuthoredLayers` with the `AuthoredBuffer` and `AuthoredLayers` types, beside `MetadataClient.layered`. `@object-ui/app-shell` re-exports them from its `authoredObjectBuffer.ts` with no change in behaviour, so its editors and plugin-designer's pages share one copy.
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
---
2+
'@objectstack/skills': patch
3+
---
4+
5+
docs(skills): the authoring skills teach one naming rule, every metadata name a package authors starts with its namespace
6+
7+
Clause-②: no
8+
Metadata-protocol: none
9+
10+
- **Before.** `objectstack-platform` stated the prefix rule for objects only, and claimed `os lint` warns on bare app, page, dashboard, flow, action, report and dataset names whenever a namespace is set. The examples across the skills named flows, actions, hooks, pages, dashboards, reports, datasets, queues, positions, permission sets, assignment rules, agents and skills bare (`lead_conversion`, `sales_rep`, `support_intake`).
11+
- **Now.** `objectstack-platform` states the rule once, beside the object rule: every metadata name a package authors starts with its namespace (`crm_send_email`, `crm_sales_rep`). The exceptions are fields, object extensions, container views and translations (`<ns>_<locale>`). It also says what is enforced today: `defineStack` refuses a bare object name, `os build` refuses a bare doc name, and `os lint`'s `naming/namespace-prefix` warns only on a name one package declares twice. Every example and eval that showed or generated a bare non-object name now carries `crm_` (or its package's namespace where the snippet has one), cross-references included.
12+
- Connector ids, the inbound api flow whose name is part of its webhook URL, and the datasource whose name keys its password variable keep their names. No schema, key or behaviour changes.
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
---
2+
'@objectstack/objectql': patch
3+
---
4+
5+
fix(objectql): the record-currency backfill cleans a driver's raw text out of a failed row, as the import door does
6+
7+
Clause-②: no
8+
Metadata-protocol: none
9+
10+
A failed row in the record-currency backfill report (`failures[].error`) now reads the import row's cleaned sentence (`sanitizeRowError` from `@objectstack/core`, the one rule both doors call) when the row's write threw anything other than a sandboxed hook's error. A driver's SQL statement, constraint name or column list no longer reaches the report, which a tenant admin reads over `POST /api/v1/meta/_migrate-record-currency-codes` and the operator reads in `os migrate record-currency-codes`. A message with no driver text reads as before. The operator's warning line keeps the whole text, so nothing is lost for diagnosis.
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
---
2+
'@objectstack/runtime': patch
3+
---
4+
5+
fix(runtime): a declarative update action refuses a caller with no edit grant `403 PERMISSION_DENIED`, as the data door does, whether or not the record exists or is visible to them
6+
7+
Clause-②: no
8+
Metadata-protocol: none
9+
10+
An `operation: 'update'` action (REST `POST /actions/:object/:action/:id`, MCP `run_action`) now judges the caller's update permission on the object before it answers on the record lookup, the order the data door already keeps ("Refusals come before the record lookup"). A caller who may read the object but holds no edit grant on it, writing a record their access hides or an id that names no record, was answered `404 RECORD_NOT_FOUND` by the action and `403 PERMISSION_DENIED` by `PATCH /data` and MCP `update_record` for the same write. Both doors now answer `403 PERMISSION_DENIED`, with the data door's sentence.
11+
12+
A caller who may update the object keeps `404 RECORD_NOT_FOUND`, one answer for a hidden record and a missing id, so neither door tells a caller whether a record it cannot see exists. A record the caller can read but not edit was already answered `403` by both doors and is unchanged.
13+
14+
No request that succeeded is refused, and no shape changes: for a caller who may not update the object, one refusal's code moves from `404 RECORD_NOT_FOUND` to the data door's `403 PERMISSION_DENIED`.
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
---
2+
'@objectstack/spec': patch
3+
'@objectstack/plugin-auth': patch
4+
'@objectstack/plugin-approvals': patch
5+
'@objectstack/service-automation': patch
6+
---
7+
8+
fix(audit): name the impersonating administrator on identity writes and on an approval decided while impersonating
9+
10+
Clause-②: yes (widening)
11+
Metadata-protocol: none
12+
13+
Two writes an administrator makes while impersonating a user still read as the user's own in the audit ledger. Both now carry the same attribution-only `impersonatedBy` a record write from that session already carries, recorded as `sys_audit_log.metadata.impersonated_by`. `user_id`, `actor` and every permission stay the impersonated user's.
14+
15+
- **Identity-table writes (`@objectstack/plugin-auth`).** A write better-auth makes on the user's behalf (renaming the profile, changing an email, a membership change, an admin route such as set-user-manager) runs as the system and is credited to the user through `attributedUserId`. On an impersonation session it now also names the administrator, read from the session row's `impersonatedBy`, never from the request body. `authSystemWriteContext()` builds it, and the adapter's `withSystemContext` writes now use that same builder. `resolveAttributedActor()` (new) answers the user and the administrator together; `runAttributedToUser()` also accepts the admitted actor object, whose new optional `impersonatedBy` the platform-admin gate fills from the session.
16+
- **The approval decider's segment (`@objectstack/spec`, `@objectstack/plugin-approvals`, `@objectstack/service-automation`).** `ResumeSignal.impersonatedBy` (new, optional) names the administrator when the decider decided from an impersonation session. It is honoured only beside `resumedBy`, on a signal carrying `RESUME_AUTHORITY_SERVICE`, so an HTTP body cannot set it. The approvals decision door fills it from the decision request's context, and a stranded decision's journal keeps it for the replay. The nodes after the decision now carry exactly the decision's administrator, and none when the decider acted in their own name. Before this, a trigger user deciding their own run kept the stamp of the write that started it, and a decider deciding while impersonated carried none.
17+
18+
No schema column and no migration.

‎.github/workflows/ci.yml‎

Lines changed: 45 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -4650,23 +4650,57 @@ jobs:
46504650
# showcase app's) than the seven packages that job hands on, so it restores
46514651
# Build Core's turbo seed instead.
46524652
#
4653-
# BUDGET: the "Run the live e2e specs" step stays under 2 minutes (14-24 s,
4654-
# median 21 s, over the 35 runs above). The widened gate puts this step on
4655-
# most pull requests and on every queue entry, so a spec that would push it
4656-
# over stays in `test:e2e:live:nightly` instead of joining the `:ci`
4657-
# allowlist.
4653+
# BUDGET: the "Run the live e2e specs" step stays under 2 minutes. It took
4654+
# 14-24 s (median 21 s) over the 35 runs above, and 43-94 s (median 70 s)
4655+
# in the 40 slowest jobs of the ceiling's population below. The widened
4656+
# gate puts this step on most pull requests and on every queue entry, so a
4657+
# spec that would push it over stays in `test:e2e:live:nightly` instead of
4658+
# joining the `:ci` allowlist.
46584659
#
4659-
# Ceiling: there is no CI population yet, so it is derived from one cold
4660-
# local run on 4 shared cores (#27154, 2026-10-28), by the rule above Lint UI:
4661-
# install 60 s + closure build 384 s + Console build 119 s + backend boot
4662-
# 19 s + specs 26 s + browser provisioning and setup ~120 s ≈ 730 s
4663-
# (12.2 min) => max(36.5, 27.2) => 40. Re-derive from the first population.
4660+
# Ceiling, by the rule above Lint UI, re-derived from the first CI population
4661+
# (#27228). Population: every completed `CI` run with event `push` or
4662+
# `schedule` on `main`, or `merge_group`, created between #27212's merge
4663+
# (2026-10-28T11:47:32Z) and 2026-11-06T05:50:51Z: 3,395 runs (1,177 push,
4664+
# 53 schedule, 2,165 merge_group). The queue runs count because this is a
4665+
# required context and a queue entry whose run is cancelled is ejected.
4666+
# Read from
4667+
# GET repos/{owner}/{repo}/actions/workflows/ci.yml/runs
4668+
# ?branch=main&event=push|schedule&status=completed&created=A..B
4669+
# GET repos/{owner}/{repo}/actions/workflows/ci.yml/runs
4670+
# ?event=merge_group&status=completed&created=A..B
4671+
# in one- or two-day windows (one listing answers at most 1,000 runs), and
4672+
# this job's check-run on each head sha from
4673+
# GET repos/{owner}/{repo}/commits/{sha}/check-runs?check_name=Live E2E UI
4674+
# kept when its job URL names one of those runs. Every run carries the job:
4675+
# 3,205 success, 181 skipped, 7 failure (316-529 s), 2 cancelled (91 s,
4676+
# 0 s); none reached a ceiling.
4677+
# Duration is `completed_at` minus `started_at`, except where the platform
4678+
# stamped one of them late: six queue jobs on 2026-11-01 read ~4,000 s or
4679+
# below zero while their steps span 387-513 s, so each of the 40 slowest
4680+
# reported jobs (and those six) is read to its last step's end instead.
4681+
# - success: n=3205, min 68 s, median 407 s, p95 563 s, p99 589 s,
4682+
# max 822 s (13.7 min; job 125022934909, a queue run on a slow runner:
4683+
# 615 s closure build, 94 s specs) => max(41.1, 28.7) => 45.
4684+
# The next slowest, to the last step, are 772, 738, 731, 702 and 699 s
4685+
# (reported 775, 740, 733, 704 and 701 s), all queue runs; push and
4686+
# schedule alone top out at 624 s and would give 35.
4687+
# `pull_request` runs are not in the population: they were not read in
4688+
# full, which the sibling rule ("every successful job") asks for. A sample
4689+
# of 93 successful ones on the same slow days (2026-11-01 to 2026-11-03)
4690+
# tops out at 675 s, under the 822 s that decides the value, so 45 holds
4691+
# either way; the next re-derivation should read them in full.
4692+
# The slow tail is the cold case: those jobs spend 406-615 s in the
4693+
# closure build, above the 384 s of the cold local run on 4 shared cores
4694+
# (#27154) that set the old 40 (≈ 730 s => max(36.5, 27.2) => 40), so the
4695+
# measured max, not that estimate, is the slowest successful run.
4696+
# Re-derive when the job's work changes; ui/scripts/__tests__/
4697+
# turbo-cache-save-bound.test.ts holds the value.
46644698
live-e2e-ui:
46654699
name: Live E2E UI
46664700
needs: filter
46674701
if: ${{ !cancelled() && needs.filter.outputs.ui_tree != 'false' && (needs.filter.outputs.ui != 'false' || needs.filter.outputs.ui_consumers != 'false' || needs.filter.outputs.core != 'false') }}
46684702
runs-on: ubuntu-latest
4669-
timeout-minutes: 40
4703+
timeout-minutes: 45
46704704
permissions:
46714705
contents: read
46724706
env:

0 commit comments

Comments
 (0)