Skip to content

Fix edge case for non atomic commit#3128

Merged
yzang2019 merged 11 commits into
mainfrom
yzang/bug-fix-STO-436
Mar 30, 2026
Merged

Fix edge case for non atomic commit#3128
yzang2019 merged 11 commits into
mainfrom
yzang/bug-fix-STO-436

Conversation

@yzang2019

@yzang2019 yzang2019 commented Mar 27, 2026

Copy link
Copy Markdown
Contributor

Describe your changes and provide context

This PR is intended to fix two issues:

  1. Make sure lattice hash is enabled if write mode is Split Write.
  2. If the node crashed during Commit after the cosmos store was committed but before the EVM/FlatKV one was, it will lead to an unrecovered mixed state with a wrong CommitInfo. The fix is to introduce some version reconciliation mechanism during initialization if the two DB version mismatch

Testing performed to validate your change

@github-actions

github-actions Bot commented Mar 27, 2026

Copy link
Copy Markdown

The latest Buf updates on your PR. Results from workflow Buf / buf (pull_request).

BuildFormatLintBreakingUpdated (UTC)
✅ passed✅ passed✅ passed✅ passedMar 30, 2026, 8:56 PM

@codecov

codecov Bot commented Mar 27, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 65.62500% with 11 lines in your changes missing coverage. Please review.
✅ Project coverage is 58.76%. Comparing base (4ff13b1) to head (4e42436).
⚠️ Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
sei-db/state_db/sc/composite/store.go 54.16% 6 Missing and 5 partials ⚠️
Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #3128      +/-   ##
==========================================
+ Coverage   58.51%   58.76%   +0.24%     
==========================================
  Files        2095     2094       -1     
  Lines      173517   172918     -599     
==========================================
+ Hits       101538   101612      +74     
+ Misses      62866    62255     -611     
+ Partials     9113     9051      -62     
Flag Coverage Δ
sei-chain-pr 57.67% <65.62%> (?)
sei-db 70.41% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
sei-db/config/sc_config.go 100.00% <100.00%> (ø)
sei-db/state_db/sc/composite/store.go 66.12% <54.16%> (-1.81%) ⬇️

... and 56 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

* main:
  Pass versioned changeset entries to wrappers + ApplyChangesetasync (#3120)
  Remove stale price snapshot creation from MidBlocker (#3117)
@yzang2019 yzang2019 enabled auto-merge March 28, 2026 11:51
@yzang2019 yzang2019 disabled auto-merge March 28, 2026 11:52
@yzang2019 yzang2019 added this pull request to the merge queue Mar 30, 2026
Merged via the queue into main with commit fcfbfdd Mar 30, 2026
39 checks passed
@yzang2019 yzang2019 deleted the yzang/bug-fix-STO-436 branch March 30, 2026 21:41
yzang2019 added a commit that referenced this pull request Mar 31, 2026
* main:
  Fix edge case for non atomic commit (#3128)
blindchaser pushed a commit that referenced this pull request Apr 17, 2026
## Describe your changes and provide context
This PR is intended to fix two issues:
1. Make sure lattice hash is enabled if write mode is Split Write.
2. If the node crashed during Commit after the cosmos store was
committed but before the EVM/FlatKV one was, it will lead to an
unrecovered mixed state with a wrong CommitInfo. The fix is to introduce
some version reconciliation mechanism during initialization if the two
DB version mismatch

## Testing performed to validate your change
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants