diff --git a/src/api/s3/encryption.rs b/src/api/s3/encryption.rs index ca140af9..0312754e 100644 --- a/src/api/s3/encryption.rs +++ b/src/api/s3/encryption.rs @@ -508,6 +508,7 @@ struct DecryptStream { state: DecryptStreamState, } +#[expect(clippy::large_enum_variant)] enum DecryptStreamState { Starting, Running(DecryptorLE31), diff --git a/src/api/s3/put.rs b/src/api/s3/put.rs index dbe063ed..27f85697 100644 --- a/src/api/s3/put.rs +++ b/src/api/s3/put.rs @@ -554,6 +554,7 @@ pub(crate) async fn read_and_put_blocks> + Ok((total_size, checksums, first_block_hash)) } +#[expect(clippy::too_many_arguments)] async fn put_block_and_meta( ctx: &ReqCtx, version: &Version, diff --git a/src/db/lmdb_adapter.rs b/src/db/lmdb_adapter.rs index 997c074c..dca121fd 100644 --- a/src/db/lmdb_adapter.rs +++ b/src/db/lmdb_adapter.rs @@ -395,7 +395,10 @@ where // this reference will only be stored and accessed from the // returned ValueIter which guarantees that it is destroyed // before the tx it is pointing to. - unsafe { &*&raw const *tx } + #[expect(clippy::deref_addrof)] + unsafe { + &*&raw const *tx + } }; let iter = iterfun(tx_lifetime_overextended)?; diff --git a/src/garage/tests/s3/ssec.rs b/src/garage/tests/s3/ssec.rs index 9f3339f7..02c9b14a 100644 --- a/src/garage/tests/s3/ssec.rs +++ b/src/garage/tests/s3/ssec.rs @@ -399,6 +399,7 @@ async fn test_multipart_upload() { } } +#[expect(clippy::too_many_arguments)] async fn test_read_encrypted( ctx: &Context, bucket: &str, diff --git a/src/model/s3/lifecycle_worker.rs b/src/model/s3/lifecycle_worker.rs index af00437e..a400b5bf 100644 --- a/src/model/s3/lifecycle_worker.rs +++ b/src/model/s3/lifecycle_worker.rs @@ -41,6 +41,7 @@ pub struct LifecycleWorker { persister: PersisterShared, } +#[expect(clippy::large_enum_variant)] enum State { Completed(NaiveDate), Running { @@ -368,6 +369,7 @@ async fn process_object( Ok(Skip::NextObject) } +#[expect(clippy::nonminimal_bool)] fn check_size_filter(version_data: &ObjectVersionData, filter: &LifecycleFilter) -> bool { let size = match version_data { ObjectVersionData::Inline(meta, _) | ObjectVersionData::FirstBlock(meta, _) => meta.size, diff --git a/src/rpc/rpc_helper.rs b/src/rpc/rpc_helper.rs index 9c8c90ff..0f744f5b 100644 --- a/src/rpc/rpc_helper.rs +++ b/src/rpc/rpc_helper.rs @@ -540,6 +540,8 @@ impl RpcHelper { // ---- functions not related to MAKING RPCs, but just determining to what nodes // they should be made and in which order ---- + #[expect(clippy::doc_overindented_list_items)] + #[expect(clippy::doc_lazy_continuation)] /// Determine to what nodes, and in what order, requests to read a data block /// should be sent. All nodes in the Vec returned by this function are tried /// one by one until there is one that returns the block (in block/manager.rs).