diff --git a/.changeset/early-beds-create.md b/.changeset/early-beds-create.md deleted file mode 100644 index 064435d..0000000 --- a/.changeset/early-beds-create.md +++ /dev/null @@ -1,5 +0,0 @@ ---- - ---- - - diff --git a/.changeset/encode-plain-struct.md b/.changeset/encode-plain-struct.md deleted file mode 100644 index 24be0a5..0000000 --- a/.changeset/encode-plain-struct.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"hyperfly": patch ---- - -A struct value must be an object tagged "[object Object]", class instances included, so a typed array, `Map`, `Set`, `Date` or boxed primitive fails with `type` as in Python and Rust. A `bytes` value may come from another realm. diff --git a/.changeset/http-api.md b/.changeset/http-api.md deleted file mode 100644 index 4f5d7d1..0000000 --- a/.changeset/http-api.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"hyperfly": minor ---- - -`NegotiateOptions.accept` is now `httpAccept`, `WellKnownResponse` is now `ArtifactResponse`, `FetchHandlerOptions` is now `RespondOptions`, and `onFallback` moves to `EncodeOptions` with `(error, "encoder-limit")`. JSON negotiations and `readBody` refusals carry a `reason` (`FallbackReason`, `RequestRefusal`), and `CodecRegistry` types its codecs. diff --git a/.changeset/http-json-fallback.md b/.changeset/http-json-fallback.md deleted file mode 100644 index bbbdaf1..0000000 --- a/.changeset/http-json-fallback.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"hyperfly": minor ---- - -JSON fallback preserves bytes as canonical padded base64 and decodes values using the first registered codec, with consistent request and response failures. Artifact loading reports unreadable responses and malformed JSON with the `artifact` error code. diff --git a/.changeset/http-robustness.md b/.changeset/http-robustness.md deleted file mode 100644 index 652f526..0000000 --- a/.changeset/http-robustness.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"hyperfly": patch ---- - -`respond` and `discovery` answer HEAD, 204, 205 and 304 without a body; HTTP helpers, deflate hooks and `serializeArtifact` throw coded `HyperflyError`s. `readBody` answers bad bodies with 400, 413 or 415 and rejects only invalid options, `validate: true` checks apply once, and `hyperfly/package.json` is exported. diff --git a/.changeset/inflate-any-size.md b/.changeset/inflate-any-size.md deleted file mode 100644 index a35c24f..0000000 --- a/.changeset/inflate-any-size.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"hyperfly": patch ---- - -Packed string columns of any size now decode in browsers and edge runtimes without node:zlib, matching node:zlib when `maxByteLength` is raised past 512 MiB. diff --git a/.changeset/ir-nesting-cap.md b/.changeset/ir-nesting-cap.md deleted file mode 100644 index 1724d2b..0000000 --- a/.changeset/ir-nesting-cap.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"hyperfly": patch ---- - -Schemas nested up to the 512-level artifact limit now compile on every entry point, and deeper schemas are rejected with code `ir` instead of exhausting the stack. diff --git a/.changeset/jsdoc-1-0.md b/.changeset/jsdoc-1-0.md deleted file mode 100644 index 1eae54b..0000000 --- a/.changeset/jsdoc-1-0.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"hyperfly": patch ---- - -Every public export now has JSDoc, including defaults, error codes and spec references. The README links the stability and security policies. diff --git a/.changeset/limits-rename.md b/.changeset/limits-rename.md deleted file mode 100644 index 5097519..0000000 --- a/.changeset/limits-rename.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"hyperfly": minor ---- - -`DecodeLimits` is renamed to `Limits`, since the same bounds apply to encoding and decoding. diff --git a/.changeset/node-22.md b/.changeset/node-22.md deleted file mode 100644 index f064849..0000000 --- a/.changeset/node-22.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"hyperfly": minor ---- - -Requires Node.js 22 or later. The `hyperfly`, `hyperfly/zod` and `hyperfly/http` entry points no longer support Node.js 18 or 20. diff --git a/.changeset/pre.json b/.changeset/pre.json deleted file mode 100644 index 23311bd..0000000 --- a/.changeset/pre.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "mode": "exit", - "tag": "alpha" -} diff --git a/.changeset/python-1-0-api.md b/.changeset/python-1-0-api.md deleted file mode 100644 index 57dacc6..0000000 --- a/.changeset/python-1-0-api.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"@hyperfly/python": patch ---- - -`Codec` is generic, `hyperfly.pydantic.compile` returns a `ModelCodec` that works anywhere a `Codec` does, and `PackHooks` and `validate_profile` are exported. `Codec(...)` now takes keyword arguments checked like `compile_ir`, and `train` raises `options` for invalid samples or thresholds. diff --git a/.changeset/python-annotated.md b/.changeset/python-annotated.md deleted file mode 100644 index 76fddb1..0000000 --- a/.changeset/python-annotated.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"@hyperfly/python": patch ---- - -Nested integer bounds follow field validation, so values changed by field validators encode safely; affected fingerprints change. Unvalidated defaults keep declared bounds and can raise `range`; unsupported schemas, recursive models and wire field names raise `UnsupportedSchemaError`. diff --git a/.changeset/python-http-parity.md b/.changeset/python-http-parity.md deleted file mode 100644 index 2f245c4..0000000 --- a/.changeset/python-http-parity.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"@hyperfly/python": patch ---- - -JSON bodies decoded under a codec are converted and checked against its schema. JSON fallback writes bytes at declared bytes positions and in plain containers as standard padded base64; `offer=""` suppresses the offer. diff --git a/.changeset/python-ir-values.md b/.changeset/python-ir-values.md deleted file mode 100644 index 6730c32..0000000 --- a/.changeset/python-ir-values.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"@hyperfly/python": patch ---- - -Integral floats such as `1.0` now encode in int fields and int literals as they do in TypeScript. Schemas nested up to the 512-level artifact limit compile, deeper ones raise code `ir` instead of hitting Python's recursion limit, and a profile must be JSON data. diff --git a/.changeset/python-json-bytes-validators.md b/.changeset/python-json-bytes-validators.md deleted file mode 100644 index a53fb70..0000000 --- a/.changeset/python-json-bytes-validators.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"@hyperfly/python": patch ---- - -HTTP JSON fallback now encodes declared bytes beneath field validators as standard padded base64, so binary payloads round trip reliably, including non-UTF-8 data. Custom serializers keep their existing output. diff --git a/.changeset/python-readme-1-0.md b/.changeset/python-readme-1-0.md deleted file mode 100644 index 110ca84..0000000 --- a/.changeset/python-readme-1-0.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"@hyperfly/python": patch ---- - -The README documents the pydantic type mapping and int bound rules, a raw IR example, the client helpers, JSON conversion under a codec and the public API. diff --git a/.changeset/python-zero-bit-arrays.md b/.changeset/python-zero-bit-arrays.md deleted file mode 100644 index f8ef46a..0000000 --- a/.changeset/python-zero-bit-arrays.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"@hyperfly/python": patch ---- - -Columnar bodies with arrays of empty fixed-length arrays now decode the same as in the TypeScript and Rust implementations. Python now accepts the bodies its own encoder writes and rejects truncated ones with `truncated`. diff --git a/.changeset/read-body-chunks.md b/.changeset/read-body-chunks.md deleted file mode 100644 index 7139b1d..0000000 --- a/.changeset/read-body-chunks.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"hyperfly": patch ---- - -`readBody` and `fetchArtifact` now read bodies correctly from streams that reuse one buffer across chunks. diff --git a/.changeset/rust-1-0-api.md b/.changeset/rust-1-0-api.md deleted file mode 100644 index 74a66bb..0000000 --- a/.changeset/rust-1-0-api.md +++ /dev/null @@ -1,4 +0,0 @@ ---- -"@hyperfly/rust": major ---- -`Codec::compile` takes a `CompileOptions` value, errors are read through `Error::code()` and `Error::message()`, and option structs and enums are `#[non_exhaustive]` so 1.x can extend them without breaking callers. diff --git a/.changeset/rust-encode-precedence.md b/.changeset/rust-encode-precedence.md deleted file mode 100644 index bc49974..0000000 --- a/.changeset/rust-encode-precedence.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"@hyperfly/rust": patch ---- - -When a columnar array has several invalid values, encoding now reports the first one in value order, matching the TypeScript and Python packages. diff --git a/.changeset/rust-grammar-render.md b/.changeset/rust-grammar-render.md deleted file mode 100644 index 7bc05eb..0000000 --- a/.changeset/rust-grammar-render.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"@hyperfly/rust": patch ---- - -Decoding grammar-coded string columns allocates less per value and runs faster. diff --git a/.changeset/rust-int-float.md b/.changeset/rust-int-float.md deleted file mode 100644 index d9926b6..0000000 --- a/.changeset/rust-int-float.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"@hyperfly/rust": minor ---- - -Integer fields and integer literals accept an integral `Value::Float` such as `1.0`, matching the TypeScript package. diff --git a/.changeset/rust-ir-nesting.md b/.changeset/rust-ir-nesting.md deleted file mode 100644 index fe29721..0000000 --- a/.changeset/rust-ir-nesting.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"@hyperfly/rust": patch ---- - -Compiling an IR whose artifact nests deeper than 512 levels fails with `ir` instead of risking a stack overflow, as the wire format requires. diff --git a/.changeset/small-islands-hammer.md b/.changeset/small-islands-hammer.md deleted file mode 100644 index 853d812..0000000 --- a/.changeset/small-islands-hammer.md +++ /dev/null @@ -1,3 +0,0 @@ ---- - ---- diff --git a/.changeset/stable-hyperfly.md b/.changeset/stable-hyperfly.md deleted file mode 100644 index 2659f16..0000000 --- a/.changeset/stable-hyperfly.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"hyperfly": major ---- - -First stable release of the TypeScript codec, Zod adapter (`hyperfly/zod`) and HTTP helpers (`hyperfly/http`). The public API and wire format stay compatible throughout 1.x per [STABILITY.md](https://github.com/eliahilse/hyperfly/blob/main/STABILITY.md). diff --git a/.changeset/stable-python.md b/.changeset/stable-python.md deleted file mode 100644 index 764d7a6..0000000 --- a/.changeset/stable-python.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"@hyperfly/python": major ---- - -First stable release of the Python codec, Pydantic adapter and HTTP helpers. The public API and wire format stay compatible throughout 1.x per [STABILITY.md](https://github.com/eliahilse/hyperfly/blob/main/STABILITY.md). diff --git a/.changeset/stable-rust.md b/.changeset/stable-rust.md deleted file mode 100644 index 746009e..0000000 --- a/.changeset/stable-rust.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"@hyperfly/rust": major ---- - -First stable release of `hyperfly-core`, the Rust codec for row and columnar encoding with optional trained profiles. The public API and wire format stay compatible throughout 1.x per [STABILITY.md](https://github.com/eliahilse/hyperfly/blob/main/STABILITY.md). diff --git a/.changeset/train-options-strict.md b/.changeset/train-options-strict.md deleted file mode 100644 index e027ad7..0000000 --- a/.changeset/train-options-strict.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"hyperfly": minor ---- - -`train` now rejects invalid `minOccurrences`, `maxEntries` and options values with a `HyperflyError` of code `options`, and clamps `minOccurrences` 0 to 1 and `maxEntries` above 16383 to 16383. diff --git a/bun.lock b/bun.lock index ee0aa84..23c58fe 100644 --- a/bun.lock +++ b/bun.lock @@ -70,7 +70,7 @@ }, "packages/hyperfly": { "name": "hyperfly", - "version": "1.0.0-alpha.1", + "version": "1.0.0", "devDependencies": { "@repo/eslint-config": "*", "@repo/typescript-config": "*", @@ -116,11 +116,11 @@ }, "python": { "name": "@hyperfly/python", - "version": "1.0.0-alpha.1", + "version": "1.0.0", }, "rust": { "name": "@hyperfly/rust", - "version": "0.1.1-alpha.0", + "version": "1.0.0", }, }, "packages": { diff --git a/packages/hyperfly/CHANGELOG.md b/packages/hyperfly/CHANGELOG.md index f3bf277..b84ecbc 100644 --- a/packages/hyperfly/CHANGELOG.md +++ b/packages/hyperfly/CHANGELOG.md @@ -1,5 +1,28 @@ # hyperfly +## 1.0.0 + +### Major Changes + +- 6880138: First stable release of the TypeScript codec, Zod adapter (`hyperfly/zod`) and HTTP helpers (`hyperfly/http`). The public API and wire format stay compatible throughout 1.x per [STABILITY.md](https://github.com/eliahilse/hyperfly/blob/main/STABILITY.md). + +### Minor Changes + +- 57ef0a3: `NegotiateOptions.accept` is now `httpAccept`, `WellKnownResponse` is now `ArtifactResponse`, `FetchHandlerOptions` is now `RespondOptions`, and `onFallback` moves to `EncodeOptions` with `(error, "encoder-limit")`. JSON negotiations and `readBody` refusals carry a `reason` (`FallbackReason`, `RequestRefusal`), and `CodecRegistry` types its codecs. +- 1508d69: JSON fallback preserves bytes as canonical padded base64 and decodes values using the first registered codec, with consistent request and response failures. Artifact loading reports unreadable responses and malformed JSON with the `artifact` error code. +- c9565d7: `DecodeLimits` is renamed to `Limits`, since the same bounds apply to encoding and decoding. +- f9863e0: Requires Node.js 22 or later. The `hyperfly`, `hyperfly/zod` and `hyperfly/http` entry points no longer support Node.js 18 or 20. +- fc9d2ca: `train` now rejects invalid `minOccurrences`, `maxEntries` and options values with a `HyperflyError` of code `options`, and clamps `minOccurrences` 0 to 1 and `maxEntries` above 16383 to 16383. + +### Patch Changes + +- 9a33ecb: A struct value must be an object tagged "[object Object]", class instances included, so a typed array, `Map`, `Set`, `Date` or boxed primitive fails with `type` as in Python and Rust. A `bytes` value may come from another realm. +- de7f289: `respond` and `discovery` answer HEAD, 204, 205 and 304 without a body; HTTP helpers, deflate hooks and `serializeArtifact` throw coded `HyperflyError`s. `readBody` answers bad bodies with 400, 413 or 415 and rejects only invalid options, `validate: true` checks apply once, and `hyperfly/package.json` is exported. +- ef98f2a: Packed string columns of any size now decode in browsers and edge runtimes without node:zlib, matching node:zlib when `maxByteLength` is raised past 512 MiB. +- fa55ea3: Schemas nested up to the 512-level artifact limit now compile on every entry point, and deeper schemas are rejected with code `ir` instead of exhausting the stack. +- ba9d30f: Every public export now has JSDoc, including defaults, error codes and spec references. The README links the stability and security policies. +- a11cc63: `readBody` and `fetchArtifact` now read bodies correctly from streams that reuse one buffer across chunks. + ## 1.0.0-alpha.1 ### Minor Changes diff --git a/packages/hyperfly/package.json b/packages/hyperfly/package.json index 1c240ff..702305f 100644 --- a/packages/hyperfly/package.json +++ b/packages/hyperfly/package.json @@ -1,6 +1,6 @@ { "name": "hyperfly", - "version": "1.0.0-alpha.1", + "version": "1.0.0", "description": "Binary compression for typed APIs. Schema-compiled codecs with a fingerprinted wire format and transparent JSON fallback.", "type": "module", "sideEffects": false, diff --git a/python/CHANGELOG.md b/python/CHANGELOG.md index 9bfea0d..5e5f95e 100644 --- a/python/CHANGELOG.md +++ b/python/CHANGELOG.md @@ -1,5 +1,21 @@ # @hyperfly/python +## 1.0.0 + +### Major Changes + +- 6880138: First stable release of the Python codec, Pydantic adapter and HTTP helpers. The public API and wire format stay compatible throughout 1.x per [STABILITY.md](https://github.com/eliahilse/hyperfly/blob/main/STABILITY.md). + +### Patch Changes + +- fd2998a: `Codec` is generic, `hyperfly.pydantic.compile` returns a `ModelCodec` that works anywhere a `Codec` does, and `PackHooks` and `validate_profile` are exported. `Codec(...)` now takes keyword arguments checked like `compile_ir`, and `train` raises `options` for invalid samples or thresholds. +- 99535ed: Nested integer bounds follow field validation, so values changed by field validators encode safely; affected fingerprints change. Unvalidated defaults keep declared bounds and can raise `range`; unsupported schemas, recursive models and wire field names raise `UnsupportedSchemaError`. +- 54eaaf4: JSON bodies decoded under a codec are converted and checked against its schema. JSON fallback writes bytes at declared bytes positions and in plain containers as standard padded base64; `offer=""` suppresses the offer. +- eb7c7f8: Integral floats such as `1.0` now encode in int fields and int literals as they do in TypeScript. Schemas nested up to the 512-level artifact limit compile, deeper ones raise code `ir` instead of hitting Python's recursion limit, and a profile must be JSON data. +- 13d0583: HTTP JSON fallback now encodes declared bytes beneath field validators as standard padded base64, so binary payloads round trip reliably, including non-UTF-8 data. Custom serializers keep their existing output. +- f41b658: The README documents the pydantic type mapping and int bound rules, a raw IR example, the client helpers, JSON conversion under a codec and the public API. +- 76d97f7: Columnar bodies with arrays of empty fixed-length arrays now decode the same as in the TypeScript and Rust implementations. Python now accepts the bodies its own encoder writes and rejects truncated ones with `truncated`. + ## 1.0.0-alpha.1 ### Patch Changes diff --git a/python/package.json b/python/package.json index e5f9b14..43271af 100644 --- a/python/package.json +++ b/python/package.json @@ -1,6 +1,6 @@ { "name": "@hyperfly/python", - "version": "1.0.0-alpha.1", + "version": "1.0.0", "private": true, "description": "Release metadata for the hyperfly PyPI distribution. Changesets bumps this version and .github/scripts/sync-versions.ts writes it to pyproject.toml." } diff --git a/python/pyproject.toml b/python/pyproject.toml index ccdaa1c..16073ca 100644 --- a/python/pyproject.toml +++ b/python/pyproject.toml @@ -4,7 +4,7 @@ build-backend = "hatchling.build" [project] name = "hyperfly" -version = "1.0.0a1" +version = "1.0.0" description = "Binary compression for typed APIs. Schema-compiled codecs with a fingerprinted wire format and transparent JSON fallback." readme = "README.md" license = "Apache-2.0" diff --git a/rust/CHANGELOG.md b/rust/CHANGELOG.md index dd737a3..4b4fffa 100644 --- a/rust/CHANGELOG.md +++ b/rust/CHANGELOG.md @@ -1,5 +1,22 @@ # @hyperfly/rust +## 1.0.0 + +### Major Changes + +- f2e9f68: `Codec::compile` takes a `CompileOptions` value, errors are read through `Error::code()` and `Error::message()`, and option structs and enums are `#[non_exhaustive]` so 1.x can extend them without breaking callers. +- 6880138: First stable release of `hyperfly-core`, the Rust codec for row and columnar encoding with optional trained profiles. The public API and wire format stay compatible throughout 1.x per [STABILITY.md](https://github.com/eliahilse/hyperfly/blob/main/STABILITY.md). + +### Minor Changes + +- e4c7200: Integer fields and integer literals accept an integral `Value::Float` such as `1.0`, matching the TypeScript package. + +### Patch Changes + +- e2d0e87: When a columnar array has several invalid values, encoding now reports the first one in value order, matching the TypeScript and Python packages. +- 609a58a: Decoding grammar-coded string columns allocates less per value and runs faster. +- 9737c8f: Compiling an IR whose artifact nests deeper than 512 levels fails with `ir` instead of risking a stack overflow, as the wire format requires. + ## 0.1.1-alpha.0 ### Patch Changes diff --git a/rust/Cargo.lock b/rust/Cargo.lock index 799f2c7..38ccb26 100644 --- a/rust/Cargo.lock +++ b/rust/Cargo.lock @@ -151,7 +151,7 @@ checksum = "ed5909b6e89a2db4456e54cd5f673791d7eca6732202bbf2a9cc504fe2f9b84a" [[package]] name = "hyperfly-core" -version = "0.1.1-alpha.0" +version = "1.0.0" dependencies = [ "miniz_oxide", "proptest", diff --git a/rust/Cargo.toml b/rust/Cargo.toml index 885db38..7298260 100644 --- a/rust/Cargo.toml +++ b/rust/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "hyperfly-core" -version = "0.1.1-alpha.0" +version = "1.0.0" edition = "2021" rust-version = "1.82" license = "Apache-2.0" diff --git a/rust/package.json b/rust/package.json index 1b1d583..135d3e6 100644 --- a/rust/package.json +++ b/rust/package.json @@ -1,6 +1,6 @@ { "name": "@hyperfly/rust", - "version": "0.1.1-alpha.0", + "version": "1.0.0", "private": true, "description": "Release metadata for the hyperfly-core crate. Changesets bumps this version and .github/scripts/sync-versions.ts writes it to Cargo.toml and Cargo.lock." }