Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/main' into alexey/state-root-tas…
Browse files Browse the repository at this point in the history
…k-integrate
  • Loading branch information
shekhirin committed Dec 17, 2024
2 parents c6289af + e663f95 commit 17e6dba
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 9 deletions.
1 change: 1 addition & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions crates/engine/tree/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ reth-metrics = { workspace = true, features = ["common"] }
# misc
rayon.workspace = true
tracing.workspace = true
derive_more.workspace = true

# optional deps for test-utils
reth-prune-types = { workspace = true, optional = true }
Expand Down
11 changes: 2 additions & 9 deletions crates/engine/tree/src/tree/root.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
//! State root task related functionality.
use alloy_primitives::map::HashSet;
use derive_more::derive::Deref;
use rayon::iter::{ParallelBridge, ParallelIterator};
use reth_errors::ProviderError;
use reth_evm::system_calls::OnStateHook;
Expand All @@ -27,7 +28,6 @@ use reth_trie_sparse::{
use revm_primitives::{keccak256, EvmState, B256};
use std::{
collections::BTreeMap,
ops::Deref,
sync::{
mpsc::{self, channel, Receiver, Sender},
Arc,
Expand Down Expand Up @@ -209,6 +209,7 @@ impl ProofSequencer {

/// A wrapper for the sender that signals completion when dropped
#[allow(dead_code)]
#[derive(Deref)]
pub(crate) struct StateHookSender<BPF: BlindedProviderFactory>(Sender<StateRootMessage<BPF>>);

#[allow(dead_code)]
Expand All @@ -218,14 +219,6 @@ impl<BPF: BlindedProviderFactory> StateHookSender<BPF> {
}
}

impl<BPF: BlindedProviderFactory> Deref for StateHookSender<BPF> {
type Target = Sender<StateRootMessage<BPF>>;

fn deref(&self) -> &Self::Target {
&self.0
}
}

impl<BPF: BlindedProviderFactory> Drop for StateHookSender<BPF> {
fn drop(&mut self) {
// Send completion signal when the sender is dropped
Expand Down

0 comments on commit 17e6dba

Please sign in to comment.