chore: namespace the load-test cargo cache key and lint the wasm32 targets - #1838
Conversation
The load harness builds crates/load under --release while writing the linux-cargo- key that desktop-release.yml also owns, so the two release builds overwrite each other's target/ and neither restores anything reusable. Namespace it the way perf-bench.yml is namespaced.
Clippy ran on host targets only, so a wasm32-only lint shipped unseen. The Core KATs job already installs both wasm32 targets; it now runs clippy over cipherbox-core, cipherbox-engine and cipherbox-wasm on each, with -D warnings. The one outstanding lint, a manual range comparison in the web storage headroom policy, is fixed with it.
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Advanced Run ID: 📒 Files selected for processing (3)
Included review availability: Your plan provides up to 1 included review per hour; 0 remain after this review. WalkthroughThe pull request adds clippy checks for two WASM targets, rewrites an equivalent range guard, and gives the load-test workflow a dedicated Cargo cache namespace. ChangesWASM validation
Load-test cache isolation
Priority: ⬇️ Low Estimated code review effort: 2 (Simple) | ~10 minutes Change: Other · Severity of issue fixed: Low Merge Risk: ⚪ Minimal · up to The PR adds targeted WASM lint coverage, preserves storage-policy behavior, and isolates the load-test cache without an identified functional or CI regression. 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
@coderabbitai review |
✅ Action performedReview finished.
|
Two CI gate hygiene fixes. No product code changes behaviour.
chore(ci): give load-test its own cargo cache key
load-test.ymlbuiltcrates/loadunder--releasewhile it wrote and restored theshared
linux-cargo-cache key. It now usesload-test-cargo-, the wayperf-bench.ymluses
perf-bench-cargo-.Closes #1408.
chore(ci): lint the wasm32 targets with clippy
Every clippy invocation in the repository named a host target, so a wasm32-only lint
shipped unseen. The
Core KATs (native + WASM)job inci-rust.ymlalready installswasm32-wasip1andwasm32-unknown-unknown, so the leg lands there. It runs clippy with-D warningsovercipherbox-core,cipherbox-engineandcipherbox-wasmon bothtargets.
The leg uses
--lib --tests, not--all-targets: the criterion benches have no wasmbuild, so
--all-targetsfails to compile for both wasm32 targets.The one outstanding lint the gate would have caught,
manual_range_containsin the webstorage headroom policy, is fixed in the same commit. The rewritten expression
(0.0..OVER_U64).contains(&bytes)is the same two comparisons in the same order, so NaN,both infinities, negatives and out-of-range values still fall to
UNMEASURED. Theexisting test
only_a_whole_in_range_headroom_reads_as_measuredcovers all of them andruns under
wasm32-unknown-unknownin this same job.Closes #1510.
Body checks / follow-ups filed
linux-cargo-key. They do not: the gate usesSwatinem/rust-cachewith the sharedkeys
workspace,core-kats,adapters,desktop,client-browserandwasm-engine. The other writer oflinux-cargo-isdesktop-release.ymlat lines194-195. The collision was therefore between two unrelated release builds. The fix is
unchanged, and after this change
desktop-release.ymlis the sole owner of that key.v2-buildlabel added. The cited lint sitemoved from
crates/wasm/src/host.rs:101to:108. The implemented scope is recordedthere: both targets, three packages,
--lib --tests.Verification
cargo fmt --all --checkcargo clippy --workspace --exclude cipherbox-desktop --exclude cipherbox-contract --all-targets -- -D warningscargo clippy -p cipherbox-core -p cipherbox-engine -p cipherbox-wasm --lib --tests --target wasm32-unknown-unknown -- -D warnings--target wasm32-wasip1cargo test -p cipherbox-wasmzizmor --no-online-audits .github/workflows/ .github/actions/reports no findingspnpm lint:tracker-refsSummary by CodeRabbit
Note
Add wasm32 Clippy lint in
ci-rust.yml, namespace load-test cache key, and simplifyweb_storage_policybounds checkworkspace-testsjob that lintscipherbox-core,cipherbox-engine, andcipherbox-wasm(library and test targets, warnings denied) acrosswasm32-wasip1andwasm32-unknown-unknownlinux-cargonamespace toload-test-cargoso it no longer collides with other jobsweb_storage_policy(host.rs) with an equivalent half-open range check for the integral headroom valueworkspace-testsjob now fails on Clippy warnings in the selected wasm32 packages; pre-existing warnings in those packages will break CIMacroscope summarized 2125a84.