Skip to content

Commit

Permalink
fix the upgrade!
Browse files Browse the repository at this point in the history
  • Loading branch information
okdas committed Oct 31, 2024
1 parent b83cede commit f0d0e7a
Showing 1 changed file with 11 additions and 3 deletions.
14 changes: 11 additions & 3 deletions app/upgrades/v0.0.10.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import (
cosmosTypes "github.com/cosmos/cosmos-sdk/types"
"github.com/cosmos/cosmos-sdk/types/module"
"github.com/pokt-network/poktroll/app/keepers"
prooftypes "github.com/pokt-network/poktroll/x/proof/types"
)

// Upgrade_0_0_10 is the upgrade handler for v0.0.10 Alpha TestNet upgrade
Expand Down Expand Up @@ -60,11 +61,18 @@ var Upgrade_0_0_10 = Upgrade{
//
// !!!! THE UPGRADE CURRENTLY BREAKS HERE !!!!
// https://gist.github.com/okdas/535bc3c0282483fef27454c70d889aa6
proofParams := keepers.ProofKeeper.GetParams(ctx)
// proofParams := keepers.ProofKeeper.GetParams(ctx)
// Need to construct params manually due to protobuf type changes:
newProofRequirementThreshold := cosmosTypes.NewCoin("upokt", math.NewInt(20000000))
newProofMissingPenalty := cosmosTypes.NewCoin("upokt", math.NewInt(320000000))
proofParams.ProofRequirementThreshold = &newProofRequirementThreshold
proofParams.ProofMissingPenalty = &newProofMissingPenalty
newProofSubmissionFee := cosmosTypes.NewCoin("upokt", math.NewInt(1000000))
proofParams := prooftypes.NewParams(
0.25,
&newProofRequirementThreshold,
&newProofMissingPenalty,
&newProofSubmissionFee,
)

err = keepers.ProofKeeper.SetParams(ctx, proofParams)
if err != nil {
return vm, err
Expand Down

0 comments on commit f0d0e7a

Please sign in to comment.