Fix xevm snapshot journal reverts#3414
Open
codchen wants to merge 2 commits into
Open
Conversation
|
The latest Buf updates on your PR. Results from workflow Buf / buf (pull_request).
|
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #3414 +/- ##
==========================================
+ Coverage 59.24% 59.25% +0.01%
==========================================
Files 2110 2110
Lines 174149 174210 +61
==========================================
+ Hits 103175 103230 +55
- Misses 62041 62044 +3
- Partials 8933 8936 +3
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
sei-will
approved these changes
May 11, 2026
arajasek
approved these changes
May 11, 2026
arajasek
approved these changes
May 11, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Tests
Note
Medium Risk
Touches EVM stateDB journaling and snapshot rollback semantics (code, nonce, address mappings), so subtle regressions could affect execution correctness, but changes are localized and covered by new regression tests.
Overview
Fixes snapshot rollback correctness in
xevm/stateby journaling key existence for code/nonce and restoring them precisely (including deleting keys when they were originally absent), rather than relying on zero/empty-value heuristics.SetCodereverts now also restore/remove any address mapping and account side-effects thatKeeper.SetCodemay have created, including resetting the auth module’s global account number when a revert removes a newly-created account.Adjusts
SetStateso same-value writes still pass through to the backing store while continuing to dedupe journal entries, and adds targeted tests for mapping cleanup, absent nonce/code preservation,CreateAccountrevert behavior, and no-op storage write-through.Reviewed by Cursor Bugbot for commit fb542d6. Bugbot is set up for automated code reviews on this repo. Configure here.