fix: build 48->49 epoch sync proof within the gc window#15978
Merged
Trisfald merged 1 commit intoJun 25, 2026
Merged
Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #15978 +/- ##
==========================================
+ Coverage 72.60% 72.61% +0.01%
==========================================
Files 952 952
Lines 205109 205122 +13
Branches 205109 205122 +13
==========================================
+ Hits 148914 148945 +31
+ Misses 51218 51198 -20
- Partials 4977 4979 +2
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
shreyan-gupta
approved these changes
Jun 25, 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.
Same as #15975
Upgrading to 2.13 (DB 48->49) crashed at startup on nodes with
gc_num_epochs_to_keep = 3withDB Not Found Error: epoch block: <hash>.Cause: the migration regenerated the epoch sync proof via
find_target_epoch_to_produce_proof_for, which anchors at the final head and reads BlockInfo ~4 epochs back, which gc=3 has already collected.Fix: build the proof anchored at the current epoch (target head-2), the same way continuous epoch sync does at a boundary. If the node restarted mid-epoch, where even head-2's inputs are collected, fall back to the freshest fully retained epoch (head-1).