@quickback-dev/cli 0.70.24 → 0.70.26
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +1 -1
- package/dist/skill/docs/api/crud.md +4 -2
- package/dist/skill/docs/define/changesets.md +6 -3
- package/dist/skill/docs/platform/realtime/table-changes.md +1 -1
- package/package.json +1 -1
- package/src/skill/docs/api/crud.md +4 -2
- package/src/skill/docs/define/changesets.md +6 -3
- package/src/skill/docs/platform/realtime/table-changes.md +1 -1
package/dist/index.js
CHANGED
|
@@ -265,8 +265,10 @@ client-generated and server-generated ids are indistinguishable in the table:
|
|
|
265
265
|
| `"nanoid"` | 21-char nanoid | `nanoid()` |
|
|
266
266
|
| `"short"` | 6 alphanumerics | matching `customAlphabet` call |
|
|
267
267
|
|
|
268
|
-
The server mints the same shape
|
|
269
|
-
|
|
268
|
+
The id is accepted, and the server mints the same shape when it is absent, on
|
|
269
|
+
every create path: `POST /`, `POST /batch`, the root and owned-child inserts of
|
|
270
|
+
a [changeset](/define/changesets), and the schema default that an action's
|
|
271
|
+
`db.insert()` falls back on.
|
|
270
272
|
|
|
271
273
|
What breaks, and how:
|
|
272
274
|
|
|
@@ -196,9 +196,12 @@ Every **child op** then pays:
|
|
|
196
196
|
checked).
|
|
197
197
|
8. **Server-minted child ids** — a client-supplied child primary key on an
|
|
198
198
|
insert is rejected (like the plain POST's strict body schema), unless the
|
|
199
|
-
project is configured for client-provided ids
|
|
200
|
-
|
|
201
|
-
|
|
199
|
+
project is configured for client-provided ids: `generateId: false`
|
|
200
|
+
(required), or [`allowClientIds: true`](/api/crud#client-supplied-ids-optimistic-updates)
|
|
201
|
+
(optional, shape-locked to the strategy; an omitted id is minted). Either
|
|
202
|
+
way the id is exempt from the child's `guards.createable`, as on the plain
|
|
203
|
+
POST. The same rule covers the root of a POST changeset, so an aggregate
|
|
204
|
+
can be built client-side with every id known up front.
|
|
202
205
|
|
|
203
206
|
Child `delete` ops stamp the **fixed `deletedAt`** audit column — exactly what
|
|
204
207
|
the plain DELETE route stamps (the audit wrapper then auto-stamps
|
|
@@ -29,7 +29,7 @@ The write chokepoint (the audit-wrapped `db`) sends one frame per (organization,
|
|
|
29
29
|
- **After commit.** Inside `db.transaction()` the frames wait for the commit and are dropped on rollback. Outside a transaction each statement has already committed when its frame is sent.
|
|
30
30
|
- **Audience.** `access.roles` (expanded through `auth.roleHierarchy`) becomes the frame's `targetRoles`, in the caller's active organization. A cron or queue write has no active organization, so the frame goes to the `organizationId` of the written rows — which requires `.returning()`; without it there are no rows to read and no frame.
|
|
31
31
|
- **Coverage.** Every write through the wrapped `db`: CRUD routes, actions, cron, queue, and email handlers. Raw SQL and writes through an unwrapped handle send nothing — use the counter to catch those.
|
|
32
|
-
- **Best-effort.** A failed send never fails the write.
|
|
32
|
+
- **Best-effort, but delivered.** A failed send never fails the write. The send is registered with `waitUntil` (from `cloudflare:workers`), so it finishes after the response is returned instead of being cancelled. This applies to fetch, queue and scheduled handlers alike.
|
|
33
33
|
|
|
34
34
|
`table` is the SQL table name — the same name trigger handlers receive.
|
|
35
35
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@quickback-dev/cli",
|
|
3
|
-
"version": "0.70.
|
|
3
|
+
"version": "0.70.26",
|
|
4
4
|
"description": "CLI for Quickback — define your backend in TypeScript, compile to a fully wired Cloudflare Worker (or Bun / Node) with auth, database, migrations, security, CMS, and Account UI.",
|
|
5
5
|
"author": "Kardoe Incorporated <paul@kardoe.com>",
|
|
6
6
|
"license": "MIT",
|
|
@@ -265,8 +265,10 @@ client-generated and server-generated ids are indistinguishable in the table:
|
|
|
265
265
|
| `"nanoid"` | 21-char nanoid | `nanoid()` |
|
|
266
266
|
| `"short"` | 6 alphanumerics | matching `customAlphabet` call |
|
|
267
267
|
|
|
268
|
-
The server mints the same shape
|
|
269
|
-
|
|
268
|
+
The id is accepted, and the server mints the same shape when it is absent, on
|
|
269
|
+
every create path: `POST /`, `POST /batch`, the root and owned-child inserts of
|
|
270
|
+
a [changeset](/define/changesets), and the schema default that an action's
|
|
271
|
+
`db.insert()` falls back on.
|
|
270
272
|
|
|
271
273
|
What breaks, and how:
|
|
272
274
|
|
|
@@ -196,9 +196,12 @@ Every **child op** then pays:
|
|
|
196
196
|
checked).
|
|
197
197
|
8. **Server-minted child ids** — a client-supplied child primary key on an
|
|
198
198
|
insert is rejected (like the plain POST's strict body schema), unless the
|
|
199
|
-
project is configured for client-provided ids
|
|
200
|
-
|
|
201
|
-
|
|
199
|
+
project is configured for client-provided ids: `generateId: false`
|
|
200
|
+
(required), or [`allowClientIds: true`](/api/crud#client-supplied-ids-optimistic-updates)
|
|
201
|
+
(optional, shape-locked to the strategy; an omitted id is minted). Either
|
|
202
|
+
way the id is exempt from the child's `guards.createable`, as on the plain
|
|
203
|
+
POST. The same rule covers the root of a POST changeset, so an aggregate
|
|
204
|
+
can be built client-side with every id known up front.
|
|
202
205
|
|
|
203
206
|
Child `delete` ops stamp the **fixed `deletedAt`** audit column — exactly what
|
|
204
207
|
the plain DELETE route stamps (the audit wrapper then auto-stamps
|
|
@@ -29,7 +29,7 @@ The write chokepoint (the audit-wrapped `db`) sends one frame per (organization,
|
|
|
29
29
|
- **After commit.** Inside `db.transaction()` the frames wait for the commit and are dropped on rollback. Outside a transaction each statement has already committed when its frame is sent.
|
|
30
30
|
- **Audience.** `access.roles` (expanded through `auth.roleHierarchy`) becomes the frame's `targetRoles`, in the caller's active organization. A cron or queue write has no active organization, so the frame goes to the `organizationId` of the written rows — which requires `.returning()`; without it there are no rows to read and no frame.
|
|
31
31
|
- **Coverage.** Every write through the wrapped `db`: CRUD routes, actions, cron, queue, and email handlers. Raw SQL and writes through an unwrapped handle send nothing — use the counter to catch those.
|
|
32
|
-
- **Best-effort.** A failed send never fails the write.
|
|
32
|
+
- **Best-effort, but delivered.** A failed send never fails the write. The send is registered with `waitUntil` (from `cloudflare:workers`), so it finishes after the response is returned instead of being cancelled. This applies to fetch, queue and scheduled handlers alike.
|
|
33
33
|
|
|
34
34
|
`table` is the SQL table name — the same name trigger handlers receive.
|
|
35
35
|
|