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

HTTP rewards verifier #6401

Open
michaelsproul opened this issue Sep 17, 2024 · 0 comments
Open

HTTP rewards verifier #6401

michaelsproul opened this issue Sep 17, 2024 · 0 comments
Labels
enhancement New feature or request HTTP-API rewards-api Implementation of the rewards API test improvement Improve tests

Comments

@michaelsproul
Copy link
Member

Description

It would be great to have a tool to cross-check the rewards returned by the HTTP rewards API against balance diffs on real networks.

This would help catch bugs like:

The tool could have a mode for checking a single slot/epoch's rewards, or a range. It could load the block/attestation/sync committee rewards using the API, and then load the relevant pre-state/post-state using the API, and compare the rewards to the difference in balance.

This tool could exist as a standalone repo outside Lighthouse, but could import e.g. eth2/common to reuse HTTP client logic. It will need to connect to an archive beacon node. Preferably running hdiffs:

Complications

The rewards APIs are known not to have full coverage. They do not handle penalties from the inactivity leak. We may want to add a mode to the range checking that warns when a range breaks the balance diff but then tries to continue (without allowing the incorrect balance to propagate).

@michaelsproul michaelsproul added enhancement New feature or request test improvement Improve tests HTTP-API rewards-api Implementation of the rewards API labels Sep 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request HTTP-API rewards-api Implementation of the rewards API test improvement Improve tests
Projects
None yet
Development

No branches or pull requests

1 participant