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

@ -319,9 +319,9 @@ impl<ChainSpec> NodeConfig<ChainSpec> {
Ok(Head {
number: head,
hash,
difficulty: header.difficulty,
difficulty: header.difficulty(),
total_difficulty,
timestamp: header.timestamp,
timestamp: header.timestamp(),
})
}
@ -344,7 +344,7 @@ impl<ChainSpec> NodeConfig<ChainSpec> {
// try to look up the header in the database
if let Some(header) = header {
info!(target: "reth::cli", ?tip, "Successfully looked up tip block in the database");
return Ok(header.number)
return Ok(header.number())
}
Ok(self.fetch_tip_from_network(client, tip.into()).await.number())