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

fix validator state when trying to update the max-rate #4647

Merged
merged 2 commits into from
Apr 30, 2024

Conversation

diego1q2w
Copy link
Contributor

During the previous hardfork we mad sure to update the max-rate to be at least the min-rate + max-rate-change to comply with the the minimum 7% rate imposed in HIP30, for validators running under that threshold. However, with that we introduced a subtle bug under the assumption that max-rate-change was a small value but in practice is not, it can go up to a 100% which will sum to a number higher than a 100% when adding the min-rate.
For a handful of validators that caused the sanity checks fails when persisting the state in the hard-drive. A issue that is hard to catch as it'll only happen once per epoch, this bug explains issues like the buggy validator or the validator with undelegated funds issues.
As this is a change in the way the data is stored in the state this will have to go with a hardfork, I guess we can inlcude it with the leader rotation.

@sophoah
Copy link
Contributor

sophoah commented Mar 28, 2024

hey @diego1q2w PR looks good. Were you able to test in localnet whether all is good and whether that really fix #4632 and #4605

@ONECasey
Copy link
Contributor

ONECasey commented Apr 2, 2024

Theres a few conflicts @diego1q2w so I fixed them

@diego1q2w
Copy link
Contributor Author

hey @diego1q2w PR looks good. Were you able to test in localnet whether all is good and whether that really fix #4632 and #4605

Yes i tested it. it worked.

@sophoah sophoah merged commit 0e29f52 into dev Apr 30, 2024
4 checks passed
@diego1q2w diego1q2w deleted the fix-validator-state-rate-100 branch April 30, 2024 08:43
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.

3 participants