From fa4b414b8b62191035b7f43892d8b92e19861712 Mon Sep 17 00:00:00 2001 From: Jen Garcia Date: Sun, 1 Nov 2026 20:59:51 -0500 Subject: [PATCH] chore: version packages --- .changeset/install-app-fingerprint.md | 5 --- .changeset/one-immutable-field-rule.md | 13 ------- .changeset/owner-entity-id.md | 14 ------- .changeset/portable-copy.md | 18 --------- .changeset/reshare-needs-read.md | 9 ----- .changeset/soft-delete-fixture-tombstone.md | 5 --- .changeset/time-values-carry-meaning.md | 15 -------- packages/adapter-api/CHANGELOG.md | 28 ++++++++++++++ packages/adapter-api/package.json | 2 +- packages/adapter-conformance/CHANGELOG.md | 22 +++++++++++ packages/adapter-conformance/package.json | 2 +- packages/adapter-local/CHANGELOG.md | 24 ++++++++++++ packages/adapter-local/package.json | 2 +- packages/blob-adapter-disk/CHANGELOG.md | 11 ++++++ packages/blob-adapter-disk/package.json | 2 +- packages/blob-adapter-s3/CHANGELOG.md | 11 ++++++ packages/blob-adapter-s3/package.json | 2 +- packages/commons/CHANGELOG.md | 11 ++++++ packages/commons/package.json | 2 +- packages/conformance-fixtures/CHANGELOG.md | 28 ++++++++++++++ packages/conformance-fixtures/package.json | 2 +- packages/core/CHANGELOG.md | 37 +++++++++++++++++++ packages/core/package.json | 2 +- .../record-adapter-do-sqlite/CHANGELOG.md | 27 ++++++++++++++ .../record-adapter-do-sqlite/package.json | 2 +- packages/record-adapter-sqlite/CHANGELOG.md | 27 ++++++++++++++ packages/record-adapter-sqlite/package.json | 2 +- packages/wire-types/CHANGELOG.md | 18 +++++++++ packages/wire-types/package.json | 2 +- 29 files changed, 255 insertions(+), 90 deletions(-) delete mode 100644 .changeset/install-app-fingerprint.md delete mode 100644 .changeset/one-immutable-field-rule.md delete mode 100644 .changeset/owner-entity-id.md delete mode 100644 .changeset/portable-copy.md delete mode 100644 .changeset/reshare-needs-read.md delete mode 100644 .changeset/soft-delete-fixture-tombstone.md delete mode 100644 .changeset/time-values-carry-meaning.md diff --git a/.changeset/install-app-fingerprint.md b/.changeset/install-app-fingerprint.md deleted file mode 100644 index 33d41007..00000000 --- a/.changeset/install-app-fingerprint.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@haverstack/core': minor ---- - -Every install apply names the plan it approves. `installApp(manifest, { did, fingerprint })` replaces `installApp(plan)`: it plans the manifest again for `did` and refuses with `StackConflictError` unless the result is the plan whose `fingerprint` it was given, so a server that shows the owner a plan in one request and applies it in another checks the approval exactly as an in-process caller passing `plan.fingerprint` does. `InstallPlan` carries that `fingerprint`: a SHA-256 over the plan the owner sees, in canonical form — schemas by `schemaHash`, every list as a set — with no Record's `version` in it, so neither a reordering store nor an edit no plan shows makes an approval stale. A list of requests is held to one rule wherever it is written — a manifest or an `_install` Record: each request a grant `grantType()` would accept, each family requested once, and an `_install`'s `defines` listing each version once. An action list is a set written without repeats: `grantType()`, a `_grant` write, a manifest's requests and an `_install` write all refuse an action named twice with `StackValidationError`, a stored list still read as a set. A manifest's refusals are reported together, each at its path in the manifest. `InstallAppOptions` is exported from `@haverstack/core`. diff --git a/.changeset/one-immutable-field-rule.md b/.changeset/one-immutable-field-rule.md deleted file mode 100644 index 770ef05e..00000000 --- a/.changeset/one-immutable-field-rule.md +++ /dev/null @@ -1,13 +0,0 @@ ---- -'@haverstack/core': minor -'@haverstack/conformance-fixtures': minor ---- - -Every immutable field follows one rule. `_config.ownerEntityId`, the `did`/`appId` bindings and `_attachment`'s `fileId`, `mimeType` and `size` are declared in one table and checked on `patchContent()`, `restoreVersion()` and `commitMigration()` alike; a migration is asked over the family the record leaves. - -- Changing or clearing an immutable field throws `StackConflictError` (`409 conflict`) with the message `Cannot change .: it is immutable once set.` Bindings and attachment fields previously threw `StackValidationError` (422). -- A new `_attachment` record whose `mimeType` conflicts with the one established for its `fileId` throws `StackConflictError` (`409 conflict`) instead of `StackValidationError` (422), like a second claim on a DID binding. -- Restating a stored value is no change: a patch that sends an `_attachment` record's current `mimeType` is accepted. -- Every content write — create, patch, restore and migrate — asks the same claim checks: binding uniqueness, and `mimeType` establishment for a record entering the `_attachment` family. `restoreVersion()` previously skipped attachment fields, binding uniqueness and `mimeType` establishment. -- A write that would change several immutable fields is refused naming the first. -- Fixtures: `error-validation-attachment-mimetype-conflict-on-create` is renamed `error-conflict-attachment-mimetype-on-create` and answers 409; `error-validation-attachment-mimetype-immutable-on-update` is replaced by `error-conflict-attachment-mimetype-change`; `error-conflict-config-owner-change` carries the shared message. diff --git a/.changeset/owner-entity-id.md b/.changeset/owner-entity-id.md deleted file mode 100644 index f9f16dcc..00000000 --- a/.changeset/owner-entity-id.md +++ /dev/null @@ -1,14 +0,0 @@ ---- -'@haverstack/core': minor -'@haverstack/wire-types': minor -'@haverstack/conformance-fixtures': minor -'@haverstack/adapter-api': minor -'@haverstack/record-adapter-sqlite': minor -'@haverstack/record-adapter-do-sqlite': minor ---- - -The stack owner has one name wherever a field can only hold the owner: `ownerEntityId`. - -- `_config`'s content is `{ ownerEntityId, timezone }`, and `ConfigContent.entityId` is `ConfigContent.ownerEntityId`. -- The discovery response (`GET /.well-known/stack`) carries `ownerEntityId` in place of `entityId`, in `DiscoveryResponse` and the discovery fixtures. The `_config` ownership-conflict fixture is `error-conflict-config-owner-change`. -- Fields that may hold any entity, such as a relationship target or a grantee, keep `entityId`. diff --git a/.changeset/portable-copy.md b/.changeset/portable-copy.md deleted file mode 100644 index 1915dfd9..00000000 --- a/.changeset/portable-copy.md +++ /dev/null @@ -1,18 +0,0 @@ ---- -'@haverstack/core': minor -'@haverstack/record-adapter-sqlite': minor -'@haverstack/record-adapter-do-sqlite': minor -'@haverstack/adapter-local': minor -'@haverstack/adapter-api': minor -'@haverstack/adapter-conformance': minor ---- - -A stack can be copied whole between adapters, authorship and history included. - -- `copyStack(from, create)` in `@haverstack/core/adapter` copies every Record, soft-deleted and unlisted ones too, with its versions and journal, plus every Type and every blob, into a new store `create` makes from the source's `_config` record and its history, and returns it open. `_config` travels as every Record does. Both ends must list their blobs, and the target must hold nothing yet, so `APIAdapter` cannot yet be copied from. Copying into a `LocalAdapter` store is an export; copying out of one is an import. -- It writes through the new optional `StackRecordAdapter.importRecord(record, { versions, journal })`, which every local adapter implements and `APIAdapter` does not. -- `StackIdentity`, `CreateStore`, `StoreSeed`, `newStoreSeed()` and `identityOf()` are exported beside it. Every adapter that creates stores takes a `seed` in place of `ownerEntityId` and `timezone`: the `_config` record, with its history, a new store is created holding. A seed only creates: storage already holding a store refuses it, and `NativeSQLiteRecordAdapter`/`LocalAdapter` take no `create` beside one. `MemoryAdapter` now holds a real `_config` record. -- Every SQLite store names its layout in a one-row `format` table, and opening one in another layout throws the new `FormatMismatchError` (from `@haverstack/core/adapter`). A new store is written whole, tables included, in one transaction — a table of the same name already in the database fails the create — and a failed `NativeSQLiteRecordAdapter.open()` removes a file it created. -- `OwnerMismatchError` reads ` is owned by "X", not "Y"`, and `copyStack()` throws it too. -- `saveVersion()` is removed from the adapter contract: `importRecord()` is the one standalone history write. -- `@haverstack/adapter-conformance` checks `importRecord()` in the record suite and adds `runCopyConformance()`, which holds a full adapter to both halves of a copy. diff --git a/.changeset/reshare-needs-read.md b/.changeset/reshare-needs-read.md deleted file mode 100644 index 5cb1bc8c..00000000 --- a/.changeset/reshare-needs-read.md +++ /dev/null @@ -1,9 +0,0 @@ ---- -'@haverstack/core': minor ---- - -Authority is gated the same way whenever it is written. - -- Resharing needs read on the Record: `editAccess()`, `setAccess()` and `setUnlisted()` refuse a creator who cannot read their Record, such as one removed from the roster that conveyed it, or a drop-box contributor. -- `permissions` and `unlisted` at `create()` pass the same gate, asked of the Record the create would make. -- A roster entry no longer counts on the principal's side of a delegated request, so a delegated app neither manages a `_group` nor creates one, even with its own DID on the roster. The owner's own software acting for a subject still can. diff --git a/.changeset/soft-delete-fixture-tombstone.md b/.changeset/soft-delete-fixture-tombstone.md deleted file mode 100644 index b44a0d2d..00000000 --- a/.changeset/soft-delete-fixture-tombstone.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@haverstack/conformance-fixtures': minor ---- - -The soft `DELETE` responses in `delete-record-soft` and `change-feed-deleted-frame-is-not-terminal` now carry the tombstone projection — `content: {}`, no authorship fields — as `docs/spec/versioning.md § The tombstone is literal` requires. A server built to the old bodies leaked the content a soft delete removes. diff --git a/.changeset/time-values-carry-meaning.md b/.changeset/time-values-carry-meaning.md deleted file mode 100644 index ed584133..00000000 --- a/.changeset/time-values-carry-meaning.md +++ /dev/null @@ -1,15 +0,0 @@ ---- -'@haverstack/core': minor -'@haverstack/wire-types': minor -'@haverstack/conformance-fixtures': minor -'@haverstack/adapter-api': minor -'@haverstack/adapter-local': minor -'@haverstack/record-adapter-sqlite': minor -'@haverstack/record-adapter-do-sqlite': minor -'@haverstack/adapter-conformance': patch ---- - -A time value carries what it means: a `date`'s form says whether it is a moment, a calendar day or a wall-clock reading (see docs/spec/data-model.md § Types). Nothing reads a stack-wide timezone, so `_config` holds only `{ ownerEntityId }`. - -- `timezone` is removed from `ConfigContent` and the `_config@1` schema, from every adapter's `open()` options, from `stack.timezone` and `StackRecordAdapter` and every adapter that exposed it, and from the discovery response (`DiscoveryResponse` and the discovery fixtures; `discovery-omits-absent-timezone` is removed). -- `StackIdentity` and `identityOf()` are removed: `ConfigContent` is what an adapter holds, and `newStoreSeed()` stores the one it is given whole. diff --git a/packages/adapter-api/CHANGELOG.md b/packages/adapter-api/CHANGELOG.md index c2890c62..0fb5872e 100644 --- a/packages/adapter-api/CHANGELOG.md +++ b/packages/adapter-api/CHANGELOG.md @@ -1,5 +1,33 @@ # @haverstack/adapter-api +## 0.43.0 + +### Minor Changes + +- [#470](https://github.com/haverstack/core/pull/470) [`e0475d2`](https://github.com/haverstack/core/commit/e0475d2fdd09581310d819d3d2b5effe4191603c) Thanks [@cuibonobo](https://github.com/cuibonobo)! - The stack owner has one name wherever a field can only hold the owner: `ownerEntityId`. + - `_config`'s content is `{ ownerEntityId, timezone }`, and `ConfigContent.entityId` is `ConfigContent.ownerEntityId`. + - The discovery response (`GET /.well-known/stack`) carries `ownerEntityId` in place of `entityId`, in `DiscoveryResponse` and the discovery fixtures. The `_config` ownership-conflict fixture is `error-conflict-config-owner-change`. + - Fields that may hold any entity, such as a relationship target or a grantee, keep `entityId`. + +- [#470](https://github.com/haverstack/core/pull/470) [`b02e69c`](https://github.com/haverstack/core/commit/b02e69c4675e7397d2fca76c314261a9744053bf) Thanks [@cuibonobo](https://github.com/cuibonobo)! - A stack can be copied whole between adapters, authorship and history included. + - `copyStack(from, create)` in `@haverstack/core/adapter` copies every Record, soft-deleted and unlisted ones too, with its versions and journal, plus every Type and every blob, into a new store `create` makes from the source's `_config` record and its history, and returns it open. `_config` travels as every Record does. Both ends must list their blobs, and the target must hold nothing yet, so `APIAdapter` cannot yet be copied from. Copying into a `LocalAdapter` store is an export; copying out of one is an import. + - It writes through the new optional `StackRecordAdapter.importRecord(record, { versions, journal })`, which every local adapter implements and `APIAdapter` does not. + - `StackIdentity`, `CreateStore`, `StoreSeed`, `newStoreSeed()` and `identityOf()` are exported beside it. Every adapter that creates stores takes a `seed` in place of `ownerEntityId` and `timezone`: the `_config` record, with its history, a new store is created holding. A seed only creates: storage already holding a store refuses it, and `NativeSQLiteRecordAdapter`/`LocalAdapter` take no `create` beside one. `MemoryAdapter` now holds a real `_config` record. + - Every SQLite store names its layout in a one-row `format` table, and opening one in another layout throws the new `FormatMismatchError` (from `@haverstack/core/adapter`). A new store is written whole, tables included, in one transaction — a table of the same name already in the database fails the create — and a failed `NativeSQLiteRecordAdapter.open()` removes a file it created. + - `OwnerMismatchError` reads ` is owned by "X", not "Y"`, and `copyStack()` throws it too. + - `saveVersion()` is removed from the adapter contract: `importRecord()` is the one standalone history write. + - `@haverstack/adapter-conformance` checks `importRecord()` in the record suite and adds `runCopyConformance()`, which holds a full adapter to both halves of a copy. + +- [#477](https://github.com/haverstack/core/pull/477) [`2169cff`](https://github.com/haverstack/core/commit/2169cff10f9c30bc44966c8ce90f5394cf50620d) Thanks [@cuibonobo](https://github.com/cuibonobo)! - A time value carries what it means: a `date`'s form says whether it is a moment, a calendar day or a wall-clock reading (see docs/spec/data-model.md § Types). Nothing reads a stack-wide timezone, so `_config` holds only `{ ownerEntityId }`. + - `timezone` is removed from `ConfigContent` and the `_config@1` schema, from every adapter's `open()` options, from `stack.timezone` and `StackRecordAdapter` and every adapter that exposed it, and from the discovery response (`DiscoveryResponse` and the discovery fixtures; `discovery-omits-absent-timezone` is removed). + - `StackIdentity` and `identityOf()` are removed: `ConfigContent` is what an adapter holds, and `newStoreSeed()` stores the one it is given whole. + +### Patch Changes + +- Updated dependencies [[`f1985fd`](https://github.com/haverstack/core/commit/f1985fdf6af7308c8f6f49e44ae5d06e911177df), [`c4ed857`](https://github.com/haverstack/core/commit/c4ed857a27ee0faea99b425afded4e4bae70e389), [`e0475d2`](https://github.com/haverstack/core/commit/e0475d2fdd09581310d819d3d2b5effe4191603c), [`b02e69c`](https://github.com/haverstack/core/commit/b02e69c4675e7397d2fca76c314261a9744053bf), [`7f3d108`](https://github.com/haverstack/core/commit/7f3d108100dbb7a358fdc8d1bb6e3edb2455ec45), [`2169cff`](https://github.com/haverstack/core/commit/2169cff10f9c30bc44966c8ce90f5394cf50620d)]: + - @haverstack/core@0.44.0 + - @haverstack/wire-types@0.43.0 + ## 0.42.0 ### Minor Changes diff --git a/packages/adapter-api/package.json b/packages/adapter-api/package.json index 321ec883..bd56744f 100644 --- a/packages/adapter-api/package.json +++ b/packages/adapter-api/package.json @@ -1,6 +1,6 @@ { "name": "@haverstack/adapter-api", - "version": "0.42.0", + "version": "0.43.0", "description": "Remote server adapter for Haverstack", "type": "module", "exports": { diff --git a/packages/adapter-conformance/CHANGELOG.md b/packages/adapter-conformance/CHANGELOG.md index f447aed3..32d7267b 100644 --- a/packages/adapter-conformance/CHANGELOG.md +++ b/packages/adapter-conformance/CHANGELOG.md @@ -1,5 +1,27 @@ # @haverstack/adapter-conformance +## 0.13.0 + +### Minor Changes + +- [#470](https://github.com/haverstack/core/pull/470) [`b02e69c`](https://github.com/haverstack/core/commit/b02e69c4675e7397d2fca76c314261a9744053bf) Thanks [@cuibonobo](https://github.com/cuibonobo)! - A stack can be copied whole between adapters, authorship and history included. + - `copyStack(from, create)` in `@haverstack/core/adapter` copies every Record, soft-deleted and unlisted ones too, with its versions and journal, plus every Type and every blob, into a new store `create` makes from the source's `_config` record and its history, and returns it open. `_config` travels as every Record does. Both ends must list their blobs, and the target must hold nothing yet, so `APIAdapter` cannot yet be copied from. Copying into a `LocalAdapter` store is an export; copying out of one is an import. + - It writes through the new optional `StackRecordAdapter.importRecord(record, { versions, journal })`, which every local adapter implements and `APIAdapter` does not. + - `StackIdentity`, `CreateStore`, `StoreSeed`, `newStoreSeed()` and `identityOf()` are exported beside it. Every adapter that creates stores takes a `seed` in place of `ownerEntityId` and `timezone`: the `_config` record, with its history, a new store is created holding. A seed only creates: storage already holding a store refuses it, and `NativeSQLiteRecordAdapter`/`LocalAdapter` take no `create` beside one. `MemoryAdapter` now holds a real `_config` record. + - Every SQLite store names its layout in a one-row `format` table, and opening one in another layout throws the new `FormatMismatchError` (from `@haverstack/core/adapter`). A new store is written whole, tables included, in one transaction — a table of the same name already in the database fails the create — and a failed `NativeSQLiteRecordAdapter.open()` removes a file it created. + - `OwnerMismatchError` reads ` is owned by "X", not "Y"`, and `copyStack()` throws it too. + - `saveVersion()` is removed from the adapter contract: `importRecord()` is the one standalone history write. + - `@haverstack/adapter-conformance` checks `importRecord()` in the record suite and adds `runCopyConformance()`, which holds a full adapter to both halves of a copy. + +### Patch Changes + +- [#477](https://github.com/haverstack/core/pull/477) [`2169cff`](https://github.com/haverstack/core/commit/2169cff10f9c30bc44966c8ce90f5394cf50620d) Thanks [@cuibonobo](https://github.com/cuibonobo)! - A time value carries what it means: a `date`'s form says whether it is a moment, a calendar day or a wall-clock reading (see docs/spec/data-model.md § Types). Nothing reads a stack-wide timezone, so `_config` holds only `{ ownerEntityId }`. + - `timezone` is removed from `ConfigContent` and the `_config@1` schema, from every adapter's `open()` options, from `stack.timezone` and `StackRecordAdapter` and every adapter that exposed it, and from the discovery response (`DiscoveryResponse` and the discovery fixtures; `discovery-omits-absent-timezone` is removed). + - `StackIdentity` and `identityOf()` are removed: `ConfigContent` is what an adapter holds, and `newStoreSeed()` stores the one it is given whole. + +- Updated dependencies [[`f1985fd`](https://github.com/haverstack/core/commit/f1985fdf6af7308c8f6f49e44ae5d06e911177df), [`c4ed857`](https://github.com/haverstack/core/commit/c4ed857a27ee0faea99b425afded4e4bae70e389), [`e0475d2`](https://github.com/haverstack/core/commit/e0475d2fdd09581310d819d3d2b5effe4191603c), [`b02e69c`](https://github.com/haverstack/core/commit/b02e69c4675e7397d2fca76c314261a9744053bf), [`7f3d108`](https://github.com/haverstack/core/commit/7f3d108100dbb7a358fdc8d1bb6e3edb2455ec45), [`2169cff`](https://github.com/haverstack/core/commit/2169cff10f9c30bc44966c8ce90f5394cf50620d)]: + - @haverstack/core@0.44.0 + ## 0.12.0 ### Minor Changes diff --git a/packages/adapter-conformance/package.json b/packages/adapter-conformance/package.json index 0698c733..616c21b5 100644 --- a/packages/adapter-conformance/package.json +++ b/packages/adapter-conformance/package.json @@ -1,6 +1,6 @@ { "name": "@haverstack/adapter-conformance", - "version": "0.12.0", + "version": "0.13.0", "description": "Runnable conformance suite for StackRecordAdapter/StackBlobAdapter implementers — the invariants docs/spec/adapters.md documents, as tests you point at your own adapter", "type": "module", "exports": { diff --git a/packages/adapter-local/CHANGELOG.md b/packages/adapter-local/CHANGELOG.md index a68ddd30..021414e5 100644 --- a/packages/adapter-local/CHANGELOG.md +++ b/packages/adapter-local/CHANGELOG.md @@ -1,5 +1,29 @@ # @haverstack/adapter-local +## 0.43.0 + +### Minor Changes + +- [#470](https://github.com/haverstack/core/pull/470) [`b02e69c`](https://github.com/haverstack/core/commit/b02e69c4675e7397d2fca76c314261a9744053bf) Thanks [@cuibonobo](https://github.com/cuibonobo)! - A stack can be copied whole between adapters, authorship and history included. + - `copyStack(from, create)` in `@haverstack/core/adapter` copies every Record, soft-deleted and unlisted ones too, with its versions and journal, plus every Type and every blob, into a new store `create` makes from the source's `_config` record and its history, and returns it open. `_config` travels as every Record does. Both ends must list their blobs, and the target must hold nothing yet, so `APIAdapter` cannot yet be copied from. Copying into a `LocalAdapter` store is an export; copying out of one is an import. + - It writes through the new optional `StackRecordAdapter.importRecord(record, { versions, journal })`, which every local adapter implements and `APIAdapter` does not. + - `StackIdentity`, `CreateStore`, `StoreSeed`, `newStoreSeed()` and `identityOf()` are exported beside it. Every adapter that creates stores takes a `seed` in place of `ownerEntityId` and `timezone`: the `_config` record, with its history, a new store is created holding. A seed only creates: storage already holding a store refuses it, and `NativeSQLiteRecordAdapter`/`LocalAdapter` take no `create` beside one. `MemoryAdapter` now holds a real `_config` record. + - Every SQLite store names its layout in a one-row `format` table, and opening one in another layout throws the new `FormatMismatchError` (from `@haverstack/core/adapter`). A new store is written whole, tables included, in one transaction — a table of the same name already in the database fails the create — and a failed `NativeSQLiteRecordAdapter.open()` removes a file it created. + - `OwnerMismatchError` reads ` is owned by "X", not "Y"`, and `copyStack()` throws it too. + - `saveVersion()` is removed from the adapter contract: `importRecord()` is the one standalone history write. + - `@haverstack/adapter-conformance` checks `importRecord()` in the record suite and adds `runCopyConformance()`, which holds a full adapter to both halves of a copy. + +- [#477](https://github.com/haverstack/core/pull/477) [`2169cff`](https://github.com/haverstack/core/commit/2169cff10f9c30bc44966c8ce90f5394cf50620d) Thanks [@cuibonobo](https://github.com/cuibonobo)! - A time value carries what it means: a `date`'s form says whether it is a moment, a calendar day or a wall-clock reading (see docs/spec/data-model.md § Types). Nothing reads a stack-wide timezone, so `_config` holds only `{ ownerEntityId }`. + - `timezone` is removed from `ConfigContent` and the `_config@1` schema, from every adapter's `open()` options, from `stack.timezone` and `StackRecordAdapter` and every adapter that exposed it, and from the discovery response (`DiscoveryResponse` and the discovery fixtures; `discovery-omits-absent-timezone` is removed). + - `StackIdentity` and `identityOf()` are removed: `ConfigContent` is what an adapter holds, and `newStoreSeed()` stores the one it is given whole. + +### Patch Changes + +- Updated dependencies [[`f1985fd`](https://github.com/haverstack/core/commit/f1985fdf6af7308c8f6f49e44ae5d06e911177df), [`c4ed857`](https://github.com/haverstack/core/commit/c4ed857a27ee0faea99b425afded4e4bae70e389), [`e0475d2`](https://github.com/haverstack/core/commit/e0475d2fdd09581310d819d3d2b5effe4191603c), [`b02e69c`](https://github.com/haverstack/core/commit/b02e69c4675e7397d2fca76c314261a9744053bf), [`7f3d108`](https://github.com/haverstack/core/commit/7f3d108100dbb7a358fdc8d1bb6e3edb2455ec45), [`2169cff`](https://github.com/haverstack/core/commit/2169cff10f9c30bc44966c8ce90f5394cf50620d)]: + - @haverstack/blob-adapter-disk@0.42.0 + - @haverstack/core@0.44.0 + - @haverstack/record-adapter-sqlite@0.36.0 + ## 0.42.0 ### Minor Changes diff --git a/packages/adapter-local/package.json b/packages/adapter-local/package.json index c2ab3c9b..8e542ff6 100644 --- a/packages/adapter-local/package.json +++ b/packages/adapter-local/package.json @@ -1,6 +1,6 @@ { "name": "@haverstack/adapter-local", - "version": "0.42.0", + "version": "0.43.0", "description": "Local (SQLite + disk) stack adapter for Haverstack", "type": "module", "engines": { diff --git a/packages/blob-adapter-disk/CHANGELOG.md b/packages/blob-adapter-disk/CHANGELOG.md index 93f9c33e..ad7c716f 100644 --- a/packages/blob-adapter-disk/CHANGELOG.md +++ b/packages/blob-adapter-disk/CHANGELOG.md @@ -1,5 +1,16 @@ # @haverstack/blob-adapter-disk +## 0.42.0 + +### Minor Changes + +- Released for a breaking change in `@haverstack/core`. + +### Patch Changes + +- Updated dependencies [[`f1985fd`](https://github.com/haverstack/core/commit/f1985fdf6af7308c8f6f49e44ae5d06e911177df), [`c4ed857`](https://github.com/haverstack/core/commit/c4ed857a27ee0faea99b425afded4e4bae70e389), [`e0475d2`](https://github.com/haverstack/core/commit/e0475d2fdd09581310d819d3d2b5effe4191603c), [`b02e69c`](https://github.com/haverstack/core/commit/b02e69c4675e7397d2fca76c314261a9744053bf), [`7f3d108`](https://github.com/haverstack/core/commit/7f3d108100dbb7a358fdc8d1bb6e3edb2455ec45), [`2169cff`](https://github.com/haverstack/core/commit/2169cff10f9c30bc44966c8ce90f5394cf50620d)]: + - @haverstack/core@0.44.0 + ## 0.41.0 ### Minor Changes diff --git a/packages/blob-adapter-disk/package.json b/packages/blob-adapter-disk/package.json index 78dc53ff..4d6123f4 100644 --- a/packages/blob-adapter-disk/package.json +++ b/packages/blob-adapter-disk/package.json @@ -1,6 +1,6 @@ { "name": "@haverstack/blob-adapter-disk", - "version": "0.41.0", + "version": "0.42.0", "description": "Disk blob adapter for Haverstack", "type": "module", "exports": { diff --git a/packages/blob-adapter-s3/CHANGELOG.md b/packages/blob-adapter-s3/CHANGELOG.md index 68661088..ba3777ed 100644 --- a/packages/blob-adapter-s3/CHANGELOG.md +++ b/packages/blob-adapter-s3/CHANGELOG.md @@ -1,5 +1,16 @@ # @haverstack/blob-adapter-s3 +## 0.30.0 + +### Minor Changes + +- Released for a breaking change in `@haverstack/core`. + +### Patch Changes + +- Updated dependencies [[`f1985fd`](https://github.com/haverstack/core/commit/f1985fdf6af7308c8f6f49e44ae5d06e911177df), [`c4ed857`](https://github.com/haverstack/core/commit/c4ed857a27ee0faea99b425afded4e4bae70e389), [`e0475d2`](https://github.com/haverstack/core/commit/e0475d2fdd09581310d819d3d2b5effe4191603c), [`b02e69c`](https://github.com/haverstack/core/commit/b02e69c4675e7397d2fca76c314261a9744053bf), [`7f3d108`](https://github.com/haverstack/core/commit/7f3d108100dbb7a358fdc8d1bb6e3edb2455ec45), [`2169cff`](https://github.com/haverstack/core/commit/2169cff10f9c30bc44966c8ce90f5394cf50620d)]: + - @haverstack/core@0.44.0 + ## 0.29.0 ### Minor Changes diff --git a/packages/blob-adapter-s3/package.json b/packages/blob-adapter-s3/package.json index 57ff456e..70b24707 100644 --- a/packages/blob-adapter-s3/package.json +++ b/packages/blob-adapter-s3/package.json @@ -1,6 +1,6 @@ { "name": "@haverstack/blob-adapter-s3", - "version": "0.29.0", + "version": "0.30.0", "description": "S3 (and S3-compatible) blob adapter for Haverstack", "type": "module", "exports": { diff --git a/packages/commons/CHANGELOG.md b/packages/commons/CHANGELOG.md index c70599f0..1307c287 100644 --- a/packages/commons/CHANGELOG.md +++ b/packages/commons/CHANGELOG.md @@ -1,5 +1,16 @@ # @haverstack/commons +## 0.39.0 + +### Minor Changes + +- Released for a breaking change in `@haverstack/core`. + +### Patch Changes + +- Updated dependencies [[`f1985fd`](https://github.com/haverstack/core/commit/f1985fdf6af7308c8f6f49e44ae5d06e911177df), [`c4ed857`](https://github.com/haverstack/core/commit/c4ed857a27ee0faea99b425afded4e4bae70e389), [`e0475d2`](https://github.com/haverstack/core/commit/e0475d2fdd09581310d819d3d2b5effe4191603c), [`b02e69c`](https://github.com/haverstack/core/commit/b02e69c4675e7397d2fca76c314261a9744053bf), [`7f3d108`](https://github.com/haverstack/core/commit/7f3d108100dbb7a358fdc8d1bb6e3edb2455ec45), [`2169cff`](https://github.com/haverstack/core/commit/2169cff10f9c30bc44966c8ce90f5394cf50620d)]: + - @haverstack/core@0.44.0 + ## 0.38.0 ### Minor Changes diff --git a/packages/commons/package.json b/packages/commons/package.json index 2f0ddc65..cc50b74d 100644 --- a/packages/commons/package.json +++ b/packages/commons/package.json @@ -1,6 +1,6 @@ { "name": "@haverstack/commons", - "version": "0.38.0", + "version": "0.39.0", "description": "Canonical Schema Commons type definitions for Haverstack — register commons types exactly as written", "type": "module", "exports": { diff --git a/packages/conformance-fixtures/CHANGELOG.md b/packages/conformance-fixtures/CHANGELOG.md index aceaca6e..80cffe00 100644 --- a/packages/conformance-fixtures/CHANGELOG.md +++ b/packages/conformance-fixtures/CHANGELOG.md @@ -1,5 +1,33 @@ # @haverstack/conformance-fixtures +## 0.38.0 + +### Minor Changes + +- [#481](https://github.com/haverstack/core/pull/481) [`c4ed857`](https://github.com/haverstack/core/commit/c4ed857a27ee0faea99b425afded4e4bae70e389) Thanks [@cuibonobo](https://github.com/cuibonobo)! - Every immutable field follows one rule. `_config.ownerEntityId`, the `did`/`appId` bindings and `_attachment`'s `fileId`, `mimeType` and `size` are declared in one table and checked on `patchContent()`, `restoreVersion()` and `commitMigration()` alike; a migration is asked over the family the record leaves. + - Changing or clearing an immutable field throws `StackConflictError` (`409 conflict`) with the message `Cannot change .: it is immutable once set.` Bindings and attachment fields previously threw `StackValidationError` (422). + - A new `_attachment` record whose `mimeType` conflicts with the one established for its `fileId` throws `StackConflictError` (`409 conflict`) instead of `StackValidationError` (422), like a second claim on a DID binding. + - Restating a stored value is no change: a patch that sends an `_attachment` record's current `mimeType` is accepted. + - Every content write — create, patch, restore and migrate — asks the same claim checks: binding uniqueness, and `mimeType` establishment for a record entering the `_attachment` family. `restoreVersion()` previously skipped attachment fields, binding uniqueness and `mimeType` establishment. + - A write that would change several immutable fields is refused naming the first. + - Fixtures: `error-validation-attachment-mimetype-conflict-on-create` is renamed `error-conflict-attachment-mimetype-on-create` and answers 409; `error-validation-attachment-mimetype-immutable-on-update` is replaced by `error-conflict-attachment-mimetype-change`; `error-conflict-config-owner-change` carries the shared message. + +- [#470](https://github.com/haverstack/core/pull/470) [`e0475d2`](https://github.com/haverstack/core/commit/e0475d2fdd09581310d819d3d2b5effe4191603c) Thanks [@cuibonobo](https://github.com/cuibonobo)! - The stack owner has one name wherever a field can only hold the owner: `ownerEntityId`. + - `_config`'s content is `{ ownerEntityId, timezone }`, and `ConfigContent.entityId` is `ConfigContent.ownerEntityId`. + - The discovery response (`GET /.well-known/stack`) carries `ownerEntityId` in place of `entityId`, in `DiscoveryResponse` and the discovery fixtures. The `_config` ownership-conflict fixture is `error-conflict-config-owner-change`. + - Fields that may hold any entity, such as a relationship target or a grantee, keep `entityId`. + +- [#480](https://github.com/haverstack/core/pull/480) [`35224ae`](https://github.com/haverstack/core/commit/35224aef6c30c7a8d19425082b385b610f7ac453) Thanks [@cuibonobo](https://github.com/cuibonobo)! - The soft `DELETE` responses in `delete-record-soft` and `change-feed-deleted-frame-is-not-terminal` now carry the tombstone projection — `content: {}`, no authorship fields — as `docs/spec/versioning.md § The tombstone is literal` requires. A server built to the old bodies leaked the content a soft delete removes. + +- [#477](https://github.com/haverstack/core/pull/477) [`2169cff`](https://github.com/haverstack/core/commit/2169cff10f9c30bc44966c8ce90f5394cf50620d) Thanks [@cuibonobo](https://github.com/cuibonobo)! - A time value carries what it means: a `date`'s form says whether it is a moment, a calendar day or a wall-clock reading (see docs/spec/data-model.md § Types). Nothing reads a stack-wide timezone, so `_config` holds only `{ ownerEntityId }`. + - `timezone` is removed from `ConfigContent` and the `_config@1` schema, from every adapter's `open()` options, from `stack.timezone` and `StackRecordAdapter` and every adapter that exposed it, and from the discovery response (`DiscoveryResponse` and the discovery fixtures; `discovery-omits-absent-timezone` is removed). + - `StackIdentity` and `identityOf()` are removed: `ConfigContent` is what an adapter holds, and `newStoreSeed()` stores the one it is given whole. + +### Patch Changes + +- Updated dependencies [[`e0475d2`](https://github.com/haverstack/core/commit/e0475d2fdd09581310d819d3d2b5effe4191603c), [`2169cff`](https://github.com/haverstack/core/commit/2169cff10f9c30bc44966c8ce90f5394cf50620d)]: + - @haverstack/wire-types@0.43.0 + ## 0.37.0 ### Minor Changes diff --git a/packages/conformance-fixtures/package.json b/packages/conformance-fixtures/package.json index fafc0a5c..6ee1f943 100644 --- a/packages/conformance-fixtures/package.json +++ b/packages/conformance-fixtures/package.json @@ -1,6 +1,6 @@ { "name": "@haverstack/conformance-fixtures", - "version": "0.37.0", + "version": "0.38.0", "description": "Request/response fixtures for the Stack API wire protocol, shared between adapter-api and server implementations", "type": "module", "exports": { diff --git a/packages/core/CHANGELOG.md b/packages/core/CHANGELOG.md index 01d295e1..2e9aa14b 100644 --- a/packages/core/CHANGELOG.md +++ b/packages/core/CHANGELOG.md @@ -1,5 +1,42 @@ # @haverstack/core +## 0.44.0 + +### Minor Changes + +- [#478](https://github.com/haverstack/core/pull/478) [`f1985fd`](https://github.com/haverstack/core/commit/f1985fdf6af7308c8f6f49e44ae5d06e911177df) Thanks [@cuibonobo](https://github.com/cuibonobo)! - Every install apply names the plan it approves. `installApp(manifest, { did, fingerprint })` replaces `installApp(plan)`: it plans the manifest again for `did` and refuses with `StackConflictError` unless the result is the plan whose `fingerprint` it was given, so a server that shows the owner a plan in one request and applies it in another checks the approval exactly as an in-process caller passing `plan.fingerprint` does. `InstallPlan` carries that `fingerprint`: a SHA-256 over the plan the owner sees, in canonical form — schemas by `schemaHash`, every list as a set — with no Record's `version` in it, so neither a reordering store nor an edit no plan shows makes an approval stale. A list of requests is held to one rule wherever it is written — a manifest or an `_install` Record: each request a grant `grantType()` would accept, each family requested once, and an `_install`'s `defines` listing each version once. An action list is a set written without repeats: `grantType()`, a `_grant` write, a manifest's requests and an `_install` write all refuse an action named twice with `StackValidationError`, a stored list still read as a set. A manifest's refusals are reported together, each at its path in the manifest. `InstallAppOptions` is exported from `@haverstack/core`. + +- [#481](https://github.com/haverstack/core/pull/481) [`c4ed857`](https://github.com/haverstack/core/commit/c4ed857a27ee0faea99b425afded4e4bae70e389) Thanks [@cuibonobo](https://github.com/cuibonobo)! - Every immutable field follows one rule. `_config.ownerEntityId`, the `did`/`appId` bindings and `_attachment`'s `fileId`, `mimeType` and `size` are declared in one table and checked on `patchContent()`, `restoreVersion()` and `commitMigration()` alike; a migration is asked over the family the record leaves. + - Changing or clearing an immutable field throws `StackConflictError` (`409 conflict`) with the message `Cannot change .: it is immutable once set.` Bindings and attachment fields previously threw `StackValidationError` (422). + - A new `_attachment` record whose `mimeType` conflicts with the one established for its `fileId` throws `StackConflictError` (`409 conflict`) instead of `StackValidationError` (422), like a second claim on a DID binding. + - Restating a stored value is no change: a patch that sends an `_attachment` record's current `mimeType` is accepted. + - Every content write — create, patch, restore and migrate — asks the same claim checks: binding uniqueness, and `mimeType` establishment for a record entering the `_attachment` family. `restoreVersion()` previously skipped attachment fields, binding uniqueness and `mimeType` establishment. + - A write that would change several immutable fields is refused naming the first. + - Fixtures: `error-validation-attachment-mimetype-conflict-on-create` is renamed `error-conflict-attachment-mimetype-on-create` and answers 409; `error-validation-attachment-mimetype-immutable-on-update` is replaced by `error-conflict-attachment-mimetype-change`; `error-conflict-config-owner-change` carries the shared message. + +- [#470](https://github.com/haverstack/core/pull/470) [`e0475d2`](https://github.com/haverstack/core/commit/e0475d2fdd09581310d819d3d2b5effe4191603c) Thanks [@cuibonobo](https://github.com/cuibonobo)! - The stack owner has one name wherever a field can only hold the owner: `ownerEntityId`. + - `_config`'s content is `{ ownerEntityId, timezone }`, and `ConfigContent.entityId` is `ConfigContent.ownerEntityId`. + - The discovery response (`GET /.well-known/stack`) carries `ownerEntityId` in place of `entityId`, in `DiscoveryResponse` and the discovery fixtures. The `_config` ownership-conflict fixture is `error-conflict-config-owner-change`. + - Fields that may hold any entity, such as a relationship target or a grantee, keep `entityId`. + +- [#470](https://github.com/haverstack/core/pull/470) [`b02e69c`](https://github.com/haverstack/core/commit/b02e69c4675e7397d2fca76c314261a9744053bf) Thanks [@cuibonobo](https://github.com/cuibonobo)! - A stack can be copied whole between adapters, authorship and history included. + - `copyStack(from, create)` in `@haverstack/core/adapter` copies every Record, soft-deleted and unlisted ones too, with its versions and journal, plus every Type and every blob, into a new store `create` makes from the source's `_config` record and its history, and returns it open. `_config` travels as every Record does. Both ends must list their blobs, and the target must hold nothing yet, so `APIAdapter` cannot yet be copied from. Copying into a `LocalAdapter` store is an export; copying out of one is an import. + - It writes through the new optional `StackRecordAdapter.importRecord(record, { versions, journal })`, which every local adapter implements and `APIAdapter` does not. + - `StackIdentity`, `CreateStore`, `StoreSeed`, `newStoreSeed()` and `identityOf()` are exported beside it. Every adapter that creates stores takes a `seed` in place of `ownerEntityId` and `timezone`: the `_config` record, with its history, a new store is created holding. A seed only creates: storage already holding a store refuses it, and `NativeSQLiteRecordAdapter`/`LocalAdapter` take no `create` beside one. `MemoryAdapter` now holds a real `_config` record. + - Every SQLite store names its layout in a one-row `format` table, and opening one in another layout throws the new `FormatMismatchError` (from `@haverstack/core/adapter`). A new store is written whole, tables included, in one transaction — a table of the same name already in the database fails the create — and a failed `NativeSQLiteRecordAdapter.open()` removes a file it created. + - `OwnerMismatchError` reads ` is owned by "X", not "Y"`, and `copyStack()` throws it too. + - `saveVersion()` is removed from the adapter contract: `importRecord()` is the one standalone history write. + - `@haverstack/adapter-conformance` checks `importRecord()` in the record suite and adds `runCopyConformance()`, which holds a full adapter to both halves of a copy. + +- [#468](https://github.com/haverstack/core/pull/468) [`7f3d108`](https://github.com/haverstack/core/commit/7f3d108100dbb7a358fdc8d1bb6e3edb2455ec45) Thanks [@cuibonobo](https://github.com/cuibonobo)! - Authority is gated the same way whenever it is written. + - Resharing needs read on the Record: `editAccess()`, `setAccess()` and `setUnlisted()` refuse a creator who cannot read their Record, such as one removed from the roster that conveyed it, or a drop-box contributor. + - `permissions` and `unlisted` at `create()` pass the same gate, asked of the Record the create would make. + - A roster entry no longer counts on the principal's side of a delegated request, so a delegated app neither manages a `_group` nor creates one, even with its own DID on the roster. The owner's own software acting for a subject still can. + +- [#477](https://github.com/haverstack/core/pull/477) [`2169cff`](https://github.com/haverstack/core/commit/2169cff10f9c30bc44966c8ce90f5394cf50620d) Thanks [@cuibonobo](https://github.com/cuibonobo)! - A time value carries what it means: a `date`'s form says whether it is a moment, a calendar day or a wall-clock reading (see docs/spec/data-model.md § Types). Nothing reads a stack-wide timezone, so `_config` holds only `{ ownerEntityId }`. + - `timezone` is removed from `ConfigContent` and the `_config@1` schema, from every adapter's `open()` options, from `stack.timezone` and `StackRecordAdapter` and every adapter that exposed it, and from the discovery response (`DiscoveryResponse` and the discovery fixtures; `discovery-omits-absent-timezone` is removed). + - `StackIdentity` and `identityOf()` are removed: `ConfigContent` is what an adapter holds, and `newStoreSeed()` stores the one it is given whole. + ## 0.43.0 ### Minor Changes diff --git a/packages/core/package.json b/packages/core/package.json index 62d7ff7f..10ad1fa1 100644 --- a/packages/core/package.json +++ b/packages/core/package.json @@ -1,6 +1,6 @@ { "name": "@haverstack/core", - "version": "0.43.0", + "version": "0.44.0", "description": "Core library for Haverstack — portable personal data stack", "type": "module", "exports": { diff --git a/packages/record-adapter-do-sqlite/CHANGELOG.md b/packages/record-adapter-do-sqlite/CHANGELOG.md index 6f30f6f9..2b6751ad 100644 --- a/packages/record-adapter-do-sqlite/CHANGELOG.md +++ b/packages/record-adapter-do-sqlite/CHANGELOG.md @@ -1,5 +1,32 @@ # @haverstack/record-adapter-do-sqlite +## 0.29.0 + +### Minor Changes + +- [#470](https://github.com/haverstack/core/pull/470) [`e0475d2`](https://github.com/haverstack/core/commit/e0475d2fdd09581310d819d3d2b5effe4191603c) Thanks [@cuibonobo](https://github.com/cuibonobo)! - The stack owner has one name wherever a field can only hold the owner: `ownerEntityId`. + - `_config`'s content is `{ ownerEntityId, timezone }`, and `ConfigContent.entityId` is `ConfigContent.ownerEntityId`. + - The discovery response (`GET /.well-known/stack`) carries `ownerEntityId` in place of `entityId`, in `DiscoveryResponse` and the discovery fixtures. The `_config` ownership-conflict fixture is `error-conflict-config-owner-change`. + - Fields that may hold any entity, such as a relationship target or a grantee, keep `entityId`. + +- [#470](https://github.com/haverstack/core/pull/470) [`b02e69c`](https://github.com/haverstack/core/commit/b02e69c4675e7397d2fca76c314261a9744053bf) Thanks [@cuibonobo](https://github.com/cuibonobo)! - A stack can be copied whole between adapters, authorship and history included. + - `copyStack(from, create)` in `@haverstack/core/adapter` copies every Record, soft-deleted and unlisted ones too, with its versions and journal, plus every Type and every blob, into a new store `create` makes from the source's `_config` record and its history, and returns it open. `_config` travels as every Record does. Both ends must list their blobs, and the target must hold nothing yet, so `APIAdapter` cannot yet be copied from. Copying into a `LocalAdapter` store is an export; copying out of one is an import. + - It writes through the new optional `StackRecordAdapter.importRecord(record, { versions, journal })`, which every local adapter implements and `APIAdapter` does not. + - `StackIdentity`, `CreateStore`, `StoreSeed`, `newStoreSeed()` and `identityOf()` are exported beside it. Every adapter that creates stores takes a `seed` in place of `ownerEntityId` and `timezone`: the `_config` record, with its history, a new store is created holding. A seed only creates: storage already holding a store refuses it, and `NativeSQLiteRecordAdapter`/`LocalAdapter` take no `create` beside one. `MemoryAdapter` now holds a real `_config` record. + - Every SQLite store names its layout in a one-row `format` table, and opening one in another layout throws the new `FormatMismatchError` (from `@haverstack/core/adapter`). A new store is written whole, tables included, in one transaction — a table of the same name already in the database fails the create — and a failed `NativeSQLiteRecordAdapter.open()` removes a file it created. + - `OwnerMismatchError` reads ` is owned by "X", not "Y"`, and `copyStack()` throws it too. + - `saveVersion()` is removed from the adapter contract: `importRecord()` is the one standalone history write. + - `@haverstack/adapter-conformance` checks `importRecord()` in the record suite and adds `runCopyConformance()`, which holds a full adapter to both halves of a copy. + +- [#477](https://github.com/haverstack/core/pull/477) [`2169cff`](https://github.com/haverstack/core/commit/2169cff10f9c30bc44966c8ce90f5394cf50620d) Thanks [@cuibonobo](https://github.com/cuibonobo)! - A time value carries what it means: a `date`'s form says whether it is a moment, a calendar day or a wall-clock reading (see docs/spec/data-model.md § Types). Nothing reads a stack-wide timezone, so `_config` holds only `{ ownerEntityId }`. + - `timezone` is removed from `ConfigContent` and the `_config@1` schema, from every adapter's `open()` options, from `stack.timezone` and `StackRecordAdapter` and every adapter that exposed it, and from the discovery response (`DiscoveryResponse` and the discovery fixtures; `discovery-omits-absent-timezone` is removed). + - `StackIdentity` and `identityOf()` are removed: `ConfigContent` is what an adapter holds, and `newStoreSeed()` stores the one it is given whole. + +### Patch Changes + +- Updated dependencies [[`f1985fd`](https://github.com/haverstack/core/commit/f1985fdf6af7308c8f6f49e44ae5d06e911177df), [`c4ed857`](https://github.com/haverstack/core/commit/c4ed857a27ee0faea99b425afded4e4bae70e389), [`e0475d2`](https://github.com/haverstack/core/commit/e0475d2fdd09581310d819d3d2b5effe4191603c), [`b02e69c`](https://github.com/haverstack/core/commit/b02e69c4675e7397d2fca76c314261a9744053bf), [`7f3d108`](https://github.com/haverstack/core/commit/7f3d108100dbb7a358fdc8d1bb6e3edb2455ec45), [`2169cff`](https://github.com/haverstack/core/commit/2169cff10f9c30bc44966c8ce90f5394cf50620d)]: + - @haverstack/core@0.44.0 + ## 0.28.0 ### Minor Changes diff --git a/packages/record-adapter-do-sqlite/package.json b/packages/record-adapter-do-sqlite/package.json index d0ffdeab..28e7dfa2 100644 --- a/packages/record-adapter-do-sqlite/package.json +++ b/packages/record-adapter-do-sqlite/package.json @@ -1,6 +1,6 @@ { "name": "@haverstack/record-adapter-do-sqlite", - "version": "0.28.0", + "version": "0.29.0", "description": "Cloudflare Durable Objects (SQLite storage) StackRecordAdapter for Haverstack — Workers, FTS5, single-writer by construction", "type": "module", "exports": { diff --git a/packages/record-adapter-sqlite/CHANGELOG.md b/packages/record-adapter-sqlite/CHANGELOG.md index c5834515..ba712677 100644 --- a/packages/record-adapter-sqlite/CHANGELOG.md +++ b/packages/record-adapter-sqlite/CHANGELOG.md @@ -1,5 +1,32 @@ # @haverstack/record-adapter-sqlite +## 0.36.0 + +### Minor Changes + +- [#470](https://github.com/haverstack/core/pull/470) [`e0475d2`](https://github.com/haverstack/core/commit/e0475d2fdd09581310d819d3d2b5effe4191603c) Thanks [@cuibonobo](https://github.com/cuibonobo)! - The stack owner has one name wherever a field can only hold the owner: `ownerEntityId`. + - `_config`'s content is `{ ownerEntityId, timezone }`, and `ConfigContent.entityId` is `ConfigContent.ownerEntityId`. + - The discovery response (`GET /.well-known/stack`) carries `ownerEntityId` in place of `entityId`, in `DiscoveryResponse` and the discovery fixtures. The `_config` ownership-conflict fixture is `error-conflict-config-owner-change`. + - Fields that may hold any entity, such as a relationship target or a grantee, keep `entityId`. + +- [#470](https://github.com/haverstack/core/pull/470) [`b02e69c`](https://github.com/haverstack/core/commit/b02e69c4675e7397d2fca76c314261a9744053bf) Thanks [@cuibonobo](https://github.com/cuibonobo)! - A stack can be copied whole between adapters, authorship and history included. + - `copyStack(from, create)` in `@haverstack/core/adapter` copies every Record, soft-deleted and unlisted ones too, with its versions and journal, plus every Type and every blob, into a new store `create` makes from the source's `_config` record and its history, and returns it open. `_config` travels as every Record does. Both ends must list their blobs, and the target must hold nothing yet, so `APIAdapter` cannot yet be copied from. Copying into a `LocalAdapter` store is an export; copying out of one is an import. + - It writes through the new optional `StackRecordAdapter.importRecord(record, { versions, journal })`, which every local adapter implements and `APIAdapter` does not. + - `StackIdentity`, `CreateStore`, `StoreSeed`, `newStoreSeed()` and `identityOf()` are exported beside it. Every adapter that creates stores takes a `seed` in place of `ownerEntityId` and `timezone`: the `_config` record, with its history, a new store is created holding. A seed only creates: storage already holding a store refuses it, and `NativeSQLiteRecordAdapter`/`LocalAdapter` take no `create` beside one. `MemoryAdapter` now holds a real `_config` record. + - Every SQLite store names its layout in a one-row `format` table, and opening one in another layout throws the new `FormatMismatchError` (from `@haverstack/core/adapter`). A new store is written whole, tables included, in one transaction — a table of the same name already in the database fails the create — and a failed `NativeSQLiteRecordAdapter.open()` removes a file it created. + - `OwnerMismatchError` reads ` is owned by "X", not "Y"`, and `copyStack()` throws it too. + - `saveVersion()` is removed from the adapter contract: `importRecord()` is the one standalone history write. + - `@haverstack/adapter-conformance` checks `importRecord()` in the record suite and adds `runCopyConformance()`, which holds a full adapter to both halves of a copy. + +- [#477](https://github.com/haverstack/core/pull/477) [`2169cff`](https://github.com/haverstack/core/commit/2169cff10f9c30bc44966c8ce90f5394cf50620d) Thanks [@cuibonobo](https://github.com/cuibonobo)! - A time value carries what it means: a `date`'s form says whether it is a moment, a calendar day or a wall-clock reading (see docs/spec/data-model.md § Types). Nothing reads a stack-wide timezone, so `_config` holds only `{ ownerEntityId }`. + - `timezone` is removed from `ConfigContent` and the `_config@1` schema, from every adapter's `open()` options, from `stack.timezone` and `StackRecordAdapter` and every adapter that exposed it, and from the discovery response (`DiscoveryResponse` and the discovery fixtures; `discovery-omits-absent-timezone` is removed). + - `StackIdentity` and `identityOf()` are removed: `ConfigContent` is what an adapter holds, and `newStoreSeed()` stores the one it is given whole. + +### Patch Changes + +- Updated dependencies [[`f1985fd`](https://github.com/haverstack/core/commit/f1985fdf6af7308c8f6f49e44ae5d06e911177df), [`c4ed857`](https://github.com/haverstack/core/commit/c4ed857a27ee0faea99b425afded4e4bae70e389), [`e0475d2`](https://github.com/haverstack/core/commit/e0475d2fdd09581310d819d3d2b5effe4191603c), [`b02e69c`](https://github.com/haverstack/core/commit/b02e69c4675e7397d2fca76c314261a9744053bf), [`7f3d108`](https://github.com/haverstack/core/commit/7f3d108100dbb7a358fdc8d1bb6e3edb2455ec45), [`2169cff`](https://github.com/haverstack/core/commit/2169cff10f9c30bc44966c8ce90f5394cf50620d)]: + - @haverstack/core@0.44.0 + ## 0.35.0 ### Minor Changes diff --git a/packages/record-adapter-sqlite/package.json b/packages/record-adapter-sqlite/package.json index 08fb9cef..6a520a95 100644 --- a/packages/record-adapter-sqlite/package.json +++ b/packages/record-adapter-sqlite/package.json @@ -1,6 +1,6 @@ { "name": "@haverstack/record-adapter-sqlite", - "version": "0.35.0", + "version": "0.36.0", "description": "Native SQLite (node:sqlite) record adapter for Haverstack — Node's built-in engine, no native compilation", "type": "module", "engines": { diff --git a/packages/wire-types/CHANGELOG.md b/packages/wire-types/CHANGELOG.md index e1dc007e..ecb19a5c 100644 --- a/packages/wire-types/CHANGELOG.md +++ b/packages/wire-types/CHANGELOG.md @@ -1,5 +1,23 @@ # @haverstack/wire-types +## 0.43.0 + +### Minor Changes + +- [#470](https://github.com/haverstack/core/pull/470) [`e0475d2`](https://github.com/haverstack/core/commit/e0475d2fdd09581310d819d3d2b5effe4191603c) Thanks [@cuibonobo](https://github.com/cuibonobo)! - The stack owner has one name wherever a field can only hold the owner: `ownerEntityId`. + - `_config`'s content is `{ ownerEntityId, timezone }`, and `ConfigContent.entityId` is `ConfigContent.ownerEntityId`. + - The discovery response (`GET /.well-known/stack`) carries `ownerEntityId` in place of `entityId`, in `DiscoveryResponse` and the discovery fixtures. The `_config` ownership-conflict fixture is `error-conflict-config-owner-change`. + - Fields that may hold any entity, such as a relationship target or a grantee, keep `entityId`. + +- [#477](https://github.com/haverstack/core/pull/477) [`2169cff`](https://github.com/haverstack/core/commit/2169cff10f9c30bc44966c8ce90f5394cf50620d) Thanks [@cuibonobo](https://github.com/cuibonobo)! - A time value carries what it means: a `date`'s form says whether it is a moment, a calendar day or a wall-clock reading (see docs/spec/data-model.md § Types). Nothing reads a stack-wide timezone, so `_config` holds only `{ ownerEntityId }`. + - `timezone` is removed from `ConfigContent` and the `_config@1` schema, from every adapter's `open()` options, from `stack.timezone` and `StackRecordAdapter` and every adapter that exposed it, and from the discovery response (`DiscoveryResponse` and the discovery fixtures; `discovery-omits-absent-timezone` is removed). + - `StackIdentity` and `identityOf()` are removed: `ConfigContent` is what an adapter holds, and `newStoreSeed()` stores the one it is given whole. + +### Patch Changes + +- Updated dependencies [[`f1985fd`](https://github.com/haverstack/core/commit/f1985fdf6af7308c8f6f49e44ae5d06e911177df), [`c4ed857`](https://github.com/haverstack/core/commit/c4ed857a27ee0faea99b425afded4e4bae70e389), [`e0475d2`](https://github.com/haverstack/core/commit/e0475d2fdd09581310d819d3d2b5effe4191603c), [`b02e69c`](https://github.com/haverstack/core/commit/b02e69c4675e7397d2fca76c314261a9744053bf), [`7f3d108`](https://github.com/haverstack/core/commit/7f3d108100dbb7a358fdc8d1bb6e3edb2455ec45), [`2169cff`](https://github.com/haverstack/core/commit/2169cff10f9c30bc44966c8ce90f5394cf50620d)]: + - @haverstack/core@0.44.0 + ## 0.42.0 ### Minor Changes diff --git a/packages/wire-types/package.json b/packages/wire-types/package.json index f30d74e4..f470bb33 100644 --- a/packages/wire-types/package.json +++ b/packages/wire-types/package.json @@ -1,6 +1,6 @@ { "name": "@haverstack/wire-types", - "version": "0.42.0", + "version": "0.43.0", "description": "HTTP wire types and serialization for Haverstack", "type": "module", "exports": {