Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merge/transition fixes #4145

Closed
wants to merge 18 commits into from
Closed

Merge/transition fixes #4145

wants to merge 18 commits into from

Conversation

MarekM25
Copy link
Contributor

@MarekM25 MarekM25 commented Jun 10, 2022

Fixes in suggest blocks from discovery during the transition

@MarekM25 MarekM25 marked this pull request as ready for review June 28, 2022 12:05
bool tdImproved = header.TotalDifficulty > (BestSuggestedBody?.TotalDifficulty ?? 0);
bool preMergeImprovementRequirementSatisfied = tdImproved && !reachedTtd;
bool terminalBlockRequirementSatisfied = tdImproved && reachedTtd && IsTerminalBlock(header) && !HeadIsPoS;
bool postMergeImprovementRequirementSatisfied = reachedTtd && (BestSuggestedBody?.Number ?? 0) <= header.Number && isPostMerge;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

(BestSuggestedBody?.Number ?? 0) <= header.Number in postMergeImprovementRequirementSatisfied -> shouldn't that be controlled by FCU?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's discuss

@LukaszRozmej
Copy link
Member

Closing in favor of #4224

@MarekM25 MarekM25 deleted the merge/transition_fixes branch December 20, 2022 15:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants