ci: add fmt/clippy/test + cross-platform determinism gates#2
Merged
Conversation
chancery had no CI, so the merged kernel-addon and its pinned golden hashes had zero automated protection. Add the two workflows the four extracted primitives already ship, adapted for the napi addon crate: - ci.yml: fmt, clippy (default + the opt-in --features napi surface), build, and test on kernel-addon. `cargo test` runs the 22-test suite including the golden determinism gate. Test uses default features only because a napi crate cannot link a test executable (Node supplies the symbols at load time); the napi surface is clippy-checked instead. - determinism.yml: runs the composition determinism proofs (the two pinned hashes) across ubuntu/macos/windows to prove same inputs, same hash, everywhere. - kernel-addon/rust-toolchain.toml: pin 1.92.0 (rustfmt + clippy) to match the four primitives so local fmt/clippy match CI exactly. Verified locally under 1.92.0: fmt clean, clippy clean (both feature sets), 22 tests green including golden_hashes_are_stable.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
chancery had no CI. The merged
kernel-addon(PR #1) and its two pinned golden hashes had zero automated protection. This adds the two workflows the four extracted primitives already ship, adapted for the napi addon crate, plus a toolchain pin.Contents
.github/workflows/ci.yml—fmt+clippy(default and the opt-in--features napisurface) +build+testonkernel-addon.cargo testruns the full 22-test suite, including the golden determinism gate (composition::golden_hashes_are_stable). The test step uses default features only, because a napi crate cannot link a test executable (Node supplies the Node-API symbols at load time); the napi surface is covered by the separate clippy step instead..github/workflows/determinism.yml— runs the composition determinism proofs (the two pinned hashes) acrossubuntu-latest/macos-latest/windows-latest, proving same inputs, same hash, everywhere. This is the cross-platform proof that the single-platformci.ymltest step does not give, and matches the intent documented incomposition.rs.kernel-addon/rust-toolchain.toml— pin1.92.0(rustfmt + clippy), matching the four primitives so localcargo fmt/clippyproduce exactly what CI enforces.Why two files
ci.ymlis the fast single-platform gate (all four checks).determinism.ymlis the focused, non-redundant cross-platform golden proof: the kernel's whole value is a verifiable core, and its hashes must be byte-identical on every OS.Verification (local, under pinned 1.92.0)
cargo fmt --all --check— cleancargo clippy --all-targets --locked -- -D warnings— cleancargo clippy --all-targets --features napi --locked -- -D warnings— cleancargo build --locked— okcargo test --locked— 22 passed, includinggolden_hashes_are_stablecargo test --locked --test composition(the determinism gate command) — 11 passedBoth workflow files validated as well-formed YAML.