near / nearcore

Reference client for NEAR Protocol
https://near.org
GNU General Public License v3.0
2.32k stars 623 forks source link

chore: Update replay-headers to report differences in rewards and kickouts #12048

Closed tayfunelmas closed 1 month ago

tayfunelmas commented 1 month ago

We have been using the neard replay-headers command to simulate validator rewards and kickouts computations for past epochs to check the difference between original and replayed runs.

Submitting the new version of the command we have been using for simulating the reward/kickout computations for chunk validators in the context of #11900.

This version no longer assumes that the original and replayed values are the same and prints the diffs in kickouts and rewards (stakes).

codecov[bot] commented 1 month ago

Codecov Report

Attention: Patch coverage is 0% with 112 lines in your changes missing coverage. Please review.

Project coverage is 71.40%. Comparing base (051289d) to head (33eac8f). Report is 1 commits behind head on master.

Files with missing lines Patch % Lines
tools/state-viewer/src/replay_headers.rs 0.00% 112 Missing :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #12048 +/- ## ========================================== - Coverage 71.42% 71.40% -0.03% ========================================== Files 814 814 Lines 163933 164040 +107 Branches 163933 164040 +107 ========================================== + Hits 117097 117132 +35 - Misses 41704 41774 +70 - Partials 5132 5134 +2 ``` | [Flag](https://app.codecov.io/gh/near/nearcore/pull/12048/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=near) | Coverage Δ | | |---|---|---| | [backward-compatibility](https://app.codecov.io/gh/near/nearcore/pull/12048/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=near) | `0.17% <0.00%> (-0.01%)` | :arrow_down: | | [db-migration](https://app.codecov.io/gh/near/nearcore/pull/12048/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=near) | `0.17% <0.00%> (-0.01%)` | :arrow_down: | | [genesis-check](https://app.codecov.io/gh/near/nearcore/pull/12048/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=near) | `1.28% <0.00%> (-0.01%)` | :arrow_down: | | [integration-tests](https://app.codecov.io/gh/near/nearcore/pull/12048/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=near) | `38.55% <0.00%> (-0.03%)` | :arrow_down: | | [linux](https://app.codecov.io/gh/near/nearcore/pull/12048/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=near) | `71.19% <0.00%> (-0.03%)` | :arrow_down: | | [linux-nightly](https://app.codecov.io/gh/near/nearcore/pull/12048/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=near) | `70.97% <0.00%> (-0.04%)` | :arrow_down: | | [macos](https://app.codecov.io/gh/near/nearcore/pull/12048/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=near) | `54.02% <0.00%> (+0.57%)` | :arrow_up: | | [pytests](https://app.codecov.io/gh/near/nearcore/pull/12048/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=near) | `1.54% <0.00%> (-0.01%)` | :arrow_down: | | [sanity-checks](https://app.codecov.io/gh/near/nearcore/pull/12048/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=near) | `1.34% <0.00%> (-0.01%)` | :arrow_down: | | [unittests](https://app.codecov.io/gh/near/nearcore/pull/12048/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=near) | `65.19% <0.00%> (-0.02%)` | :arrow_down: | | [upgradability](https://app.codecov.io/gh/near/nearcore/pull/12048/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=near) | `0.22% <0.00%> (-0.01%)` | :arrow_down: | Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=near#carryforward-flags-in-the-pull-request-comment) to find out more.

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.