Fail CI on Rust advisories, and on a skipped Rust check - #450
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Advanced Run ID: 📒 Files selected for processing (1)
Included review availability: Your plan provides up to 1 included review per hour; 0 remain after this review. 📝 WalkthroughWalkthroughThe workflow adds a Rust advisory audit job. The aggregate Rust job now waits for the shared, desktop, and audit jobs and fails unless all three succeed. ChangesRust CI validation
Priority: ⬇️ Low Estimated code review effort: 2 (Simple) | ~10 minutes Change: Feature Suggested reviewers: Sequence Diagram(s)sequenceDiagram
participant RustShared
participant RustDesktop
participant AuditJob
participant RustAggregate
RustShared-->>RustAggregate: provide result
RustDesktop-->>RustAggregate: provide result
AuditJob-->>RustAggregate: provide result
RustAggregate->>RustAggregate: fail unless all results are success
Merge Risk: ⚪ Minimal · up to The Rust advisory audit and aggregate check should correctly report dependency failures, skips, and cancellations under normal workflow execution. 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 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 |
Deploying with
|
| Status | Name | Latest Commit | Preview URL | Updated (UTC) |
|---|---|---|---|---|
| ✅ Deployment successful! View logs |
ceiling | d20dcd2 | Commit Preview URL Branch Preview URL |
Sep 18 2026, 12:49 AM |
RUSTSEC-2026-0285(rustls) andRUSTSEC-2026-0258(h2) both shipped in a released build and neither was visible from CI. Nothing here rancargo audit, somainstayed green while the lockfile carried them, and they were only found by looking by hand. This adds the gate.What changes
New
auditjob (Rust / advisory audit, ubuntu, 15 minute timeout). It installs cargo-audit throughtaiki-e/install-actionpinned to a full commit SHA with the version comment, as the other third-party actions here are, and runscargo audit --file Cargo.lockat the workspace root, which covers both manifests from the single root lockfile.Only vulnerabilities fail it. The advisory categories that are informational (unmaintained, unsound, yanked) do not, so the 11 currently open against this graph keep reporting without blocking a pull request:
fxhash,proc-macro-error, theunic-*set,event-listener,glib,rand 0.7. A real vulnerability has to be bumped, or waived with an explicit--ignorenext to a comment saying why, which is the shape a genuine lockfile-only entry would take.The
Rustaggregate now includes it, and fails instead of skipping. It wasneeds: [rust-shared, rust-desktop]with a bareecho. A job that is skipped because a job it needs failed reports as skipped rather than failed, so a redRust / sharedorRust / desktopleft the requiredRustcheck looking satisfied. It now runsif: always()and fails unless all three jobs, including the audit, report success.Rustis already a required status check onmain, so the audit blocks merges without any repository settings change.Verification
The aggregate's shell logic was exercised both ways: all-success passes, and one
failureresult exits 1 with the error annotation, so the required check goes red rather than quiet.Expect this to bite once
The first time a vulnerability is published against a crate this repo already pins,
maingoes red and stays red until it is bumped or waived. That is the point, and it is the difference between this and what happened with rustls and h2.Note
Add
cargo auditjob to CI and failRustaggregate status on skipped checksauditjob to the CI workflow that runscargo audit --file Cargo.lockwith a 15-minute timeout, failing on unignored vulnerability advisories.Rustaggregate-status job in ci.yml to run withif: always(), depend onrust-shared,rust-desktop, andaudit, and fail unless all three reportsuccess.Rustcheck now fails whencargo auditfinds advisories or when any required Rust job is skipped; previously it always reported success.Macroscope summarized d20dcd2.
Summary by CodeRabbit