-
Notifications
You must be signed in to change notification settings - Fork 174
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
Incorrect output of fees_to_staker for rpc getblock/showblock #2566
Comments
Interesting. We need to track this down. I may do a non-milestone leisure release even before the hardfork point to fix a few problems that have cropped up. All in all so far this was a pretty smooth release given the changes. |
@iFoggz, do you want to take a spin at it? |
i should have some time tomorrow to do so just got home a bit ago and kids have visit with there older sister who in foster care. i may find time tonight as wel. |
i have updated the report. fees_to_staker/fees_collected not really related. so corrected my report on it. |
No big big rush I think. But if we can get a fix pinned by the end of the weekend that would be good. |
The field is misnamed for one.... It should be called mrc_fees_to_staker rather than fees_to_staker, because it is supposed to tally the total fees to the staker from all mrc's in the claim. It is not supposed to include standard transaction fees that are also to the staker. This should be zero for all blocks with no mrcs (which also means any block < v12). Unfortunately I forgot to add a 0 initialzer for the requisite member variable, claim.m_mrc_fees_to_staker. For blocks with mrc's this doesn't matter, because it is assigned the correct value, but for all non-mrc blocks (including all < v12 blocks in 5.4.0.0), it assumes a random value. I will put up a small PR to rename the field so that it is not confusing, and also initialize the field to zero in the claim constructor. |
Bug Report
Current behavior
fees_to_staker show erroneous outputs.
Expected behavior
fees_to_staker should be zero unless the staker is receiving fees.
Steps to reproduce:
For instance on MainNet:
showblock 2656056:
however showblock/getblock shows "fees_to_staker": 18.02401069
For instance on TestNet:
showblock 1968886:
however showblock/getblock shows "fees_to_staker": 0.00000320
Screenshots
Not applicable
Gridcoin version
5.4.0.0 release .deb
Machine specs
Extra information
The text was updated successfully, but these errors were encountered: