ChainSafe / ChainSafe/lodestar

Review block import pipeline for optimization especially with Reth users

Open
#7,321 2 comments 0 reactions 0 assignees View on GitHub
meta-bug scope-interop scope-profitability
Dominant language
TypeScript
Stars
1.4k
Forks
483
Avg merge
1d 18h
Merged PRs (30d)
156

Description

@g11tech has reported some Lido CSM users having bad results with `timely_target_wrong_head_vote` running Lodestar v1.23.x with Reth.

![Image](https://github.com/user-attachments/assets/73d9ef11-aeba-40c3-8e43-319df2cddf89)

`notifyNewPayload` roundtrip shows estimated latency around 800ms, which adds to critical time required to see + import the block for head voting, sometimes surpassing the 4s mark.

![Image](https://github.com/user-attachments/assets/e9c5a9f6-65d7-4fb8-9077-044e4d214825)

@nflaig also reports slow `notifyNewPayload` calls being twice as high as Nethermind at ~150-200ms. Request durations are spiky as well. Importing late head (>4s) seems to correspond with the spikes in duration requests.

![Image](https://github.com/user-attachments/assets/caab1ec7-3673-4e90-b218-df69ee71d45f)

![Image](https://github.com/user-attachments/assets/4511745e-1cff-4ee9-a4bc-812d78af0bed)

Where Nethermind (with comparable hardware) shows:

![Image](https://github.com/user-attachments/assets/e9b5cde4-d114-4e44-afe2-f8ccc23ed12f)

This ticket is to track the issue and for us to optimize our import block pipeline for max efficiency.

Contributor guide

Open the contributing guide

Research direction

Start by profiling the notifyNewPayload path and the block import pipeline described in the issue, comparing latency and request spikes against the reported Lodestar, Reth, and Nethermind results. The issue does not name files or tests; completion would require identifying and reducing the import latency that contributes to late head voting.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
blockchain, performance
Issue type
Bug
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.