Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(op): move l1block loading to verification #1970

Merged
merged 2 commits into from
Jan 6, 2025

Conversation

rakita
Copy link
Member

@rakita rakita commented Jan 6, 2025

No description provided.

@rakita rakita force-pushed the rakita/load_l1block_ver branch from be03d46 to 40818a8 Compare January 6, 2025 12:55
@rakita rakita marked this pull request as ready for review January 6, 2025 12:57
Copy link
Collaborator

@mattsse mattsse left a comment

Choose a reason for hiding this comment

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

this looks correct now

let l1_block_info =
crate::optimism::L1BlockInfo::try_fetch(&mut context.evm.inner.db, SPEC::SPEC_ID)
.map_err(EVMError::Database)?;
context.evm.inner.l1_block_info = Some(l1_block_info);
Copy link
Member Author

Choose a reason for hiding this comment

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

@mattsse I added this part where the load is only done if l1_block_info field is None.

This can be a small optimization for the future where this is set before execution.

And every time after Revm finishes it will be set to None so it does not get that weird side effect. So it will function as before.

Copy link
Collaborator

Choose a reason for hiding this comment

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

makes sense

@rakita rakita merged commit 1054af9 into release/v52 Jan 6, 2025
18 of 22 checks passed
@rakita rakita deleted the rakita/load_l1block_ver branch January 9, 2025 00:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants