feat: add header AT to provider (#13030)

Co-authored-by: Arsenii Kulikov <klkvrr@gmail.com>
This commit is contained in:
Matthias Seitz
2024-12-02 14:24:48 +01:00
committed by GitHub
parent 519a10ae99
commit 332cce1f9b
71 changed files with 669 additions and 434 deletions

View File

@ -14,6 +14,7 @@ reth-provider.workspace = true
reth-node-ethereum.workspace = true
reth-node-types.workspace = true
alloy-consensus.workspace = true
alloy-rpc-types-eth.workspace = true
alloy-primitives.workspace = true

View File

@ -1,3 +1,4 @@
use alloy_consensus::BlockHeader;
use alloy_primitives::{Address, B256};
use alloy_rpc_types_eth::{Filter, FilteredParams};
use reth_chainspec::ChainSpecBuilder;
@ -193,7 +194,7 @@ fn receipts_provider_example<
// receipts and do something with the data
// 1. get the bloom from the header
let header = provider.header_by_number(header_num)?.unwrap();
let bloom = header.logs_bloom;
let bloom = header.logs_bloom();
// 2. Construct the address/topics filters
// For a hypothetical address, we'll want to filter down for a specific indexed topic (e.g.