-
Notifications
You must be signed in to change notification settings - Fork 69
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
IF: accumulate the weight in vote calculation #2131
Conversation
Note:start |
unittests/block_state_tests.cpp
Outdated
@@ -96,7 +191,7 @@ BOOST_AUTO_TEST_CASE(verify_qc_test) try { | |||
digest_type strong_digest(fc::sha256("0000000000000000000000000000002")); | |||
std::vector<uint8_t> strong_digest_data(strong_digest.data(), strong_digest.data() + strong_digest.data_size()); | |||
digest_type weak_digest(fc::sha256("0000000000000000000000000000003")); | |||
std::vector<uint8_t> weak_digest_data(weak_digest.data(), weak_digest.data() + weak_digest.data_size()); | |||
std::vector<uint8_t> weak_digest_data(weak_digest.data(), weak_digest.data() + weak_digest. data_size()); |
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.
the spaces after weak_digest.
seem to be a mistake.
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.
Thanks for noticing this!
Not related to your changes, but looks like we have a real issue with this test: |
Currently in the weak and strong vote calculations, it is assuming they are all of equal weight. It needs to refer to the weights in the finalizer policy to determine how to accumulate the weight.
Resolved #2084