Skip to content

Commit 319d7a8

Browse files
committed
Merge origin/main (b3247dd) into claude/project-thread-rothb5
Brings in #35406 (#35215 G-A + G-D). Conflicts resolved keeping both sides: - references/filing-gate.md: this branch's Blocked-by p2 line and blocker-grade line kept; main's deletion of the maintainer quote line under them kept. - references/lanes/director.md: this branch's needs_decision decision-box line kept; main's trimmed 「必须人工决裁」 line (revoked history removed) kept. - scripts/pm/check-skill-line-ratchet.mjs: filing-gate.md ceiling = measured 83 (83 + 4 for #35259, - 4 for #35215 G-A), both citations kept. lanes/eval.md 45 -> 44 and lanes/queue.md 32 -> 31 lowered to the measured count (files #35406 touched, headroom 0). Claude-Session: https://claude.ai/code/session_01Utp6CaAqjP52wVTzs99H5G Co-authored-by: Claude <noreply@anthropic.com>
2 parents 7c80463 + b3247dd commit 319d7a8

116 files changed

Lines changed: 4151 additions & 297 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: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
---
2+
'@objectstack/spec': patch
3+
'@objectstack/metadata-protocol': patch
4+
'@objectstack/plugin-security': patch
5+
'@objectstack/cli': patch
6+
---
7+
8+
fix: four refusals say what the author can act on — the clone control by its console label, an empty or short unknown key, and an unknown CLI command
9+
10+
Clause-②: no
11+
Metadata-protocol: none
12+
13+
Nothing new is accepted or refused; only the words change.
14+
15+
- **Packaged permission sets.** The `ITEM_LOCKED` save refusal and the `NOT_OVERRIDABLE` lock refusals sent the admin to a "Clone" action. Studio's Access pillar and Setup label that control "New similar" ("新建类似" in a Chinese session), so the diagnostic and both end-user messages, in every language they ship, now name it that way.
16+
- **Unknown keys.** A refusal naming an empty key printed it as empty backticks; it now says "an empty key (`""`)" and offers no rename. On a key of five characters or fewer, a "Did you mean" rename is offered only when the declared key is one edit away, counting a swap of two adjacent letters as one: `lable` → `label` is still offered, while a removed `aria` is no longer answered with `areas`.
17+
- **CLI.** `os <topic> <unknown>` and `os <unknown>` still exit 2 without running anything, and now name the command as typed (`command environments frobnicate not found`) and end with the help that lists the real ones (`See more help with \`os environments --help\``).
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
---
2+
'@object-ui/plugin-grid': patch
3+
'@object-ui/i18n': patch
4+
'@objectstack/spec': patch
5+
'@object-ui/types': patch
6+
---
7+
8+
feat(plugin-grid): an aggregate bulk action that resolves with a `BulkActionResult` is reported per row: the rows it moved, the rows it refused with its own reasons, and the rows it did not confirm
9+
10+
Clause-②: yes
11+
Metadata-protocol: none
12+
13+
The grid's bulk executor now reads the resolve value of an `execution: 'aggregate'` bulk handler. When it is a `BulkActionResult` (`{ succeeded: string[], failed: { id, message }[] }`, `BulkActionResultSchema` in `@objectstack/spec/ui`), the result panel shows how many selected rows were moved, lists each refused row under its record with the handler's `message` (and in the error CSV), and lists every selected row the result names in neither list as "not confirmed", never as succeeded. Ids are read against the dispatched `params._selectedIds`: an id outside the selection is dropped, a duplicate counts once, an id in both lists counts as failed, and when one id is in `failed` twice the first entry's message wins. A rejection is unchanged: it stays one outcome for the whole selection.
14+
15+
A handler that partly succeeds no longer has to reject to avoid being reported as full success: resolve with the per-row answer instead. The `[PLANNED — not enforced]` marker is removed from `BulkActionResultSchema`'s description and its reference page, and the "all-or-nothing" wording is removed from the `bulkActionDefs` description (`@objectstack/spec`) and the `BulkActionDef.execution` TSDoc (`@object-ui/types`).
16+
17+
**Declared behaviour change.** An existing aggregate handler whose own return value carries a top-level `succeeded` or `failed` member in another form (for example counts, `{ succeeded: 2, failed: 1 }`, or only one of the two lists) was reported as full success and is now reported as "unreadable": the panel says the action finished but its result could not be read, prints no per-row count, and the grid re-reads its rows when the dialog closes. To keep the success report, return a value with neither member (a summary under another name), or return both lists in the `BulkActionResult` shape. A handler that returns nothing, or a value with neither member, keeps today's report.
18+
19+
The widening is additive: three new keys in every locale pack `@object-ui/i18n` publishes (`grid.bulk.resultNotConfirmed`, `grid.bulk.notConfirmedRecords`, `grid.bulk.aggregateUnreadable`). No metadata key, value or default changes.
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
---
2+
'@objectstack/skills': patch
3+
---
4+
5+
docs(skills): the hooks skill teaches when a `before*` hook's `ctx.api` writes roll back with a refused save
6+
7+
Clause-②: no
8+
Metadata-protocol: none
9+
10+
objectstack-data's `references/data-hooks.md`, "Before vs After Hooks" table: the `before*` Transaction cell no longer says only "Within transaction". It now says the hook runs in one transaction with the outer write, so a refusal anywhere in that write (a validation, a later hook, a driver constraint) rolls back the hook's `ctx.api` writes too, with no per-hook opt-out. It names the four exits: a caller's open transaction decides; a hooked object off the default datasource, or a default driver with no transactions (Turso's remote transport), opens none, so those writes stay stored after a refusal; a hook registered in code with `registerHook` opens none. It also says MongoDB needs a replica set, which was read in the driver's code and not measured. Best Practices gains one DON'T: a `before*` hook does not write business records to another datasource through `ctx.api`. Its transaction refuses that write with `CrossDatasourceTransactionWriteError`, and only an append-only ledger (`lifecycle.class` `audit` / `telemetry` / `event`) is written outside it. `evals/hooks-security-seeds-datasources.json` gains two cases, one for each rule. Four restatements in data-hooks.md were removed to pay for the new text.
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
---
2+
'@object-ui/app-shell': patch
3+
---
4+
5+
fix(console): Home's Recently Accessed leaves out a row whose object is not registered, and never asks that object by name
6+
7+
Clause-②: no
8+
Metadata-protocol: none
9+
10+
Home's Recently Accessed kept a row for a record, an object or a list view whose object's package was disabled after the row was stored. The row opened a page the environment no longer serves, and its icon and label asked `GET /meta/object/NAME` by name, which answered 404 on every Home render.
11+
12+
Now the objects the recent rows name are asked in one `GET /meta/object?names=` read, which leaves an unregistered object out instead of answering 404. A row whose object that read leaves out is not drawn and takes no place among the six rows. Only an object the read answered served is read by name for its icon and label. While the read has not answered, or after it failed, the row is drawn with its stored title or its object's bundle label and its kind's icon, and nothing is asked by name. Once the whole object registry is loaded, Home reads presence from that list. This is the rule a record page's related lists, a dashboard's `requiresObject` widgets and the navigation's `requiresObject` entries already follow.
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
---
2+
'@object-ui/app-shell': patch
3+
---
4+
5+
fix(console): a permission set outside a delegated security administrator's scope offers no Add and no Remove
6+
7+
Clause-②: no
8+
Metadata-protocol: none
9+
10+
On a permission set's Assigned users section, a delegated security administrator was offered Add user, the member picker and each row's Remove for a set outside every delegated scope they hold, and the server then refused the write (403 `DELEGATION_SCOPE_VIOLATION`). The section now reads the caller's own delegable-scope report (`my-delegable-scope`, through `useAuth().describeDelegableScope`, as the invite dialog does): where the report names delegated scopes and the set is in none of their `assignablePermissionSets`, the section lists the holders with no Add, no picker, no Remove and no "click Add" sentence. The server's gate still decides every write (ADR-0090 D6/D12); the section judges nothing else, so a set the report allowlists keeps its controls and a write the gate still refuses (a target user outside the delegate's business-unit subtree) is refused by the server in its own words.
11+
12+
Every other caller keeps the controls as before: a tenant-level administrator, a caller whose report names no delegated scope (how the report draws an organization administrator), and any caller while the report is read, where no runtime serves it, or where the read fails. An organization administrator who also holds a delegated scope is read as the delegate its scopes describe, since the report does not tell the two apart.
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
---
2+
'@object-ui/fields': patch
3+
---
4+
5+
fix(fields): the filter-condition builder takes no edit until the object's schema has answered, so a number bound is never saved as text
6+
7+
Clause-②: no
8+
Metadata-protocol: none
9+
10+
The criteria builder (the `filter-condition` widget a sharing rule's criteria uses) shows a stored criteria as soon as it opens, but it reads the object's field types from a schema request that answers later. Until that answer arrived, a value box was a plain text box, and a number typed into it was saved as text: `{"amount":{"$gt":"6"}}` instead of `{"amount":{"$gt":6}}`. Once the answer arrived, the box changed to a number box but the text already saved stayed. The server reads such a value as the number it spells, so this changed no rule's matches. It did make the saved document depend on whether the admin typed before or after a network read.
11+
12+
The builder's controls are now disabled while that request is in flight, and nothing is emitted from them. When the answer arrives they are enabled, and each value box has its column's type. If the request fails, the builder is released with no field types, as before. A host that offers no schema request never holds the builder. The raw-JSON editor is not held.
13+
14+
No metadata key, value or default changes. A criteria already saved is not rewritten.
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
---
2+
'@objectstack/runtime': patch
3+
'@objectstack/cloud-connection': patch
4+
---
5+
6+
fix(runtime, cloud-connection): an upgrade replaces the package's seed datasets on the shared replay list
7+
8+
Clause-②: yes (widening)
9+
Metadata-protocol: none
10+
11+
The shared `seed-datasets` list that per-organization seed replay reads was append-only. After a package was upgraded in a running process, the superseded version's datasets stayed on the list until a restart, so every organization founded in between replayed the old and the new version's seed sets. When the upgrade changed an object's `fallback: true` set, the two marked sets refused that object's fallback choice, and a dataset declaring `dependsOn` that object refused the whole load for an organization whose locale no set lists.
12+
13+
`mergeSeedDatasets(ctx, datasets, owner?)` takes an optional `owner`. Given, the owner's earlier entries are replaced on the same live array (in their place) instead of kept beside the new ones; an empty `datasets` takes them off. Omitted, the datasets are appended as before, which is what a config app's boot merge still does. The install-local door merges under the package id on install, upgrade, reinstall, reseed and rehydrate, so the list holds the installed version only: reinstalling the same version adds no duplicate, and a version that ships no seed data takes its predecessor's datasets off the list.
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
---
2+
'@objectstack/metadata-protocol': patch
3+
---
4+
5+
fix(metadata-protocol)!: global search leaves out the objects of a disabled package, the answer every data route already gives
6+
7+
Clause-②: yes (narrowing: global search stops returning a disabled package's records, the answer every data route already gives)
8+
Metadata-protocol: none
9+
10+
<!-- adr-0087: not-required (no-migration-prescription) No schema key, accepted value or metadata type is added, removed or renamed, and nothing stored is rewritten: the moved answer is which objects GET /api/v1/search sweeps once a package is disabled. A caller that needs those records re-enables the package. -->
11+
12+
**BREAKING** for a caller of `GET /api/v1/search` (and of `searchAll` in process) on an environment that disables a package. A disable takes the package's records off the data plane: `GET /api/v1/data/:object` and the by-id read answer `404 OBJECT_PACKAGE_DISABLED`. Global search did not ask that question, so the same records, with their titles and matched text, still came back as hits. The sweep now asks the registry's `isObjectPackageDisabled`, the predicate the data routes ask, and passes over such an object: it is never queried, never named and never counted in `totalObjects`. An explicit `?objects=` naming it answers as one naming no object at all; search is a sweep, not a by-name read, so there is no 404 there.
13+
14+
An enabled object whose title is a reference to an object of a disabled package keeps the bare id as its hit title, the answer a searcher who may not read the target already gets: the title is the disabled record's data.
15+
16+
The fix: re-enable the package to have its records searched again. An environment with no disabled package sees no change. Published pages were already filtered, since the page sweep reads through the `/meta/page` list, which omits a disabled package's items.
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
---
2+
'@objectstack/plugin-auth': patch
3+
'@objectstack/platform-objects': patch
4+
'@objectstack/cli': patch
5+
---
6+
7+
fix(auth)!: a server outside development mode refuses a development seed credential, and `os user set-password` sets a new one on the server
8+
9+
Clause-②: yes (narrowing) — narrowed: on a server whose `NODE_ENV` is not `development`, a password sign-in that submits the development seed password (`admin123`, or the value `OS_SEED_ADMIN_PASSWORD` sets) is refused on every account, and an account the development seed created opens no session while its stored password is still the one it was seeded with. Widened: the `os user set-password` command, the `sys_user.dev_seed_credential` column, and new `@objectstack/plugin-auth` exports `setOperatorPassword`, `findAccountByEmail`, `operatorPasswordRefusal`, `OPERATOR_PASSWORD_MIN_LENGTH`, `OPERATOR_PASSWORD_MAX_LENGTH` and the types `OperatorPasswordResetEngine`, `OperatorPasswordResetOutcome`, `OperatorPasswordResetRefusalReason`.
10+
Metadata-protocol: none
11+
12+
<!-- adr-0087: not-required (no-migration-prescription) No authorable key, accepted value or metadata type is added, removed or renamed; a system column is added; nothing stored is rewritten: the moved answer is whether a server outside development mode accepts a development seed credential at sign-in. The one-line fix for a refused account is in the body: set a new password on the server with os user set-password. -->
13+
14+
**BREAKING** for a deployment that serves, outside development mode, a database `os dev` seeded, or any account whose password is the development seed password. Such a sign-in is refused. Set a new password on the server with `os user set-password <email>`; the refusal names the command. A server in development mode (`os dev`) is unchanged.
15+
16+
**The rule: a server outside development mode never accepts a development seed credential.** Development mode is `NODE_ENV=development`, the condition the development seed itself runs under. The rule lives in the auth plugin, so `os start`, `os serve`, the image and a custom host all apply it.
17+
18+
- **The seed password is refused at sign-in, on any account.** A password sign-in with the development seed password answers `403 PERMISSION_DENIED`, and its message names `os user set-password`. It is decided on the submitted password alone, before any account is read, so every address gets the same answer. This covers the seeded admin, the stack's `demoStaff`, any other account on that password, and a database seeded by an earlier release.
19+
- **The accounts the development seed creates are marked.** `os dev`'s admin and each `demoStaff` account carry `sys_user.dev_seed_credential`: a one-way digest of the password hash the seed stored, never the password. The column is never returned on reads, and any password change stops it matching.
20+
- **A marked account still on its seed password opens no session**, on any sign-in door (password, emailed link, one-time code, passkey, social or SSO, impersonation), whatever password it was seeded with, `os dev --admin-password` included. A password check never confirms that seed password: a password sign-in answers it as a wrong password.
21+
- **No password change is offered at sign-in.** Whoever signed in first could perform it. The way out is the operator's reset on the server.
22+
23+
**`os user set-password <email>`** sets the account's password in the project database. It reads the new password from a terminal prompt (twice, not echoed) or from standard input with `--password-stdin`, never from the command line, and takes `--database-url` like the other one-shot commands. It checks that the new password is not a development seed password and is 8 to 128 characters long; the deployment's own password policy and password history are not applied. It writes nothing on a refusal. It deletes the account's outstanding password-reset links and codes from the project database before the new password lands. It clears the account's development seed mark and any sign-in lock, records the change time, and ends every session and revokes every API key of the account, as an administrator's forced reset does. It asks for no password change at the next sign-in. It writes the project database only: a secondary storage the host configures for the auth service is out of its reach, for the reset links and the sessions alike. With one configured, run the command with the server stopped, or restart the server afterwards; a secondary storage kept outside the server process outlives a restart and is cleared of the account's entries by hand.
24+
25+
**Not detected:** a database seeded before this release with a custom seed password carries no mark and no well-known password. Set a new password with `os user set-password` on each account it seeded before serving it outside development mode.
26+
27+
**Not ended at boot:** this release refuses the development seed password and every new session for a seeded account still on it. Sessions and API keys a seeded account was issued before the server left development mode are ended by `os user set-password`; run it on each seeded account before serving the database. Ending them at boot is follow-up #35184.

0 commit comments

Comments
 (0)