mirror of
https://github.com/hl-archive-node/nanoreth.git
synced 2025-12-06 10:59:55 +00:00
chore: add and fix more lints, improve docs (#4765)
This commit is contained in:
@ -46,7 +46,7 @@ pub enum DatabaseError {
|
||||
}
|
||||
|
||||
/// Database write operation type
|
||||
#[derive(Debug, PartialEq, Eq, Clone)]
|
||||
#[derive(Clone, Copy, Debug, PartialEq, Eq)]
|
||||
#[allow(missing_docs)]
|
||||
pub enum DatabaseWriteOperation {
|
||||
CursorAppend,
|
||||
|
||||
@ -1,22 +1,18 @@
|
||||
#![cfg_attr(docsrs, feature(doc_cfg))]
|
||||
#![doc(
|
||||
html_logo_url = "https://raw.githubusercontent.com/paradigmxyz/reth/main/assets/reth-docs.png",
|
||||
html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256",
|
||||
issue_tracker_base_url = "https://github.com/paradigmxzy/reth/issues/"
|
||||
)]
|
||||
#![warn(missing_docs, unreachable_pub)]
|
||||
#![deny(unused_must_use, rust_2018_idioms)]
|
||||
#![doc(test(
|
||||
no_crate_inject,
|
||||
attr(deny(warnings, rust_2018_idioms), allow(dead_code, unused_variables))
|
||||
))]
|
||||
|
||||
//! A collection of shared traits and error types used in Reth.
|
||||
//!
|
||||
//! ## Feature Flags
|
||||
//!
|
||||
//! - `test-utils`: Export utilities for testing
|
||||
|
||||
#![doc(
|
||||
html_logo_url = "https://raw.githubusercontent.com/paradigmxyz/reth/main/assets/reth-docs.png",
|
||||
html_favicon_url = "https://avatars0.githubusercontent.com/u/97369466?s=256",
|
||||
issue_tracker_base_url = "https://github.com/paradigmxzy/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))]
|
||||
|
||||
/// Consensus traits.
|
||||
pub mod consensus;
|
||||
|
||||
|
||||
@ -70,7 +70,7 @@ impl EthResponseValidator for RequestResult<Vec<Header>> {
|
||||
}
|
||||
|
||||
/// Error variants that can happen when sending requests to a session.
|
||||
#[derive(Debug, Error, Clone, Eq, PartialEq)]
|
||||
#[derive(Clone, Debug, Error, Eq, PartialEq)]
|
||||
#[allow(missing_docs)]
|
||||
pub enum RequestError {
|
||||
#[error("Closed channel to the peer.")]
|
||||
|
||||
@ -354,6 +354,7 @@ fn ensure_valid_body_response(
|
||||
/// NOTE: this assumes that bodies responses are returned by the client in the same order as the
|
||||
/// hash array used to request them.
|
||||
#[must_use = "futures do nothing unless polled"]
|
||||
#[allow(missing_debug_implementations)]
|
||||
pub struct FetchFullBlockRangeFuture<Client>
|
||||
where
|
||||
Client: BodiesClient + HeadersClient,
|
||||
|
||||
@ -49,7 +49,7 @@ impl SyncState {
|
||||
}
|
||||
|
||||
/// A [NetworkSyncUpdater] implementation that does nothing.
|
||||
#[derive(Debug, Clone, Default)]
|
||||
#[derive(Clone, Copy, Debug, Default)]
|
||||
#[non_exhaustive]
|
||||
pub struct NoopSyncStateUpdater;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user