mirror of
https://github.com/fabro-sh/fabro.git
synced 2026-10-08 03:10:26 +00:00
chore(clippy): add unwrap-used baseline
Enable clippy's unwrap_used lint at warn level, document the long-term policy carveouts for tests and LockResult, and localize the generated OpenAPI client exemption so the remaining warning surface is real repo code.
This commit is contained in:
parent
72924ba611
commit
83743de293
3 changed files with 4 additions and 0 deletions
|
|
@ -106,6 +106,7 @@ empty_structs_with_brackets = "warn"
|
|||
disallowed_methods = "deny"
|
||||
exit = "warn"
|
||||
get_unwrap = "warn"
|
||||
unwrap_used = "warn"
|
||||
rc_buffer = "warn"
|
||||
rc_mutex = "warn"
|
||||
rest_pat_in_fully_bound_structs = "warn"
|
||||
|
|
|
|||
|
|
@ -1,5 +1,7 @@
|
|||
absolute-paths-max-segments = 2
|
||||
absolute-paths-allowed-crates = ["std", "core", "alloc"]
|
||||
allow-unwrap-in-tests = true
|
||||
allow-unwrap-types = ["std::sync::LockResult"]
|
||||
disallowed-methods = [
|
||||
{ path = "std::thread::sleep", reason = "Prefer tokio::time::sleep on Tokio paths; document intentional blocking sleeps with #[expect(clippy::disallowed_methods, reason = \"...\")]", replacement = "tokio::time::sleep" },
|
||||
{ path = "std::thread::spawn", reason = "Prefer Tokio task APIs on async paths; document intentional dedicated OS threads with #[expect(clippy::disallowed_methods, reason = \"...\")]" },
|
||||
|
|
|
|||
|
|
@ -5,6 +5,7 @@
|
|||
clippy::disallowed_methods,
|
||||
clippy::disallowed_types,
|
||||
clippy::needless_lifetimes,
|
||||
clippy::unwrap_used,
|
||||
unreachable_pub,
|
||||
unused_imports,
|
||||
reason = "Generated OpenAPI client code intentionally preserves codegen output."
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue