From 41521a12d6818796a512fed28cd13b32d8b89bfa Mon Sep 17 00:00:00 2001 From: Elia <83713217+eliahilse@users.noreply.github.com> Date: Tue, 20 Oct 2026 16:16:50 +0200 Subject: [PATCH 1/2] chore: release 1.0.0 of every package Exits Changesets prerelease mode and adds a major changeset per package, so the next release PR versions hyperfly, the Python package and hyperfly-core as 1.0.0, publishes to npm `latest` and creates non-prerelease GitHub releases. The prerelease changesets already listed under 1.0.0-alpha.1 are dropped so the 1.0.0 changelog entries carry the 1.0 summaries. Install lines and status wording drop the prerelease forms. Co-Authored-By: Claude Opus 5.5 --- .changeset/pre.json | 2 +- .changeset/pre/bounded-accept-header.md | 5 ----- .changeset/pre/bounded-python-accept.md | 5 ----- .changeset/pre/bounded-rust-inflate.md | 5 ----- .changeset/pre/byte-budget.md | 5 ----- .changeset/pre/client-artifact-bootstrap.md | 5 ----- .changeset/pre/closed-ir-objects.md | 5 ----- .changeset/pre/coded-errors.md | 5 ----- .changeset/pre/decode-item-budget.md | 5 ----- .changeset/pre/edge-safe-fetch-adapter.md | 5 ----- .changeset/pre/fiery-snakes-travel.md | 5 ----- .changeset/pre/http-depth-fallback.md | 5 ----- .changeset/pre/long-humans-show.md | 5 ----- .changeset/pre/maxbytes-options.md | 5 ----- .changeset/pre/package-readme.md | 5 ----- .changeset/pre/portable-inflate.md | 5 ----- .changeset/pre/python-byte-budget.md | 5 ----- .changeset/pre/python-decode-budget.md | 5 ----- .changeset/pre/python-error-codes.md | 5 ----- .changeset/pre/python-error-contract.md | 5 ----- .changeset/pre/python-http-negotiation.md | 5 ----- .changeset/pre/python-integral-ir-numbers.md | 5 ----- .changeset/pre/python-ir-acceptance.md | 5 ----- .changeset/pre/python-options-errors.md | 5 ----- .changeset/pre/python-packaging.md | 5 ----- .changeset/pre/python-train.md | 5 ----- .changeset/pre/ready-moles-count.md | 5 ----- .changeset/pre/rust-byte-budget.md | 5 ----- .changeset/pre/rust-compact-string-columns.md | 5 ----- .changeset/pre/rust-crate-metadata.md | 5 ----- .changeset/pre/rust-decode-budget.md | 5 ----- .changeset/pre/rust-decode-proptest.md | 2 -- .changeset/pre/rust-literal-zero.md | 5 ----- .changeset/pre/rust-public-api.md | 5 ----- .changeset/pre/short-pigs-reply.md | 5 ----- .changeset/pre/strict-ir-field-flags.md | 5 ----- .changeset/pre/tame-berries-wear.md | 5 ----- .changeset/pre/trim-root-exports.md | 5 ----- .changeset/stable-hyperfly.md | 5 +++++ .changeset/stable-python.md | 5 +++++ .changeset/stable-rust.md | 5 +++++ .github/scripts/release.test.ts | 7 ++++++- .github/scripts/release.ts | 5 ++++- .github/scripts/sync-versions.test.ts | 5 ++++- CONTRIBUTING.md | 5 ++--- README.md | 10 +++++----- apps/web/app/docs/page.tsx | 15 ++++++++------- apps/web/app/page.tsx | 2 +- packages/hyperfly/README.md | 8 +++----- python/README.md | 5 ++--- rust/README.md | 2 +- 51 files changed, 52 insertions(+), 211 deletions(-) delete mode 100644 .changeset/pre/bounded-accept-header.md delete mode 100644 .changeset/pre/bounded-python-accept.md delete mode 100644 .changeset/pre/bounded-rust-inflate.md delete mode 100644 .changeset/pre/byte-budget.md delete mode 100644 .changeset/pre/client-artifact-bootstrap.md delete mode 100644 .changeset/pre/closed-ir-objects.md delete mode 100644 .changeset/pre/coded-errors.md delete mode 100644 .changeset/pre/decode-item-budget.md delete mode 100644 .changeset/pre/edge-safe-fetch-adapter.md delete mode 100644 .changeset/pre/fiery-snakes-travel.md delete mode 100644 .changeset/pre/http-depth-fallback.md delete mode 100644 .changeset/pre/long-humans-show.md delete mode 100644 .changeset/pre/maxbytes-options.md delete mode 100644 .changeset/pre/package-readme.md delete mode 100644 .changeset/pre/portable-inflate.md delete mode 100644 .changeset/pre/python-byte-budget.md delete mode 100644 .changeset/pre/python-decode-budget.md delete mode 100644 .changeset/pre/python-error-codes.md delete mode 100644 .changeset/pre/python-error-contract.md delete mode 100644 .changeset/pre/python-http-negotiation.md delete mode 100644 .changeset/pre/python-integral-ir-numbers.md delete mode 100644 .changeset/pre/python-ir-acceptance.md delete mode 100644 .changeset/pre/python-options-errors.md delete mode 100644 .changeset/pre/python-packaging.md delete mode 100644 .changeset/pre/python-train.md delete mode 100644 .changeset/pre/ready-moles-count.md delete mode 100644 .changeset/pre/rust-byte-budget.md delete mode 100644 .changeset/pre/rust-compact-string-columns.md delete mode 100644 .changeset/pre/rust-crate-metadata.md delete mode 100644 .changeset/pre/rust-decode-budget.md delete mode 100644 .changeset/pre/rust-decode-proptest.md delete mode 100644 .changeset/pre/rust-literal-zero.md delete mode 100644 .changeset/pre/rust-public-api.md delete mode 100644 .changeset/pre/short-pigs-reply.md delete mode 100644 .changeset/pre/strict-ir-field-flags.md delete mode 100644 .changeset/pre/tame-berries-wear.md delete mode 100644 .changeset/pre/trim-root-exports.md create mode 100644 .changeset/stable-hyperfly.md create mode 100644 .changeset/stable-python.md create mode 100644 .changeset/stable-rust.md diff --git a/.changeset/pre.json b/.changeset/pre.json index 9a89b8a..23311bd 100644 --- a/.changeset/pre.json +++ b/.changeset/pre.json @@ -1,4 +1,4 @@ { - "mode": "pre", + "mode": "exit", "tag": "alpha" } diff --git a/.changeset/pre/bounded-accept-header.md b/.changeset/pre/bounded-accept-header.md deleted file mode 100644 index ff0e3d0..0000000 --- a/.changeset/pre/bounded-accept-header.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"hyperfly": patch ---- - -`parseAccept` now examines at most 32 entries of a `Hyperfly-Accept` header and ignores uppercase fingerprints, so a padded or malformed header costs a bounded amount of work. diff --git a/.changeset/pre/bounded-python-accept.md b/.changeset/pre/bounded-python-accept.md deleted file mode 100644 index 9c5c079..0000000 --- a/.changeset/pre/bounded-python-accept.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"@hyperfly/python": patch ---- - -`parse_accept` now examines at most 32 `Hyperfly-Accept` entries and ignores uppercase or malformed fingerprints instead of normalising them. diff --git a/.changeset/pre/bounded-rust-inflate.md b/.changeset/pre/bounded-rust-inflate.md deleted file mode 100644 index a62a907..0000000 --- a/.changeset/pre/bounded-rust-inflate.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"@hyperfly/rust": patch ---- - -Decoding a packed string column no longer allocates its declared size up front, so a few hostile bytes cannot force a 256 MiB allocation. diff --git a/.changeset/pre/byte-budget.md b/.changeset/pre/byte-budget.md deleted file mode 100644 index b108ecf..0000000 --- a/.changeset/pre/byte-budget.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"hyperfly": minor ---- - -Decoding enforces a per-message byte budget on string and bytes values, `maxTotalBytes` and `maxByteAmplification`, so payloads that expand into large strings are refused with `limit`. Encoders count the same bytes, and HTTP falls back to JSON. diff --git a/.changeset/pre/client-artifact-bootstrap.md b/.changeset/pre/client-artifact-bootstrap.md deleted file mode 100644 index ce5f204..0000000 --- a/.changeset/pre/client-artifact-bootstrap.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"hyperfly": minor ---- - -Clients can bootstrap from a `Hyperfly-Offer` with `fetchArtifact` or `loadArtifact`, which verify the artifact fingerprint before returning a codec. diff --git a/.changeset/pre/closed-ir-objects.md b/.changeset/pre/closed-ir-objects.md deleted file mode 100644 index 3e278d5..0000000 --- a/.changeset/pre/closed-ir-objects.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"hyperfly": patch ---- - -`compileIR` now rejects IR and profiles with unknown keys, accepts `-0` as the literal or bound `0`, and reports any malformed JSON input as a `HyperflyError` with code `ir`, so every implementation accepts the same schemas. diff --git a/.changeset/pre/coded-errors.md b/.changeset/pre/coded-errors.md deleted file mode 100644 index 409296d..0000000 --- a/.changeset/pre/coded-errors.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"hyperfly": minor ---- - -Malformed JSON, failed zod validation and invalid compile options now throw a `HyperflyError` with code `json`, `validation` or `options`, keeping the original error as `cause` where there is one. diff --git a/.changeset/pre/decode-item-budget.md b/.changeset/pre/decode-item-budget.md deleted file mode 100644 index 73891a0..0000000 --- a/.changeset/pre/decode-item-budget.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"hyperfly": minor ---- - -The new `maxTotalItems` limit caps the array items in one message, so nested arrays can't turn a small hostile body into a huge allocation. `maxAmplification` now defaults to 32; routes with long constant runs raise it on both peers. diff --git a/.changeset/pre/edge-safe-fetch-adapter.md b/.changeset/pre/edge-safe-fetch-adapter.md deleted file mode 100644 index 89c0fa2..0000000 --- a/.changeset/pre/edge-safe-fetch-adapter.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"hyperfly": minor ---- - -`readBody` caps request bodies (`maxBytes`, default `DEFAULT_MAX_BODY_BYTES`) and answers bad bodies with 400, 413 or 415 instead of throwing. `respond` honours `Accept` q=0, sends `Vary: Hyperfly-Accept, Accept`, and falls back to JSON through `onFallback` when the encoder refuses a value. diff --git a/.changeset/pre/fiery-snakes-travel.md b/.changeset/pre/fiery-snakes-travel.md deleted file mode 100644 index 064435d..0000000 --- a/.changeset/pre/fiery-snakes-travel.md +++ /dev/null @@ -1,5 +0,0 @@ ---- - ---- - - diff --git a/.changeset/pre/http-depth-fallback.md b/.changeset/pre/http-depth-fallback.md deleted file mode 100644 index f397b2d..0000000 --- a/.changeset/pre/http-depth-fallback.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"hyperfly": patch ---- - -`respond` and `encodeFor` also fall back to JSON when the encoder refuses a value for exceeding `maxDepth`, as they already did for the other limits. diff --git a/.changeset/pre/long-humans-show.md b/.changeset/pre/long-humans-show.md deleted file mode 100644 index 064435d..0000000 --- a/.changeset/pre/long-humans-show.md +++ /dev/null @@ -1,5 +0,0 @@ ---- - ---- - - diff --git a/.changeset/pre/maxbytes-options.md b/.changeset/pre/maxbytes-options.md deleted file mode 100644 index 31c4ceb..0000000 --- a/.changeset/pre/maxbytes-options.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"hyperfly": patch ---- - -`readBody` and `fetchArtifact` reject an invalid `maxBytes` with a `HyperflyError` of code `options`, like compile options. diff --git a/.changeset/pre/package-readme.md b/.changeset/pre/package-readme.md deleted file mode 100644 index 4a43f40..0000000 --- a/.changeset/pre/package-readme.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"hyperfly": patch ---- - -The package README now covers the decode limits and how to raise them on both peers, the JSON fallback, every error code, the three entry points, runtime support, an Express server and per-tenant artifact serving. diff --git a/.changeset/pre/portable-inflate.md b/.changeset/pre/portable-inflate.md deleted file mode 100644 index 62eca7b..0000000 --- a/.changeset/pre/portable-inflate.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"hyperfly": minor ---- - -Packed string columns now decode in browsers, edge runtimes and older Node versions through a built-in inflater, so `defaultPackHooks()` always provides `inflate`. diff --git a/.changeset/pre/python-byte-budget.md b/.changeset/pre/python-byte-budget.md deleted file mode 100644 index 64b4ab4..0000000 --- a/.changeset/pre/python-byte-budget.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"@hyperfly/python": patch ---- - -The new `max_total_bytes` and `max_byte_amplification` limits cap the decoded bytes of every string and bytes value in one body, including literals, enum members and profile values, so a small body can no longer decode to a huge one. diff --git a/.changeset/pre/python-decode-budget.md b/.changeset/pre/python-decode-budget.md deleted file mode 100644 index 3cb25e2..0000000 --- a/.changeset/pre/python-decode-budget.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"@hyperfly/python": patch ---- - -Small hostile bodies now fail fast: the new `max_total_items` limit caps the items one body declares across its arrays, and `max_amplification` defaults to 32. Encoders refuse what a same-limits decoder rejects, and columnar decoding keeps columns packed until the body decodes. diff --git a/.changeset/pre/python-error-codes.md b/.changeset/pre/python-error-codes.md deleted file mode 100644 index e69f860..0000000 --- a/.changeset/pre/python-error-codes.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"@hyperfly/python": patch ---- - -A malformed JSON body now raises `DecodeError` with code `json`, and a failed model validation raises `EncodeError` or `DecodeError` with code `validation`; the original `json.JSONDecodeError` or pydantic `ValidationError` is wrapped and stays reachable through `__cause__`. diff --git a/.changeset/pre/python-error-contract.md b/.changeset/pre/python-error-contract.md deleted file mode 100644 index aca5673..0000000 --- a/.changeset/pre/python-error-contract.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"@hyperfly/python": patch ---- - -The pydantic `compile` accepts `profile=`, JSON fallback serializes pydantic models and enums, and float overflow raises `EncodeError` with code `float`. `Codec.fingerprint`, `artifact` and `plan` are now read-only. diff --git a/.changeset/pre/python-http-negotiation.md b/.changeset/pre/python-http-negotiation.md deleted file mode 100644 index 4128f09..0000000 --- a/.changeset/pre/python-http-negotiation.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"@hyperfly/python": patch ---- - -`negotiate` honours an `http_accept` q=0 opt-out and `encode_for` falls back to JSON through `on_fallback` when the codec refuses a value. `decode_request` and `read_body` read bounded request bodies and raise `RequestError` with status 400, 413 or 415. diff --git a/.changeset/pre/python-integral-ir-numbers.md b/.changeset/pre/python-integral-ir-numbers.md deleted file mode 100644 index 83aa186..0000000 --- a/.changeset/pre/python-integral-ir-numbers.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"@hyperfly/python": patch ---- - -`compile_ir` now rejects IR and profiles with unknown keys, and accepts integral floats such as `2.0` or `-0.0` wherever an integer is expected, with the same fingerprint as the plain integer. A literal `0` also accepts a `-0.0` value. diff --git a/.changeset/pre/python-ir-acceptance.md b/.changeset/pre/python-ir-acceptance.md deleted file mode 100644 index 88c1504..0000000 --- a/.changeset/pre/python-ir-acceptance.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"@hyperfly/python": patch ---- - -`compile_ir` rejects malformed IR with `HyperflyError` code `ir`, including explicit `None` bounds and lengths and non-boolean field flags, matching the TypeScript package. diff --git a/.changeset/pre/python-options-errors.md b/.changeset/pre/python-options-errors.md deleted file mode 100644 index 2c8a14b..0000000 --- a/.changeset/pre/python-options-errors.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"@hyperfly/python": patch ---- - -`compile_ir`, the pydantic `compile`, `read_body` and `decode_request` reject malformed `limits`, `plan`, `pack`, `validate` or `max_bytes` options with a `HyperflyError` of code `options`, as the TypeScript package does. diff --git a/.changeset/pre/python-packaging.md b/.changeset/pre/python-packaging.md deleted file mode 100644 index d408b96..0000000 --- a/.changeset/pre/python-packaging.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"@hyperfly/python": patch ---- - -The `hyperfly` distribution is marked typed with `py.typed`, lists its supported Python versions and project links, and leaves tests out of the sdist. diff --git a/.changeset/pre/python-train.md b/.changeset/pre/python-train.md deleted file mode 100644 index 9d1df52..0000000 --- a/.changeset/pre/python-train.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"@hyperfly/python": patch ---- - -Adds `train`, the reference profile trainer, so Python services can build columnar profiles from their own traffic. It produces the same profiles as the TypeScript trainer. diff --git a/.changeset/pre/ready-moles-count.md b/.changeset/pre/ready-moles-count.md deleted file mode 100644 index 064435d..0000000 --- a/.changeset/pre/ready-moles-count.md +++ /dev/null @@ -1,5 +0,0 @@ ---- - ---- - - diff --git a/.changeset/pre/rust-byte-budget.md b/.changeset/pre/rust-byte-budget.md deleted file mode 100644 index 2c1f461..0000000 --- a/.changeset/pre/rust-byte-budget.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"@hyperfly/rust": patch ---- - -A per-body byte budget bounds the decoded bytes of strings and bytes values, including reconstructed values. The new limits are `max_total_bytes` and `max_byte_amplification`. diff --git a/.changeset/pre/rust-compact-string-columns.md b/.changeset/pre/rust-compact-string-columns.md deleted file mode 100644 index c95370b..0000000 --- a/.changeset/pre/rust-compact-string-columns.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"@hyperfly/rust": patch ---- - -Decoding a columnar body keeps each string and enum column in one buffer until every column has decoded, so a body that fails partway through needs about half the memory it did. The encoder now refuses arrays its decoder would reject under the one-bit floor. diff --git a/.changeset/pre/rust-crate-metadata.md b/.changeset/pre/rust-crate-metadata.md deleted file mode 100644 index 22ad2c3..0000000 --- a/.changeset/pre/rust-crate-metadata.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"@hyperfly/rust": patch ---- - -The `hyperfly-core` crate now ships crates.io metadata, a README with a runnable example as its crate docs, and declares Rust 1.82 as its minimum supported version. diff --git a/.changeset/pre/rust-decode-budget.md b/.changeset/pre/rust-decode-budget.md deleted file mode 100644 index 11b4b3b..0000000 --- a/.changeset/pre/rust-decode-budget.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"@hyperfly/rust": patch ---- - -Decoding now charges every array against a per-body item budget, so a small hostile body is rejected in bounded time. The new `max_total_items` limit caps that budget, and the default `max_amplification` is now 32. diff --git a/.changeset/pre/rust-decode-proptest.md b/.changeset/pre/rust-decode-proptest.md deleted file mode 100644 index a845151..0000000 --- a/.changeset/pre/rust-decode-proptest.md +++ /dev/null @@ -1,2 +0,0 @@ ---- ---- diff --git a/.changeset/pre/rust-literal-zero.md b/.changeset/pre/rust-literal-zero.md deleted file mode 100644 index 6e03fc3..0000000 --- a/.changeset/pre/rust-literal-zero.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"@hyperfly/rust": patch ---- - -A literal `0` now accepts a float `0.0` or `-0.0` value on encode, matching the TypeScript and Python packages. diff --git a/.changeset/pre/rust-public-api.md b/.changeset/pre/rust-public-api.md deleted file mode 100644 index 00c2f5c..0000000 --- a/.changeset/pre/rust-public-api.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"@hyperfly/rust": patch ---- - -Everything needed to build, compile and run a codec is imported from the crate root and documented there. A compiled codec's identity is read through `Codec::artifact()` and `Codec::fingerprint()`. diff --git a/.changeset/pre/short-pigs-reply.md b/.changeset/pre/short-pigs-reply.md deleted file mode 100644 index 064435d..0000000 --- a/.changeset/pre/short-pigs-reply.md +++ /dev/null @@ -1,5 +0,0 @@ ---- - ---- - - diff --git a/.changeset/pre/strict-ir-field-flags.md b/.changeset/pre/strict-ir-field-flags.md deleted file mode 100644 index e495916..0000000 --- a/.changeset/pre/strict-ir-field-flags.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"hyperfly": patch ---- - -`compileIR` rejects IR with missing or mistyped nodes, members or fields, and struct fields whose `optional` or `nullable` flag is not a boolean, with a `HyperflyError` of code `ir` instead of a `TypeError`. diff --git a/.changeset/pre/tame-berries-wear.md b/.changeset/pre/tame-berries-wear.md deleted file mode 100644 index 064435d..0000000 --- a/.changeset/pre/tame-berries-wear.md +++ /dev/null @@ -1,5 +0,0 @@ ---- - ---- - - diff --git a/.changeset/pre/trim-root-exports.md b/.changeset/pre/trim-root-exports.md deleted file mode 100644 index 7b01fbc..0000000 --- a/.changeset/pre/trim-root-exports.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -"hyperfly": minor ---- - -`CodecRegistry` accepts codecs compiled from typed schemas, and `DEFAULT_LIMITS` is frozen (pass `limits` instead of mutating it). The root entry no longer exports `serializeNode`, `fingerprintOf`, `toHex`, `sha256`, `columnarEligible`, `enumerateColumns`, `MAX_DICT_ENTRIES`, `INT_MAX`, `INT_MIN`, `MAGIC`, `HEADER_SIZE` or `WIRE_VERSION`. diff --git a/.changeset/stable-hyperfly.md b/.changeset/stable-hyperfly.md new file mode 100644 index 0000000..2659f16 --- /dev/null +++ b/.changeset/stable-hyperfly.md @@ -0,0 +1,5 @@ +--- +"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 new file mode 100644 index 0000000..764d7a6 --- /dev/null +++ b/.changeset/stable-python.md @@ -0,0 +1,5 @@ +--- +"@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 new file mode 100644 index 0000000..746009e --- /dev/null +++ b/.changeset/stable-rust.md @@ -0,0 +1,5 @@ +--- +"@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/.github/scripts/release.test.ts b/.github/scripts/release.test.ts index 5f10582..ff8ab63 100644 --- a/.github/scripts/release.test.ts +++ b/.github/scripts/release.test.ts @@ -1,5 +1,5 @@ import { describe, expect, test } from "bun:test" -import { changelogSection, distTag, needsRelease, publishedCommit, pythonDists, repositoryMatches, vcsInfoCommit, withGitHead } from "./release" +import { changelogSection, distTag, needsRelease, publishedCommit, pythonDists, releaseFlags, repositoryMatches, vcsInfoCommit, withGitHead } from "./release" const sha = "0123456789abcdef0123456789abcdef01234567" @@ -16,6 +16,11 @@ test("prereleases publish under next, never latest", () => { expect(distTag("1.0.0")).toBe("latest") }) +test("only prereleases get prerelease GitHub release flags", () => { + expect(releaseFlags("1.0.0")).toEqual([]) + expect(releaseFlags("1.0.0-alpha.1")).toEqual(["--prerelease", "--latest=false"]) +}) + test("the packed manifest records the commit as gitHead and keeps every other field", () => { const original = `${JSON.stringify({ name: "hyperfly", version: "1.2.3", exports: { ".": "./dist/index.js" } }, null, 2)}\n` expect(JSON.parse(withGitHead(original, sha))).toEqual({ name: "hyperfly", version: "1.2.3", exports: { ".": "./dist/index.js" }, gitHead: sha }) diff --git a/.github/scripts/release.ts b/.github/scripts/release.ts index cd4adf0..d7397d3 100644 --- a/.github/scripts/release.ts +++ b/.github/scripts/release.ts @@ -52,6 +52,9 @@ export const prerelease = (version: string) => version.includes("-") /** npm's dist-tag for a version: prereleases never move `latest` */ export const distTag = (version: string) => (prerelease(version) ? "next" : "latest") +/** gh release flags for a version: prereleases are marked as such and never become the latest release */ +export const releaseFlags = (version: string) => (prerelease(version) ? ["--prerelease", "--latest=false"] : []) + /** the body of a CHANGELOG.md section for one version, or undefined when there is none */ export function changelogSection(changelog: string, version: string): string | undefined { const lines = changelog.split("\n") @@ -138,7 +141,7 @@ async function tagAndRelease(tag: string, commit: () => Promise, version await $`git push origin ${`refs/tags/${tag}`}` } if (await released(tag)) return - const flags = prerelease(version) ? ["--prerelease", "--latest=false"] : [] + const flags = releaseFlags(version) await $`gh release create ${tag} --title ${tag} --notes ${body} --verify-tag ${flags}` } diff --git a/.github/scripts/sync-versions.test.ts b/.github/scripts/sync-versions.test.ts index f574ff8..a20d6c5 100644 --- a/.github/scripts/sync-versions.test.ts +++ b/.github/scripts/sync-versions.test.ts @@ -2,7 +2,10 @@ import { describe, expect, test } from "bun:test" import { pep440, setLockVersion, setTomlVersion, tomlString } from "./sync-versions" describe("pep440", () => { - test("keeps a release version", () => expect(pep440("1.2.3")).toBe("1.2.3")) + test("keeps a release version", () => { + expect(pep440("1.0.0")).toBe("1.0.0") + expect(pep440("1.2.3")).toBe("1.2.3") + }) test("maps alpha, beta and rc", () => { expect(pep440("1.0.0-alpha.0")).toBe("1.0.0a0") expect(pep440("1.0.0-alpha.12")).toBe("1.0.0a12") diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index e3f7b7c..6246221 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -26,9 +26,8 @@ the PyPI and crates.io versions for Changesets. `bun run version-packages` writes them into `pyproject.toml` (as PEP 440, `1.0.0-alpha.1` becomes `1.0.0a1`), `Cargo.toml` and `Cargo.lock`. -The repository is in prerelease mode (`.changeset/pre.json`, tag `alpha`), so -every bump produces an `-alpha.N` version. `bun changeset pre exit` leaves it -before the first stable release. +A future prerelease line starts with `bun changeset pre enter ` and ends with +`bun changeset pre exit`. ## Releasing diff --git a/README.md b/README.md index fc7704b..d6ecc60 100644 --- a/README.md +++ b/README.md @@ -6,14 +6,14 @@ Typed APIs already know what their data can contain. Production traffic reveals the data usually contains. Hyperfly uses both to compile a binary protocol for one exact route, instead of shipping generic JSON through a generic compressor. -**Pre-release.** The wire format is specified, three implementations agree on it -byte-for-byte, and the benchmarks below are reproducible, but nothing is stable yet: -expect breaking changes before 1.0. +The wire format is specified and the three implementations agree on it byte for byte; +the public APIs and wire format are stable for 1.x per [STABILITY.md](STABILITY.md). +The benchmarks below are reproducible. | Package | Install | Docs | |---|---|---| -| TypeScript, Zod adapter, HTTP | `npm install hyperfly@next zod` | [packages/hyperfly](packages/hyperfly/README.md) | -| Python, Pydantic adapter, HTTP | `pip install --pre "hyperfly[pydantic]"` | [python](python/README.md) | +| TypeScript, Zod adapter, HTTP | `npm install hyperfly zod` | [packages/hyperfly](packages/hyperfly/README.md) | +| Python, Pydantic adapter, HTTP | `pip install "hyperfly[pydantic]"` | [python](python/README.md) | | Rust codec | `cargo add hyperfly-core` | [rust](rust/README.md) | Zod and Pydantic are needed only for the schema adapters; the codec and HTTP layers diff --git a/apps/web/app/docs/page.tsx b/apps/web/app/docs/page.tsx index ea9a372..049947e 100644 --- a/apps/web/app/docs/page.tsx +++ b/apps/web/app/docs/page.tsx @@ -4,6 +4,7 @@ import { Mark } from "../mark"; const GITHUB = "https://github.com/eliahilse/hyperfly"; const README = `${GITHUB}/tree/main/packages/hyperfly`; +const STABILITY = `${GITHUB}/blob/main/STABILITY.md`; const SECTIONS = [ ["install", "Install"], ["compile", "Compile a codec"], @@ -66,8 +67,9 @@ export default function DocsPage() {

- Hyperfly is a pre-release; expect breaking changes before 1.0. This guide covers the - first request. The package README has the API and + Hyperfly 1.x keeps the public API and wire format compatible per the{" "} + stability policy. This guide covers the first request. + The package README has the API and runtime reference tables.