Skip to content

chore(lint): enable clippy::allow_attributes_without_reason#13

Open
tupe12334 wants to merge 1 commit into
mainfrom
fix/issue-11-allow-attributes-without-reason
Open

chore(lint): enable clippy::allow_attributes_without_reason#13
tupe12334 wants to merge 1 commit into
mainfrom
fix/issue-11-allow-attributes-without-reason

Conversation

@tupe12334

Copy link
Copy Markdown
Member

What

Enables the clippy::allow_attributes_without_reason restriction lint at deny level in lib/Cargo.toml, and adds a reason = "..." to every existing #[allow(...)] / #![allow(...)] site.

Why

This crate already denies a strong panic-safety set (unwrap_used, expect_used, panic, indexing_slicing, …), but the suppressions that opt out carried no recorded justification. Requiring a reason makes every suppression self-documenting and auditable in review.

Sites updated

  • Test-module opt-outs of the panic lints in download.rs, extract.rs, daemon.rs, github.rs, platform.rs, lib.rs, install.rs, and the tests/e2e_install.rs integration test — all gain reason = "tests deliberately unwrap/panic to fail fast on broken fixtures".
  • The retained ReleaseInfo::tag dead_code allow gains reason = "retained for consumers that need the resolved tag".

No production logic changes.

Verification

cargo clippy --manifest-path lib/Cargo.toml --all-targets -- -D warnings and cargo test --manifest-path lib/Cargo.toml both pass.

Closes #11


🤖 Generated with Claude Code

This pull request was opened by the "Open issues → fix PRs (owned repos + my orgs)" routine of moadim.

Deny clippy::allow_attributes_without_reason in lib/Cargo.toml and add a
reason = "..." to every existing #[allow(...)] site (test modules opting out
of the panic-safety lints, plus the retained dead_code tag field). No
production logic changes.

Closes #11

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Enable clippy::allow_attributes_without_reason lint rule

1 participant