-
Notifications
You must be signed in to change notification settings - Fork 4
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
Add proper saving for last tick quorum data per epoch interval #78
Conversation
validator/tick/models.go
Outdated
return interval, nil | ||
} | ||
|
||
return nil, errors.New(fmt.Sprintf("unable to find processed tick intervals for epoch %d", epoch)) |
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.
errors.Errorf should be used instead of errors.New with Sprintf
validator/tick/models.go
Outdated
return nil, errors.New(fmt.Sprintf("unable to find processed tick intervals for epoch %d", epoch)) | ||
} | ||
|
||
func IsLast(tickNumber uint32, epoch uint32, intervals []*protobuff.ProcessedTickIntervalsPerEpoch) (bool, int, error) { |
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 function is not self explanatory from the definition, you either redefine it or if you can't change it to make it more explanatory, then adding a comment is mandatory
store/store.go
Outdated
for key, qd := range lastQuorumDataPerEpochIntervals.QuorumDataPerInterval { | ||
|
||
if qd != nil { | ||
fmt.Printf("DEBUG: %d %d\n", key, qd.QuorumTickStructure.TickNumber) |
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.
do you need to remove the debug print statements?
No description provided.