-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
[1.2.0] Check for result phase at activate method #3492
[1.2.0] Check for result phase at activate method #3492
Conversation
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.
NACK
The vote results are only populated if viewing the results on the first block of the results phase. If you try to view the results after that, they are still empty.
fillCycleList(); | ||
} | ||
|
||
private void checkForResultPhase(int chainHeight) { | ||
if (periodService.getFirstBlockOfPhase(chainHeight, DaoPhase.Phase.RESULT) == chainHeight) { |
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.
Shouldn't this be <= chainHeight
?
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.
periodService.getFirstBlockOfPhase
gets the height of the first block of the current phase so this check will return true for all chainHeight
in the RESULT
phase.
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.
NACK
fillCycleList(); | ||
} | ||
|
||
private void checkForResultPhase(int chainHeight) { | ||
if (periodService.getFirstBlockOfPhase(chainHeight, DaoPhase.Phase.RESULT) == chainHeight) { |
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.
periodService.getFirstBlockOfPhase
gets the height of the first block of the current phase so this check will return true for all chainHeight
in the RESULT
phase.
@sqrrm I think you approved by mistake -> NACK |
I first approved without testing. Then I read a bit more, checked out and tested and it fails, working on a fix. Don't know how to undo the approve. |
I made a new PR at #3500 that fixes this |
Superseded by #3500 |
Fixes #3487