Let just clippy pass on macOS - #43
Merged
Merged
Conversation
The two statvfs helpers, disk_usage in walgit-wal/src/registry.rs and disk_avail in walgit-server/src/rebuild.rs, widen the block-count fields with `as u64`. Those fields are u32 on macOS and u64 on Linux, so on a Mac the strict set fails with cast_lossless and the gate tobi#15 added never passes locally, while `u64::from` would be a useless conversion on Linux where CI runs. No spelling satisfies both platforms, so each helper carries a targeted allow with a comment saying why, the shape the Cargo.toml lint notes ask for. Checked with cargo clippy --workspace --all-targets -- -D warnings on macOS, now clean; the change is a no-op on Linux. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01CSbhRh6UEjFrgBYYzucvDe
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.
just clippyfails on a Mac while CI on Linux is green: the twostatvfshelpers,disk_usageincrates/walgit-wal/src/registry.rsanddisk_availincrates/walgit-server/src/rebuild.rs, widen the block-count fields withas u64, and those fields areu32on macOS andu64on Linux. The strict set flagscast_losslesshere and would flaguseless_conversionthere if the cast becameu64::from, so no spelling satisfies both. Each helper gets a targeted#[allow(clippy::cast_lossless)]with a comment saying why, the shape the lint notes inCargo.tomlask for. Six lines, no behaviour change, a no-op on Linux.Checked with
cargo clippy --workspace --all-targets -- -D warningson macOS, now clean. Part of what #11 asks for: a contributor's laptop and CI agreeing on the gates #15 added.