Skip to content

release: v1.8.0 - #16

Merged
orelvis15 merged 1 commit into
mainfrom
release/1.8.0
Oct 30, 2026
Merged

orelvis15 merged 1 commit into
mainfrom
release/1.8.0

Conversation

@orelvis15

Copy link
Copy Markdown
Collaborator

Version bump and changelog for v1.8.0. Stacked on #15: merge that first, and this PR then shows only the release commit.

  • Workspace, Node SDK and Kotlin SDK move to 1.8.0. The lockfiles follow, including fuzz/ and desktop/src-tauri/.
  • Unreleased becomes [1.8.0].

Why 1.8.0 rather than 1.7.1: besides the zstd 0.14 security bump (#14), the section adds public cavs-store API: ChunkTransform with repack_run_with, and SyncMode with set_sync_mode.

After merge: push the v1.8.0 tag on the merge commit. release.yml then builds and publishes the crates to crates.io. terragov/cavs-db needs that publish: it takes cavs-format, cavs-hash, cavs-chunker and cavs-proto from crates.io, and cavs-format 1.7.0 there still requires zstd 0.13 (terragov/cavs-db#293, terragov/archis#1385).

@claude claude Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Claude Code Review

This repository is configured for manual code reviews. Comment @claude review for a one-time review, or @claude review always to subscribe this PR to a review on every future push.

Tip: disable this comment in your organization's Code Review settings.

@terrarevbot terrarevbot Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🛑 Staff Review: CHANGES REQUESTED

The Node lockfile gives version 1.8.0 for all five native packages but still downloads and checksums the 1.6.0 tarballs, and the crates.io publish this PR triggers cannot be undone, so the zstd semver question and the internal crate version requirements need checking before the tag is pushed.

📋 Executive Assessment

On the surface this is a version-bump-and-changelog PR. The actual change is larger. It moves the workspace to a new major version of zstd (0.13 to 0.14, which is a breaking change under Rust's 0.x versioning rules). It also refreshes two lockfiles that were badly out of date: fuzz/ was still at 0.5.0 and desktop/src-tauri/ at 1.3.0. That refresh quietly adds a full HTTP/TLS stack (ureq, rustls, ring, webpki-roots) to the desktop app through cavs-fetch. Those dependencies come from changes already on main, but this PR is where they first get locked, so it should be reviewed as a dependency change, not just a version number. That the lockfiles drifted five or more minor versions shows CI does not build fuzz/ or desktop/src-tauri/ with --locked. Fuzz coverage and desktop release builds may therefore have been running against dependency versions nobody reviewed.

The most concrete defect is in sdks/node/package-lock.json. Each @orelvis15/cavs-sdk-<platform> entry now says version: 1.8.0, but its resolved URL and integrity hash still point at the 1.6.0 tarball. This was already wrong at 1.7.0 and is now repeated. npm ci trusts resolved and integrity, so any CI job or developer machine that installs from this lockfile gets 1.6.0 native binaries under a 1.8.0 JS wrapper. That would break any C ABI symbol added in 1.7.0 or 1.8.0, or let it pass silently while testing the wrong code.

The release goes out by pushing a tag, and crates.io publishes cannot be reversed. Two questions should be answered first. (1) Does any public cavs-format, cavs-store or cavs-fetch API expose zstd types? If so, moving to zstd 0.14 breaks those crates' public API and 1.8.0 is the wrong version number. (2) Were the version requirements between the cavs crates in the workspace bumped to 1.8.0? If they still say 1.7.0, a downstream project such as cavs-db can end up with cavs-format 1.8.0 next to cavs-store 1.7.0, which lacks ChunkTransform and SyncMode. The compatibility evidence in the changelog (identical bytes, each build reading what the other wrote) is good. It should be committed as a golden-file test, not left as a claim in prose.

📊 Risk Assessment

Dimension Risk Level
Architectural Integrity 🟡 MEDIUM
Operational & Failure Resilience 🟡 MEDIUM
Security & Trust Boundary 🟢 LOW

🔍 Adversarial Findings & Stress-Test Scenarios

1. [🛑 HIGH] Node lockfile says 1.8.0 for the native packages but downloads the 1.6.0 tarballs

  • Location: sdks/node/package-lock.json#L31
  • Category: backward_compatibility
  • Failure Scenario: CI or a contributor runs npm ci in sdks/node. package.json and the lockfile both say 1.8.0, so the sync check passes. npm then downloads the resolved URL (cavs-sdk-<platform>-1.6.0.tgz), checks it against the 1.6.0 integrity hash, and installs it. koffi loads the 1.6.0 native library from the 1.8.0 JS layer.
  • Impact: Any FFI symbol added in 1.7.0 or 1.8.0 fails to load at runtime, or tests pass while exercising a two-release-old native core. This was already wrong at 1.7.0, so Node SDK test results for 1.7.0 may have come from the wrong binary. Published consumers are unaffected because package-lock.json is not shipped, but the repo's own validation is wrong.
  • Recommendation: Regenerate the lockfile once the 1.8.0 platform packages are on npm (rm package-lock.json && npm install --package-lock-only), or remove the resolved and integrity fields for the platform packages until then. Add a CI check that every resolved URL for @orelvis15/cavs-sdk-* contains the package's version.
# CI guard
jq -r '.packages | to_entries[] | select(.key|test("cavs-sdk-")) | select((.value.resolved // "") | contains("-" + .value.version + ".tgz") | not) | .key' sdks/node/package-lock.json | (! grep .)

2. [⚠️ MEDIUM] zstd 0.13 to 0.14 is a breaking change; 1.8.0 is only correct if no zstd type is in the public API

  • Location: Cargo.toml#L73
  • Category: backward_compatibility
  • Failure Scenario: A public item in cavs-format, cavs-store or cavs-fetch takes or returns a zstd type: an error variant wrapping zstd::Error or std::io::Error built from zstd, a From<zstd::…> impl, or a ChunkTransform signature with zstd parameters. A downstream crate like cavs-db that uses zstd 0.13 directly then gets type mismatches after cargo update.
  • Impact: Downstream code stops compiling under a minor version bump, which breaks the semver promise. Because publishes to crates.io cannot be reversed, the only fix would be a yank followed by a 2.0.0.
  • Recommendation: Before tagging, run cargo semver-checks check-release --baseline-version 1.7.0 on every published crate, and grep public signatures for zstd::. Record the result in the changelog's Security section, e.g. 'zstd is a private dependency; no public type changes'.
cargo install cargo-semver-checks
for c in cavs-hash cavs-chunker cavs-store cavs-format cavs-proto cavs-fetch; do cargo semver-checks check-release -p $c --baseline-version 1.7.0; done

3. [⚠️ MEDIUM] Check that the version requirements between cavs crates in the workspace moved to 1.8.0

  • Location: Cargo.toml#L31
  • Category: backward_compatibility
  • Failure Scenario: Only two lines in Cargo.toml change. If [workspace.dependencies] still says cavs-store = { path = ..., version = "1.7.0" }, the published cavs-format 1.8.0 accepts any cavs-store ^1.7.0. A cavs-db lockfile that already pins cavs-store 1.7.0 keeps it when someone runs cargo update -p cavs-format, so cavs-format 1.8.0 is built against cavs-store 1.7.0.
  • Impact: If cavs-format 1.8.0 (or cavs-fetch, or cavs-sdk-core) uses ChunkTransform, repack_run_with or SyncMode, downstream builds fail to compile, or the minimal-versions CI job does. The cavs-db upgrade this release exists to unblock would fail on its first attempt.
  • Recommendation: Bump the internal crate version requirements to 1.8.0 in the same commit, or confirm they are already exact or current. Add a cargo +nightly update -Z minimal-versions && cargo check --workspace job, or cargo publish --dry-run per crate in the right order, to release.yml before the real publish.

4. [⚠️ MEDIUM] Fuzz and desktop lockfiles were several releases stale, so CI is not building them with --locked

  • Location: fuzz/Cargo.lock#L60
  • Category: test_rigor
  • Failure Scenario: fuzz/Cargo.lock still listed the cavs crates at 0.5.0, and desktop/src-tauri/Cargo.lock at 1.3.0, while the workspace was at 1.7.0. Both directories are excluded from the workspace, so cargo test --all never touches their lockfiles. Fuzz builds and desktop release builds have been resolving dependencies fresh, or not running at all.
  • Impact: Fuzz targets may not have built or run against current decoders for many releases, a coverage gap in a project whose architecture depends on hardened decoders. Desktop binaries were built from dependency versions nobody reviewed, so the zstd advisories this PR fixes could come back in the desktop build.
  • Recommendation: Add CI jobs that run cargo build --locked (and cargo fuzz build) in fuzz/ and cargo check --locked in desktop/src-tauri/, plus cargo audit or cargo deny against both lockfiles. Make lockfile refresh a step in docs/RELEASING.md.

5. [ℹ️ LOW] Desktop app now locks in a TLS and HTTP client stack (ureq, rustls, ring, webpki-roots) with no review note

  • Location: desktop/src-tauri/Cargo.lock#L620
  • Category: security
  • Failure Scenario: cavs-sdk-core now depends on cavs-fetch, which brings ureq 2.12.1, rustls 0.23, ring 0.17.14 and a bundled webpki-roots 0.26 (a shim over 1.0) into the desktop binary. The bundled trust roots bypass the OS certificate store.
  • Impact: The desktop app can now make HTTPS requests with a fixed set of trusted root certificates. Enterprise users behind TLS-intercepting proxies will see failures, the roots only update when the app does, and the dependency surface grows. None of this is mentioned in the changelog or the desktop release notes.
  • Recommendation: Confirm the desktop app should include network fetch. If it should, consider rustls-native-certs or rustls-platform-verifier for desktop, and mention the change in the desktop release notes. Gate cavs-fetch in sdk-core behind a feature if desktop does not need it.

6. [ℹ️ LOW] The zstd compatibility claim is in prose only; no golden-file test in CI

  • Location: CHANGELOG.md#L68
  • Category: test_rigor
  • Failure Scenario: A later zstd-sys release bundles a different libzstd, or the zstd crate changes default parameters (window log, checksum flag). Packs written by older builds still need to verify and append, but nothing in CI checks this.
  • Impact: A silent format change could break the dedup and append invariants for existing stores, and it would only show up in production.
  • Recommendation: Commit the 0.13-produced pack, pack index and index segment as fixtures. Add a test that (a) verifies, unpacks and appends to them, and (b) checks that re-packing the same input gives identical bytes apart from asset_uuid.

7. [💡 NOTE] The new public cavs-store APIs and cavs-fetch are not reflected in the architecture docs or changelog links

  • Location: CHANGELOG.md#L9
  • Category: docs_spec_drift
  • Failure Scenario: The release adds public ChunkTransform/repack_run_with and SyncMode/set_sync_mode, but the cavs-store row in docs/ARCHITECTURE.md is not updated. Keep a Changelog footer links such as [1.8.0]: …compare/v1.7.0...v1.8.0 are also not added.
  • Impact: There is a small gap between the code and the docs. CONTRIBUTING.md requires doc updates when interfaces change.
  • Recommendation: Update the cavs-store row in ARCHITECTURE.md (durability modes, re-encoding repack) and add the comparison links to the changelog footer, or confirm that #15 already did this.

💡 Staff Architectural Inquiries

Strategic questions for the author regarding scale, invariants, or recovery:

  • What does release.yml do if publishing fails partway, for example cavs-format 1.8.0 lands but cavs-proto fails? Is the publish order derived from the dependency graph, and is a dry run of every crate a required step before the first real publish?
  • Go SDK users get versions from git tags. Does the release also need an sdks/go/v1.8.0 tag, and do the npm, Maven and Go SDKs check at runtime that the native core is the version they expect, so a mismatch like the 1.6.0 lockfile problem fails loudly?
  • zstd-sys declares links = "zstd", so only one copy can exist in a build. Have you run cargo tree -d -i zstd-sys in cavs-db with this release to confirm zstd 0.13 and 0.14 (through zstd-safe 7 and 8) resolve to a single zstd-sys, not a links conflict?
  • Given how far the fuzz and desktop lockfiles drifted, should those directories join the workspace, or get their own required CI jobs, so a release cannot be cut while they are stale?

🌟 Positive Engineering Highlights

  • The PR explains why this is 1.8.0 rather than 1.7.1 (new public cavs-store API), which is the right call for added public API.
  • The changelog's Security entry is unusually specific. It names the exact locked versions, lists the RUSTSEC IDs, notes that the bundled libzstd (1.5.7) is the same in both versions, and describes a two-way compatibility check between builds.
  • The out-of-workspace lockfiles (fuzz and desktop) were refreshed alongside the workspace, so the zstd fix covers every build target and not just the main workspace.
  • The release is split cleanly from the feature work (stacked on #15), and the PR spells out the tag-to-publish sequence and the downstream dependency (cavs-db #293).

Review conducted by GitHub Review Bot with adversarial Staff-level engineering vision.

"node_modules/@orelvis15/cavs-sdk-darwin-arm64": {
"version": "1.7.0",
"version": "1.8.0",
"resolved": "https://registry.npmjs.org/@orelvis15/cavs-sdk-darwin-arm64/-/cavs-sdk-darwin-arm64-1.6.0.tgz",

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[HIGH] Node lockfile says 1.8.0 for the native packages but downloads the 1.6.0 tarballs

Failure Scenario: CI or a contributor runs npm ci in sdks/node. package.json and the lockfile both say 1.8.0, so the sync check passes. npm then downloads the resolved URL (cavs-sdk-<platform>-1.6.0.tgz), checks it against the 1.6.0 integrity hash, and installs it. koffi loads the 1.6.0 native library from the 1.8.0 JS layer.
Impact: Any FFI symbol added in 1.7.0 or 1.8.0 fails to load at runtime, or tests pass while exercising a two-release-old native core. This was already wrong at 1.7.0, so Node SDK test results for 1.7.0 may have come from the wrong binary. Published consumers are unaffected because package-lock.json is not shipped, but the repo's own validation is wrong.
Recommendation: Regenerate the lockfile once the 1.8.0 platform packages are on npm (rm package-lock.json && npm install --package-lock-only), or remove the resolved and integrity fields for the platform packages until then. Add a CI check that every resolved URL for @orelvis15/cavs-sdk-* contains the package's version.

Suggested change
"resolved": "https://registry.npmjs.org/@orelvis15/cavs-sdk-darwin-arm64/-/cavs-sdk-darwin-arm64-1.6.0.tgz",
# CI guard
jq -r '.packages | to_entries[] | select(.key|test("cavs-sdk-")) | select((.value.resolved // "") | contains("-" + .value.version + ".tgz") | not) | .key' sdks/node/package-lock.json | (! grep .)

Comment thread Cargo.toml
chacha20poly1305 = "0.10"
fastcdc = "3.1"
zstd = "0.13"
zstd = "0.14"

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[MEDIUM] zstd 0.13 to 0.14 is a breaking change; 1.8.0 is only correct if no zstd type is in the public API

Failure Scenario: A public item in cavs-format, cavs-store or cavs-fetch takes or returns a zstd type: an error variant wrapping zstd::Error or std::io::Error built from zstd, a From<zstd::…> impl, or a ChunkTransform signature with zstd parameters. A downstream crate like cavs-db that uses zstd 0.13 directly then gets type mismatches after cargo update.
Impact: Downstream code stops compiling under a minor version bump, which breaks the semver promise. Because publishes to crates.io cannot be reversed, the only fix would be a yank followed by a 2.0.0.
Recommendation: Before tagging, run cargo semver-checks check-release --baseline-version 1.7.0 on every published crate, and grep public signatures for zstd::. Record the result in the changelog's Security section, e.g. 'zstd is a private dependency; no public type changes'.

Suggested change
zstd = "0.14"
cargo install cargo-semver-checks
for c in cavs-hash cavs-chunker cavs-store cavs-format cavs-proto cavs-fetch; do cargo semver-checks check-release -p $c --baseline-version 1.7.0; done

Comment thread Cargo.toml

[workspace.package]
version = "1.7.0"
version = "1.8.0"

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[MEDIUM] Check that the version requirements between cavs crates in the workspace moved to 1.8.0

Failure Scenario: Only two lines in Cargo.toml change. If [workspace.dependencies] still says cavs-store = { path = ..., version = "1.7.0" }, the published cavs-format 1.8.0 accepts any cavs-store ^1.7.0. A cavs-db lockfile that already pins cavs-store 1.7.0 keeps it when someone runs cargo update -p cavs-format, so cavs-format 1.8.0 is built against cavs-store 1.7.0.
Impact: If cavs-format 1.8.0 (or cavs-fetch, or cavs-sdk-core) uses ChunkTransform, repack_run_with or SyncMode, downstream builds fail to compile, or the minimal-versions CI job does. The cavs-db upgrade this release exists to unblock would fail on its first attempt.
Recommendation: Bump the internal crate version requirements to 1.8.0 in the same commit, or confirm they are already exact or current. Add a cargo +nightly update -Z minimal-versions && cargo check --workspace job, or cargo publish --dry-run per crate in the right order, to release.yml before the real publish.

Comment thread fuzz/Cargo.lock
[[package]]
name = "cavs-format"
version = "0.5.0"
version = "1.8.0"

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[MEDIUM] Fuzz and desktop lockfiles were several releases stale, so CI is not building them with --locked

Failure Scenario: fuzz/Cargo.lock still listed the cavs crates at 0.5.0, and desktop/src-tauri/Cargo.lock at 1.3.0, while the workspace was at 1.7.0. Both directories are excluded from the workspace, so cargo test --all never touches their lockfiles. Fuzz builds and desktop release builds have been resolving dependencies fresh, or not running at all.
Impact: Fuzz targets may not have built or run against current decoders for many releases, a coverage gap in a project whose architecture depends on hardened decoders. Desktop binaries were built from dependency versions nobody reviewed, so the zstd advisories this PR fixes could come back in the desktop build.
Recommendation: Add CI jobs that run cargo build --locked (and cargo fuzz build) in fuzz/ and cargo check --locked in desktop/src-tauri/, plus cargo audit or cargo deny against both lockfiles. Make lockfile refresh a step in docs/RELEASING.md.

[[package]]
name = "cavs-sdk-core"
version = "1.3.0"
version = "1.8.0"

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[LOW] Desktop app now locks in a TLS and HTTP client stack (ureq, rustls, ring, webpki-roots) with no review note

Failure Scenario: cavs-sdk-core now depends on cavs-fetch, which brings ureq 2.12.1, rustls 0.23, ring 0.17.14 and a bundled webpki-roots 0.26 (a shim over 1.0) into the desktop binary. The bundled trust roots bypass the OS certificate store.
Impact: The desktop app can now make HTTPS requests with a fixed set of trusted root certificates. Enterprise users behind TLS-intercepting proxies will see failures, the roots only update when the app does, and the dependency surface grows. None of this is mentioned in the changelog or the desktop release notes.
Recommendation: Confirm the desktop app should include network fetch. If it should, consider rustls-native-certs or rustls-platform-verifier for desktop, and mention the change in the desktop release notes. Gate cavs-fetch in sdk-core behind a feature if desktop does not need it.

Comment thread CHANGELOG.md

### Security

- **zstd 0.14** (terragov/cavs#14). The workspace moves from `zstd = "0.13"`

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[LOW] The zstd compatibility claim is in prose only; no golden-file test in CI

Failure Scenario: A later zstd-sys release bundles a different libzstd, or the zstd crate changes default parameters (window log, checksum flag). Packs written by older builds still need to verify and append, but nothing in CI checks this.
Impact: A silent format change could break the dedup and append invariants for existing stores, and it would only show up in production.
Recommendation: Commit the 0.13-produced pack, pack index and index segment as fixtures. Add a test that (a) verifies, unpacks and appends to them, and (b) checks that re-packing the same input gives identical bytes apart from asset_uuid.

Comment thread CHANGELOG.md

## [Unreleased]

## [1.8.0] — zstd 0.14, re-encoding repack, sync modes, cheaper ledger saves

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[INFO] The new public cavs-store APIs and cavs-fetch are not reflected in the architecture docs or changelog links

Failure Scenario: The release adds public ChunkTransform/repack_run_with and SyncMode/set_sync_mode, but the cavs-store row in docs/ARCHITECTURE.md is not updated. Keep a Changelog footer links such as [1.8.0]: …compare/v1.7.0...v1.8.0 are also not added.
Impact: There is a small gap between the code and the docs. CONTRIBUTING.md requires doc updates when interfaces change.
Recommendation: Update the cavs-store row in ARCHITECTURE.md (durability modes, re-encoding repack) and add the comparison links to the changelog footer, or confirm that #15 already did this.

…ledger saves

- zstd 0.14 (#14): clears RUSTSEC-2026-0391/0398/0403/0410; stored bytes
  unchanged.
- cavs-store: a repack can re-encode the chunks it moves (ChunkTransform).
- cavs-store: SyncMode, the caller chooses what a sync waits for.
- cavs-store: a ledger save appends a sealed journal record instead of
  rewriting index.bin.
- Bump workspace and Node/Kotlin SDKs to 1.8.0.
@orelvis15
orelvis15 merged commit dfae5ad into main Oct 30, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant