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

Test Blobber rewards and service charges #469

Closed
2 tasks
Sriep opened this issue Nov 11, 2022 · 0 comments · Fixed by 0chain/0chain#2320
Closed
2 tasks

Test Blobber rewards and service charges #469

Sriep opened this issue Nov 11, 2022 · 0 comments · Fixed by 0chain/0chain#2320
Assignees
Labels

Comments

@Sriep
Copy link
Contributor

Sriep commented Nov 11, 2022

Add a blobber collect service charge test to TestCollectRewards.

0chain/0chain#1828 and 0chain/0chain#1829 and 0chain/0chain#1832 and 0chain/0chain#1833 should fix collect rewards, so the service charge can be collected correctly; we should test this.

For storage writes and reads over an allocation period (say few minutes) which needs to include expiration and cancellation variants, the tokens needs to be absolute in the sense that they all need to go to the blobbers for storing data at a particular write price and reading data at a specific price. I'd do separate prices for blobbers and make sure the results conform to expectations. The validator income should be absolute as well in terms of challenges they worked on, but there will be probabilistic variance among them.

TestBlobberRewards needs a rework. Can be done after 0chain/0chain#1816 and 0chain/0chain#1777.

For blobber rewards, if all blobbers are uniform in reads/writes/storage/stake/price, then the probabilistic distribution should be uniform. We should test with non-uniform blobbers to see if the variance changes as per expectations. This is a tricky test and we need to consider different scenarios to make sure its working properly.

Also, see blobber reward lottery. It would be good if we could come up with a strategy to test rewards distribution is uniform in the long term, and consistent with the formulas.

  • Check blobber gets rewards for passing challenges. Ensure the tokenomics is correct on 0chain (ping @Kishan-Dhakan for clarification): @uneet7
  • Check blobber gets slashed for failing challenges. Ensure the tokenomics is correct on 0chain (ping @Kishan-Dhakan for clarification): TBD
@Sriep Sriep self-assigned this Nov 11, 2022
@Sriep Sriep added the mainnet label Nov 11, 2022
@Sriep Sriep linked a pull request Nov 11, 2022 that will close this issue
@stewartie4 stewartie4 added this to To Do in System Tests Nov 14, 2022
@Kishan-Dhakan Kishan-Dhakan changed the title Add a blobber collect sevice charge test to TestCollectRewards Test Blobber rewards and service charges Dec 19, 2022
@Kishan-Dhakan Kishan-Dhakan assigned Kishan-Dhakan and unassigned Sriep Feb 2, 2023
@Jayashsatolia403 Jayashsatolia403 linked a pull request Apr 26, 2023 that will close this issue
3 tasks
System Tests automation moved this from To Do to Done May 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Development

Successfully merging a pull request may close this issue.

3 participants