Repository navigation
ci(rust): make clippy actually run and use it as the single compile gate - #2383
Merged
Merged
Conversation
|
Important Review skippedAuto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the ⚙️ Run configuration
You can disable this status message by setting the Use the checkbox below for a quick retry:
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 |
DeliciousBuding
force-pushed
the
ci/rust-gate-single-pass
branch
from
October 19, 2026 12:55
15ffc7d to
2b374c4
Compare
Co-authored-by: Codex <codex@delicious233.com>
DeliciousBuding
force-pushed
the
ci/rust-gate-single-pass
branch
from
October 19, 2026 13:10
2b374c4 to
bc68af7
Compare
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.
vuln-scan-rustcompiled the desktop crate twice:cargo check --all-targets(blocking) and thencargo clippy --all-targets(advisory,continue-on-error). Both run the same type-check.While checking that, CI showed the advisory one never actually linted:
dtolnay/rust-toolchain@1.96.0installs without the clippy component, andcontinue-on-errorswallowed the failure. So the job paid for a second compile pass that could not have produced a lint result.What changed
dtolnay/rust-toolchainnow installscomponents: clippy, so clippy actually runs.cargo checkstep.cargo clippybecomes the compile gate, and it keeps the exact property the old pair had: compile errors fail the job, lint warnings do not. No-D warningsis configured in the crate (no[lints], noRUSTFLAGS), so clippy's exit code is driven by compilation only — which is whycontinue-on-errorwas there in the first place.swatinem/rust-cache@v2(workspaces: app/desktop/src-tauri -> target), the same cache already used bydesktop-linux-buildand both release jobs. Without it, every desktop-changed PR recompiles the whole dependency tree.Verified locally (cargo 1.96.0, the version CI pins)
cargo clippy --all-targetsonapp/desktop/src-tauri: exits 0, 29 warnings,Finished ... in 1m 44s. Warnings stay advisory, and clippy now surfaces them instead of dying on a missing component.compile_error!probe insrc/lib.rs: exits 101,could not compile agenthub-desktop ... due to 1 previous error. So the compile gate is still blocking. Probe reverted;git statusshows only the workflow file.actionlint -shellcheck=1.7.12 (the validate job's pinned version): exit 0.verify-ci-invariants.pyandverify-doc-ssot.pypass.Net: one fewer full compile pass per Rust-touching PR, dependency caching across runs, and a lint step that actually produces a verdict.