Skip to content
This repository has been archived by the owner on Jan 6, 2025. It is now read-only.

Mismatched comparison when assessing finality #117

Open
djrtwo opened this issue Apr 30, 2018 · 2 comments
Open

Mismatched comparison when assessing finality #117

djrtwo opened this issue Apr 30, 2018 · 2 comments
Labels

Comments

@djrtwo
Copy link
Contributor

djrtwo commented Apr 30, 2018

@yzhang90 noticed that comparing current_dynasty_votes and total_curdyn_deposits happens after proc_reward(

if (current_dynasty_votes >= self.total_curdyn_deposits * 2 / 3 and
), which means current_dynasty_votes is the value before the proc_reward but total_curdyn_deposits is the value after proc_reward. This seems unintentional. Both should comparison should likely happen between the two values prior to the reward inclusion or after the reward inclusion. Not with one of the values before and one after.

@karlfloersch I wanted to make sure this is a bug and not an intentional feature before I move forward with changing it.

@djrtwo djrtwo added bug and removed question labels May 9, 2018
@djrtwo
Copy link
Contributor Author

djrtwo commented May 9, 2018

This is a bug. I'll spec it more closely and get it fixed soon.

@djrtwo
Copy link
Contributor Author

djrtwo commented Jun 6, 2018

We plan to bulk update the total deposit variables from the vote rewards in initialize_epoch in this issue #158

Ensure that when a PR is submit for #158 that this is no longer an issue

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

1 participant