Skip to content
This repository has been archived by the owner on Feb 6, 2025. It is now read-only.

Commit

Permalink
fix lint issues
Browse files Browse the repository at this point in the history
  • Loading branch information
Keefe Liu committed Oct 29, 2024
1 parent 47e1790 commit 12b87fe
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 deletions.
1 change: 1 addition & 0 deletions crates/blockchain-tree/src/chain.rs
Original file line number Diff line number Diff line change
Expand Up @@ -351,6 +351,7 @@ impl AppendableChain {
Ok(())
}

#[allow(clippy::type_complexity)]
fn setup_prefetch<N, E>(
externals: &TreeExternals<N, E>,
) -> (
Expand Down
12 changes: 8 additions & 4 deletions crates/engine/tree/src/tree/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2278,9 +2278,11 @@ where
// different view of the database.
let persistence_in_progress = self.persistence_state.in_progress();
if !persistence_in_progress {
state_root_result = match self
.compute_state_root_parallel(block.parent_hash, &hashed_state, missing_leaves_cache)
{
state_root_result = match self.compute_state_root_parallel(
block.parent_hash,
&hashed_state,
missing_leaves_cache,
) {
Ok((state_root, trie_output)) => Some((state_root, trie_output)),
Err(ParallelStateRootError::Provider(ProviderError::ConsistentView(error))) => {
debug!(target: "engine", %error, "Parallel state root computation failed consistency check, falling back");
Expand Down Expand Up @@ -2388,7 +2390,8 @@ where
// Extend with block we are validating root for.
input.append_ref(hashed_state);

ParallelStateRoot::new(consistent_view, input).incremental_root_with_updates_and_cache(missing_leaves_cache)
ParallelStateRoot::new(consistent_view, input)
.incremental_root_with_updates_and_cache(missing_leaves_cache)
}

/// Handles an error that occurred while inserting a block.
Expand Down Expand Up @@ -2632,6 +2635,7 @@ where
Ok(())
}

#[allow(clippy::type_complexity)]
fn setup_prefetch(
&self,
) -> (
Expand Down

0 comments on commit 12b87fe

Please sign in to comment.