Repository navigation
fix(k9): satisfy the K9 validator in three contracts - #169
Conversation
The Dogfood Gate's "Validate K9 contracts" job (k9-ecosystem/validate-action) fails on main with four errors: - config/build.k9.ncl, config/rust-fmt.k9.ncl: "Missing K9 format marker". The K9! preamble sat on line 2, under the SPDX comment; the validator requires it as the first non-empty line, which is how the contractiles templates lay it out. K9! now comes first, SPDX second. - config/rust-fmt.k9.ncl: "Pedigree block missing 'name' field". Both config contracts now carry a pedigree name. - setup-dev-env.k9.ncl: "Hunt-level K9 file must include a 'signature' or 'signature_required' field". It is a Hunt component (it runs installers and shell commands), so its pedigree now declares signature_required = true, as contractiles/self-validating/template-hunt.k9.ncl does. The validator now reports 10 files scanned, 0 errors. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_0132Cdz3iwk2QGKv2sUhhsye
|
No actionable comments were generated in the recent review. Summary
Merge Risk:
|
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
… build ClusterFuzzLite fails in build_fuzzers on every PR, for three reasons: - It runs `docker build -f .clusterfuzzlite/Dockerfile`, but the directory only had a Containerfile. Add a Dockerfile that mirrors it (same pinned base-builder-rust digest). The Containerfile stays for podman-first local builds. - build.sh copied targets from ./target/..., but cargo-fuzz writes them to ./fuzz/target/x86_64-unknown-linux-gnu/release/. The copy failed with "cannot stat". - Once built, fuzz_parser reported a leak on its first input (a single newline). The leak comes from nickel-lang-parser, which allocates AST nodes in a bumpalo arena that never runs destructors, so strings in those nodes always leak. Add fuzz_parser.options turning off leak detection for libFuzzer and ASan, and have build.sh copy each target's .options file to $OUT. ASan still reports memory-safety errors. Verified locally with the same base image: - The compile finishes and $OUT contains fuzz_parser. - A 90-second fuzz run (615 executions) produced no crashes. - With both leak switches off, the run exits 0 with no artifacts. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_0132Cdz3iwk2QGKv2sUhhsye (cherry picked from commit 3f5120d)
SonarCloud failed this PR on a D security rating for new code: - Dockerfile:10 "Copying recursively might inadvertently add sensitive data to the container." `COPY . $SRC/bunsenite` sent the whole checkout, .git included, into the build image. - build.sh:13 "Use '[[' instead of '['". The image now copies only what the fuzz build reads: - Cargo.toml and Cargo.lock - src/ - benches/ (declared as [[bench]] targets) - crates/ (the patched nickel-lang-vector) - fuzz/ - .clusterfuzzlite/ (build.sh reads the per-target .options from there) The Containerfile gets the same change, to stay in sync. Nothing in these paths uses include_str!/include_bytes! on files outside them, and `cargo metadata` resolves both manifests from that subset. The "runs as root" warning stays as it is: the OSS-Fuzz base-builder image needs root. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_0132Cdz3iwk2QGKv2sUhhsye (cherry picked from commit bb33a7e)
|
ClusterFuzzLite PR (address) fails here for reasons unrelated to this PR. It also fails on #170 fixes all three, and its fuzz job is green. I've cherry-picked its two commits here (d402894 and f73ee73). Git will drop the duplicate changes whichever PR merges first. Generated by Claude Code |
|
SonarCloud (B security rating). The cause is a single hotspot that arrived with the ported ClusterFuzzLite commits: Generated by Claude Code |
|



What was wrong
The Dogfood Gate's Validate K9 contracts job (
k9-ecosystem/validate-action) fails onmainwith four errors:config/build.k9.nclconfig/rust-fmt.k9.nclconfig/rust-fmt.k9.nclsetup-dev-env.k9.nclChanges
config/build.k9.ncl,config/rust-fmt.k9.ncl:K9!preamble was on line 2, under the SPDX comment. The validator needs it as the first non-empty line, as thecontractiles/self-validating/template-*.k9.nclfiles lay it out. It now comes first, with SPDX second.name.setup-dev-env.k9.nclis a Hunt component: it runs installers and shell commands. Its pedigree now declaressignature_required = true, astemplate-hunt.k9.ncldoes.Testing
I ran the current
k9-ecosystemvalidator (with the action's default ignore list) locally on this branch: 10 files scanned, 0 errors. Onmainit reports 4 errors.Generated by Claude Code