fix(rust): make clawdstrike publishable on crates.io again#213
fix(rust): make clawdstrike publishable on crates.io again#213
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: e9921a34cd
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
|
|
||
| if has_signal_mode { | ||
| println!("cargo:rustc-cfg=has_nono_signal_mode"); | ||
| } |
There was a problem hiding this comment.
Build script missing rerun-if-changed for external file
Low Severity
The build script reads infra/vendor/nono/src/capability.rs to decide whether to set has_nono_signal_mode, but never emits a cargo:rerun-if-changed directive for that path. Without it, Cargo only reruns the script when files inside the clawdstrike package change. If the nono vendor source is updated to add signal_mode() but no clawdstrike file changes, the cfg flag stays stale at false and signal_mode_label silently hard-codes "isolated" in attestation output—even when the sandbox actually allows signals.


Summary
clawdstrikewith the publishedhushspec 0.1.1API instead of the stale vendored0.1.0surfacehushspecsnapshot to match the published crate and keep local builds consistent with crates.io verificationnono::CapabilitySet::signal_mode()dependency fromclawdstrikeattestation outputWhy
cargo publish --dry-run -p clawdstrikewas failing for0.2.7, which is the root reason the Rust release lane drifted after thev0.2.7release. This patch getsclawdstrikeitself back to a real publishable state.Validation
cargo test -p clawdstrike --libcargo test -p clawdstrike --test hushspec_compilercargo publish --dry-run --locked --allow-dirty -p clawdstrikeNote
Medium Risk
Touches policy compilation/merge semantics and sandbox attestation serialization, which can affect enforcement defaults and receipt output, but changes are localized and covered by new/updated tests.
Overview
Makes
clawdstrikepublishable again by updating its manifest metadata (crate-localREADME.md) and aligning the vendoredhushspecdependency to0.1.1(lockfiles refreshed accordingly).Updates the HushSpec compiler and decompiler to match the
hushspec 0.1.1API where several detection/origins fields are now optional, and adds merge-aware tracking so sparse overlays preserve inheritedprompt_injection/jailbreakvalues instead of overwriting with defaults (plus new regression tests).Adjusts sandbox attestation
signal_modereporting to be compatible with upstreamnono: adds abuild.rsprobe + cfg gate and falls back to emitting"isolated"whensignal_mode()is unavailable; CI coverage gating also excludesvendor/hushspec/changes and a new vendoredinfra/vendor/diffsnapshot is added.Written by Cursor Bugbot for commit f490f3e. This will update automatically on new commits. Configure here.