-
Notifications
You must be signed in to change notification settings - Fork 461
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
Remove upper limit for ChainLevelHelper.GetNextHeader #4373
Conversation
our unit tests are failing |
Fixed |
@@ -110,6 +110,13 @@ public class MergeBlockDownloader : BlockDownloader | |||
|
|||
bool HasMoreToSync(out BlockHeader[]? headers, out int headersToRequest) | |||
{ | |||
if (!_beaconPivot.BeaconPivotExists()) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This condition is wrong. We can have situation when we don't have beacon pivot and we want to sync.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what do you think about Math.Min(ProcessDestination, BestKnownNumber) >= BestKnownBeaconNumber?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Imagine that you have timeout in NewPayloadHandler. For the next payload we insert it without cache and return SYNCING. We don't have beaconPivot in this situation.
ec509ed
to
d361bee
Compare
Changes:
Types of changes
Testing
Requires testing
In case you checked yes, did you write tests??
Comments about testing , should you have some (optional)
Further comments (optional)
If this is a relatively large or complex change, kick off the discussion by explaining why you chose the solution you did and what alternatives you considered, etc...