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

bug: it will drop a valid span batch data when the block height of L2 reached 7134334 on the optimism sepolia network #207

Open
thinkAfCod opened this issue Feb 5, 2024 · 4 comments

Comments

@thinkAfCod
Copy link
Contributor

Even though every loop has called the update_safe_head method to put block info of 7134334 into the state.l2_refs, it will drop the span batch with the message 'prev L2 block not found'.

If Magi gets the previous L2 block from the op-geth, it will run correctly.

@GrapeBaBa
Copy link
Contributor

@ncitron This is tested on OP Seoplia testnet, 7134334 block not executed correctly.

@thinkAfCod
Copy link
Contributor Author

The l2_refs only caches block info in the range of [safe_head - (max_seq_drift / block_time), safe_head].
In the optimism sepolia testnet, the max_seq_drift is 600, and block_time is 2.
When the safe_head is 7134334, the result is [7134034, 7134334]
Unexpectedly, the span batch is valid which timestamp is 1706070328 and refs to 7133894 but the l2 ref info of 7133894 has been removed from l2_refs when the safe head is 7134334.

@ncitron
Copy link
Contributor

ncitron commented Feb 5, 2024

Oh this is interesting. I was under the impression that after the sequencer drift you are supposed to start injecting empty blocks so this caching length would be acceptable. We'll need to figure out what the correct number to increase it to is.

@GrapeBaBa do you have any idea what it should be?

@GrapeBaBa
Copy link
Contributor

Oh this is interesting. I was under the impression that after the sequencer drift you are supposed to start injecting empty blocks so this caching length would be acceptable. We'll need to figure out what the correct number to increase it to is.

@GrapeBaBa do you have any idea what it should be?

No, @thinkAfCod current fixed it by qurey op-geth when can't find it in the cache.

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

No branches or pull requests

3 participants