Preserve historical withdrawal accounting on Drivenet - #49
Draft
ekulkisnek wants to merge 1 commit into
Draft
ekulkisnek wants to merge 1 commit into
ekulkisnek wants to merge 1 commit into
Conversation
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.
Problem
Commit 48208c5 correctly made new withdrawals fund both the payout and mainchain fee, but Drivenet already contained blocks mined under the former payout-only rule. Current nodes stop syncing when they revalidate those blocks.
Fix
Evidence
Before this change, replay stopped at height 447 on block
f9a7a9117bec4ed6c4fffbf3b651b60f9459a5fc881f267b271778874ad55d0f. A second historical block was found at height 807:208e6bb567efd46d073bab68d9cff041279faada60c7f27a011a56bd1f7f86b7. With both exact exceptions, the node replayed the existing Drivenet history to tip height 7360.Validation:
cargo test --workspace --locked,cargo clippy --workspace --all-targets --locked -- -D warnings, formatting, and diff checks pass.