test(flatkv): add EVM migration docker integration coverage#3400
test(flatkv): add EVM migration docker integration coverage#3400blindchaser wants to merge 4 commits intomainfrom
Conversation
a6335b1 to
a9518ab
Compare
|
The latest Buf updates on your PR. Results from workflow Buf / buf (pull_request).
|
a9518ab to
1acc8aa
Compare
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: a9518ab773
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| if err != nil { | ||
| return fmt.Errorf("failed to create FlatKV importer at height %d: %w", height, err) | ||
| } | ||
| defer func() { _ = importer.Close() }() |
There was a problem hiding this comment.
Avoid finalizing partial imports after errors
Because this deferred Close runs on every return path, any error after some nodes have been added but before the explicit successful close—such as an exporter error, context cancellation, or an invalid EVM key from migrateEVMNode—still calls KVImporter.Close, which finalizes the import, writes a snapshot, and leaves a committed partial FlatKV store even though the command reports failure. This can make a failed migration look retryable while leaving corrupted migrated state on disk; only finalize on the success path or add an abort/cleanup path for failures.
Useful? React with 👍 / 👎.
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #3400 +/- ##
==========================================
- Coverage 59.03% 59.02% -0.02%
==========================================
Files 2105 2106 +1
Lines 173300 173529 +229
==========================================
+ Hits 102312 102421 +109
- Misses 62104 62202 +98
- Partials 8884 8906 +22
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
1acc8aa to
32871b0
Compare
32871b0 to
cda2dc8
Compare
Describe your changes and provide context
Testing performed to validate your change