style: unbreak the Linting job on main (rustfmt + macOS precedence guard) - #594
Merged
Conversation
Two independent breakages, both surfaced by the Linting job on PR #593. `cargo fmt --all -- --check` fails on main: the delivery-stats work (#586, merged as #588) landed with five files unformatted — a method chain in the rest subscription-row builder, two in delivery_stats.rs, the `pub use` ordering in the subscriptions lib, the first-try-rate `then()` closure in the UI page, and an assert in subscriptions_http. This is pure `cargo fmt` output; no logic changes. The HTS canonical-precedence guard (#200) then fails on macOS only. `grep -r ... src/` prints `src//backends/mod.rs` under BSD grep, so the literal `grep -v 'src/backends/mod.rs'` exclusion never matched and the script flagged the two sanctioned test constants inside the file it is meant to exclude. The lint job runs on a self-hosted pool with both Linux and macOS runners, so it passed or failed by where it landed; recent greens were all Linux legs. The exclusion is now a regex tolerating the repeated slash. Verified locally: `cargo fmt --all -- --check` clean, the guard script exits 0, and clippy with the CI flag set is clean. Claude-Session: https://claude.ai/code/session_0172oQyVFqtG8stqBPZXriVe
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
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.
The Linting job is red on main and therefore on every open PR — including #593, which changes no Rust at all. Two independent causes.
1.
cargo fmt --all -- --checkfails on mainThe delivery-stats work (#586, merged as #588) landed with five files unformatted:
crates/rest/src/lib.rs— method chain in the subscription-row buildercrates/subscriptions/src/delivery_stats.rs— alock()chain and anassert_eq!crates/subscriptions/src/lib.rs—pub useorderingcrates/ui/src/subscriptions.rs— the first-try-ratethen()closurecrates/ui/tests/subscriptions_http.rs— anassert!with a messageThe diff is verbatim
cargo fmtoutput. No logic changes.2. The HTS canonical-precedence guard (#200) fails on macOS runners
grep -r … src/prints paths assrc//backends/mod.rsunder BSD grep, so the literalgrep -v 'src/backends/mod.rs'exclusion never matched and the script flagged the two sanctioned test constants living in the very file it is meant to exclude. The lint job runs on a[self-hosted]pool with both Linux and macOS runners, so this passed or failed depending on where the job landed — every recent green was a Linux leg, and #593's red landed on macOS. The exclusion is now a regex that tolerates the repeated slash.This one was latent behind the fmt failure: fixing only the formatting would have moved the red one step down the job.
Verification
cargo fmt --all -- --check— cleancrates/hts/scripts/check-canonical-precedence.sh— exits 0 (run on macOS, the leg that was failing)cargo clippy --all-targets --all-featureswith the CI flag set — cleanhttps://claude.ai/code/session_0172oQyVFqtG8stqBPZXriVe