Skip to content

feat(optimism): Add launch_wss_flashblocks_service function spawning a task sending last pending block#18067

Merged
RomanHodulak merged 1 commit intomainfrom
reth-optimism-flashblocks4
Aug 26, 2025
Merged

feat(optimism): Add launch_wss_flashblocks_service function spawning a task sending last pending block#18067
RomanHodulak merged 1 commit intomainfrom
reth-optimism-flashblocks4

Conversation

@RomanHodulak
Copy link
Contributor

@RomanHodulak RomanHodulak commented Aug 26, 2025

Part of #17858

Adds a function for launching the flashblock service and getting a receiver for last pending block.

@RomanHodulak RomanHodulak force-pushed the reth-optimism-flashblocks4 branch from 0cbdf3d to 7d0762d Compare August 26, 2025 14:37
@RomanHodulak RomanHodulak changed the title feat(optimism): Launch FlashBlockService when websocket URL is provided in OpEthApi feat(optimism): Add launch_wss_flashblocks_service function spawning a task sending last pending block Aug 26, 2025
@RomanHodulak RomanHodulak linked an issue Aug 26, 2025 that may be closed by this pull request
@RomanHodulak RomanHodulak requested a review from klkvr August 26, 2025 14:41
+ 'static,
{
let stream = FlashBlockWsStream::new(ws_url);
let mut service = FlashBlockService::new(stream, evm_config, provider, ());
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looking at

https://github.com/paradigmxyz/reth/blob/main/crates/optimism/flashblocks/src/payload.rs#L47-L69

I think we dont even need the Builder == () here because we already have all the infos here

in fact using BuildPendingEnv would result in an incorrect block, but we can tackle this next, we likely need to restrict

https://github.com/paradigmxyz/reth/blob/main/crates/optimism/evm/src/lib.rs#L124-L124

from<ExecutionPayloadBaseV1>

or smth like this

@github-project-automation github-project-automation bot moved this from Backlog to In Progress in Reth Tracker Aug 26, 2025
@mattsse mattsse added C-enhancement New feature or request A-op-reth Related to Optimism and op-reth labels Aug 26, 2025
@RomanHodulak RomanHodulak added this pull request to the merge queue Aug 26, 2025
Merged via the queue into main with commit 3c7301e Aug 26, 2025
43 checks passed
@RomanHodulak RomanHodulak deleted the reth-optimism-flashblocks4 branch August 26, 2025 15:30
@github-project-automation github-project-automation bot moved this from In Progress to Done in Reth Tracker Aug 26, 2025
lwedge99 pushed a commit to sentioxyz/reth that referenced this pull request Sep 16, 2025
theochap pushed a commit to ethereum-optimism/optimism that referenced this pull request Jan 22, 2026
theochap pushed a commit to ethereum-optimism/optimism that referenced this pull request Feb 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-op-reth Related to Optimism and op-reth C-enhancement New feature or request

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

Add function that spawns flash block service

2 participants