-
Notifications
You must be signed in to change notification settings - Fork 8
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] Implement Global Mint Reimbursement Request #878
base: main
Are you sure you want to change the base?
Conversation
…Invalid_SupplierExceedsMaxClaimableAmount
…_pokt_reimbursement_request
…_pokt_reimbursement_request
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
proofParams := s.keepers.ProofKeeper.GetParams(s.ctx) | ||
proofParams.ProofRequestProbability = 0 | ||
proofRequirementThreshold := cosmostypes.NewInt64Coin(volatile.DenomuPOKT, math.MaxInt64) | ||
proofParams.ProofRequirementThreshold = &proofRequirementThreshold | ||
s.keepers.ProofKeeper.SetParams(s.ctx, proofParams) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wdyt about extracting this to a TokenomicsModuleKeeperOpt
factory and passing it above, do you think it would get decent reuse?
Perhaps something like WithMaxProofRequirementThreshold()
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Brilliant! 😄
} | ||
|
||
// Update the application's on-chain stake | ||
newAppStake, err := application.Stake.SafeSub(newMintCoin) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm curious to understand if/how this interacts with the application min. stake and/or maxClaimableAmount
. 🤔
TL;DR, it seems to me like min. stake SHOULD be collateral for app overservicing AND GMRR. Is this that unnecessary? Do we need to update MaxClaimableAmount
?
MaxClaimableAmount
prevents actualSettlementCoin
from exceeding application stake - min. stake
(once we add the unsettled sessions coefficient 😅) but it seems like with GMRR we would also need to also account for the potential magnitude of actualSettlementCoin + newMintCoin
. Wouldn't min. stake actually need to cover actualSettlementCoin + newMintCoin
for each claim in each session between the current and currently settling sessions?
Since newMintCoin
is a function of actualSettlementCoin
, it seems like we should be able to consider it in the same scope as maxClaimableAmount
if that's the way to go here.
Summary
This PR adds
Issue
Type of change
Select one or more from the following:
Testing
make go_develop_and_test
make test_e2e
devnet-test-e2e
label to the PR.Sanity Checklist