Skip to content

Instantly share code, notes, and snippets.

View binarynightowl's full-sized avatar

Taylor Dettling binarynightowl

View GitHub Profile
@binarynightowl
binarynightowl / main.rs
Created April 29, 2025 13:03
Rough example of extending reth rpc
use std::hash::Hash;
use clap::Parser;
use futures_util::FutureExt;
use mainnet_executor::instrument_ext::{InstrumentExt, InstrumentExtApiServer};
use mainnet_observer::transaction_processor::processor;
use mainnet_observer::{ObserverExEx, RethCliObserverExex};
use reth::{builder::NodeHandle, chainspec::EthereumChainSpecParser, cli::Cli};
use reth_node_ethereum::node::EthereumNode;
use reth_rpc::EthFilter;
use reth_tasks::TokioTaskExecutor;
@binarynightowl
binarynightowl / error
Created April 5, 2025 20:01
EthApi In an ExEx
error[E0599]: the method `spawn_with_call_at` exists for struct `EthApi<<Node as FullNodeTypes>::Provider, ..., ..., ...>`, but its trait bounds were not satisfied
--> mainnet-observer/src/main.rs:123:39
|
123 | let sim = eth_api.spawn_with_call_at(
| --------^^^^^^^^^^^^^^^^^^ method cannot be called due to unsatisfied trait bounds
|
::: /Users/user/.cargo/git/checkouts/reth-e231042ee7db3fb7/ed7da87/crates/rpc/rpc-eth-types/src/error/mod.rs:43:1
|
43 | pub enum EthApiError {
| -------------------- doesn't satisfy `_: FromEvmError<<Node as FullNodeComponents>::Evm>`