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

[Tokenomics] Fix zero app stake chain halt #905

Draft
wants to merge 7 commits into
base: release/v0.0.9-3
Choose a base branch
from

Conversation

red-0ne
Copy link
Contributor

@red-0ne red-0ne commented Nov 6, 2024

Summary

This PR prevents chain halts when the Application stake is 0

Issue

The following error happens because application stake fell to 0.

poktrolld 4:53PM INF claim does not require proof due to compute units (5) being less than the threshold (20) and random sample (0.84) being greater than probability (0.25) method=proofRequirementForClaim module=server
poktrolld 4:53PM WRN Claim by supplier pokt1jvsuszgvsjyp4lxnfxqmrf7lqh4jutplcw8wx7 EXCEEDS LIMITS for application pokt1gsufws4c5dhemd0z3njfh859xl0624xyyw5m87. Max claimable amount < Claim amount: 0upokt < 210 application=pokt1gsufws4c5dhemd0z3njfh859xl0624xyyw5m87 claim_settlement_upokt=210 helper=ensureClaimAmountLimits method=ProcessTokenLogicModules module=x/tokenomics num_relays=5 service_id=0021 session_id=084deab39f3d7ff81426853ea186561e8ac1746987cf55edea22a98eff35e775 supplier_operator=pokt1jvsuszgvsjyp4lxnfxqmrf7lqh4jutplcw8wx7
poktrolld 4:53PM INF About to start processing TLMs for (5) relays, equal to (0upokt) claimed actual_settlement_upokt=0upokt application=pokt1gsufws4c5dhemd0z3njfh859xl0624xyyw5m87 claim_settlement_upokt=210 method=ProcessTokenLogicModules module=x/tokenomics num_relays=5 service_id=0021 session_id=084deab39f3d7ff81426853ea186561e8ac1746987cf55edea22a98eff35e775 supplier_operator=pokt1jvsuszgvsjyp4lxnfxqmrf7lqh4jutplcw8wx7
poktrolld 4:53PM INF Starting TLM processing: "TLMGlobalMint" actual_settlement_upokt=0upokt application=pokt1gsufws4c5dhemd0z3njfh859xl0624xyyw5m87 claim_settlement_upokt=210 method=ProcessTokenLogicModules module=x/tokenomics num_relays=5 service_id=0021 session_id=084deab39f3d7ff81426853ea186561e8ac1746987cf55edea22a98eff35e775 supplier_operator=pokt1jvsuszgvsjyp4lxnfxqmrf7lqh4jutplcw8wx7
poktrolld 4:53PM ERR error processing token logic modules for claim "084deab39f3d7ff81426853ea186561e8ac1746987cf55edea22a98eff35e775": TLM "TLMGlobalMint": mint amount cannot be zero: failed to process TLM [/go/pkg/mod/cosmossdk.io/[email protected]/errors.go:155] module=server num_claim_compute_units=5 num_relays_in_session_tree=5 proof_requirement=NOT_REQUIRED session_id=084deab39f3d7ff81426853ea186561e8ac1746987cf55edea22a98eff35e775 supplier_operator_address=pokt1jvsuszgvsjyp4lxnfxqmrf7lqh4jutplcw8wx7
poktrolld 4:53PM ERR could not settle pending claims due to error TLM "TLMGlobalMint": mint amount cannot be zero: failed to process TLM [/go/pkg/mod/cosmossdk.io/[email protected]/errors.go:155] method=EndBlocker module=x/tokenomics

Type of change

Select one or more from the following:

Testing

  • Unit Tests: make go_develop_and_test
  • LocalNet E2E Tests: make test_e2e
  • DevNet E2E Tests: Add the devnet-test-e2e label to the PR.

Sanity Checklist

  • I have tested my changes using the available tooling
  • I have commented my code
  • I have performed a self-review of my own code; both comments & source code
  • I create and reference any new tickets, if applicable
  • I have left TODOs throughout the codebase, if applicable

@red-0ne red-0ne added bug Something isn't working tokenomics Token Economics - what else do you need? labels Nov 6, 2024
@red-0ne red-0ne added this to the Shannon Beta TestNet Launch milestone Nov 6, 2024
@red-0ne red-0ne self-assigned this Nov 6, 2024
@red-0ne red-0ne changed the base branch from main to dk-v0.0.9 November 6, 2024 21:25
@red-0ne red-0ne changed the base branch from dk-v0.0.9 to dk-v0.0.9-upgrade November 6, 2024 21:25
@red-0ne red-0ne changed the base branch from dk-v0.0.9-upgrade to release/v0.0.9-3 November 6, 2024 21:29
@okdas okdas added the push-image CI related - pushes images to ghcr.io label Nov 6, 2024
Copy link

github-actions bot commented Nov 6, 2024

The image is going to be pushed after the next commit.

You can use make trigger_ci to push an empty commit.

If you also want to run E2E tests, please add devnet-test-e2e label.

@red-0ne red-0ne requested a review from okdas November 6, 2024 21:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working push-image CI related - pushes images to ghcr.io tokenomics Token Economics - what else do you need?
Projects
Status: 👀 In review
Development

Successfully merging this pull request may close these issues.

2 participants