Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion crates/flashblocks/payload/src/generator.rs
Original file line number Diff line number Diff line change
Expand Up @@ -274,6 +274,9 @@ impl<Builder, Client, Tasks> FlashblocksPayloadJobGenerator<Client, Tasks, Build
where
Builder: PayloadBuilder<BuiltPayload = OpBuiltPayload>,
{
/// Check for any existing flashblock for the same payload id exists, and if so
/// reduces all existing flashblocks into a payload, returning the payload and the
/// next flashblock index to build on top of.
fn check_for_pre_state(
&self,
attributes: &<Builder as PayloadBuilder>::Attributes,
Expand Down Expand Up @@ -303,7 +306,7 @@ where
None,
);

return Ok(Some((payload, flashblock.flashblock().index)));
return Ok(Some((payload, flashblock.flashblock().index + 1)));
}
}

Expand Down
2 changes: 2 additions & 0 deletions crates/flashblocks/primitives/src/flashblocks.rs
Original file line number Diff line number Diff line change
Expand Up @@ -156,6 +156,8 @@ impl Flashblock {
acc.base = next.flashblock.base;
}

acc.index = next.flashblock.index;
Copy link
Contributor Author

@alessandromazza98 alessandromazza98 Nov 14, 2025

Choose a reason for hiding this comment

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

this modification here is the one to review carefully. It's not mentioned in the audit


acc.metadata.fees = next.flashblock.metadata.fees;
acc.metadata.flashblock_timestamp = next.flashblock.metadata.flashblock_timestamp;

Expand Down
Loading