From 9aa44093cf2db327220d03386beebd6cc653d87e Mon Sep 17 00:00:00 2001 From: Thomas Coratger <60488569+tcoratger@users.noreply.github.com> Date: Thu, 4 Jan 2024 14:38:02 +0100 Subject: [PATCH] lints: move top-level lints to [workspace.lints] manifest table (#5935) --- Cargo.toml | 8 ++++++++ bin/reth/Cargo.toml | 3 +++ bin/reth/build.rs | 2 ++ bin/reth/src/lib.rs | 3 +-- bin/reth/src/main.rs | 1 + bin/reth/src/optimism.rs | 1 + crates/blockchain-tree/Cargo.toml | 3 +++ crates/blockchain-tree/src/lib.rs | 2 -- crates/config/Cargo.toml | 3 +++ crates/config/src/lib.rs | 2 -- crates/consensus/auto-seal/Cargo.toml | 3 +++ crates/consensus/auto-seal/src/lib.rs | 4 +--- crates/consensus/auto-seal/tests/it/auto_mine.rs | 1 + crates/consensus/beacon/Cargo.toml | 3 +++ crates/consensus/beacon/src/lib.rs | 8 -------- crates/consensus/common/Cargo.toml | 5 ++++- crates/consensus/common/src/lib.rs | 2 -- crates/ethereum-forks/Cargo.toml | 3 +++ crates/ethereum-forks/src/lib.rs | 2 -- crates/interfaces/Cargo.toml | 3 +++ crates/interfaces/src/lib.rs | 9 +-------- crates/metrics/Cargo.toml | 3 +++ crates/metrics/metrics-derive/Cargo.toml | 3 +++ crates/metrics/metrics-derive/src/lib.rs | 2 -- crates/metrics/src/lib.rs | 2 -- crates/net/common/Cargo.toml | 3 +++ crates/net/common/src/lib.rs | 2 -- crates/net/discv4/Cargo.toml | 3 +++ crates/net/discv4/src/lib.rs | 4 +--- crates/net/dns/Cargo.toml | 3 +++ crates/net/dns/src/lib.rs | 4 +--- crates/net/downloaders/Cargo.toml | 3 +++ crates/net/downloaders/src/lib.rs | 2 -- crates/net/ecies/Cargo.toml | 3 +++ crates/net/ecies/src/lib.rs | 2 -- crates/net/eth-wire/Cargo.toml | 3 +++ crates/net/eth-wire/src/lib.rs | 2 -- crates/net/nat/Cargo.toml | 3 +++ crates/net/nat/src/lib.rs | 2 -- crates/net/network-api/Cargo.toml | 3 +++ crates/net/network-api/src/lib.rs | 2 -- crates/net/network/Cargo.toml | 3 +++ crates/net/network/benches/bench.rs | 1 + crates/net/network/src/lib.rs | 3 +-- crates/net/network/tests/it/clique/clique_middleware.rs | 1 + crates/net/network/tests/it/clique/geth.rs | 1 + crates/net/network/tests/it/clique/mod.rs | 1 + crates/net/network/tests/it/multiplex.rs | 1 + crates/net/network/tests/it/requests.rs | 1 + crates/payload/basic/Cargo.toml | 3 +++ crates/payload/basic/src/lib.rs | 8 -------- crates/payload/builder/Cargo.toml | 3 +++ crates/payload/builder/src/lib.rs | 2 -- crates/payload/ethereum/Cargo.toml | 5 ++++- crates/payload/ethereum/src/lib.rs | 2 -- crates/payload/optimism/Cargo.toml | 5 ++++- crates/payload/optimism/src/lib.rs | 2 -- crates/payload/validator/Cargo.toml | 5 ++++- crates/payload/validator/src/lib.rs | 9 +-------- crates/primitives/Cargo.toml | 3 +++ crates/primitives/benches/nibbles.rs | 1 + crates/primitives/benches/recover_ecdsa_crit.rs | 1 + crates/primitives/benches/trie_root.rs | 1 + crates/primitives/src/lib.rs | 2 -- crates/prune/Cargo.toml | 3 +++ crates/prune/src/lib.rs | 3 +-- crates/revm/Cargo.toml | 3 +++ crates/revm/revm-inspectors/Cargo.toml | 5 ++++- crates/revm/revm-inspectors/src/lib.rs | 2 -- crates/revm/src/lib.rs | 2 -- crates/rpc/ipc/Cargo.toml | 3 +++ crates/rpc/ipc/src/lib.rs | 2 -- crates/rpc/rpc-api/Cargo.toml | 3 +++ crates/rpc/rpc-api/src/lib.rs | 2 -- crates/rpc/rpc-builder/Cargo.toml | 3 +++ crates/rpc/rpc-builder/src/lib.rs | 2 -- crates/rpc/rpc-builder/tests/it/http.rs | 1 + crates/rpc/rpc-builder/tests/it/serde.rs | 2 +- crates/rpc/rpc-engine-api/Cargo.toml | 5 ++++- crates/rpc/rpc-engine-api/src/lib.rs | 2 -- crates/rpc/rpc-testing-util/Cargo.toml | 3 +++ crates/rpc/rpc-testing-util/src/lib.rs | 2 -- crates/rpc/rpc-types-compat/Cargo.toml | 3 +++ crates/rpc/rpc-types-compat/src/lib.rs | 2 -- crates/rpc/rpc-types/Cargo.toml | 3 +++ crates/rpc/rpc-types/src/lib.rs | 2 -- crates/rpc/rpc/Cargo.toml | 4 ++++ crates/rpc/rpc/src/lib.rs | 2 -- crates/snapshot/Cargo.toml | 3 +++ crates/snapshot/src/lib.rs | 2 -- crates/stages/Cargo.toml | 3 +++ crates/stages/benches/criterion.rs | 1 + crates/stages/benches/setup/account_hashing.rs | 1 + crates/stages/benches/setup/constants.rs | 1 + crates/stages/benches/setup/mod.rs | 1 + crates/stages/src/lib.rs | 2 -- crates/storage/codecs/Cargo.toml | 5 ++++- crates/storage/codecs/derive/Cargo.toml | 3 +++ crates/storage/codecs/derive/src/lib.rs | 6 +++--- crates/storage/codecs/src/lib.rs | 9 +-------- crates/storage/db/Cargo.toml | 3 +++ crates/storage/db/benches/criterion.rs | 1 + crates/storage/db/benches/hash_keys.rs | 1 + crates/storage/db/benches/iai.rs | 2 +- crates/storage/db/build.rs | 2 ++ crates/storage/db/src/lib.rs | 2 -- crates/storage/libmdbx-rs/Cargo.toml | 3 +++ crates/storage/libmdbx-rs/benches/cursor.rs | 1 + crates/storage/libmdbx-rs/benches/transaction.rs | 1 + crates/storage/libmdbx-rs/benches/utils.rs | 1 + crates/storage/libmdbx-rs/src/lib.rs | 3 +-- crates/storage/nippy-jar/Cargo.toml | 5 ++++- crates/storage/nippy-jar/src/lib.rs | 3 +-- crates/storage/provider/Cargo.toml | 3 +++ crates/storage/provider/src/lib.rs | 2 -- crates/tasks/Cargo.toml | 3 +++ crates/tasks/src/lib.rs | 2 -- crates/tokio-util/Cargo.toml | 3 +++ crates/tokio-util/src/lib.rs | 2 -- crates/tracing/Cargo.toml | 3 +++ crates/tracing/src/lib.rs | 2 -- crates/transaction-pool/Cargo.toml | 3 +++ crates/transaction-pool/src/lib.rs | 2 -- crates/trie/Cargo.toml | 5 ++++- crates/trie/benches/prefix_set.rs | 1 + crates/trie/src/lib.rs | 2 -- testing/ef-tests/Cargo.toml | 3 +++ testing/ef-tests/src/lib.rs | 2 -- 128 files changed, 211 insertions(+), 145 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index 84fd76b96a..6734ecabe2 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -66,6 +66,14 @@ default-members = ["bin/reth"] # https://doc.rust-lang.org/edition-guide/rust-2021/default-cargo-resolver.html resolver = "2" +[workspace.lints] +rust.missing_debug_implementations = "warn" +rust.missing_docs = "warn" +rust.unreachable_pub = "warn" +rustdoc.all = "warn" +rust.unused_must_use = "deny" +rust.rust_2018_idioms = "deny" + [workspace.package] version = "0.1.0-alpha.13" edition = "2021" diff --git a/bin/reth/Cargo.toml b/bin/reth/Cargo.toml index 281fe9e3bd..4ad25b1cd0 100644 --- a/bin/reth/Cargo.toml +++ b/bin/reth/Cargo.toml @@ -9,6 +9,9 @@ repository.workspace = true description = "Reth node implementation" default-run = "reth" +[lints] +workspace = true + [package.metadata.cargo-udeps.ignore] normal = [ # Used for diagrams in docs diff --git a/bin/reth/build.rs b/bin/reth/build.rs index b06bdf197c..f24f9b22db 100644 --- a/bin/reth/build.rs +++ b/bin/reth/build.rs @@ -1,3 +1,5 @@ +#![allow(missing_docs)] + use std::error::Error; use vergen::EmitBuilder; diff --git a/bin/reth/src/lib.rs b/bin/reth/src/lib.rs index 3a6e0fce53..e260778e81 100644 --- a/bin/reth/src/lib.rs +++ b/bin/reth/src/lib.rs @@ -24,8 +24,7 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_docs, unreachable_pub, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] +#![allow(missing_debug_implementations)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] pub mod args; diff --git a/bin/reth/src/main.rs b/bin/reth/src/main.rs index 44c5655b84..ea057ee6b3 100644 --- a/bin/reth/src/main.rs +++ b/bin/reth/src/main.rs @@ -1,4 +1,5 @@ // We use jemalloc for performance reasons +#![allow(missing_docs)] #[cfg(all(feature = "jemalloc", unix))] #[global_allocator] static ALLOC: jemallocator::Jemalloc = jemallocator::Jemalloc; diff --git a/bin/reth/src/optimism.rs b/bin/reth/src/optimism.rs index 554b91a3ae..89ba2dd840 100644 --- a/bin/reth/src/optimism.rs +++ b/bin/reth/src/optimism.rs @@ -1,3 +1,4 @@ +#![allow(missing_docs, rustdoc::missing_crate_level_docs)] // We use jemalloc for performance reasons #[cfg(all(feature = "jemalloc", unix))] #[global_allocator] diff --git a/crates/blockchain-tree/Cargo.toml b/crates/blockchain-tree/Cargo.toml index c5f0c3a0c7..fd4b97e0ed 100644 --- a/crates/blockchain-tree/Cargo.toml +++ b/crates/blockchain-tree/Cargo.toml @@ -7,6 +7,9 @@ license.workspace = true homepage.workspace = true repository.workspace = true +[lints] +workspace = true + [package.metadata.cargo-udeps.ignore] normal = [ # Used for diagrams in docs diff --git a/crates/blockchain-tree/src/lib.rs b/crates/blockchain-tree/src/lib.rs index b825ce5bea..6bb3d5412b 100644 --- a/crates/blockchain-tree/src/lib.rs +++ b/crates/blockchain-tree/src/lib.rs @@ -15,8 +15,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, unreachable_pub, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] pub mod blockchain_tree; diff --git a/crates/config/Cargo.toml b/crates/config/Cargo.toml index 7eb14b5eef..fbea21259d 100644 --- a/crates/config/Cargo.toml +++ b/crates/config/Cargo.toml @@ -7,6 +7,9 @@ license.workspace = true homepage.workspace = true repository.workspace = true +[lints] +workspace = true + [dependencies] # reth reth-network.workspace = true diff --git a/crates/config/src/lib.rs b/crates/config/src/lib.rs index 764397f6a2..362e814632 100644 --- a/crates/config/src/lib.rs +++ b/crates/config/src/lib.rs @@ -5,8 +5,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, unreachable_pub, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] pub mod config; diff --git a/crates/consensus/auto-seal/Cargo.toml b/crates/consensus/auto-seal/Cargo.toml index 704b7a97ae..10538ad193 100644 --- a/crates/consensus/auto-seal/Cargo.toml +++ b/crates/consensus/auto-seal/Cargo.toml @@ -8,6 +8,9 @@ homepage.workspace = true repository.workspace = true description = "A consensus impl for local testing purposes" +[lints] +workspace = true + [dependencies] # reth reth-beacon-consensus.workspace = true diff --git a/crates/consensus/auto-seal/src/lib.rs b/crates/consensus/auto-seal/src/lib.rs index b4cd16ff06..b219f083bc 100644 --- a/crates/consensus/auto-seal/src/lib.rs +++ b/crates/consensus/auto-seal/src/lib.rs @@ -12,8 +12,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, unreachable_pub, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] use reth_beacon_consensus::BeaconEngineMessage; @@ -42,7 +40,7 @@ use std::{ time::{SystemTime, UNIX_EPOCH}, }; use tokio::sync::{mpsc::UnboundedSender, RwLock, RwLockReadGuard, RwLockWriteGuard}; -use tracing::{trace, warn}; +use tracing::trace; mod client; mod mode; diff --git a/crates/consensus/auto-seal/tests/it/auto_mine.rs b/crates/consensus/auto-seal/tests/it/auto_mine.rs index 7417f830b9..6b4bf15446 100644 --- a/crates/consensus/auto-seal/tests/it/auto_mine.rs +++ b/crates/consensus/auto-seal/tests/it/auto_mine.rs @@ -1,3 +1,4 @@ +#![allow(unreachable_pub)] //! auto-mine consensus integration test use clap::Parser; diff --git a/crates/consensus/beacon/Cargo.toml b/crates/consensus/beacon/Cargo.toml index d892b6c262..9fd50ca82b 100644 --- a/crates/consensus/beacon/Cargo.toml +++ b/crates/consensus/beacon/Cargo.toml @@ -7,6 +7,9 @@ license.workspace = true homepage.workspace = true repository.workspace = true +[lints] +workspace = true + [dependencies] # reth reth-beacon-consensus-core.workspace = true diff --git a/crates/consensus/beacon/src/lib.rs b/crates/consensus/beacon/src/lib.rs index 00ee920dc8..f548691529 100644 --- a/crates/consensus/beacon/src/lib.rs +++ b/crates/consensus/beacon/src/lib.rs @@ -5,14 +5,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn( - missing_debug_implementations, - missing_docs, - unused_crate_dependencies, - unreachable_pub, - rustdoc::all -)] -#![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] pub use reth_beacon_consensus_core::BeaconConsensus; diff --git a/crates/consensus/common/Cargo.toml b/crates/consensus/common/Cargo.toml index 0a32714919..c8690d02bb 100644 --- a/crates/consensus/common/Cargo.toml +++ b/crates/consensus/common/Cargo.toml @@ -7,8 +7,11 @@ license.workspace = true homepage.workspace = true repository.workspace = true +[lints] +workspace = true + [dependencies] -# reth +# reth reth-primitives.workspace = true reth-interfaces.workspace = true reth-provider.workspace = true diff --git a/crates/consensus/common/src/lib.rs b/crates/consensus/common/src/lib.rs index f1bb63a039..fce6d957a7 100644 --- a/crates/consensus/common/src/lib.rs +++ b/crates/consensus/common/src/lib.rs @@ -5,8 +5,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, unreachable_pub, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] /// Collection of consensus validation methods. diff --git a/crates/ethereum-forks/Cargo.toml b/crates/ethereum-forks/Cargo.toml index d4ee55f14c..99ecf2ef16 100644 --- a/crates/ethereum-forks/Cargo.toml +++ b/crates/ethereum-forks/Cargo.toml @@ -8,6 +8,9 @@ homepage.workspace = true repository.workspace = true description = "Ethereum fork types used in reth." +[lints] +workspace = true + [dependencies] # reth reth-codecs.workspace = true diff --git a/crates/ethereum-forks/src/lib.rs b/crates/ethereum-forks/src/lib.rs index c03b0f8405..f8c8238a46 100644 --- a/crates/ethereum-forks/src/lib.rs +++ b/crates/ethereum-forks/src/lib.rs @@ -11,8 +11,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, unreachable_pub, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms, unused_crate_dependencies)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] mod forkid; diff --git a/crates/interfaces/Cargo.toml b/crates/interfaces/Cargo.toml index 58f70059b8..fafcdaf88e 100644 --- a/crates/interfaces/Cargo.toml +++ b/crates/interfaces/Cargo.toml @@ -7,6 +7,9 @@ license.workspace = true homepage.workspace = true repository.workspace = true +[lints] +workspace = true + [dependencies] reth-primitives.workspace = true reth-nippy-jar.workspace = true diff --git a/crates/interfaces/src/lib.rs b/crates/interfaces/src/lib.rs index 7764bfc790..3e92ea5929 100644 --- a/crates/interfaces/src/lib.rs +++ b/crates/interfaces/src/lib.rs @@ -9,14 +9,7 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn( - missing_debug_implementations, - missing_docs, - unused_crate_dependencies, - unreachable_pub, - rustdoc::all -)] -#![deny(unused_must_use, rust_2018_idioms)] +#![warn(unused_crate_dependencies)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] /// Consensus traits. diff --git a/crates/metrics/Cargo.toml b/crates/metrics/Cargo.toml index dcec46cd46..015f24d232 100644 --- a/crates/metrics/Cargo.toml +++ b/crates/metrics/Cargo.toml @@ -8,6 +8,9 @@ homepage.workspace = true repository.workspace = true description = "reth metrics utilities" +[lints] +workspace = true + [dependencies] # reth reth-metrics-derive.workspace = true diff --git a/crates/metrics/metrics-derive/Cargo.toml b/crates/metrics/metrics-derive/Cargo.toml index 6f3a6ba467..732e3d5433 100644 --- a/crates/metrics/metrics-derive/Cargo.toml +++ b/crates/metrics/metrics-derive/Cargo.toml @@ -7,6 +7,9 @@ license.workspace = true homepage.workspace = true repository.workspace = true +[lints] +workspace = true + [lib] proc-macro = true diff --git a/crates/metrics/metrics-derive/src/lib.rs b/crates/metrics/metrics-derive/src/lib.rs index 24e7bafa0e..8b6c3dc7e5 100644 --- a/crates/metrics/metrics-derive/src/lib.rs +++ b/crates/metrics/metrics-derive/src/lib.rs @@ -5,8 +5,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, unreachable_pub, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] use proc_macro::TokenStream; diff --git a/crates/metrics/src/lib.rs b/crates/metrics/src/lib.rs index 71eb722530..285e4dc314 100644 --- a/crates/metrics/src/lib.rs +++ b/crates/metrics/src/lib.rs @@ -10,8 +10,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, unreachable_pub, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] /// Metrics derive macro. diff --git a/crates/net/common/Cargo.toml b/crates/net/common/Cargo.toml index 0535b58be4..8d85fc9067 100644 --- a/crates/net/common/Cargo.toml +++ b/crates/net/common/Cargo.toml @@ -8,6 +8,9 @@ homepage.workspace = true repository.workspace = true description = "Types shared across network code" +[lints] +workspace = true + [dependencies] # reth reth-primitives.workspace = true diff --git a/crates/net/common/src/lib.rs b/crates/net/common/src/lib.rs index f65702aaec..d5ad6c7046 100644 --- a/crates/net/common/src/lib.rs +++ b/crates/net/common/src/lib.rs @@ -5,8 +5,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, unreachable_pub, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] pub mod ban_list; diff --git a/crates/net/discv4/Cargo.toml b/crates/net/discv4/Cargo.toml index 274a32893e..74b6d4786d 100644 --- a/crates/net/discv4/Cargo.toml +++ b/crates/net/discv4/Cargo.toml @@ -8,6 +8,9 @@ homepage.workspace = true repository.workspace = true description = "Ethereum network discovery" +[lints] +workspace = true + [dependencies] # reth reth-primitives.workspace = true diff --git a/crates/net/discv4/src/lib.rs b/crates/net/discv4/src/lib.rs index 734bb2433a..8fdfd16a98 100644 --- a/crates/net/discv4/src/lib.rs +++ b/crates/net/discv4/src/lib.rs @@ -21,8 +21,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms, unreachable_pub, unused_crate_dependencies)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] use crate::{ @@ -64,7 +62,7 @@ use tokio::{ time::Interval, }; use tokio_stream::{wrappers::ReceiverStream, Stream, StreamExt}; -use tracing::{debug, trace, warn}; +use tracing::{debug, trace}; pub mod error; pub mod proto; diff --git a/crates/net/dns/Cargo.toml b/crates/net/dns/Cargo.toml index 02dd202d7b..3a0c2d3ec5 100644 --- a/crates/net/dns/Cargo.toml +++ b/crates/net/dns/Cargo.toml @@ -8,6 +8,9 @@ homepage.workspace = true repository.workspace = true description = "Support for EIP-1459 Node Discovery via DNS" +[lints] +workspace = true + [dependencies] # reth reth-primitives.workspace = true diff --git a/crates/net/dns/src/lib.rs b/crates/net/dns/src/lib.rs index 878ec20240..f72ac4b2e1 100644 --- a/crates/net/dns/src/lib.rs +++ b/crates/net/dns/src/lib.rs @@ -10,8 +10,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, unreachable_pub, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] pub use crate::resolver::{DnsResolver, MapResolver, Resolver}; @@ -47,7 +45,7 @@ use tokio_stream::{ wrappers::{ReceiverStream, UnboundedReceiverStream}, Stream, StreamExt, }; -use tracing::{debug, trace, warn}; +use tracing::{debug, trace}; mod config; mod error; diff --git a/crates/net/downloaders/Cargo.toml b/crates/net/downloaders/Cargo.toml index 0ed401223e..f1cd2b2344 100644 --- a/crates/net/downloaders/Cargo.toml +++ b/crates/net/downloaders/Cargo.toml @@ -8,6 +8,9 @@ homepage.workspace = true repository.workspace = true description = "Implementations of various block downloaders" +[lints] +workspace = true + [dependencies] # reth reth-interfaces.workspace = true diff --git a/crates/net/downloaders/src/lib.rs b/crates/net/downloaders/src/lib.rs index 042c749eae..02743ec26e 100644 --- a/crates/net/downloaders/src/lib.rs +++ b/crates/net/downloaders/src/lib.rs @@ -9,8 +9,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, unreachable_pub, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] /// The collection of algorithms for downloading block bodies. diff --git a/crates/net/ecies/Cargo.toml b/crates/net/ecies/Cargo.toml index f578c4f09a..748def5571 100644 --- a/crates/net/ecies/Cargo.toml +++ b/crates/net/ecies/Cargo.toml @@ -7,6 +7,9 @@ license.workspace = true homepage.workspace = true repository.workspace = true +[lints] +workspace = true + [dependencies] reth-primitives.workspace = true reth-net-common.workspace = true diff --git a/crates/net/ecies/src/lib.rs b/crates/net/ecies/src/lib.rs index bd2449d03a..54cdffb7eb 100644 --- a/crates/net/ecies/src/lib.rs +++ b/crates/net/ecies/src/lib.rs @@ -5,8 +5,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, unreachable_pub, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] pub mod algorithm; diff --git a/crates/net/eth-wire/Cargo.toml b/crates/net/eth-wire/Cargo.toml index 29e6adcf0e..2030a280d3 100644 --- a/crates/net/eth-wire/Cargo.toml +++ b/crates/net/eth-wire/Cargo.toml @@ -8,6 +8,9 @@ license.workspace = true homepage.workspace = true repository.workspace = true +[lints] +workspace = true + [dependencies] # reth reth-codecs.workspace = true diff --git a/crates/net/eth-wire/src/lib.rs b/crates/net/eth-wire/src/lib.rs index c090deb5f6..cfb2fd9fc9 100644 --- a/crates/net/eth-wire/src/lib.rs +++ b/crates/net/eth-wire/src/lib.rs @@ -10,8 +10,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, unreachable_pub, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] pub mod builder; diff --git a/crates/net/nat/Cargo.toml b/crates/net/nat/Cargo.toml index 86ba73b931..d19023be11 100644 --- a/crates/net/nat/Cargo.toml +++ b/crates/net/nat/Cargo.toml @@ -8,6 +8,9 @@ homepage.workspace = true repository.workspace = true description = "Helpers for working around NAT" +[lints] +workspace = true + [dependencies] # nat diff --git a/crates/net/nat/src/lib.rs b/crates/net/nat/src/lib.rs index 080319eef2..855cf47ff6 100644 --- a/crates/net/nat/src/lib.rs +++ b/crates/net/nat/src/lib.rs @@ -9,8 +9,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, unreachable_pub, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] use igd::aio::search_gateway; diff --git a/crates/net/network-api/Cargo.toml b/crates/net/network-api/Cargo.toml index 51bd3a58a2..145826cd96 100644 --- a/crates/net/network-api/Cargo.toml +++ b/crates/net/network-api/Cargo.toml @@ -8,6 +8,9 @@ homepage.workspace = true repository.workspace = true description = "Network interfaces" +[lints] +workspace = true + [dependencies] # reth reth-primitives.workspace = true diff --git a/crates/net/network-api/src/lib.rs b/crates/net/network-api/src/lib.rs index 5d97f32068..4afa7673f7 100644 --- a/crates/net/network-api/src/lib.rs +++ b/crates/net/network-api/src/lib.rs @@ -11,8 +11,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, unreachable_pub, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] use async_trait::async_trait; diff --git a/crates/net/network/Cargo.toml b/crates/net/network/Cargo.toml index d861b2cfe8..0e363eebf2 100644 --- a/crates/net/network/Cargo.toml +++ b/crates/net/network/Cargo.toml @@ -8,6 +8,9 @@ homepage.workspace = true repository.workspace = true description = "Ethereum network support" +[lints] +workspace = true + [package.metadata.cargo-udeps.ignore] normal = [ # Used for diagrams in docs diff --git a/crates/net/network/benches/bench.rs b/crates/net/network/benches/bench.rs index 9f4fb56659..a4bd2410b5 100644 --- a/crates/net/network/benches/bench.rs +++ b/crates/net/network/benches/bench.rs @@ -1,3 +1,4 @@ +#![allow(missing_docs)] use criterion::*; use futures::StreamExt; use pprof::criterion::{Output, PProfProfiler}; diff --git a/crates/net/network/src/lib.rs b/crates/net/network/src/lib.rs index 4c102b78f4..526330b573 100644 --- a/crates/net/network/src/lib.rs +++ b/crates/net/network/src/lib.rs @@ -106,8 +106,7 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, rustdoc::all)] // TODO(danipopes): unreachable_pub -#![deny(unused_must_use, rust_2018_idioms)] +#![allow(unreachable_pub)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] #[cfg(any(test, feature = "test-utils"))] diff --git a/crates/net/network/tests/it/clique/clique_middleware.rs b/crates/net/network/tests/it/clique/clique_middleware.rs index e79d80e964..4d3d1cad40 100644 --- a/crates/net/network/tests/it/clique/clique_middleware.rs +++ b/crates/net/network/tests/it/clique/clique_middleware.rs @@ -1,3 +1,4 @@ +#![allow(unreachable_pub)] //! Helper extension traits for working with clique providers. use async_trait::async_trait; diff --git a/crates/net/network/tests/it/clique/geth.rs b/crates/net/network/tests/it/clique/geth.rs index b512efd2e4..6534fd87db 100644 --- a/crates/net/network/tests/it/clique/geth.rs +++ b/crates/net/network/tests/it/clique/geth.rs @@ -1,3 +1,4 @@ +#![allow(unreachable_pub)] //! Helper struct for working with a clique geth instance. use enr::k256::ecdsa::SigningKey; diff --git a/crates/net/network/tests/it/clique/mod.rs b/crates/net/network/tests/it/clique/mod.rs index d8fb1070c6..8328234e3e 100644 --- a/crates/net/network/tests/it/clique/mod.rs +++ b/crates/net/network/tests/it/clique/mod.rs @@ -1,3 +1,4 @@ +#![allow(unreachable_pub)] pub mod clique_middleware; mod geth; diff --git a/crates/net/network/tests/it/multiplex.rs b/crates/net/network/tests/it/multiplex.rs index 6ed8125331..1e61efb4d2 100644 --- a/crates/net/network/tests/it/multiplex.rs +++ b/crates/net/network/tests/it/multiplex.rs @@ -1,3 +1,4 @@ +#![allow(unreachable_pub)] //! Testing gossiping of transactions. use crate::multiplex::proto::{PingPongProtoMessage, PingPongProtoMessageKind}; diff --git a/crates/net/network/tests/it/requests.rs b/crates/net/network/tests/it/requests.rs index 3ea46d189a..535cf41675 100644 --- a/crates/net/network/tests/it/requests.rs +++ b/crates/net/network/tests/it/requests.rs @@ -1,3 +1,4 @@ +#![allow(unreachable_pub)] //! Tests for eth related requests use rand::Rng; diff --git a/crates/payload/basic/Cargo.toml b/crates/payload/basic/Cargo.toml index 4ecbaa698b..374a6e36e4 100644 --- a/crates/payload/basic/Cargo.toml +++ b/crates/payload/basic/Cargo.toml @@ -8,6 +8,9 @@ homepage.workspace = true repository.workspace = true description = "A basic payload builder for reth that uses the txpool API to build payloads." +[lints] +workspace = true + [dependencies] # reth reth-primitives.workspace = true diff --git a/crates/payload/basic/src/lib.rs b/crates/payload/basic/src/lib.rs index 3f07ca28fc..21fc1ab2c0 100644 --- a/crates/payload/basic/src/lib.rs +++ b/crates/payload/basic/src/lib.rs @@ -5,14 +5,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn( - missing_debug_implementations, - missing_docs, - unused_crate_dependencies, - unreachable_pub, - rustdoc::all -)] -#![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] use alloy_rlp::Encodable; diff --git a/crates/payload/builder/Cargo.toml b/crates/payload/builder/Cargo.toml index 056629ce69..854b182459 100644 --- a/crates/payload/builder/Cargo.toml +++ b/crates/payload/builder/Cargo.toml @@ -8,6 +8,9 @@ homepage.workspace = true repository.workspace = true description = "reth payload builder" +[lints] +workspace = true + [dependencies] # reth reth-primitives.workspace = true diff --git a/crates/payload/builder/src/lib.rs b/crates/payload/builder/src/lib.rs index 0d5bdec9da..0aae50e49c 100644 --- a/crates/payload/builder/src/lib.rs +++ b/crates/payload/builder/src/lib.rs @@ -97,8 +97,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, unreachable_pub, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] pub mod database; diff --git a/crates/payload/ethereum/Cargo.toml b/crates/payload/ethereum/Cargo.toml index 91e2410f22..cb2d7baa0a 100644 --- a/crates/payload/ethereum/Cargo.toml +++ b/crates/payload/ethereum/Cargo.toml @@ -8,6 +8,9 @@ homepage.workspace = true repository.workspace = true description = "A basic ethereum payload builder for reth that uses the txpool API to build payloads." +[lints] +workspace = true + [dependencies] # reth reth-primitives.workspace = true @@ -26,4 +29,4 @@ tracing.workspace = true [features] # This is a workaround for reth-cli crate to allow this as mandatory dependency without breaking the build even if unused. # This makes managing features and testing workspace easier because clippy always builds all members if --workspace is provided -optimism = [] \ No newline at end of file +optimism = [] diff --git a/crates/payload/ethereum/src/lib.rs b/crates/payload/ethereum/src/lib.rs index 5738b51c39..6de0eabe22 100644 --- a/crates/payload/ethereum/src/lib.rs +++ b/crates/payload/ethereum/src/lib.rs @@ -5,8 +5,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, unreachable_pub, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] #[cfg(not(feature = "optimism"))] diff --git a/crates/payload/optimism/Cargo.toml b/crates/payload/optimism/Cargo.toml index 388cb4c408..f5f9309804 100644 --- a/crates/payload/optimism/Cargo.toml +++ b/crates/payload/optimism/Cargo.toml @@ -8,6 +8,9 @@ homepage.workspace = true repository.workspace = true description = "A payload builder for op-reth that builds optimistic payloads." +[lints] +workspace = true + [dependencies] # reth reth-primitives.workspace = true @@ -32,4 +35,4 @@ optimism = [ "reth-transaction-pool/optimism", "reth-provider/optimism", "reth-payload-builder/optimism", -] \ No newline at end of file +] diff --git a/crates/payload/optimism/src/lib.rs b/crates/payload/optimism/src/lib.rs index 11b36e9876..07a45324e4 100644 --- a/crates/payload/optimism/src/lib.rs +++ b/crates/payload/optimism/src/lib.rs @@ -5,8 +5,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, unreachable_pub, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] #[cfg(feature = "optimism")] diff --git a/crates/payload/validator/Cargo.toml b/crates/payload/validator/Cargo.toml index f3003d62e3..d138001a70 100644 --- a/crates/payload/validator/Cargo.toml +++ b/crates/payload/validator/Cargo.toml @@ -8,8 +8,11 @@ homepage.workspace = true repository.workspace = true description = "Payload validation support" +[lints] +workspace = true + [dependencies] # reth reth-primitives.workspace = true reth-rpc-types.workspace = true -reth-rpc-types-compat.workspace = true \ No newline at end of file +reth-rpc-types-compat.workspace = true diff --git a/crates/payload/validator/src/lib.rs b/crates/payload/validator/src/lib.rs index c4c7d13794..89840c032b 100644 --- a/crates/payload/validator/src/lib.rs +++ b/crates/payload/validator/src/lib.rs @@ -5,14 +5,7 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn( - missing_debug_implementations, - missing_docs, - unreachable_pub, - unused_crate_dependencies, - rustdoc::all -)] -#![deny(unused_must_use, rust_2018_idioms)] +#![warn(unused_crate_dependencies)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] use reth_primitives::{ChainSpec, SealedBlock}; diff --git a/crates/primitives/Cargo.toml b/crates/primitives/Cargo.toml index 87347f9950..42b0b4e99d 100644 --- a/crates/primitives/Cargo.toml +++ b/crates/primitives/Cargo.toml @@ -8,6 +8,9 @@ repository.workspace = true rust-version.workspace = true description = "Commonly used types in reth." +[lints] +workspace = true + [dependencies] # reth reth-codecs.workspace = true diff --git a/crates/primitives/benches/nibbles.rs b/crates/primitives/benches/nibbles.rs index 1db4f83788..e8e3f65f9b 100644 --- a/crates/primitives/benches/nibbles.rs +++ b/crates/primitives/benches/nibbles.rs @@ -1,3 +1,4 @@ +#![allow(missing_docs)] use criterion::{criterion_group, criterion_main, Criterion}; use proptest::{prelude::*, strategy::ValueTree}; use reth_primitives::trie::Nibbles; diff --git a/crates/primitives/benches/recover_ecdsa_crit.rs b/crates/primitives/benches/recover_ecdsa_crit.rs index 57893faa9f..e1e896dbbf 100644 --- a/crates/primitives/benches/recover_ecdsa_crit.rs +++ b/crates/primitives/benches/recover_ecdsa_crit.rs @@ -1,3 +1,4 @@ +#![allow(missing_docs)] use alloy_rlp::Decodable; use criterion::{criterion_group, criterion_main, Criterion}; use pprof::criterion::{Output, PProfProfiler}; diff --git a/crates/primitives/benches/trie_root.rs b/crates/primitives/benches/trie_root.rs index 6baf543194..ce9d41788c 100644 --- a/crates/primitives/benches/trie_root.rs +++ b/crates/primitives/benches/trie_root.rs @@ -1,3 +1,4 @@ +#![allow(missing_docs, unreachable_pub)] use criterion::{black_box, criterion_group, criterion_main, Criterion}; use proptest::{ prelude::*, diff --git a/crates/primitives/src/lib.rs b/crates/primitives/src/lib.rs index 988c82ecf4..12117fecc8 100644 --- a/crates/primitives/src/lib.rs +++ b/crates/primitives/src/lib.rs @@ -12,8 +12,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, unreachable_pub, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] mod account; diff --git a/crates/prune/Cargo.toml b/crates/prune/Cargo.toml index 70d649915d..750cd84d6b 100644 --- a/crates/prune/Cargo.toml +++ b/crates/prune/Cargo.toml @@ -8,6 +8,9 @@ homepage.workspace = true repository.workspace = true description = "Pruning implementation" +[lints] +workspace = true + [dependencies] # reth reth-primitives.workspace = true diff --git a/crates/prune/src/lib.rs b/crates/prune/src/lib.rs index cee0e5dd51..b712f9e5b6 100644 --- a/crates/prune/src/lib.rs +++ b/crates/prune/src/lib.rs @@ -5,8 +5,7 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, unreachable_pub, rustdoc::all)] // TODO(danipopes): missing_docs -#![deny(unused_must_use, rust_2018_idioms)] +#![allow(missing_docs)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] mod builder; diff --git a/crates/revm/Cargo.toml b/crates/revm/Cargo.toml index 18f74ecf22..6d12f754ae 100644 --- a/crates/revm/Cargo.toml +++ b/crates/revm/Cargo.toml @@ -8,6 +8,9 @@ homepage.workspace = true repository.workspace = true description = "reth specific revm utilities" +[lints] +workspace = true + [dependencies] # reth reth-primitives.workspace = true diff --git a/crates/revm/revm-inspectors/Cargo.toml b/crates/revm/revm-inspectors/Cargo.toml index bdfbe51f77..3664cbcf39 100644 --- a/crates/revm/revm-inspectors/Cargo.toml +++ b/crates/revm/revm-inspectors/Cargo.toml @@ -8,8 +8,11 @@ homepage.workspace = true repository.workspace = true description = "revm inspector implementations used by reth" +[lints] +workspace = true + [dependencies] -# reth +# reth reth-rpc-types.workspace = true # eth diff --git a/crates/revm/revm-inspectors/src/lib.rs b/crates/revm/revm-inspectors/src/lib.rs index 67854ba0c5..e524eb517d 100644 --- a/crates/revm/revm-inspectors/src/lib.rs +++ b/crates/revm/revm-inspectors/src/lib.rs @@ -10,8 +10,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, unreachable_pub, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms, unused_crate_dependencies)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] /// An inspector implementation for an EIP2930 Accesslist diff --git a/crates/revm/src/lib.rs b/crates/revm/src/lib.rs index 116269da66..8cc8056468 100644 --- a/crates/revm/src/lib.rs +++ b/crates/revm/src/lib.rs @@ -5,8 +5,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, unreachable_pub, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] /// Contains glue code for integrating reth database into revm's [Database]. diff --git a/crates/rpc/ipc/Cargo.toml b/crates/rpc/ipc/Cargo.toml index df904112c4..b01b689505 100644 --- a/crates/rpc/ipc/Cargo.toml +++ b/crates/rpc/ipc/Cargo.toml @@ -8,6 +8,9 @@ homepage.workspace = true repository.workspace = true description = "IPC support for reth" +[lints] +workspace = true + [dependencies] # async/net diff --git a/crates/rpc/ipc/src/lib.rs b/crates/rpc/ipc/src/lib.rs index 4cfc537fcd..66dacf9be9 100644 --- a/crates/rpc/ipc/src/lib.rs +++ b/crates/rpc/ipc/src/lib.rs @@ -9,8 +9,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, unreachable_pub, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] #[cfg(unix)] diff --git a/crates/rpc/rpc-api/Cargo.toml b/crates/rpc/rpc-api/Cargo.toml index 58d0349d38..13586f119d 100644 --- a/crates/rpc/rpc-api/Cargo.toml +++ b/crates/rpc/rpc-api/Cargo.toml @@ -8,6 +8,9 @@ homepage.workspace = true repository.workspace = true description = "Reth RPC interfaces" +[lints] +workspace = true + [dependencies] # reth reth-primitives.workspace = true diff --git a/crates/rpc/rpc-api/src/lib.rs b/crates/rpc/rpc-api/src/lib.rs index d414c116e6..e5a4b1981b 100644 --- a/crates/rpc/rpc-api/src/lib.rs +++ b/crates/rpc/rpc-api/src/lib.rs @@ -11,8 +11,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, unreachable_pub, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] mod admin; diff --git a/crates/rpc/rpc-builder/Cargo.toml b/crates/rpc/rpc-builder/Cargo.toml index 6ae2e8a1dc..88ad4deafc 100644 --- a/crates/rpc/rpc-builder/Cargo.toml +++ b/crates/rpc/rpc-builder/Cargo.toml @@ -8,6 +8,9 @@ homepage.workspace = true repository.workspace = true description = "Helpers for configuring RPC" +[lints] +workspace = true + [dependencies] # reth reth-primitives.workspace = true diff --git a/crates/rpc/rpc-builder/src/lib.rs b/crates/rpc/rpc-builder/src/lib.rs index 92df2ae70d..a559f3b8ac 100644 --- a/crates/rpc/rpc-builder/src/lib.rs +++ b/crates/rpc/rpc-builder/src/lib.rs @@ -132,8 +132,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, unreachable_pub, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] use std::{ diff --git a/crates/rpc/rpc-builder/tests/it/http.rs b/crates/rpc/rpc-builder/tests/it/http.rs index 1caf47ba88..41b2773217 100644 --- a/crates/rpc/rpc-builder/tests/it/http.rs +++ b/crates/rpc/rpc-builder/tests/it/http.rs @@ -1,3 +1,4 @@ +#![allow(unreachable_pub)] //! Standalone http tests use crate::utils::{launch_http, launch_http_ws, launch_ws}; diff --git a/crates/rpc/rpc-builder/tests/it/serde.rs b/crates/rpc/rpc-builder/tests/it/serde.rs index 1559dd27ac..a781e1d477 100644 --- a/crates/rpc/rpc-builder/tests/it/serde.rs +++ b/crates/rpc/rpc-builder/tests/it/serde.rs @@ -21,7 +21,7 @@ impl ToRpcParams for RawRpcParams { async fn test_eth_balance_serde() { let handle = launch_http(vec![RethRpcModule::Eth]).await; let s = r#"{"jsonrpc":"2.0","id":1,"method":"eth_getBalance","params":["0xaa00000000000000000000000000000000000000","0x898753d8fdd8d92c1907ca21e68c7970abd290c647a202091181deec3f30a0b2"]}"#; - let req: Request = serde_json::from_str(s).unwrap(); + let req: Request<'_> = serde_json::from_str(s).unwrap(); let client = handle.http_client().unwrap(); let params = RawRpcParams(RawValue::from_string(req.params.unwrap().to_string()).unwrap()); diff --git a/crates/rpc/rpc-engine-api/Cargo.toml b/crates/rpc/rpc-engine-api/Cargo.toml index b718862a9c..18f31ee85b 100644 --- a/crates/rpc/rpc-engine-api/Cargo.toml +++ b/crates/rpc/rpc-engine-api/Cargo.toml @@ -8,8 +8,11 @@ homepage.workspace = true repository.workspace = true description = "Implementation of Engine API" +[lints] +workspace = true + [dependencies] -# reth +# reth reth-primitives.workspace = true reth-interfaces.workspace = true reth-provider.workspace = true diff --git a/crates/rpc/rpc-engine-api/src/lib.rs b/crates/rpc/rpc-engine-api/src/lib.rs index d39025d508..965b0448af 100644 --- a/crates/rpc/rpc-engine-api/src/lib.rs +++ b/crates/rpc/rpc-engine-api/src/lib.rs @@ -6,8 +6,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, unreachable_pub, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] /// The Engine API implementation. diff --git a/crates/rpc/rpc-testing-util/Cargo.toml b/crates/rpc/rpc-testing-util/Cargo.toml index 53b04c7a0e..af72a3c71d 100644 --- a/crates/rpc/rpc-testing-util/Cargo.toml +++ b/crates/rpc/rpc-testing-util/Cargo.toml @@ -8,6 +8,9 @@ homepage.workspace = true repository.workspace = true description = "Reth RPC testing helpers" +[lints] +workspace = true + [dependencies] # reth reth-primitives.workspace = true diff --git a/crates/rpc/rpc-testing-util/src/lib.rs b/crates/rpc/rpc-testing-util/src/lib.rs index f4a5740cb9..047236dc6e 100644 --- a/crates/rpc/rpc-testing-util/src/lib.rs +++ b/crates/rpc/rpc-testing-util/src/lib.rs @@ -5,8 +5,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, unreachable_pub, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] pub mod debug; diff --git a/crates/rpc/rpc-types-compat/Cargo.toml b/crates/rpc/rpc-types-compat/Cargo.toml index e85060334f..e9d0b86229 100644 --- a/crates/rpc/rpc-types-compat/Cargo.toml +++ b/crates/rpc/rpc-types-compat/Cargo.toml @@ -8,6 +8,9 @@ homepage.workspace = true repository.workspace = true description = "Compatibility layer for reth-primitives and ethereum RPC types" +[lints] +workspace = true + [dependencies] reth-primitives.workspace = true reth-rpc-types.workspace = true diff --git a/crates/rpc/rpc-types-compat/src/lib.rs b/crates/rpc/rpc-types-compat/src/lib.rs index 4f4db3cef7..115231670c 100644 --- a/crates/rpc/rpc-types-compat/src/lib.rs +++ b/crates/rpc/rpc-types-compat/src/lib.rs @@ -7,8 +7,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, unreachable_pub, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] pub mod block; diff --git a/crates/rpc/rpc-types/Cargo.toml b/crates/rpc/rpc-types/Cargo.toml index 7074686e39..89f972e235 100644 --- a/crates/rpc/rpc-types/Cargo.toml +++ b/crates/rpc/rpc-types/Cargo.toml @@ -8,6 +8,9 @@ homepage.workspace = true repository.workspace = true description = "Reth RPC types" +[lints] +workspace = true + [dependencies] # ethereum alloy-rlp = { workspace = true, features = ["arrayvec", "derive"] } diff --git a/crates/rpc/rpc-types/src/lib.rs b/crates/rpc/rpc-types/src/lib.rs index f71f766081..84cd0992b5 100644 --- a/crates/rpc/rpc-types/src/lib.rs +++ b/crates/rpc/rpc-types/src/lib.rs @@ -7,8 +7,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, unreachable_pub, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] mod admin; diff --git a/crates/rpc/rpc/Cargo.toml b/crates/rpc/rpc/Cargo.toml index 6e50bafbde..89aaa1e0fa 100644 --- a/crates/rpc/rpc/Cargo.toml +++ b/crates/rpc/rpc/Cargo.toml @@ -7,6 +7,10 @@ license.workspace = true homepage.workspace = true repository.workspace = true description = "Reth RPC implementation" + +[lints] +workspace = true + [dependencies] # reth reth-interfaces.workspace = true diff --git a/crates/rpc/rpc/src/lib.rs b/crates/rpc/rpc/src/lib.rs index 340886dab9..cb068ad787 100644 --- a/crates/rpc/rpc/src/lib.rs +++ b/crates/rpc/rpc/src/lib.rs @@ -22,8 +22,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, unreachable_pub, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] mod admin; diff --git a/crates/snapshot/Cargo.toml b/crates/snapshot/Cargo.toml index 0eed673216..a082c01135 100644 --- a/crates/snapshot/Cargo.toml +++ b/crates/snapshot/Cargo.toml @@ -8,6 +8,9 @@ homepage.workspace = true repository.workspace = true description = "Snapshotting implementation" +[lints] +workspace = true + [dependencies] # reth reth-primitives.workspace = true diff --git a/crates/snapshot/src/lib.rs b/crates/snapshot/src/lib.rs index 82f42b2d4c..1673aa0b8e 100644 --- a/crates/snapshot/src/lib.rs +++ b/crates/snapshot/src/lib.rs @@ -5,8 +5,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, unreachable_pub, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] mod error; diff --git a/crates/stages/Cargo.toml b/crates/stages/Cargo.toml index 890bc135ed..d3ddca5be3 100644 --- a/crates/stages/Cargo.toml +++ b/crates/stages/Cargo.toml @@ -8,6 +8,9 @@ homepage.workspace = true repository.workspace = true description = "Staged syncing primitives used in reth." +[lints] +workspace = true + [package.metadata.cargo-udeps.ignore] normal = [ # Used for diagrams in docs diff --git a/crates/stages/benches/criterion.rs b/crates/stages/benches/criterion.rs index 2a45c2521f..b8e8db7b89 100644 --- a/crates/stages/benches/criterion.rs +++ b/crates/stages/benches/criterion.rs @@ -1,3 +1,4 @@ +#![allow(missing_docs, elided_lifetimes_in_paths)] use criterion::{ async_executor::FuturesExecutor, criterion_group, criterion_main, measurement::WallTime, BenchmarkGroup, Criterion, diff --git a/crates/stages/benches/setup/account_hashing.rs b/crates/stages/benches/setup/account_hashing.rs index 61d7662678..497dce2787 100644 --- a/crates/stages/benches/setup/account_hashing.rs +++ b/crates/stages/benches/setup/account_hashing.rs @@ -1,3 +1,4 @@ +#![allow(unreachable_pub)] use super::{constants, StageRange}; use reth_db::{ cursor::DbCursorRO, database::Database, tables, transaction::DbTx, DatabaseError as DbError, diff --git a/crates/stages/benches/setup/constants.rs b/crates/stages/benches/setup/constants.rs index 17b3f711de..d3aba8d042 100644 --- a/crates/stages/benches/setup/constants.rs +++ b/crates/stages/benches/setup/constants.rs @@ -1 +1,2 @@ +#![allow(unreachable_pub)] pub const ACCOUNT_HASHING_DB: &str = "ACCOUNT_HASHING_DB"; diff --git a/crates/stages/benches/setup/mod.rs b/crates/stages/benches/setup/mod.rs index a4422e23f4..f6322cc50d 100644 --- a/crates/stages/benches/setup/mod.rs +++ b/crates/stages/benches/setup/mod.rs @@ -1,3 +1,4 @@ +#![allow(unreachable_pub)] use itertools::concat; use reth_db::{ cursor::DbCursorRO, diff --git a/crates/stages/src/lib.rs b/crates/stages/src/lib.rs index f6ae6b8a5f..7c8ed234b2 100644 --- a/crates/stages/src/lib.rs +++ b/crates/stages/src/lib.rs @@ -64,8 +64,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, unreachable_pub, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] mod error; diff --git a/crates/storage/codecs/Cargo.toml b/crates/storage/codecs/Cargo.toml index 05d9e7403d..409190da53 100644 --- a/crates/storage/codecs/Cargo.toml +++ b/crates/storage/codecs/Cargo.toml @@ -7,6 +7,9 @@ license.workspace = true homepage.workspace = true repository.workspace = true +[lints] +workspace = true + [dependencies] codecs-derive = { path = "./derive", default-features = false } @@ -33,4 +36,4 @@ compact = ["codecs-derive/compact"] scale = ["codecs-derive/scale"] postcard = ["codecs-derive/postcard"] no_codec = ["codecs-derive/no_codec"] -optimism = ["codecs-derive/optimism"] \ No newline at end of file +optimism = ["codecs-derive/optimism"] diff --git a/crates/storage/codecs/derive/Cargo.toml b/crates/storage/codecs/derive/Cargo.toml index 8d295b562e..1fe4a6a062 100644 --- a/crates/storage/codecs/derive/Cargo.toml +++ b/crates/storage/codecs/derive/Cargo.toml @@ -8,6 +8,9 @@ homepage.workspace = true repository.workspace = true readme = "../README.md" +[lints] +workspace = true + [package.metadata.cargo-udeps.ignore] normal = [ # Used in proc macros diff --git a/crates/storage/codecs/derive/src/lib.rs b/crates/storage/codecs/derive/src/lib.rs index 0b412788b0..f7334557fb 100644 --- a/crates/storage/codecs/derive/src/lib.rs +++ b/crates/storage/codecs/derive/src/lib.rs @@ -5,7 +5,7 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![deny(unused_must_use, rust_2018_idioms)] +#![allow(unreachable_pub, missing_docs)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] use proc_macro::{self, TokenStream, TokenTree}; @@ -30,14 +30,14 @@ pub fn derive_zstd(input: TokenStream) -> TokenStream { /// This code implements the main codec. If the codec supports it, it will also provide the [derive_arbitrary()] function, which automatically implements arbitrary traits and roundtrip fuzz tests. /// /// If you prefer to manually implement the arbitrary traits, you can still use the [add_arbitrary_tests()] function to add arbitrary fuzz tests. -/// +/// /// Example usage: /// * `#[main_codec(rlp)]`: will implement `derive_arbitrary(rlp)` or `derive_arbitrary(compact, rlp)`, if `compact` is the `main_codec`. /// * `#[main_codec(no_arbitrary)]`: will skip `derive_arbitrary` (both trait implementations and tests) #[proc_macro_attribute] #[rustfmt::skip] #[allow(unreachable_code)] -pub fn main_codec(args: TokenStream, input: TokenStream) -> TokenStream { +pub fn main_codec(args: TokenStream, input: TokenStream) -> TokenStream { #[cfg(feature = "compact")] return use_compact(args, input); diff --git a/crates/storage/codecs/src/lib.rs b/crates/storage/codecs/src/lib.rs index 993c323cb1..8725204fa3 100644 --- a/crates/storage/codecs/src/lib.rs +++ b/crates/storage/codecs/src/lib.rs @@ -5,14 +5,7 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn( - missing_debug_implementations, - missing_docs, - unused_crate_dependencies, - unreachable_pub, - rustdoc::all -)] -#![deny(unused_must_use, rust_2018_idioms)] +#![warn(unused_crate_dependencies)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] #![cfg_attr(not(feature = "std"), no_std)] diff --git a/crates/storage/db/Cargo.toml b/crates/storage/db/Cargo.toml index 46cc2a2158..62ef2200fe 100644 --- a/crates/storage/db/Cargo.toml +++ b/crates/storage/db/Cargo.toml @@ -8,6 +8,9 @@ homepage.workspace = true repository.workspace = true description = "Staged syncing primitives used in reth." +[lints] +workspace = true + [dependencies] # reth reth-primitives.workspace = true diff --git a/crates/storage/db/benches/criterion.rs b/crates/storage/db/benches/criterion.rs index 223c3d1d19..d245c46f03 100644 --- a/crates/storage/db/benches/criterion.rs +++ b/crates/storage/db/benches/criterion.rs @@ -1,3 +1,4 @@ +#![allow(missing_docs, elided_lifetimes_in_paths)] use criterion::{ black_box, criterion_group, criterion_main, measurement::WallTime, BenchmarkGroup, Criterion, }; diff --git a/crates/storage/db/benches/hash_keys.rs b/crates/storage/db/benches/hash_keys.rs index e2534d0b2c..7f432f6d54 100644 --- a/crates/storage/db/benches/hash_keys.rs +++ b/crates/storage/db/benches/hash_keys.rs @@ -1,3 +1,4 @@ +#![allow(missing_docs, elided_lifetimes_in_paths)] use criterion::{ black_box, criterion_group, criterion_main, measurement::WallTime, BenchmarkGroup, Criterion, }; diff --git a/crates/storage/db/benches/iai.rs b/crates/storage/db/benches/iai.rs index e4c6b75339..cd15377436 100644 --- a/crates/storage/db/benches/iai.rs +++ b/crates/storage/db/benches/iai.rs @@ -1,4 +1,4 @@ -#![allow(non_snake_case)] +#![allow(missing_docs, non_snake_case, unreachable_pub)] use paste::paste; use reth_db::table::{Compress, Decode, Decompress, Encode, Table}; diff --git a/crates/storage/db/build.rs b/crates/storage/db/build.rs index edec6873ad..1cb8e95fc4 100644 --- a/crates/storage/db/build.rs +++ b/crates/storage/db/build.rs @@ -1,3 +1,5 @@ +#![allow(missing_docs)] + use std::error::Error; use vergen::EmitBuilder; diff --git a/crates/storage/db/src/lib.rs b/crates/storage/db/src/lib.rs index a57779d4f0..92f6b46d2e 100644 --- a/crates/storage/db/src/lib.rs +++ b/crates/storage/db/src/lib.rs @@ -60,8 +60,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, unreachable_pub, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] /// Traits defining the database abstractions, such as cursors and transactions. diff --git a/crates/storage/libmdbx-rs/Cargo.toml b/crates/storage/libmdbx-rs/Cargo.toml index 7acda0894f..c6b3f46508 100644 --- a/crates/storage/libmdbx-rs/Cargo.toml +++ b/crates/storage/libmdbx-rs/Cargo.toml @@ -8,6 +8,9 @@ description = "Idiomatic and safe MDBX wrapper with good licence" homepage.workspace = true repository.workspace = true +[lints] +workspace = true + [lib] name = "reth_libmdbx" diff --git a/crates/storage/libmdbx-rs/benches/cursor.rs b/crates/storage/libmdbx-rs/benches/cursor.rs index 89c87c6f41..c05cef4b6e 100644 --- a/crates/storage/libmdbx-rs/benches/cursor.rs +++ b/crates/storage/libmdbx-rs/benches/cursor.rs @@ -1,3 +1,4 @@ +#![allow(missing_docs)] mod utils; use ::ffi::*; diff --git a/crates/storage/libmdbx-rs/benches/transaction.rs b/crates/storage/libmdbx-rs/benches/transaction.rs index 72713acd3a..91e2c44044 100644 --- a/crates/storage/libmdbx-rs/benches/transaction.rs +++ b/crates/storage/libmdbx-rs/benches/transaction.rs @@ -1,3 +1,4 @@ +#![allow(missing_docs, unreachable_pub)] mod utils; use criterion::{black_box, criterion_group, criterion_main, Criterion}; diff --git a/crates/storage/libmdbx-rs/benches/utils.rs b/crates/storage/libmdbx-rs/benches/utils.rs index bf24b4866a..25d7b762c5 100644 --- a/crates/storage/libmdbx-rs/benches/utils.rs +++ b/crates/storage/libmdbx-rs/benches/utils.rs @@ -1,3 +1,4 @@ +#![allow(unreachable_pub)] use reth_libmdbx::{Environment, WriteFlags}; use tempfile::{tempdir, TempDir}; diff --git a/crates/storage/libmdbx-rs/src/lib.rs b/crates/storage/libmdbx-rs/src/lib.rs index ee9e204f95..d988932af5 100644 --- a/crates/storage/libmdbx-rs/src/lib.rs +++ b/crates/storage/libmdbx-rs/src/lib.rs @@ -4,8 +4,7 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, unreachable_pub, rustdoc::all)] // TODO(danipopes): missing_docs -#![deny(unused_must_use, rust_2018_idioms)] +#![allow(missing_docs)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] pub use crate::{ diff --git a/crates/storage/nippy-jar/Cargo.toml b/crates/storage/nippy-jar/Cargo.toml index 10926c3d8c..fb7fc4ae7d 100644 --- a/crates/storage/nippy-jar/Cargo.toml +++ b/crates/storage/nippy-jar/Cargo.toml @@ -8,6 +8,9 @@ homepage.workspace = true repository.workspace = true description = "Immutable data store format" +[lints] +workspace = true + [lib] name = "reth_nippy_jar" @@ -38,4 +41,4 @@ tempfile.workspace = true [features] -default = [] \ No newline at end of file +default = [] diff --git a/crates/storage/nippy-jar/src/lib.rs b/crates/storage/nippy-jar/src/lib.rs index 471e771e25..20d499a636 100644 --- a/crates/storage/nippy-jar/src/lib.rs +++ b/crates/storage/nippy-jar/src/lib.rs @@ -5,8 +5,7 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, unreachable_pub, rustdoc::all)] // TODO(danipopes): missing_docs -#![deny(unused_must_use, rust_2018_idioms)] +#![allow(missing_docs)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] use memmap2::Mmap; diff --git a/crates/storage/provider/Cargo.toml b/crates/storage/provider/Cargo.toml index 413b71d80c..64ff9742a4 100644 --- a/crates/storage/provider/Cargo.toml +++ b/crates/storage/provider/Cargo.toml @@ -8,6 +8,9 @@ homepage.workspace = true repository.workspace = true description = "Reth storage provider." +[lints] +workspace = true + [dependencies] # reth reth-primitives.workspace = true diff --git a/crates/storage/provider/src/lib.rs b/crates/storage/provider/src/lib.rs index 8391735e55..a1aa097475 100644 --- a/crates/storage/provider/src/lib.rs +++ b/crates/storage/provider/src/lib.rs @@ -9,8 +9,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, unreachable_pub, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] /// Various provider traits. diff --git a/crates/tasks/Cargo.toml b/crates/tasks/Cargo.toml index 078e611760..ebd0df6bff 100644 --- a/crates/tasks/Cargo.toml +++ b/crates/tasks/Cargo.toml @@ -8,6 +8,9 @@ homepage.workspace = true repository.workspace = true description = "Task management" +[lints] +workspace = true + [dependencies] # async diff --git a/crates/tasks/src/lib.rs b/crates/tasks/src/lib.rs index 7ba3fd170a..010bc4e147 100644 --- a/crates/tasks/src/lib.rs +++ b/crates/tasks/src/lib.rs @@ -5,8 +5,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, unreachable_pub, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] use crate::{ diff --git a/crates/tokio-util/Cargo.toml b/crates/tokio-util/Cargo.toml index 573bd78c99..e8c21e0fa0 100644 --- a/crates/tokio-util/Cargo.toml +++ b/crates/tokio-util/Cargo.toml @@ -8,6 +8,9 @@ homepage.workspace = true repository.workspace = true description = "Additional utilities for working with Tokio in reth." +[lints] +workspace = true + [dependencies] # async diff --git a/crates/tokio-util/src/lib.rs b/crates/tokio-util/src/lib.rs index 244b44346d..072d55ef06 100644 --- a/crates/tokio-util/src/lib.rs +++ b/crates/tokio-util/src/lib.rs @@ -5,8 +5,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, unreachable_pub, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] mod event_listeners; diff --git a/crates/tracing/Cargo.toml b/crates/tracing/Cargo.toml index 424545b98a..4ed18c307a 100644 --- a/crates/tracing/Cargo.toml +++ b/crates/tracing/Cargo.toml @@ -8,6 +8,9 @@ homepage.workspace = true repository.workspace = true description = "tracing helpers" +[lints] +workspace = true + [dependencies] tracing.workspace = true tracing-subscriber = { version = "0.3", default-features = false, features = ["env-filter", "fmt"] } diff --git a/crates/tracing/src/lib.rs b/crates/tracing/src/lib.rs index 2fc551a5f6..561991dad9 100644 --- a/crates/tracing/src/lib.rs +++ b/crates/tracing/src/lib.rs @@ -13,8 +13,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, unreachable_pub, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] use rolling_file::{RollingConditionBasic, RollingFileAppender}; diff --git a/crates/transaction-pool/Cargo.toml b/crates/transaction-pool/Cargo.toml index 5d00994116..6651437d3b 100644 --- a/crates/transaction-pool/Cargo.toml +++ b/crates/transaction-pool/Cargo.toml @@ -8,6 +8,9 @@ homepage.workspace = true repository.workspace = true description = "Transaction pool implementation" +[lints] +workspace = true + [package.metadata.cargo-udeps.ignore] normal = [ # Used for diagrams in docs diff --git a/crates/transaction-pool/src/lib.rs b/crates/transaction-pool/src/lib.rs index 16158c0d98..1ab914e773 100644 --- a/crates/transaction-pool/src/lib.rs +++ b/crates/transaction-pool/src/lib.rs @@ -146,8 +146,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, unreachable_pub, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] use crate::{identifier::TransactionId, pool::PoolInner}; diff --git a/crates/trie/Cargo.toml b/crates/trie/Cargo.toml index efdec94f86..8593ad8397 100644 --- a/crates/trie/Cargo.toml +++ b/crates/trie/Cargo.toml @@ -8,6 +8,9 @@ homepage.workspace = true repository.workspace = true description = "Merkle trie implementation" +[lints] +workspace = true + [dependencies] # reth reth-primitives.workspace = true @@ -22,7 +25,7 @@ tokio = { workspace = true, default-features = false, features = ["sync"] } # tracing tracing.workspace = true -# misc +# misc thiserror.workspace = true derive_more = "0.99" auto_impl = "1" diff --git a/crates/trie/benches/prefix_set.rs b/crates/trie/benches/prefix_set.rs index 2fd8ff28d4..343b99b021 100644 --- a/crates/trie/benches/prefix_set.rs +++ b/crates/trie/benches/prefix_set.rs @@ -1,3 +1,4 @@ +#![allow(missing_docs, unreachable_pub, elided_lifetimes_in_paths)] use criterion::{ black_box, criterion_group, criterion_main, measurement::WallTime, BenchmarkGroup, Criterion, }; diff --git a/crates/trie/src/lib.rs b/crates/trie/src/lib.rs index 9e842a7bfa..866ea33b44 100644 --- a/crates/trie/src/lib.rs +++ b/crates/trie/src/lib.rs @@ -11,8 +11,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, unreachable_pub, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] /// The implementation of a container for storing intermediate changes to a trie. diff --git a/testing/ef-tests/Cargo.toml b/testing/ef-tests/Cargo.toml index 29813d1dbe..6f1d776d15 100644 --- a/testing/ef-tests/Cargo.toml +++ b/testing/ef-tests/Cargo.toml @@ -8,6 +8,9 @@ license.workspace = true homepage.workspace = true repository.workspace = true +[lints] +workspace = true + [features] ef-tests = [] diff --git a/testing/ef-tests/src/lib.rs b/testing/ef-tests/src/lib.rs index 24180d5cce..45f296d1f5 100644 --- a/testing/ef-tests/src/lib.rs +++ b/testing/ef-tests/src/lib.rs @@ -5,8 +5,6 @@ html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256", issue_tracker_base_url = "https://github.com/paradigmxyz/reth/issues/" )] -#![warn(missing_debug_implementations, missing_docs, unreachable_pub, rustdoc::all)] -#![deny(unused_must_use, rust_2018_idioms)] #![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] pub mod case;