feat(envelope): pick up cachekit-core 0.4.0 bin envelopes (LAB-900) - #249
feat(envelope): pick up cachekit-core 0.4.0 bin envelopes (LAB-900)#24927Bslash6 wants to merge 2 commits into
Conversation
Bump cachekit-core 0.3.0 -> 0.4.0 (LAB-900, protocol 1.1 rollout stage 5). Fresh writes now emit StorageEnvelope compressed_data as MessagePack bin (0xc4/0xc5/0xc6) instead of array-of-ints; legacy envelopes stay readable forever. No py-side code change — the envelope codec is single-sourced in cachekit-core. Byte-verification (tests/unit/protocol/test_envelope_wire_vectors.py, fixture vendored sha256-pinned from cachekit-io/protocol wire-format.json): - legacy-read: all 6 pre-0.4.0 array-of-ints vectors decode via the real FFI retrieve path, and a transcoded legacy envelope is served through the full decorator retrieve path (FileBackend L2, no recompute) - bin-emit: fresh decorator writes carry a bin-encoded envelope inside the CK v3 frame; bin8/bin16/bin32 width tiers pinned against the real writer (the protocol *_bin pins only cover bin8) - re-encode identity: the 0.4.0 writer reproduces all 6 *_bin protocol pins byte-identically - round-trip identity through the full stack, compressible + incompressible Docs: DEVELOPMENT.md envelope row replaced — the documented custom [version][format][checksum][...] layout never existed (cachekit-core#46 envelope-doc residual); now describes the real rmp_serde positional fixarray(4) with the 0.4.0 bin encoding and permanent legacy-read rule. Secrets baseline: wire-format.json hex vectors are high-entropy test pins, audited into .secrets.baseline (same convention as the AAD/encryption tests).
|
Warning Review limit reachedYou’ve reached a temporary PR review limit under our Fair Usage Limits Policy. Next review available in: 24 minutes Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: ASSERTIVE Plan: Pro Run ID: ⛔ Files ignored due to path filters (1)
📒 Files selected for processing (6)
Comment |
This comment has been minimized.
This comment has been minimized.
- tests/critical/test_byte_storage_error_injection.py: the final-envelope-size security check's premise died with 0.4.0 — a 500MB incompressible payload no longer inflates ~2x (bin encoding is ~1.004x), stores fine, and the expected ValueError never raised (slow-marked, so PR CI skipped the breakage). Input now sits 16 bytes under the 512MiB input cap so the LZ4 incompressible-block overhead pushes the final envelope over the limit again. randbytes chunked at 128MiB (getrandbits takes a C int). - tests/unit/protocol/test_envelope_wire_vectors.py: merged the two byte-identical decode tests into one parametrized over all 12 vectors. - DEVELOPMENT.md: 'dual-read proven in both directions' de-ambiguated — this repo's suite proves both encodings decode, not cross-SDK direction.
Kody Review CompleteGreat news! 🎉 Keep up the excellent work! 🚀 Kody Guide: Usage and ConfigurationInteracting with Kody
Current Kody ConfigurationReview OptionsThe following review options are enabled or disabled:
|
|
@kody start-review |
Closes LAB-900 (parent LAB-764 stage 5 — protocol 1.1 rollout, final leg for Python).
What
cachekit-core0.3.0 → 0.4.0 (rust/Cargo.toml+Cargo.lock). Fresh writes now emitStorageEnvelope.compressed_dataas MessagePackbin(0xc4/0xc5/0xc6); pre-0.4.0 array-of-ints envelopes remain readable forever. No py-side code change — the envelope codec is single-sourced in cachekit-core.tests/unit/protocol/test_envelope_wire_vectors.py, 27 tests; fixture vendored sha256-pinned from protocolwire-format.json@a4b392b), closing LAB-764's "interop parity proven, not asserted" AC for Python:*_binpins only cover bin8 — per the decision record's deferred-coverage note).ByteStorage.store()reproduces all 6*_binprotocol pins byte-identically.[version:1][format:1][checksum:8][compressed_data]layout never existed. Now documents the realrmp_serdepositionalfixarray(4)[compressed_data, checksum, original_size, format], the 0.4.0binencoding, and the permanent legacy-read rule. (The Blake3-mislabel half of chore(main): release 0.3.1 #46 is a separate residual, untouched here.).secrets.baseline: the fixture's hex vectors are high-entropy by design; audited in, same convention as the existing AAD/encryption test entries.Verification (local, CI-equivalent invocations)
ruff format --check ./ruff check .— cleanbasedpyright --level error— 0 errorspytest tests/unit/ -m "not slow"— 1936 passed (includes doctests + markdown-docs)pytest tests/critical/ -m "not slow"— 234 passedpytest tests/integration/ -m "not slow" --ignore=tests/integration/saas— 240 passedcargo test --release --features python— greenNotes
decisions/envelope-bin-encoding.md).Supply-chain / SCA evidence (cachekit-core 0.3.0 → 0.4.0)
OSV.dev batch scan (
api.osv.dev/v1/querybatch, 2026-07-29) of all 243 crates.io packages inCargo.lock:cachekit-core 0.4.0: 0 known advisories (OSV/RustSec/GHSA). Its full dependency subtree (aes,aes-gcm,ring,lz4_flex,sha2,hkdf,hmac,rmp-serde,xxhash-rust,zeroize, …) is also clean.Cargo.lockis updated: the sole lockfile delta vsmainiscachekit-core 0.3.0 → 0.4.0, resolved from crates.io with checksum6aba1513135a7b92a124ad6983f7e80e5f5c78c4f9c74384079efa3fbf491eab.anyhowvia protobuf-codegen,bincodevia iai-callgrind,proc-macro-error2via iai-callgrind-macros,quick-xmlvia inferno,randvia proptest) — all present onmainbefore this PR, none in the runtime tree, none introduced or touched by this bump.