From e6b77d8aaf0b95451ef16d3e6b91b0d1db502cda Mon Sep 17 00:00:00 2001 From: Vladislav Mikitich Date: Wed, 25 Sep 2024 22:29:38 +0300 Subject: [PATCH] upgrade v0.50 (#19) --- .golangci.yml | 3 + Makefile | 2 +- app/ante/ante.go | 5 +- app/ante/check_accounts.go | 2 +- app/ante/expected_keepers.go | 6 +- app/ante/sig_verification.go | 70 +- app/ante/track_gas.go | 27 +- app/ante/zero-gas.go | 65 +- app/app.go | 363 +++++----- app/encoding.go | 16 +- app/export.go | 129 ++-- app/simulation_test.go | 10 +- app/upgrade/v101/upgrade.go | 18 - app/upgrade/v110/convert_sp.go | 69 -- app/upgrade/v110/migrate_scorum_params.go | 67 -- app/upgrade/v110/upgrade.go | 57 -- app/upgrade/{v101 => v120}/README.md | 0 app/upgrade/v120/upgrade.go | 76 +++ app/validate.go | 2 +- cmd/scorumd/cmd/collectgentx.go | 25 +- cmd/scorumd/cmd/config.go | 251 ------- cmd/scorumd/cmd/genaccounts.go | 5 +- cmd/scorumd/cmd/prune.go | 121 ---- cmd/scorumd/cmd/root.go | 128 ++-- cmd/scorumd/main.go | 16 +- go.mod | 157 +++-- go.sum | 626 ++++++------------ proto/buf.lock | 6 +- proto/buf.yaml | 2 +- proto/network/aviatrix/v1/tx.proto | 15 +- proto/network/scorum/v1/params.proto | 23 +- proto/network/scorum/v1/proposal.proto | 17 - proto/network/scorum/v1/tx.proto | 34 +- proto/network/scorum/v1/types.proto | 2 + testutil/keeper/account.go | 16 +- testutil/keeper/bank.go | 16 +- testutil/keeper/context.go | 38 +- testutil/keeper/nft.go | 13 +- testutil/keeper/scorum.go | 1 + testutil/keeper/staking.go | 7 +- x/aviatrix/keeper/keeper.go | 4 +- x/aviatrix/keeper/keeper_test.go | 8 +- .../msg_server_adjust_plane_experience.go | 2 +- ...msg_server_adjust_plane_experience_test.go | 9 +- x/aviatrix/keeper/msg_server_create.go | 2 +- .../msg_server_set_plane_experience_test.go | 9 +- x/aviatrix/keeper/plane.go | 2 +- x/aviatrix/module.go | 22 +- x/aviatrix/simulation/operations.go | 11 +- x/aviatrix/simulation/proposals.go | 4 +- x/aviatrix/types/expected_keepers.go | 16 +- x/aviatrix/types/query.pb.go | 2 +- x/aviatrix/types/tx.pb.go | 63 +- x/nft/validation.go | 2 +- x/scorum/client/cli/proposal_mint.go | 107 ++- x/scorum/client/cli/tx.go | 9 +- x/scorum/client/cli/tx_mint_gas.go | 5 +- x/scorum/client/proposal_handler.go | 9 - x/scorum/handler.go | 23 - x/scorum/keeper/gas.go | 45 +- x/scorum/keeper/keeper.go | 14 +- x/scorum/keeper/keeper_test.go | 8 +- x/scorum/keeper/msg_mint.go | 28 + ...proposal_mint_test.go => msg_mint_test.go} | 22 +- x/scorum/keeper/msg_server_burn_test.go | 6 +- x/scorum/keeper/msg_server_mint_gas.go | 2 +- x/scorum/keeper/msg_server_mint_gas_test.go | 10 +- x/scorum/keeper/params_test.go | 10 +- x/scorum/keeper/proposal_mint.go | 19 - x/scorum/keeper/query_params_test.go | 10 +- x/scorum/keeper/validator_reward.go | 8 +- x/scorum/module.go | 39 +- x/scorum/simulation/genesis.go | 3 +- x/scorum/simulation/operations.go | 28 +- x/scorum/simulation/params.go | 5 +- x/scorum/simulation/proposals.go | 49 +- x/scorum/types/codec.go | 13 +- x/scorum/types/expected_keepers.go | 38 +- x/scorum/types/genesis_test.go | 9 +- x/scorum/types/keys.go | 3 +- x/scorum/types/msg_mint.go | 56 ++ x/scorum/types/msg_mint_gas.go | 4 +- x/scorum/types/params.go | 34 +- x/scorum/types/params.pb.go | 136 ++-- x/scorum/types/proposal.go | 49 -- x/scorum/types/proposal.pb.go | 480 -------------- x/scorum/types/tx.pb.go | 518 +++++++++++++-- x/scorum/types/types.pb.go | 19 +- x/scorum/wrapper/account_keeper.go | 11 +- x/scorum/wrapper/staking_bank_keeper.go | 11 +- 90 files changed, 2004 insertions(+), 2498 deletions(-) delete mode 100644 app/upgrade/v101/upgrade.go delete mode 100644 app/upgrade/v110/convert_sp.go delete mode 100644 app/upgrade/v110/migrate_scorum_params.go delete mode 100644 app/upgrade/v110/upgrade.go rename app/upgrade/{v101 => v120}/README.md (100%) create mode 100644 app/upgrade/v120/upgrade.go delete mode 100644 cmd/scorumd/cmd/config.go delete mode 100644 cmd/scorumd/cmd/prune.go delete mode 100644 proto/network/scorum/v1/proposal.proto delete mode 100644 x/scorum/client/proposal_handler.go delete mode 100644 x/scorum/handler.go create mode 100644 x/scorum/keeper/msg_mint.go rename x/scorum/keeper/{proposal_mint_test.go => msg_mint_test.go} (59%) delete mode 100644 x/scorum/keeper/proposal_mint.go create mode 100644 x/scorum/types/msg_mint.go delete mode 100644 x/scorum/types/proposal.go delete mode 100644 x/scorum/types/proposal.pb.go diff --git a/.golangci.yml b/.golangci.yml index 0af1970..9d18962 100644 --- a/.golangci.yml +++ b/.golangci.yml @@ -89,3 +89,6 @@ issues: - errcheck path: testutil + - linters: + - errcheck + path: x/scorum/client/cli \ No newline at end of file diff --git a/Makefile b/Makefile index 153a813..7610487 100644 --- a/Makefile +++ b/Makefile @@ -11,7 +11,7 @@ DOCKER := $(shell which docker) LINTER_NAME := golangci-lint LINTER_VERSION := v1.59.0 -CONTAINER_PROTO_VERSION=0.13.0 +CONTAINER_PROTO_VERSION=0.14.0 CONTAINER_PROTO_IMAGE=ghcr.io/cosmos/proto-builder:$(CONTAINER_PROTO_VERSION) GOSRC := $(shell go env GOPATH)/src diff --git a/app/ante/ante.go b/app/ante/ante.go index 0ed78ca..a3d3fef 100644 --- a/app/ante/ante.go +++ b/app/ante/ante.go @@ -2,6 +2,7 @@ package ante import ( errorsmod "cosmossdk.io/errors" + circuitante "cosmossdk.io/x/circuit/ante" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" "github.com/cosmos/cosmos-sdk/x/auth/ante" @@ -13,6 +14,7 @@ type HandlerOptions struct { ScorumKeeper ScorumKeeper AccountKeeper AccountKeeper BankKeeper BankKeeper + CircuitKeeper circuitante.CircuitBreaker } func NewAnteHandler(options HandlerOptions) (sdk.AnteHandler, error) { @@ -34,7 +36,8 @@ func NewAnteHandler(options HandlerOptions) (sdk.AnteHandler, error) { anteDecorators := []sdk.AnteDecorator{ ante.NewSetUpContextDecorator(), // outermost AnteDecorator. SetUpContext must be called first - NewZeroGasTxDecorator(options.ScorumKeeper), + circuitante.NewCircuitBreakerDecorator(options.CircuitKeeper), + NewZeroGasTxDecorator(options.AccountKeeper, options.ScorumKeeper), NewTrackGasConsumedDecorator(options.AccountKeeper, options.BankKeeper, options.ScorumKeeper), ante.NewExtensionOptionsDecorator(options.ExtensionOptionChecker), ante.NewValidateBasicDecorator(), diff --git a/app/ante/check_accounts.go b/app/ante/check_accounts.go index d6d58db..0db7b44 100644 --- a/app/ante/check_accounts.go +++ b/app/ante/check_accounts.go @@ -32,7 +32,7 @@ func (d CheckAddressesDecorator) AnteHandle( for _, msg := range tx.GetMsgs() { for _, addr := range extractAddresses(msg) { if !d.ak.HasAccount(ctx, addr) { - if err := d.sk.Mint(ctx, addr, sdk.NewCoin(scorumtypes.GasDenom, d.sk.GetParams(ctx).GasLimit.Int)); err != nil { + if err := d.sk.Mint(ctx, addr, sdk.NewCoin(scorumtypes.GasDenom, d.sk.GetParams(ctx).GasLimit)); err != nil { return sdk.Context{}, errorsmod.Wrap(sdkerrors.ErrPanic, fmt.Sprintf("failed to mint gas to new account: %s", err.Error())) } } diff --git a/app/ante/expected_keepers.go b/app/ante/expected_keepers.go index 8e156c1..e35afce 100644 --- a/app/ante/expected_keepers.go +++ b/app/ante/expected_keepers.go @@ -1,6 +1,8 @@ package ante import ( + "context" + sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/x/auth/ante" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" @@ -19,11 +21,11 @@ type ScorumKeeper interface { type AccountKeeper interface { ante.AccountKeeper - HasAccount(ctx sdk.Context, addr sdk.AccAddress) bool + HasAccount(ctx context.Context, addr sdk.AccAddress) bool } type BankKeeper interface { authtypes.BankKeeper - GetBalance(ctx sdk.Context, addr sdk.AccAddress, denom string) sdk.Coin + GetBalance(ctx context.Context, addr sdk.AccAddress, denom string) sdk.Coin } diff --git a/app/ante/sig_verification.go b/app/ante/sig_verification.go index de1ec58..4f06bff 100644 --- a/app/ante/sig_verification.go +++ b/app/ante/sig_verification.go @@ -3,10 +3,14 @@ package ante import ( "fmt" + errorsmod "cosmossdk.io/errors" + txsigning "cosmossdk.io/x/tx/signing" + codectypes "github.com/cosmos/cosmos-sdk/codec/types" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" "github.com/cosmos/cosmos-sdk/x/auth/ante" authsigning "github.com/cosmos/cosmos-sdk/x/auth/signing" + "google.golang.org/protobuf/types/known/anypb" ) // SigVerificationDecorator is a copy of cosmos original SigVerificationDecorator @@ -16,10 +20,10 @@ type SigVerificationDecorator struct { ak AccountKeeper sk ScorumKeeper - signModeHandler authsigning.SignModeHandler + signModeHandler *txsigning.HandlerMap } -func NewSigVerificationDecorator(ak AccountKeeper, sk ScorumKeeper, signModeHandler authsigning.SignModeHandler) SigVerificationDecorator { +func NewSigVerificationDecorator(ak AccountKeeper, sk ScorumKeeper, signModeHandler *txsigning.HandlerMap) SigVerificationDecorator { return SigVerificationDecorator{ ak: ak, sk: sk, @@ -27,9 +31,9 @@ func NewSigVerificationDecorator(ak AccountKeeper, sk ScorumKeeper, signModeHand } } func (svd SigVerificationDecorator) AnteHandle(ctx sdk.Context, tx sdk.Tx, simulate bool, next sdk.AnteHandler) (newCtx sdk.Context, err error) { - sigTx, ok := tx.(authsigning.SigVerifiableTx) + sigTx, ok := tx.(authsigning.Tx) if !ok { - return ctx, sdkerrors.Wrap(sdkerrors.ErrTxDecode, "invalid transaction type") + return ctx, errorsmod.Wrap(sdkerrors.ErrTxDecode, "invalid transaction type") } // stdSigs contains the sequence number, account number, and signatures. @@ -39,15 +43,18 @@ func (svd SigVerificationDecorator) AnteHandle(ctx sdk.Context, tx sdk.Tx, simul return ctx, err } - signerAddrs := sigTx.GetSigners() + signers, err := sigTx.GetSigners() + if err != nil { + return ctx, err + } // check that signer length and signature length are the same - if len(sigs) != len(signerAddrs) { - return ctx, sdkerrors.Wrapf(sdkerrors.ErrUnauthorized, "invalid number of signer; expected: %d, got %d", len(signerAddrs), len(sigs)) + if len(sigs) != len(signers) { + return ctx, errorsmod.Wrapf(sdkerrors.ErrUnauthorized, "invalid number of signer; expected: %d, got %d", len(signers), len(sigs)) } for i, sig := range sigs { - acc, err := ante.GetSignerAcc(ctx, svd.ak, signerAddrs[i]) + acc, err := ante.GetSignerAcc(ctx, svd.ak, signers[i]) if err != nil { return ctx, err } @@ -55,16 +62,19 @@ func (svd SigVerificationDecorator) AnteHandle(ctx sdk.Context, tx sdk.Tx, simul // retrieve pubkey pubKey := acc.GetPubKey() if !simulate && pubKey == nil { - return ctx, sdkerrors.Wrap(sdkerrors.ErrInvalidPubKey, "pubkey on account is not set") + return ctx, errorsmod.Wrap(sdkerrors.ErrInvalidPubKey, "pubkey on account is not set") } // Check account sequence number. - // Applicable only for not supervisors - if !svd.sk.IsSupervisor(ctx, acc.GetAddress().String()) && sig.Sequence != acc.GetSequence() { - return ctx, sdkerrors.Wrapf( - sdkerrors.ErrWrongSequence, - "account sequence mismatch, expected %d, got %d", acc.GetSequence(), sig.Sequence, - ) + if sig.Sequence != acc.GetSequence() { + // Check account sequence number. + // Applicable only for not supervisors + if !svd.sk.IsSupervisor(ctx, acc.GetAddress().String()) && sig.Sequence != acc.GetSequence() { + return ctx, errorsmod.Wrapf( + sdkerrors.ErrWrongSequence, + "account sequence mismatch, expected %d, got %d", acc.GetSequence(), sig.Sequence, + ) + } } // retrieve signer data @@ -74,17 +84,27 @@ func (svd SigVerificationDecorator) AnteHandle(ctx sdk.Context, tx sdk.Tx, simul if !genesis { accNum = acc.GetAccountNumber() } - signerData := authsigning.SignerData{ - Address: acc.GetAddress().String(), - ChainID: chainID, - AccountNumber: accNum, - Sequence: sig.Sequence, // acc.GetSequence() was originally here, but supervisors allowed to put any value - PubKey: pubKey, - } // no need to verify signatures on recheck tx if !simulate && !ctx.IsReCheckTx() { - err := authsigning.VerifySignature(pubKey, signerData, sig.Data, svd.signModeHandler, tx) + anyPk, _ := codectypes.NewAnyWithValue(pubKey) + + signerData := txsigning.SignerData{ + Address: acc.GetAddress().String(), + ChainID: chainID, + AccountNumber: accNum, + Sequence: acc.GetSequence(), + PubKey: &anypb.Any{ + TypeUrl: anyPk.TypeUrl, + Value: anyPk.Value, + }, + } + adaptableTx, ok := tx.(authsigning.V2AdaptableTx) + if !ok { + return ctx, fmt.Errorf("expected tx to implement V2AdaptableTx, got %T", tx) + } + txData := adaptableTx.GetSigningTxData() + err = authsigning.VerifySignature(ctx, pubKey, signerData, sig.Data, svd.signModeHandler, txData) if err != nil { var errMsg string if ante.OnlyLegacyAminoSigners(sig.Data) { @@ -92,9 +112,9 @@ func (svd SigVerificationDecorator) AnteHandle(ctx sdk.Context, tx sdk.Tx, simul // and therefore communicate sequence number as a potential cause of error. errMsg = fmt.Sprintf("signature verification failed; please verify account number (%d), sequence (%d) and chain-id (%s)", accNum, acc.GetSequence(), chainID) } else { - errMsg = fmt.Sprintf("signature verification failed; please verify account number (%d) and chain-id (%s)", accNum, chainID) + errMsg = fmt.Sprintf("signature verification failed; please verify account number (%d) and chain-id (%s): (%s)", accNum, chainID, err.Error()) } - return ctx, sdkerrors.Wrap(sdkerrors.ErrUnauthorized, errMsg) + return ctx, errorsmod.Wrap(sdkerrors.ErrUnauthorized, errMsg) } } diff --git a/app/ante/track_gas.go b/app/ante/track_gas.go index 17fcce6..ccd7e2f 100644 --- a/app/ante/track_gas.go +++ b/app/ante/track_gas.go @@ -4,6 +4,8 @@ import ( errorsmod "cosmossdk.io/errors" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" + "github.com/cosmos/cosmos-sdk/x/auth/ante" + authsigning "github.com/cosmos/cosmos-sdk/x/auth/signing" ) type TrackGasConsumedDecorator struct { @@ -26,14 +28,27 @@ func (d TrackGasConsumedDecorator) AnteHandle( simulate bool, next sdk.AnteHandler, ) (newCtx sdk.Context, err error) { - for _, v := range tx.GetMsgs() { - for _, addr := range v.GetSigners() { - if !d.ak.HasAccount(ctx, addr) { - return sdk.Context{}, errorsmod.Wrap(sdkerrors.ErrUnknownAddress, "address is not registered") - } + sigTx, ok := tx.(authsigning.Tx) + if !ok { + return ctx, errorsmod.Wrap(sdkerrors.ErrTxDecode, "invalid transaction type") + } + + signers, err := sigTx.GetSigners() + if !ok { + return ctx, err + } - d.sk.SetAddressToRestoreGas(ctx, addr) + for _, signer := range signers { + addr, err := ante.GetSignerAcc(ctx, d.ak, signer) + if err != nil { + return ctx, err } + + if !d.ak.HasAccount(ctx, addr.GetAddress()) { + return sdk.Context{}, errorsmod.Wrap(sdkerrors.ErrUnknownAddress, "address is not registered") + } + + d.sk.SetAddressToRestoreGas(ctx, addr.GetAddress()) } return next(ctx, tx, simulate) diff --git a/app/ante/zero-gas.go b/app/ante/zero-gas.go index d35768b..89a5bd7 100644 --- a/app/ante/zero-gas.go +++ b/app/ante/zero-gas.go @@ -4,15 +4,25 @@ import ( "fmt" "math" + "github.com/cosmos/cosmos-sdk/x/auth/ante" + + errorsmod "cosmossdk.io/errors" + sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" + authsigning "github.com/cosmos/cosmos-sdk/x/auth/signing" + + storetypes "cosmossdk.io/store/types" + sdk "github.com/cosmos/cosmos-sdk/types" ) type ZeroGasTxDecorator struct { sk ScorumKeeper + ak AccountKeeper } -func NewZeroGasTxDecorator(sk ScorumKeeper) ZeroGasTxDecorator { +func NewZeroGasTxDecorator(ak AccountKeeper, sk ScorumKeeper) ZeroGasTxDecorator { return ZeroGasTxDecorator{ + ak: ak, sk: sk, } } @@ -23,17 +33,30 @@ func (d ZeroGasTxDecorator) AnteHandle( simulate bool, next sdk.AnteHandler, ) (newCtx sdk.Context, err error) { - for _, msg := range tx.GetMsgs() { - for _, v := range msg.GetSigners() { - if d.sk.IsSupervisor(ctx.WithGasMeter(NewFixedGasMeter(0, ctx.GasMeter().Limit())), v.String()) { - return next( - ctx. - WithGasMeter(NewFixedGasMeter(0, ctx.GasMeter().Limit())). - WithMinGasPrices(sdk.NewDecCoins()), - tx, - simulate, - ) - } + sigTx, ok := tx.(authsigning.Tx) + if !ok { + return ctx, errorsmod.Wrap(sdkerrors.ErrTxDecode, "invalid transaction type") + } + + signers, err := sigTx.GetSigners() + if !ok { + return ctx, err + } + + for _, signer := range signers { + v, err := ante.GetSignerAcc(ctx, d.ak, signer) + if err != nil { + return ctx, err + } + + if d.sk.IsSupervisor(ctx.WithGasMeter(NewFixedGasMeter(0, ctx.GasMeter().Limit())), v.GetAddress().String()) { + return next( + ctx. + WithGasMeter(NewFixedGasMeter(0, ctx.GasMeter().Limit())). + WithMinGasPrices(sdk.NewDecCoins()), + tx, + simulate, + ) } } @@ -41,41 +64,41 @@ func (d ZeroGasTxDecorator) AnteHandle( } type fixedGasMeter struct { - limit sdk.Gas - consumed sdk.Gas + limit storetypes.Gas + consumed storetypes.Gas } // NewFixedGasMeter returns a reference to a new basicGasMeter. -func NewFixedGasMeter(consumed, limit sdk.Gas) sdk.GasMeter { +func NewFixedGasMeter(consumed, limit storetypes.Gas) storetypes.GasMeter { return &fixedGasMeter{ limit: limit, consumed: consumed, } } -func (g *fixedGasMeter) GasConsumed() sdk.Gas { +func (g *fixedGasMeter) GasConsumed() storetypes.Gas { return g.consumed } -func (g *fixedGasMeter) Limit() sdk.Gas { +func (g *fixedGasMeter) Limit() storetypes.Gas { return g.limit } -func (g *fixedGasMeter) GasRemaining() sdk.Gas { +func (g *fixedGasMeter) GasRemaining() storetypes.Gas { return math.MaxUint64 } -func (g *fixedGasMeter) GasConsumedToLimit() sdk.Gas { +func (g *fixedGasMeter) GasConsumedToLimit() storetypes.Gas { if g.IsPastLimit() { return g.limit } return g.consumed } -func (g *fixedGasMeter) ConsumeGas(_ sdk.Gas, _ string) { +func (g *fixedGasMeter) ConsumeGas(_ storetypes.Gas, _ string) { } -func (g *fixedGasMeter) RefundGas(_ sdk.Gas, _ string) { +func (g *fixedGasMeter) RefundGas(_ storetypes.Gas, _ string) { } func (g *fixedGasMeter) IsPastLimit() bool { diff --git a/app/app.go b/app/app.go index b2f0aa7..36d9044 100644 --- a/app/app.go +++ b/app/app.go @@ -7,6 +7,20 @@ import ( "os" "path/filepath" + v120 "github.com/scorum/cosmos-network/app/upgrade/v120" + + "cosmossdk.io/client/v2/autocli" + "cosmossdk.io/core/appmodule" + + govkeeper "github.com/cosmos/cosmos-sdk/x/gov/keeper" + + db "github.com/cosmos/cosmos-db" + "github.com/cosmos/cosmos-sdk/codec/address" + authcodec "github.com/cosmos/cosmos-sdk/x/auth/codec" + "github.com/cosmos/ibc-go/modules/capability" + capabilitykeeper "github.com/cosmos/ibc-go/modules/capability/keeper" + capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" + autocliv1 "cosmossdk.io/api/cosmos/autocli/v1" reflectionv1 "cosmossdk.io/api/cosmos/reflection/v1" @@ -15,23 +29,40 @@ import ( consensusparamtypes "github.com/cosmos/cosmos-sdk/x/consensus/types" paramsclient "github.com/cosmos/cosmos-sdk/x/params/client" - upgradeclient "github.com/cosmos/cosmos-sdk/x/upgrade/client" govclient "github.com/cosmos/cosmos-sdk/x/gov/client" - govkeeper "github.com/cosmos/cosmos-sdk/x/gov/keeper" - paramstypes "github.com/cosmos/cosmos-sdk/x/params/types" - ica "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts" - ibcfeetypes "github.com/cosmos/ibc-go/v7/modules/apps/29-fee/types" - ibckeeper "github.com/cosmos/ibc-go/v7/modules/core/keeper" + govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" - dbm "github.com/cometbft/cometbft-db" + paramstypes "github.com/cosmos/cosmos-sdk/x/params/types" + ica "github.com/cosmos/ibc-go/v8/modules/apps/27-interchain-accounts" + ibcfeetypes "github.com/cosmos/ibc-go/v8/modules/apps/29-fee/types" + ibcclienttypes "github.com/cosmos/ibc-go/v8/modules/core/02-client/types" + ibcconnectiontypes "github.com/cosmos/ibc-go/v8/modules/core/03-connection/types" + ibckeeper "github.com/cosmos/ibc-go/v8/modules/core/keeper" + + "cosmossdk.io/log" + storetypes "cosmossdk.io/store/types" + "cosmossdk.io/x/circuit" + circuitkeeper "cosmossdk.io/x/circuit/keeper" + circuittypes "cosmossdk.io/x/circuit/types" + "cosmossdk.io/x/evidence" + evidencekeeper "cosmossdk.io/x/evidence/keeper" + evidencetypes "cosmossdk.io/x/evidence/types" + "cosmossdk.io/x/feegrant" + feegrantkeeper "cosmossdk.io/x/feegrant/keeper" + feegrantmodule "cosmossdk.io/x/feegrant/module" + "cosmossdk.io/x/nft" + nftkeeper "cosmossdk.io/x/nft/keeper" + nftmodule "cosmossdk.io/x/nft/module" + "cosmossdk.io/x/upgrade" + upgradekeeper "cosmossdk.io/x/upgrade/keeper" + upgradetypes "cosmossdk.io/x/upgrade/types" abci "github.com/cometbft/cometbft/abci/types" - "github.com/cometbft/cometbft/libs/log" tmos "github.com/cometbft/cometbft/libs/os" "github.com/cosmos/cosmos-sdk/baseapp" "github.com/cosmos/cosmos-sdk/client" + "github.com/cosmos/cosmos-sdk/client/grpc/cmtservice" nodeservice "github.com/cosmos/cosmos-sdk/client/grpc/node" - "github.com/cosmos/cosmos-sdk/client/grpc/tmservice" "github.com/cosmos/cosmos-sdk/codec" "github.com/cosmos/cosmos-sdk/codec/types" "github.com/cosmos/cosmos-sdk/runtime" @@ -39,8 +70,6 @@ import ( "github.com/cosmos/cosmos-sdk/server/api" "github.com/cosmos/cosmos-sdk/server/config" servertypes "github.com/cosmos/cosmos-sdk/server/types" - "github.com/cosmos/cosmos-sdk/store/streaming" - storetypes "github.com/cosmos/cosmos-sdk/store/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" "github.com/cosmos/cosmos-sdk/version" @@ -58,25 +87,15 @@ import ( "github.com/cosmos/cosmos-sdk/x/bank" bankkeeper "github.com/cosmos/cosmos-sdk/x/bank/keeper" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" - "github.com/cosmos/cosmos-sdk/x/capability" - capabilitykeeper "github.com/cosmos/cosmos-sdk/x/capability/keeper" - capabilitytypes "github.com/cosmos/cosmos-sdk/x/capability/types" "github.com/cosmos/cosmos-sdk/x/crisis" crisiskeeper "github.com/cosmos/cosmos-sdk/x/crisis/keeper" crisistypes "github.com/cosmos/cosmos-sdk/x/crisis/types" distr "github.com/cosmos/cosmos-sdk/x/distribution" distrkeeper "github.com/cosmos/cosmos-sdk/x/distribution/keeper" distrtypes "github.com/cosmos/cosmos-sdk/x/distribution/types" - "github.com/cosmos/cosmos-sdk/x/evidence" - evidencekeeper "github.com/cosmos/cosmos-sdk/x/evidence/keeper" - evidencetypes "github.com/cosmos/cosmos-sdk/x/evidence/types" - "github.com/cosmos/cosmos-sdk/x/feegrant" - feegrantkeeper "github.com/cosmos/cosmos-sdk/x/feegrant/keeper" - feegrantmodule "github.com/cosmos/cosmos-sdk/x/feegrant/module" "github.com/cosmos/cosmos-sdk/x/genutil" genutiltypes "github.com/cosmos/cosmos-sdk/x/genutil/types" "github.com/cosmos/cosmos-sdk/x/gov" - govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" govv1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1" govv1beta1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1" "github.com/cosmos/cosmos-sdk/x/group" @@ -85,9 +104,6 @@ import ( "github.com/cosmos/cosmos-sdk/x/mint" mintkeeper "github.com/cosmos/cosmos-sdk/x/mint/keeper" minttypes "github.com/cosmos/cosmos-sdk/x/mint/types" - "github.com/cosmos/cosmos-sdk/x/nft" - nftkeeper "github.com/cosmos/cosmos-sdk/x/nft/keeper" - nftmodule "github.com/cosmos/cosmos-sdk/x/nft/module" "github.com/cosmos/cosmos-sdk/x/params" paramskeeper "github.com/cosmos/cosmos-sdk/x/params/keeper" paramproposal "github.com/cosmos/cosmos-sdk/x/params/types/proposal" @@ -97,33 +113,26 @@ import ( "github.com/cosmos/cosmos-sdk/x/staking" stakingkeeper "github.com/cosmos/cosmos-sdk/x/staking/keeper" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" - "github.com/cosmos/cosmos-sdk/x/upgrade" - upgradekeeper "github.com/cosmos/cosmos-sdk/x/upgrade/keeper" - upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types" - icacontroller "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller" - icacontrollerkeeper "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller/keeper" - icacontrollertypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller/types" - icahost "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/host" - icahostkeeper "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/host/keeper" - icahosttypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/host/types" - icatypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/types" - ibcfee "github.com/cosmos/ibc-go/v7/modules/apps/29-fee" - ibcfeekeeper "github.com/cosmos/ibc-go/v7/modules/apps/29-fee/keeper" - ibctransfer "github.com/cosmos/ibc-go/v7/modules/apps/transfer" - ibctransferkeeper "github.com/cosmos/ibc-go/v7/modules/apps/transfer/keeper" - ibctransfertypes "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types" - ibc "github.com/cosmos/ibc-go/v7/modules/core" - ibcclient "github.com/cosmos/ibc-go/v7/modules/core/02-client" - ibcclientclient "github.com/cosmos/ibc-go/v7/modules/core/02-client/client" - ibcclienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" - ibcporttypes "github.com/cosmos/ibc-go/v7/modules/core/05-port/types" - ibcexported "github.com/cosmos/ibc-go/v7/modules/core/exported" - ibctm "github.com/cosmos/ibc-go/v7/modules/light-clients/07-tendermint" + icacontroller "github.com/cosmos/ibc-go/v8/modules/apps/27-interchain-accounts/controller" + icacontrollerkeeper "github.com/cosmos/ibc-go/v8/modules/apps/27-interchain-accounts/controller/keeper" + icacontrollertypes "github.com/cosmos/ibc-go/v8/modules/apps/27-interchain-accounts/controller/types" + icahost "github.com/cosmos/ibc-go/v8/modules/apps/27-interchain-accounts/host" + icahostkeeper "github.com/cosmos/ibc-go/v8/modules/apps/27-interchain-accounts/host/keeper" + icahosttypes "github.com/cosmos/ibc-go/v8/modules/apps/27-interchain-accounts/host/types" + icatypes "github.com/cosmos/ibc-go/v8/modules/apps/27-interchain-accounts/types" + ibcfee "github.com/cosmos/ibc-go/v8/modules/apps/29-fee" + ibcfeekeeper "github.com/cosmos/ibc-go/v8/modules/apps/29-fee/keeper" + ibctransfer "github.com/cosmos/ibc-go/v8/modules/apps/transfer" + ibctransferkeeper "github.com/cosmos/ibc-go/v8/modules/apps/transfer/keeper" + ibctransfertypes "github.com/cosmos/ibc-go/v8/modules/apps/transfer/types" + ibc "github.com/cosmos/ibc-go/v8/modules/core" + ibcporttypes "github.com/cosmos/ibc-go/v8/modules/core/05-port/types" + ibcexported "github.com/cosmos/ibc-go/v8/modules/core/exported" + ibctm "github.com/cosmos/ibc-go/v8/modules/light-clients/07-tendermint" "github.com/scorum/cosmos-network/app/ante" "github.com/spf13/cast" "github.com/scorum/cosmos-network/x/scorum" - scorumclient "github.com/scorum/cosmos-network/x/scorum/client" scorumkeeper "github.com/scorum/cosmos-network/x/scorum/keeper" scorumtypes "github.com/scorum/cosmos-network/x/scorum/types" scorumwrapper "github.com/scorum/cosmos-network/x/scorum/wrapper" @@ -133,9 +142,6 @@ import ( aviatrixtypes "github.com/scorum/cosmos-network/x/aviatrix/types" "github.com/scorum/cosmos-network/docs" - - v101 "github.com/scorum/cosmos-network/app/upgrade/v101" - v110 "github.com/scorum/cosmos-network/app/upgrade/v110" ) const ( @@ -161,14 +167,10 @@ var ( distr.AppModuleBasic{}, gov.NewAppModuleBasic([]govclient.ProposalHandler{ paramsclient.ProposalHandler, - upgradeclient.LegacyProposalHandler, - upgradeclient.LegacyCancelProposalHandler, - ibcclientclient.UpdateClientProposalHandler, - ibcclientclient.UpgradeProposalHandler, - scorumclient.ProposalHandler, }), params.AppModuleBasic{}, crisis.AppModuleBasic{}, + circuit.AppModuleBasic{}, slashing.AppModuleBasic{}, feegrantmodule.AppModuleBasic{}, groupmodule.AppModuleBasic{}, @@ -252,6 +254,7 @@ type App struct { GroupKeeper groupkeeper.Keeper NftKeeper nftkeeper.Keeper ConsensusParamsKeeper consensusparamkeeper.Keeper + CircuitKeeper circuitkeeper.Keeper IBCKeeper *ibckeeper.Keeper // IBC Keeper must be a pointer in the app, so we can SetRouter on it correctly IBCFeeKeeper ibcfeekeeper.Keeper @@ -280,7 +283,7 @@ type App struct { // New returns a reference to an initialized blockchain app func New( logger log.Logger, - db dbm.DB, + db db.DB, traceStore io.Writer, loadLatest bool, skipUpgradeHeights map[int64]bool, @@ -308,14 +311,8 @@ func New( bApp.SetTxEncoder(encodingConfig.TxConfig.TxEncoder()) keys := GetKeys() - tkeys := sdk.NewTransientStoreKeys(paramstypes.TStoreKey) - memKeys := sdk.NewMemoryStoreKeys(capabilitytypes.MemStoreKey) - - // load state streaming if enabled - if _, _, err := streaming.LoadStreamingServices(bApp, appOpts, appCodec, logger, keys); err != nil { - logger.Error("failed to load state streaming", "err", err) - os.Exit(1) - } + tkeys := storetypes.NewTransientStoreKeys(paramstypes.TStoreKey) + memKeys := storetypes.NewMemoryStoreKeys(capabilitytypes.MemStoreKey) app := &App{ BaseApp: bApp, @@ -337,10 +334,11 @@ func New( // set the BaseApp's parameter store app.ConsensusParamsKeeper = consensusparamkeeper.NewKeeper( - appCodec, keys[consensusparamtypes.StoreKey], + appCodec, runtime.NewKVStoreService(keys[consensusparamtypes.StoreKey]), authtypes.NewModuleAddress(govtypes.ModuleName).String(), + runtime.EventService{}, ) - bApp.SetParamStore(&app.ConsensusParamsKeeper) + bApp.SetParamStore(&app.ConsensusParamsKeeper.ParamsStore) // add capability keeper and ScopeToModule for ibc module app.CapabilityKeeper = capabilitykeeper.NewKeeper( @@ -359,15 +357,16 @@ func New( // add keepers app.AccountKeeper = authkeeper.NewAccountKeeper( appCodec, - keys[authtypes.StoreKey], + runtime.NewKVStoreService(keys[authtypes.StoreKey]), authtypes.ProtoBaseAccount, maccPerms, - sdk.Bech32PrefixAccAddr, + address.NewBech32Codec(sdk.GetConfig().GetBech32AccountAddrPrefix()), + sdk.GetConfig().GetBech32AccountAddrPrefix(), authtypes.NewModuleAddress(govtypes.ModuleName).String(), ) app.AuthzKeeper = authzkeeper.NewKeeper( - keys[authz.ModuleName], + runtime.NewKVStoreService(keys[authz.ModuleName]), appCodec, app.MsgServiceRouter(), app.AccountKeeper, @@ -375,23 +374,26 @@ func New( app.BankKeeper = bankkeeper.NewBaseKeeper( appCodec, - keys[banktypes.StoreKey], + runtime.NewKVStoreService(keys[banktypes.StoreKey]), app.AccountKeeper, app.BlockedModuleAccountAddrs(), authtypes.NewModuleAddress(govtypes.ModuleName).String(), + logger, ) app.StakingKeeper = stakingkeeper.NewKeeper( appCodec, - keys[stakingtypes.StoreKey], + runtime.NewKVStoreService(keys[stakingtypes.StoreKey]), app.AccountKeeper, scorumwrapper.NewStakingBankKeeper(app.BankKeeper, &app.ScorumKeeper), // used to prevent burning on slashing. authtypes.NewModuleAddress(govtypes.ModuleName).String(), + authcodec.NewBech32Codec(sdk.GetConfig().GetBech32ValidatorAddrPrefix()), + authcodec.NewBech32Codec(sdk.GetConfig().GetBech32ConsensusAddrPrefix()), ) app.MintKeeper = mintkeeper.NewKeeper( appCodec, - keys[minttypes.StoreKey], + runtime.NewKVStoreService(keys[minttypes.StoreKey]), app.StakingKeeper, app.AccountKeeper, app.BankKeeper, @@ -401,7 +403,7 @@ func New( app.DistrKeeper = distrkeeper.NewKeeper( appCodec, - keys[distrtypes.StoreKey], + runtime.NewKVStoreService(keys[distrtypes.StoreKey]), app.AccountKeeper, app.BankKeeper, app.StakingKeeper, @@ -411,18 +413,19 @@ func New( app.SlashingKeeper = slashingkeeper.NewKeeper( appCodec, legacyAmino, - keys[slashingtypes.StoreKey], + runtime.NewKVStoreService(keys[slashingtypes.StoreKey]), app.StakingKeeper, authtypes.NewModuleAddress(govtypes.ModuleName).String(), ) app.CrisisKeeper = crisiskeeper.NewKeeper( appCodec, - keys[crisistypes.StoreKey], + runtime.NewKVStoreService(keys[crisistypes.StoreKey]), invCheckPeriod, app.BankKeeper, authtypes.FeeCollectorName, authtypes.NewModuleAddress(govtypes.ModuleName).String(), + address.NewBech32Codec(sdk.GetConfig().GetBech32AccountAddrPrefix()), ) groupConfig := group.DefaultConfig() @@ -440,19 +443,27 @@ func New( app.FeeGrantKeeper = feegrantkeeper.NewKeeper( appCodec, - keys[feegrant.StoreKey], + runtime.NewKVStoreService(keys[feegrant.StoreKey]), app.AccountKeeper, ) app.UpgradeKeeper = upgradekeeper.NewKeeper( skipUpgradeHeights, - keys[upgradetypes.StoreKey], + runtime.NewKVStoreService(keys[upgradetypes.StoreKey]), appCodec, homePath, app.BaseApp, authtypes.NewModuleAddress(govtypes.ModuleName).String(), ) + app.CircuitKeeper = circuitkeeper.NewKeeper( + appCodec, + runtime.NewKVStoreService(keys[circuittypes.StoreKey]), + authtypes.NewModuleAddress(govtypes.ModuleName).String(), + app.AccountKeeper.AddressCodec(), + ) + app.BaseApp.SetCircuitBreaker(&app.CircuitKeeper) + // ... other modules keepers // Create IBC Keeper @@ -462,13 +473,14 @@ func New( app.StakingKeeper, app.UpgradeKeeper, scopedIBCKeeper, + authtypes.NewModuleAddress(govtypes.ModuleName).String(), ) app.IBCFeeKeeper = ibcfeekeeper.NewKeeper( appCodec, app.keys[ibcfeetypes.StoreKey], app.IBCKeeper.ChannelKeeper, app.IBCKeeper.ChannelKeeper, - &app.IBCKeeper.PortKeeper, + app.IBCKeeper.PortKeeper, app.AccountKeeper, app.BankKeeper, ) @@ -482,16 +494,18 @@ func New( app.BankKeeper, app.StakingKeeper, authtypes.FeeCollectorName, + authtypes.NewModuleAddress(govtypes.ModuleName).String(), ) // create keeper wrappers to mint gas scorumWrapperAccountKeeper := scorumwrapper.NewAccountKeeper(app.AccountKeeper, app.BankKeeper, app.ScorumKeeper) scorumWrapperBankKeeper := bankkeeper.NewBaseKeeper( appCodec, - keys[banktypes.StoreKey], + runtime.NewKVStoreService(keys[banktypes.StoreKey]), scorumWrapperAccountKeeper, app.BlockedModuleAccountAddrs(), authtypes.NewModuleAddress(govtypes.ModuleName).String(), + logger, ) // Create Transfer Keepers @@ -501,10 +515,11 @@ func New( app.GetSubspace(ibctransfertypes.ModuleName), app.IBCFeeKeeper, app.IBCKeeper.ChannelKeeper, - &app.IBCKeeper.PortKeeper, + app.IBCKeeper.PortKeeper, scorumWrapperAccountKeeper, scorumWrapperBankKeeper, scopedIBCTransferKeeper, + authtypes.NewModuleAddress(govtypes.ModuleName).String(), ) app.ICAHostKeeper = icahostkeeper.NewKeeper( @@ -513,31 +528,37 @@ func New( app.GetSubspace(icahosttypes.SubModuleName), app.IBCFeeKeeper, app.IBCKeeper.ChannelKeeper, - &app.IBCKeeper.PortKeeper, + app.IBCKeeper.PortKeeper, scorumWrapperAccountKeeper, scopedICAHostKeeper, app.MsgServiceRouter(), + authtypes.NewModuleAddress(govtypes.ModuleName).String(), ) app.ICAControllerKeeper = icacontrollerkeeper.NewKeeper( appCodec, keys[icacontrollertypes.StoreKey], app.GetSubspace(icacontrollertypes.SubModuleName), app.IBCFeeKeeper, - app.IBCKeeper.ChannelKeeper, &app.IBCKeeper.PortKeeper, - scopedICAControllerKeeper, app.MsgServiceRouter(), + app.IBCKeeper.ChannelKeeper, + app.IBCKeeper.PortKeeper, + scopedICAControllerKeeper, + app.MsgServiceRouter(), + authtypes.NewModuleAddress(govtypes.ModuleName).String(), ) // Create evidence Keeper for to register the IBC light client misbehaviour evidence route evidenceKeeper := evidencekeeper.NewKeeper( appCodec, - keys[evidencetypes.StoreKey], + runtime.NewKVStoreService(keys[evidencetypes.StoreKey]), app.StakingKeeper, app.SlashingKeeper, + address.NewBech32Codec(sdk.GetConfig().GetBech32AccountAddrPrefix()), + runtime.ProvideCometInfoService(), ) // If evidence needs to be handled for the app, set routes in router here and seal app.EvidenceKeeper = *evidenceKeeper app.NftKeeper = nftkeeper.NewKeeper( - keys[nft.StoreKey], + runtime.NewKVStoreService(keys[nft.StoreKey]), appCodec, app.AccountKeeper, app.BankKeeper, @@ -556,24 +577,17 @@ func New( // by granting the governance module the right to execute the message. // See: https://docs.cosmos.network/main/modules/gov#proposal-messages govRouter := govv1beta1.NewRouter() - govRouter. - AddRoute(govtypes.RouterKey, govv1beta1.ProposalHandler). - AddRoute(paramproposal.RouterKey, params.NewParamChangeProposalHandler(app.ParamsKeeper)). // This should be removed. It is still in place to avoid failures of modules that have not yet been upgraded. - AddRoute(upgradetypes.RouterKey, upgrade.NewSoftwareUpgradeProposalHandler(app.UpgradeKeeper)). - AddRoute(ibcclienttypes.RouterKey, ibcclient.NewClientProposalHandler(app.IBCKeeper.ClientKeeper)). - AddRoute(scorumtypes.RouterKey, scorum.NewMintProposalHandler(app.ScorumKeeper)) - + govRouter.AddRoute(govtypes.RouterKey, govv1beta1.ProposalHandler). + AddRoute(paramproposal.RouterKey, params.NewParamChangeProposalHandler(app.ParamsKeeper)) govConfig := govtypes.DefaultConfig() - /* - Example of setting gov params: - govConfig.MaxMetadataLen = 10000 - */ + govKeeper := govkeeper.NewKeeper( appCodec, - keys[govtypes.StoreKey], + runtime.NewKVStoreService(keys[govtypes.StoreKey]), app.AccountKeeper, app.BankKeeper, app.StakingKeeper, + app.DistrKeeper, app.MsgServiceRouter(), govConfig, authtypes.NewModuleAddress(govtypes.ModuleName).String(), @@ -639,10 +653,7 @@ func New( // must be passed by reference here. app.mm = module.NewManager( - genutil.NewAppModule( - app.AccountKeeper, app.StakingKeeper, app.BaseApp.DeliverTx, - encodingConfig.TxConfig, - ), + genutil.NewAppModule(app.AccountKeeper, app.StakingKeeper, app, encodingConfig.TxConfig), auth.NewAppModule(appCodec, app.AccountKeeper, authsims.RandomGenesisAccounts, app.GetSubspace(authtypes.ModuleName)), authzmodule.NewAppModule(appCodec, app.AuthzKeeper, app.AccountKeeper, app.BankKeeper, app.interfaceRegistry), vesting.NewAppModule(app.AccountKeeper, app.BankKeeper), @@ -654,24 +665,29 @@ func New( mint.NewAppModule(appCodec, app.MintKeeper, app.AccountKeeper, minttypes.DefaultInflationCalculationFn, app.GetSubspace(minttypes.ModuleName)), slashing.NewAppModule( appCodec, app.SlashingKeeper, app.AccountKeeper, app.BankKeeper, app.StakingKeeper, - app.GetSubspace(slashingtypes.ModuleName), + app.GetSubspace(slashingtypes.ModuleName), app.interfaceRegistry, ), distr.NewAppModule(appCodec, app.DistrKeeper, app.AccountKeeper, app.BankKeeper, app.StakingKeeper, app.GetSubspace(distrtypes.ModuleName)), staking.NewAppModule(appCodec, app.StakingKeeper, app.AccountKeeper, app.BankKeeper, app.GetSubspace(stakingtypes.ModuleName)), - upgrade.NewAppModule(app.UpgradeKeeper), + upgrade.NewAppModule(app.UpgradeKeeper, app.AccountKeeper.AddressCodec()), evidence.NewAppModule(app.EvidenceKeeper), params.NewAppModule(app.ParamsKeeper), nftmodule.NewAppModule(appCodec, app.NftKeeper, app.AccountKeeper, app.BankKeeper, app.interfaceRegistry), consensus.NewAppModule(appCodec, app.ConsensusParamsKeeper), + circuit.NewAppModule(appCodec, app.CircuitKeeper), ibc.NewAppModule(app.IBCKeeper), ibctransfer.NewAppModule(app.IBCTransferKeeper), ibcfee.NewAppModule(app.IBCFeeKeeper), ica.NewAppModule(&app.ICAControllerKeeper, &app.ICAHostKeeper), - scorum.NewAppModule(appCodec, app.ScorumKeeper, app.AccountKeeper, app.BankKeeper), + scorum.NewAppModule(appCodec, app.AccountKeeper.AddressCodec(), app.ScorumKeeper, app.AccountKeeper, app.BankKeeper), aviatrix.NewAppModule(appCodec, app.AviatrixKeeper, app.ScorumKeeper, app.NftKeeper, app.AccountKeeper, app.BankKeeper), crisis.NewAppModule(app.CrisisKeeper, skipGenesisInvariants, app.GetSubspace(crisistypes.ModuleName)), // always be last to make sure that it checks for all invariants and not only part of them ) + app.mm.SetOrderPreBlockers( + upgradetypes.ModuleName, + ) + // During begin block slashing happens after distr.BeginBlocker so that // there is nothing left over in the validator fee pool, so as to keep the // CanWithdrawInvariant invariant. @@ -759,6 +775,7 @@ func New( upgradetypes.ModuleName, vestingtypes.ModuleName, consensusparamtypes.ModuleName, + circuittypes.ModuleName, ibctransfertypes.ModuleName, ibcexported.ModuleName, icatypes.ModuleName, @@ -776,7 +793,16 @@ func New( // app.mm.SetOrderMigrations(custom order) app.configurator = module.NewConfigurator(app.appCodec, app.MsgServiceRouter(), app.GRPCQueryRouter()) - app.mm.RegisterServices(app.configurator) + if err := app.mm.RegisterServices(app.configurator); err != nil { + logger.Error("failed to register services", "err", err) + os.Exit(1) + } + + // load state streaming if enabled + if err := app.RegisterStreamingServices(appOpts, keys); err != nil { + logger.Error("failed to load state streaming", "err", err) + os.Exit(1) + } autocliv1.RegisterQueryServer(app.GRPCQueryRouter(), runtimeservices.NewAutoCLIQueryService(app.mm.Modules)) @@ -791,10 +817,6 @@ func New( app.MountTransientStores(tkeys) app.MountMemoryStores(memKeys) - // initialize BaseApp - app.SetInitChainer(app.InitChainer) - app.SetBeginBlocker(app.BeginBlocker) - anteHandler, err := ante.NewAnteHandler( ante.HandlerOptions{ HandlerOptions: cosmosante.HandlerOptions{ @@ -807,6 +829,7 @@ func New( AccountKeeper: app.AccountKeeper, BankKeeper: app.BankKeeper, ScorumKeeper: app.ScorumKeeper, + CircuitKeeper: &app.CircuitKeeper, }, ) if err != nil { @@ -815,6 +838,7 @@ func New( app.SetAnteHandler(anteHandler) app.SetInitChainer(app.InitChainer) + app.SetPreBlocker(app.PreBlocker) app.SetBeginBlocker(app.BeginBlocker) app.SetEndBlocker(app.EndBlocker) @@ -832,34 +856,10 @@ func New( app.ScopedICAControllerKeeper = scopedICAControllerKeeper // create the simulation manager and define the order of the modules for deterministic simulations - app.sm = module.NewSimulationManager( - auth.NewAppModule(appCodec, app.AccountKeeper, authsims.RandomGenesisAccounts, app.GetSubspace(authtypes.ModuleName)), - authzmodule.NewAppModule(appCodec, app.AuthzKeeper, app.AccountKeeper, app.BankKeeper, app.interfaceRegistry), - bank.NewAppModule(appCodec, app.BankKeeper, app.AccountKeeper, app.GetSubspace(banktypes.ModuleName)), - capability.NewAppModule(appCodec, *app.CapabilityKeeper, false), - feegrantmodule.NewAppModule(appCodec, app.AccountKeeper, app.BankKeeper, app.FeeGrantKeeper, app.interfaceRegistry), - gov.NewAppModule(appCodec, &app.GovKeeper, app.AccountKeeper, app.BankKeeper, app.GetSubspace(govtypes.ModuleName)), - mint.NewAppModule(appCodec, app.MintKeeper, app.AccountKeeper, minttypes.DefaultInflationCalculationFn, app.GetSubspace(minttypes.ModuleName)), - staking.NewAppModule(appCodec, app.StakingKeeper, app.AccountKeeper, app.BankKeeper, app.GetSubspace(stakingtypes.ModuleName)), - distr.NewAppModule( - appCodec, app.DistrKeeper, app.AccountKeeper, app.BankKeeper, app.StakingKeeper, - app.GetSubspace(distrtypes.ModuleName), - ), - slashing.NewAppModule( - appCodec, app.SlashingKeeper, app.AccountKeeper, app.BankKeeper, app.StakingKeeper, - app.GetSubspace(slashingtypes.ModuleName), - ), - params.NewAppModule(app.ParamsKeeper), - groupmodule.NewAppModule(appCodec, app.GroupKeeper, app.AccountKeeper, app.BankKeeper, app.interfaceRegistry), - evidence.NewAppModule(app.EvidenceKeeper), - nftmodule.NewAppModule(appCodec, app.NftKeeper, app.AccountKeeper, app.BankKeeper, app.interfaceRegistry), - ibc.NewAppModule(app.IBCKeeper), - ibctransfer.NewAppModule(app.IBCTransferKeeper), - ibcfee.NewAppModule(app.IBCFeeKeeper), - ica.NewAppModule(&app.ICAControllerKeeper, &app.ICAHostKeeper), - scorum.NewAppModule(appCodec, app.ScorumKeeper, app.AccountKeeper, app.BankKeeper), - aviatrix.NewAppModule(appCodec, app.AviatrixKeeper, app.ScorumKeeper, app.NftKeeper, app.AccountKeeper, app.BankKeeper), - ) + overrideModules := map[string]module.AppModuleSimulation{ + authtypes.ModuleName: auth.NewAppModule(app.appCodec, app.AccountKeeper, authsims.RandomGenesisAccounts, app.GetSubspace(authtypes.ModuleName)), + } + app.sm = module.NewSimulationManagerFromAppModules(app.mm.Modules, overrideModules) app.sm.RegisterStoreDecoders() return app @@ -868,24 +868,32 @@ func New( // Name returns the name of the App func (app *App) Name() string { return app.BaseApp.Name() } +// PreBlocker application updates every pre block +func (app *App) PreBlocker(ctx sdk.Context, _ *abci.RequestFinalizeBlock) (*sdk.ResponsePreBlock, error) { + return app.mm.PreBlock(ctx) +} + // BeginBlocker application updates every begin block -func (app *App) BeginBlocker(ctx sdk.Context, req abci.RequestBeginBlock) abci.ResponseBeginBlock { - return app.mm.BeginBlock(ctx, req) +func (app *App) BeginBlocker(ctx sdk.Context) (sdk.BeginBlock, error) { + return app.mm.BeginBlock(ctx) } // EndBlocker application updates every end block -func (app *App) EndBlocker(ctx sdk.Context, req abci.RequestEndBlock) abci.ResponseEndBlock { - return app.mm.EndBlock(ctx, req) +func (app *App) EndBlocker(ctx sdk.Context) (sdk.EndBlock, error) { + return app.mm.EndBlock(ctx) } // InitChainer application update at chain initialization -func (app *App) InitChainer(ctx sdk.Context, req abci.RequestInitChain) abci.ResponseInitChain { +func (app *App) InitChainer(ctx sdk.Context, req *abci.RequestInitChain) (*abci.ResponseInitChain, error) { var genesisState GenesisState if err := json.Unmarshal(req.AppStateBytes, &genesisState); err != nil { panic(err) } - app.UpgradeKeeper.SetModuleVersionMap(ctx, app.mm.GetVersionMap()) + if err := app.UpgradeKeeper.SetModuleVersionMap(ctx, app.mm.GetVersionMap()); err != nil { + panic(err) + } + return app.mm.InitGenesis(ctx, app.appCodec, genesisState) } @@ -929,6 +937,27 @@ func (app *App) AppCodec() codec.Codec { return app.appCodec } +// AutoCliOpts returns the autocli options for the app. +func (app *App) AutoCliOpts() autocli.AppOptions { + modules := make(map[string]appmodule.AppModule, 0) + for _, m := range app.mm.Modules { + if moduleWithName, ok := m.(module.HasName); ok { + moduleName := moduleWithName.Name() + if appModule, ok := moduleWithName.(appmodule.AppModule); ok { + modules[moduleName] = appModule + } + } + } + + return autocli.AppOptions{ + Modules: modules, + ModuleOptions: runtimeservices.ExtractAutoCLIOptions(app.mm.Modules), + AddressCodec: authcodec.NewBech32Codec(sdk.GetConfig().GetBech32AccountAddrPrefix()), + ValidatorAddressCodec: authcodec.NewBech32Codec(sdk.GetConfig().GetBech32ValidatorAddrPrefix()), + ConsensusAddressCodec: authcodec.NewBech32Codec(sdk.GetConfig().GetBech32ConsensusAddrPrefix()), + } +} + // InterfaceRegistry returns an InterfaceRegistry func (app *App) InterfaceRegistry() types.InterfaceRegistry { return app.interfaceRegistry @@ -973,7 +1002,7 @@ func (app *App) RegisterAPIRoutes(apiSvr *api.Server, apiConfig config.APIConfig // Register new tx routes from grpc-gateway. authtx.RegisterGRPCGatewayRoutes(clientCtx, apiSvr.GRPCGatewayRouter) // Register new tendermint queries routes from grpc-gateway. - tmservice.RegisterGRPCGatewayRoutes(clientCtx, apiSvr.GRPCGatewayRouter) + cmtservice.RegisterGRPCGatewayRoutes(clientCtx, apiSvr.GRPCGatewayRouter) // Register node gRPC service for grpc-gateway. nodeservice.RegisterGRPCGatewayRoutes(clientCtx, apiSvr.GRPCGatewayRouter) @@ -991,7 +1020,7 @@ func (app *App) RegisterTxService(clientCtx client.Context) { // RegisterTendermintService implements the Application.RegisterTendermintService method. func (app *App) RegisterTendermintService(clientCtx client.Context) { - tmservice.RegisterTendermintService( + cmtservice.RegisterTendermintService( clientCtx, app.BaseApp.GRPCQueryRouter(), app.interfaceRegistry, @@ -1000,8 +1029,8 @@ func (app *App) RegisterTendermintService(clientCtx client.Context) { } // RegisterNodeService implements the Application.RegisterNodeService method. -func (app *App) RegisterNodeService(clientCtx client.Context) { - nodeservice.RegisterNodeService(clientCtx, app.GRPCQueryRouter()) +func (app *App) RegisterNodeService(clientCtx client.Context, cfg config.Config) { + nodeservice.RegisterNodeService(clientCtx, app.GRPCQueryRouter(), cfg) } // GetMaccPerms returns a copy of the module account permissions @@ -1025,13 +1054,16 @@ func initParamsKeeper(appCodec codec.BinaryCodec, legacyAmino *codec.LegacyAmino paramsKeeper.Subspace(slashingtypes.ModuleName).WithKeyTable(slashingtypes.ParamKeyTable()) paramsKeeper.Subspace(govtypes.ModuleName).WithKeyTable(govv1.ParamKeyTable()) paramsKeeper.Subspace(crisistypes.ModuleName).WithKeyTable(crisistypes.ParamKeyTable()) - paramsKeeper.Subspace(ibctransfertypes.ModuleName) - paramsKeeper.Subspace(ibcexported.ModuleName) - paramsKeeper.Subspace(icacontrollertypes.SubModuleName) - paramsKeeper.Subspace(icahosttypes.SubModuleName) paramsKeeper.Subspace(scorumtypes.ModuleName) paramsKeeper.Subspace(aviatrixtypes.ModuleName) + keyTable := ibcclienttypes.ParamKeyTable() + keyTable.RegisterParamSet(&ibcconnectiontypes.Params{}) + paramsKeeper.Subspace(ibcexported.ModuleName).WithKeyTable(keyTable) + paramsKeeper.Subspace(ibctransfertypes.ModuleName).WithKeyTable(ibctransfertypes.ParamKeyTable()) + paramsKeeper.Subspace(icacontrollertypes.SubModuleName).WithKeyTable(icacontrollertypes.ParamKeyTable()) + paramsKeeper.Subspace(icahosttypes.SubModuleName).WithKeyTable(icahosttypes.ParamKeyTable()) + return paramsKeeper } @@ -1041,23 +1073,7 @@ func (app *App) SimulationManager() *module.SimulationManager { } func (app *App) setupUpgradeHandlers() { - app.UpgradeKeeper.SetUpgradeHandler(v101.Name, v101.Handler(app.configurator, app.mm)) - app.UpgradeKeeper.SetUpgradeHandler( - v110.Name, - v110.Handler( - app.configurator, - app.mm, - app.cdc, - app.GetSubspace(scorumtypes.ModuleName), - app.ParamsKeeper, - &app.ConsensusParamsKeeper, - app.ScorumKeeper, - app.BankKeeper, - app.GovKeeper, - app.MintKeeper, - app.StakingKeeper, - ), - ) + app.UpgradeKeeper.SetUpgradeHandler(v120.Name, v120.Handler(app.configurator, app.mm, app.cdc, app.GetSubspace(scorumtypes.ModuleName))) upgradeInfo, err := app.UpgradeKeeper.ReadUpgradeInfoFromDisk() if err != nil { @@ -1068,24 +1084,21 @@ func (app *App) setupUpgradeHandlers() { return } - if upgradeInfo.Name == v110.Name { + if upgradeInfo.Name == v120.Name { app.SetStoreLoader(upgradetypes.UpgradeStoreLoader(upgradeInfo.Height, &storetypes.StoreUpgrades{ Added: []string{ - crisistypes.StoreKey, - consensusparamtypes.StoreKey, - ibcfeetypes.StoreKey, + circuittypes.ModuleName, }, - Deleted: []string{"nonfungibletokentransfer"}, })) } } func GetKeys() map[string]*storetypes.KVStoreKey { - return sdk.NewKVStoreKeys( + return storetypes.NewKVStoreKeys( authtypes.StoreKey, authz.ModuleName, banktypes.StoreKey, stakingtypes.StoreKey, crisistypes.StoreKey, minttypes.StoreKey, distrtypes.StoreKey, slashingtypes.StoreKey, govtypes.StoreKey, paramstypes.StoreKey, upgradetypes.StoreKey, feegrant.StoreKey, evidencetypes.StoreKey, - capabilitytypes.StoreKey, group.StoreKey, nft.StoreKey, consensusparamtypes.StoreKey, + capabilitytypes.StoreKey, group.StoreKey, nft.StoreKey, consensusparamtypes.StoreKey, circuittypes.StoreKey, // ibc ibcexported.StoreKey, ibcfeetypes.StoreKey, ibctransfertypes.StoreKey, icahosttypes.StoreKey, icacontrollertypes.StoreKey, diff --git a/app/encoding.go b/app/encoding.go index fe004fa..40ce128 100644 --- a/app/encoding.go +++ b/app/encoding.go @@ -1,10 +1,14 @@ package app import ( + "cosmossdk.io/x/tx/signing" "github.com/cosmos/cosmos-sdk/codec" + "github.com/cosmos/cosmos-sdk/codec/address" "github.com/cosmos/cosmos-sdk/codec/types" "github.com/cosmos/cosmos-sdk/std" + sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/x/auth/tx" + "github.com/cosmos/gogoproto/proto" "github.com/scorum/cosmos-network/app/params" ) @@ -12,7 +16,17 @@ import ( // makeEncodingConfig creates an EncodingConfig for an amino based test configuration. func makeEncodingConfig() params.EncodingConfig { amino := codec.NewLegacyAmino() - interfaceRegistry := types.NewInterfaceRegistry() + interfaceRegistry, _ := types.NewInterfaceRegistryWithOptions(types.InterfaceRegistryOptions{ + ProtoFiles: proto.HybridResolver, + SigningOptions: signing.Options{ + AddressCodec: address.Bech32Codec{ + Bech32Prefix: sdk.GetConfig().GetBech32AccountAddrPrefix(), + }, + ValidatorAddressCodec: address.Bech32Codec{ + Bech32Prefix: sdk.GetConfig().GetBech32ValidatorAddrPrefix(), + }, + }, + }) marshaler := codec.NewProtoCodec(interfaceRegistry) txCfg := tx.NewTxConfig(marshaler, tx.DefaultSignModes) diff --git a/app/export.go b/app/export.go index 55e0087..3bd7b7f 100644 --- a/app/export.go +++ b/app/export.go @@ -2,12 +2,13 @@ package app import ( "encoding/json" + "fmt" "log" - tmproto "github.com/cometbft/cometbft/proto/tendermint/types" + storetypes "cosmossdk.io/store/types" + servertypes "github.com/cosmos/cosmos-sdk/server/types" sdk "github.com/cosmos/cosmos-sdk/types" - distrtypes "github.com/cosmos/cosmos-sdk/x/distribution/types" slashingtypes "github.com/cosmos/cosmos-sdk/x/slashing/types" "github.com/cosmos/cosmos-sdk/x/staking" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" @@ -19,7 +20,7 @@ func (app *App) ExportAppStateAndValidators( forZeroHeight bool, jailAllowedAddrs []string, modulesToExport []string, ) (servertypes.ExportedApp, error) { // as if they could withdraw from the start of the next block - ctx := app.NewContext(true, tmproto.Header{Height: app.LastBlockHeight()}) + ctx := app.NewContext(true) // We export at last height + 1, because that's the height at which // Tendermint will start InitChain. @@ -29,7 +30,11 @@ func (app *App) ExportAppStateAndValidators( app.prepForZeroHeightGenesis(ctx, jailAllowedAddrs) } - genState := app.mm.ExportGenesis(ctx, app.appCodec) + genState, err := app.mm.ExportGenesis(ctx, app.appCodec) + if err != nil { + return servertypes.ExportedApp{}, err + } + appState, err := json.MarshalIndent(genState, "", " ") if err != nil { return servertypes.ExportedApp{}, err @@ -74,21 +79,33 @@ func (app *App) prepForZeroHeightGenesis(ctx sdk.Context, jailAllowedAddrs []str /* Handle fee distribution state. */ // withdraw all validator commission - app.StakingKeeper.IterateValidators(ctx, func(_ int64, val stakingtypes.ValidatorI) (stop bool) { - _, err := app.DistrKeeper.WithdrawValidatorCommission(ctx, val.GetOperator()) - if err != nil && !distrtypes.ErrNoValidatorCommission.Is(err) { + err := app.StakingKeeper.IterateValidators(ctx, func(_ int64, val stakingtypes.ValidatorI) (stop bool) { + valBz, err := app.StakingKeeper.ValidatorAddressCodec().StringToBytes(val.GetOperator()) + if err != nil { panic(err) } + _, _ = app.DistrKeeper.WithdrawValidatorCommission(ctx, valBz) return false }) + if err != nil { + panic(err) + } // withdraw all delegator rewards - dels := app.StakingKeeper.GetAllDelegations(ctx) + dels, err := app.StakingKeeper.GetAllDelegations(ctx) + if err != nil { + panic(err) + } + for _, delegation := range dels { - _, err := app.DistrKeeper.WithdrawDelegationRewards(ctx, delegation.GetDelegatorAddr(), delegation.GetValidatorAddr()) + valAddr, err := sdk.ValAddressFromBech32(delegation.ValidatorAddress) if err != nil { panic(err) } + + delAddr := sdk.MustAccAddressFromBech32(delegation.DelegatorAddress) + + _, _ = app.DistrKeeper.WithdrawDelegationRewards(ctx, delAddr, valAddr) } // clear validator slash events @@ -102,15 +119,26 @@ func (app *App) prepForZeroHeightGenesis(ctx sdk.Context, jailAllowedAddrs []str ctx = ctx.WithBlockHeight(0) // reinitialize all validators - app.StakingKeeper.IterateValidators(ctx, func(_ int64, val stakingtypes.ValidatorI) (stop bool) { + err = app.StakingKeeper.IterateValidators(ctx, func(_ int64, val stakingtypes.ValidatorI) (stop bool) { + valBz, err := app.StakingKeeper.ValidatorAddressCodec().StringToBytes(val.GetOperator()) + if err != nil { + panic(err) + } // donate any unwithdrawn outstanding reward fraction tokens to the community pool - scraps := app.DistrKeeper.GetValidatorOutstandingRewardsCoins(ctx, val.GetOperator()) - feePool := app.DistrKeeper.GetFeePool(ctx) + scraps, err := app.DistrKeeper.GetValidatorOutstandingRewardsCoins(ctx, valBz) + if err != nil { + panic(err) + } + feePool, err := app.DistrKeeper.FeePool.Get(ctx) + if err != nil { + panic(err) + } feePool.CommunityPool = feePool.CommunityPool.Add(scraps...) - app.DistrKeeper.SetFeePool(ctx, feePool) + if err := app.DistrKeeper.FeePool.Set(ctx, feePool); err != nil { + panic(err) + } - err := app.DistrKeeper.Hooks().AfterValidatorCreated(ctx, val.GetOperator()) - if err != nil { + if err := app.DistrKeeper.Hooks().AfterValidatorCreated(ctx, valBz); err != nil { panic(err) } return false @@ -118,13 +146,20 @@ func (app *App) prepForZeroHeightGenesis(ctx sdk.Context, jailAllowedAddrs []str // reinitialize all delegations for _, del := range dels { - err := app.DistrKeeper.Hooks().BeforeDelegationCreated(ctx, del.GetDelegatorAddr(), del.GetValidatorAddr()) + valAddr, err := sdk.ValAddressFromBech32(del.ValidatorAddress) if err != nil { panic(err) } - err = app.DistrKeeper.Hooks().AfterDelegationModified(ctx, del.GetDelegatorAddr(), del.GetValidatorAddr()) - if err != nil { - panic(err) + delAddr := sdk.MustAccAddressFromBech32(del.DelegatorAddress) + + if err := app.DistrKeeper.Hooks().BeforeDelegationCreated(ctx, delAddr, valAddr); err != nil { + // never called as BeforeDelegationCreated always returns nil + panic(fmt.Errorf("error while incrementing period: %w", err)) + } + + if err := app.DistrKeeper.Hooks().AfterDelegationModified(ctx, delAddr, valAddr); err != nil { + // never called as AfterDelegationModified always returns nil + panic(fmt.Errorf("error while creating a new delegation period record: %w", err)) } } @@ -134,33 +169,43 @@ func (app *App) prepForZeroHeightGenesis(ctx sdk.Context, jailAllowedAddrs []str /* Handle staking state. */ // iterate through redelegations, reset creation height - app.StakingKeeper.IterateRedelegations(ctx, func(_ int64, red stakingtypes.Redelegation) (stop bool) { + if err := app.StakingKeeper.IterateRedelegations(ctx, func(_ int64, red stakingtypes.Redelegation) (stop bool) { for i := range red.Entries { red.Entries[i].CreationHeight = 0 } - app.StakingKeeper.SetRedelegation(ctx, red) + err = app.StakingKeeper.SetRedelegation(ctx, red) + if err != nil { + panic(err) + } return false - }) + }); err != nil { + panic(err) + } // iterate through unbonding delegations, reset creation height - app.StakingKeeper.IterateUnbondingDelegations(ctx, func(_ int64, ubd stakingtypes.UnbondingDelegation) (stop bool) { + if err := app.StakingKeeper.IterateUnbondingDelegations(ctx, func(_ int64, ubd stakingtypes.UnbondingDelegation) (stop bool) { for i := range ubd.Entries { ubd.Entries[i].CreationHeight = 0 } - app.StakingKeeper.SetUnbondingDelegation(ctx, ubd) + err = app.StakingKeeper.SetUnbondingDelegation(ctx, ubd) + if err != nil { + panic(err) + } return false - }) + }); err != nil { + panic(err) + } // Iterate through validators by power descending, reset bond heights, and // update bond intra-tx counters. - store := ctx.KVStore(app.keys[stakingtypes.StoreKey]) - iter := sdk.KVStoreReversePrefixIterator(store, stakingtypes.ValidatorsByPowerIndexKey) + store := ctx.KVStore(app.GetKey(stakingtypes.StoreKey)) + iter := storetypes.KVStoreReversePrefixIterator(store, stakingtypes.ValidatorsKey) counter := int16(0) for ; iter.Valid(); iter.Next() { - addr := sdk.ValAddress(iter.Value()) - validator, found := app.StakingKeeper.GetValidator(ctx, addr) - if !found { + addr := sdk.ValAddress(stakingtypes.AddressFromValidatorsKey(iter.Key())) + validator, err := app.StakingKeeper.GetValidator(ctx, addr) + if err != nil { panic("expected validator, not found") } @@ -169,25 +214,35 @@ func (app *App) prepForZeroHeightGenesis(ctx sdk.Context, jailAllowedAddrs []str validator.Jailed = true } - app.StakingKeeper.SetValidator(ctx, validator) + if err := app.StakingKeeper.SetValidator(ctx, validator); err != nil { + panic(err) + } counter++ } - iter.Close() + if err := iter.Close(); err != nil { + app.Logger().Error("error while closing the key-value store reverse prefix iterator: ", err) + return + } - if _, err := app.StakingKeeper.ApplyAndReturnValidatorSetUpdates(ctx); err != nil { - panic(err) + _, err = app.StakingKeeper.ApplyAndReturnValidatorSetUpdates(ctx) + if err != nil { + log.Fatal(err) } /* Handle slashing state. */ // reset start height on signing infos - app.SlashingKeeper.IterateValidatorSigningInfos( + if err := app.SlashingKeeper.IterateValidatorSigningInfos( ctx, func(addr sdk.ConsAddress, info slashingtypes.ValidatorSigningInfo) (stop bool) { info.StartHeight = 0 - app.SlashingKeeper.SetValidatorSigningInfo(ctx, addr, info) + if err := app.SlashingKeeper.SetValidatorSigningInfo(ctx, addr, info); err != nil { + panic(err) + } return false }, - ) + ); err != nil { + panic(err) + } } diff --git a/app/simulation_test.go b/app/simulation_test.go index 6b84031..3d6a579 100644 --- a/app/simulation_test.go +++ b/app/simulation_test.go @@ -13,10 +13,10 @@ import ( "github.com/cosmos/cosmos-sdk/testutil/sims" - dbm "github.com/cometbft/cometbft-db" - "github.com/cometbft/cometbft/libs/log" + "cosmossdk.io/log" + "cosmossdk.io/store" + db "github.com/cosmos/cosmos-db" "github.com/cosmos/cosmos-sdk/baseapp" - "github.com/cosmos/cosmos-sdk/store" simulationtypes "github.com/cosmos/cosmos-sdk/types/simulation" "github.com/cosmos/cosmos-sdk/x/simulation" "github.com/scorum/cosmos-network/app" @@ -56,12 +56,12 @@ func TestAppStateDeterminism(t *testing.T) { for j := 0; j < numTimesToRunPerSeed; j++ { var logger log.Logger if sim.FlagVerboseValue { - logger = log.TestingLogger() + logger = log.NewTestLogger(t) } else { logger = log.NewNopLogger() } - db := dbm.NewMemDB() + db := db.NewMemDB() simapp := app.New( logger, db, diff --git a/app/upgrade/v101/upgrade.go b/app/upgrade/v101/upgrade.go deleted file mode 100644 index d423696..0000000 --- a/app/upgrade/v101/upgrade.go +++ /dev/null @@ -1,18 +0,0 @@ -package v101 - -import ( - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/cosmos-sdk/types/module" - upgrade "github.com/cosmos/cosmos-sdk/x/upgrade/types" -) - -const Name = "v1.0.1 Scorum Upgrade" - -func Handler( - cfg module.Configurator, - mm *module.Manager, -) func(ctx sdk.Context, _ upgrade.Plan, _ module.VersionMap) (module.VersionMap, error) { - return func(ctx sdk.Context, _ upgrade.Plan, fromVM module.VersionMap) (module.VersionMap, error) { - return mm.RunMigrations(ctx, cfg, fromVM) - } -} diff --git a/app/upgrade/v110/convert_sp.go b/app/upgrade/v110/convert_sp.go deleted file mode 100644 index 1c748b8..0000000 --- a/app/upgrade/v110/convert_sp.go +++ /dev/null @@ -1,69 +0,0 @@ -package v110 - -import ( - "fmt" - - sdk "github.com/cosmos/cosmos-sdk/types" - bankkeeper "github.com/cosmos/cosmos-sdk/x/bank/keeper" - govkeeper "github.com/cosmos/cosmos-sdk/x/gov/keeper" - mintkeeper "github.com/cosmos/cosmos-sdk/x/mint/keeper" - stakingkeeper "github.com/cosmos/cosmos-sdk/x/staking/keeper" - scorumkeeper "github.com/scorum/cosmos-network/x/scorum/keeper" - scorumtypes "github.com/scorum/cosmos-network/x/scorum/types" -) - -func convertSP( - ctx sdk.Context, - bk bankkeeper.Keeper, sk scorumkeeper.Keeper, - gk govkeeper.Keeper, mk mintkeeper.Keeper, - stk *stakingkeeper.Keeper, -) error { - var err error - bk.IterateAllBalances(ctx, func(address sdk.AccAddress, coin sdk.Coin) (stop bool) { - if coin.Denom != "nsp" { - return false - } - - if err = sk.Burn(ctx, address, coin); err != nil { - err = fmt.Errorf("failed to burn nsp") - return true - } - - coin.Denom = scorumtypes.SCRDenom - if err = sk.Mint(ctx, address, coin); err != nil { - err = fmt.Errorf("failed to mint nscr") - return true - } - - return false - }) - if err != nil { - return err - } - - stakingParams := stk.GetParams(ctx) - stakingParams.BondDenom = scorumtypes.SCRDenom - if err := stk.SetParams(ctx, stakingParams); err != nil { - return fmt.Errorf("failed to set staking params: %w", err) - } - - govParams := gk.GetParams(ctx) - for i := range govParams.MinDeposit { - coin := govParams.MinDeposit[i] - if coin.Denom == "nsp" { - coin.Denom = scorumtypes.SCRDenom - } - govParams.MinDeposit[i] = coin - } - if err := gk.SetParams(ctx, govParams); err != nil { - return fmt.Errorf("failed to set gov params: %w", err) - } - - mintParams := mk.GetParams(ctx) - mintParams.MintDenom = scorumtypes.SCRDenom - if err := mk.SetParams(ctx, mintParams); err != nil { - return fmt.Errorf("failed to set mint params: %w", err) - } - - return nil -} diff --git a/app/upgrade/v110/migrate_scorum_params.go b/app/upgrade/v110/migrate_scorum_params.go deleted file mode 100644 index d715b96..0000000 --- a/app/upgrade/v110/migrate_scorum_params.go +++ /dev/null @@ -1,67 +0,0 @@ -package v110 - -import ( - "fmt" - - "github.com/cosmos/cosmos-sdk/codec" - sdk "github.com/cosmos/cosmos-sdk/types" - paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" - scorumtypes "github.com/scorum/cosmos-network/x/scorum/types" -) - -var ( - KeySPWithdrawalTotalPeriods = []byte("SPWithdrawalTotalPeriods") - KeySPWithdrawalPeriodDurationSeconds = []byte("SPWithdrawalPeriodDurationSeconds") -) - -//nolint:lll -type Params struct { - Supervisors []string `protobuf:"bytes,1,rep,name=supervisors,proto3" json:"supervisors,omitempty"` - GasLimit sdk.IntProto `protobuf:"bytes,2,opt,name=gas_limit,json=gasLimit,proto3" json:"gas_limit"` - GasUnconditionedAmount sdk.IntProto `protobuf:"bytes,3,opt,name=gas_unconditioned_amount,json=gasUnconditionedAmount,proto3" json:"gas_unconditioned_amount"` - GasAdjustCoefficient sdk.DecProto `protobuf:"bytes,4,opt,name=gas_adjust_coefficient,json=gasAdjustCoefficient,proto3" json:"gas_adjust_coefficient"` - SpWithdrawalTotalPeriods uint32 `protobuf:"varint,5,opt,name=sp_withdrawal_total_periods,json=spWithdrawalTotalPeriods,proto3" json:"sp_withdrawal_total_periods,omitempty"` - SpWithdrawalPeriodDurationSeconds uint32 `protobuf:"varint,6,opt,name=sp_withdrawal_period_duration_seconds,json=spWithdrawalPeriodDurationSeconds,proto3" json:"sp_withdrawal_period_duration_seconds,omitempty"` - ValidatorsReward scorumtypes.ValidatorsRewardParams `protobuf:"bytes,7,opt,name=validators_reward,json=validatorsReward,proto3" json:"validators_reward"` -} - -func (p *Params) ParamSetPairs() paramtypes.ParamSetPairs { - noValidate := func(value interface{}) error { return nil } - return paramtypes.ParamSetPairs{ - paramtypes.NewParamSetPair(scorumtypes.KeySupervisors, &p.Supervisors, noValidate), - paramtypes.NewParamSetPair(scorumtypes.KeyGasLimit, &p.GasLimit, noValidate), - paramtypes.NewParamSetPair(scorumtypes.KeyGasUnconditionedAmount, &p.GasUnconditionedAmount, noValidate), - paramtypes.NewParamSetPair(scorumtypes.KeyGasAdjustCoefficient, &p.GasAdjustCoefficient, noValidate), - paramtypes.NewParamSetPair(KeySPWithdrawalTotalPeriods, &p.SpWithdrawalTotalPeriods, noValidate), - paramtypes.NewParamSetPair(KeySPWithdrawalPeriodDurationSeconds, &p.SpWithdrawalPeriodDurationSeconds, noValidate), - paramtypes.NewParamSetPair(scorumtypes.KeyValidatorsRewardPoolAddress, &p.ValidatorsReward.PoolAddress, noValidate), - paramtypes.NewParamSetPair(scorumtypes.KeyValidatorsRewardPoolBlockReward, &p.ValidatorsReward.BlockReward, noValidate), - } -} - -func migrateScorumParams( - ctx sdk.Context, - cdc *codec.LegacyAmino, - ps paramtypes.Subspace, -) error { - var old Params - - for _, pair := range old.ParamSetPairs() { - if err := cdc.UnmarshalJSON(ps.GetRaw(ctx, pair.Key), pair.Value); err != nil { - return fmt.Errorf("failed to get old scorum params: %w", err) - } - } - - ps.SetParamSet(ctx, &scorumtypes.Params{ - Supervisors: old.Supervisors, - GasLimit: old.GasLimit, - GasUnconditionedAmount: old.GasUnconditionedAmount, - GasAdjustCoefficient: old.GasAdjustCoefficient, - ValidatorsReward: scorumtypes.ValidatorsRewardParams{ - PoolAddress: old.ValidatorsReward.PoolAddress, - BlockReward: old.ValidatorsReward.BlockReward, - }, - }) - - return nil -} diff --git a/app/upgrade/v110/upgrade.go b/app/upgrade/v110/upgrade.go deleted file mode 100644 index 87c39c7..0000000 --- a/app/upgrade/v110/upgrade.go +++ /dev/null @@ -1,57 +0,0 @@ -package v110 - -import ( - "fmt" - - "github.com/cosmos/cosmos-sdk/baseapp" - "github.com/cosmos/cosmos-sdk/codec" - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/cosmos-sdk/types/module" - bankkeeper "github.com/cosmos/cosmos-sdk/x/bank/keeper" - consensusparamkeeper "github.com/cosmos/cosmos-sdk/x/consensus/keeper" - govkeeper "github.com/cosmos/cosmos-sdk/x/gov/keeper" - mintkeeper "github.com/cosmos/cosmos-sdk/x/mint/keeper" - paramskeeper "github.com/cosmos/cosmos-sdk/x/params/keeper" - paramstypes "github.com/cosmos/cosmos-sdk/x/params/types" - paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" - stakingkeeper "github.com/cosmos/cosmos-sdk/x/staking/keeper" - upgrade "github.com/cosmos/cosmos-sdk/x/upgrade/types" - scorumkeeper "github.com/scorum/cosmos-network/x/scorum/keeper" -) - -const Name = "v1.1.0" - -func Handler( - cfg module.Configurator, - mm *module.Manager, - cdc *codec.LegacyAmino, - scorumParamSpace paramtypes.Subspace, - pk paramskeeper.Keeper, - cpk *consensusparamkeeper.Keeper, - sk scorumkeeper.Keeper, - bk bankkeeper.Keeper, - gk govkeeper.Keeper, - mk mintkeeper.Keeper, - stk *stakingkeeper.Keeper, -) func(ctx sdk.Context, _ upgrade.Plan, _ module.VersionMap) (module.VersionMap, error) { - return func(ctx sdk.Context, _ upgrade.Plan, fromVM module.VersionMap) (module.VersionMap, error) { - baseAppLegacySS := pk.Subspace(baseapp.Paramspace). - WithKeyTable(paramstypes.ConsensusParamsKeyTable()) - baseapp.MigrateParams(ctx, baseAppLegacySS, cpk) - - migrationMap, err := mm.RunMigrations(ctx, cfg, fromVM) - if err != nil { - return nil, err - } - - if err := migrateScorumParams(ctx, cdc, scorumParamSpace); err != nil { - return nil, fmt.Errorf("fialed to migrate scorum params: %w", err) - } - - if err := convertSP(ctx, bk, sk, gk, mk, stk); err != nil { - return nil, fmt.Errorf("fialed to convert sp denom to scr: %w", err) - } - - return migrationMap, nil - } -} diff --git a/app/upgrade/v101/README.md b/app/upgrade/v120/README.md similarity index 100% rename from app/upgrade/v101/README.md rename to app/upgrade/v120/README.md diff --git a/app/upgrade/v120/upgrade.go b/app/upgrade/v120/upgrade.go new file mode 100644 index 0000000..b5a4777 --- /dev/null +++ b/app/upgrade/v120/upgrade.go @@ -0,0 +1,76 @@ +package v120 + +import ( + "context" + "fmt" + + "github.com/cosmos/cosmos-sdk/codec" + + paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" + scorumtypes "github.com/scorum/cosmos-network/x/scorum/types" + + "github.com/cosmos/cosmos-sdk/types" + + upgrade "cosmossdk.io/x/upgrade/types" + "github.com/cosmos/cosmos-sdk/types/module" +) + +const Name = "v1.2.0" + +//nolint:lll +type Params struct { + Supervisors []string `protobuf:"bytes,1,rep,name=supervisors,proto3" json:"supervisors,omitempty"` + GasLimit types.IntProto `protobuf:"bytes,2,opt,name=gas_limit,json=gasLimit,proto3" json:"gas_limit"` + GasUnconditionedAmount types.IntProto `protobuf:"bytes,3,opt,name=gas_unconditioned_amount,json=gasUnconditionedAmount,proto3" json:"gas_unconditioned_amount"` + GasAdjustCoefficient types.DecProto `protobuf:"bytes,4,opt,name=gas_adjust_coefficient,json=gasAdjustCoefficient,proto3" json:"gas_adjust_coefficient"` + ValidatorsReward ValidatorsRewardParams `protobuf:"bytes,5,opt,name=validators_reward,json=validatorsReward,proto3" json:"validators_reward"` +} + +type ValidatorsRewardParams struct { + PoolAddress string `protobuf:"bytes,1,opt,name=pool_address,json=poolAddress,proto3" json:"pool_address,omitempty"` + BlockReward types.Coin `protobuf:"bytes,2,opt,name=block_reward,json=blockReward,proto3" json:"block_reward"` +} + +func (p *Params) ParamSetPairs() paramtypes.ParamSetPairs { + noValidate := func(value interface{}) error { return nil } + return paramtypes.ParamSetPairs{ + paramtypes.NewParamSetPair(scorumtypes.KeySupervisors, &p.Supervisors, noValidate), + paramtypes.NewParamSetPair(scorumtypes.KeyGasLimit, &p.GasLimit, noValidate), + paramtypes.NewParamSetPair(scorumtypes.KeyGasUnconditionedAmount, &p.GasUnconditionedAmount, noValidate), + paramtypes.NewParamSetPair(scorumtypes.KeyGasAdjustCoefficient, &p.GasAdjustCoefficient, noValidate), + paramtypes.NewParamSetPair(scorumtypes.KeyValidatorsRewardPoolAddress, &p.ValidatorsReward.PoolAddress, noValidate), + paramtypes.NewParamSetPair(scorumtypes.KeyValidatorsRewardPoolBlockReward, &p.ValidatorsReward.BlockReward, noValidate), + } +} + +func Handler( + cfg module.Configurator, + mm *module.Manager, + cdc *codec.LegacyAmino, + ps paramtypes.Subspace, +) func(ctx context.Context, _ upgrade.Plan, _ module.VersionMap) (module.VersionMap, error) { + return func(ctx context.Context, _ upgrade.Plan, fromVM module.VersionMap) (module.VersionMap, error) { + sdkCtx := types.UnwrapSDKContext(ctx) + var old Params + + for _, pair := range old.ParamSetPairs() { + if err := cdc.UnmarshalJSON(ps.GetRaw(sdkCtx, pair.Key), pair.Value); err != nil { + return nil, fmt.Errorf("failed to get old scorum params: %w", err) + } + } + + ps.GetParamSetIfExists(sdkCtx, &old) + ps.SetParamSet(sdkCtx, &scorumtypes.Params{ + Supervisors: old.Supervisors, + GasLimit: old.GasLimit.Int, + GasUnconditionedAmount: old.GasUnconditionedAmount.Int, + GasAdjustCoefficient: old.GasAdjustCoefficient.Dec, + ValidatorsReward: scorumtypes.ValidatorsRewardParams{ + PoolAddress: old.ValidatorsReward.PoolAddress, + BlockReward: old.ValidatorsReward.BlockReward, + }, + }) + + return mm.RunMigrations(ctx, cfg, fromVM) + } +} diff --git a/app/validate.go b/app/validate.go index 1a8b73a..21aebbb 100644 --- a/app/validate.go +++ b/app/validate.go @@ -1,3 +1,3 @@ package app -import _ "github.com/scorum/cosmos-network/x/nft" +import _ "cosmossdk.io/x/nft" diff --git a/cmd/scorumd/cmd/collectgentx.go b/cmd/scorumd/cmd/collectgentx.go index 6b64b1a..4b07990 100644 --- a/cmd/scorumd/cmd/collectgentx.go +++ b/cmd/scorumd/cmd/collectgentx.go @@ -4,11 +4,13 @@ import ( "encoding/json" "fmt" + "cosmossdk.io/math" + "github.com/scorum/cosmos-network/app" + appparams "github.com/scorum/cosmos-network/app/params" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/server" - "github.com/cosmos/cosmos-sdk/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" distrtypes "github.com/cosmos/cosmos-sdk/x/distribution/types" "github.com/cosmos/cosmos-sdk/x/genutil" @@ -19,13 +21,22 @@ import ( "github.com/spf13/cobra" ) -func CollectGenTxsCmd(genBalIterator banktypes.GenesisBalancesIterator, defaultNodeHome string) *cobra.Command { +func CollectGenTxsCmd( + encodingConfig appparams.EncodingConfig, + genBalIterator banktypes.GenesisBalancesIterator, + defaultNodeHome string, +) *cobra.Command { gentxModule, ok := app.ModuleBasics[genutiltypes.ModuleName].(genutil.AppModuleBasic) if !ok { panic(fmt.Errorf("expected %s module to be an instance of type %T", genutiltypes.ModuleName, genutil.AppModuleBasic{})) } - cmd := genutilcli.CollectGenTxsCmd(genBalIterator, defaultNodeHome, gentxModule.GenTxValidator) + cmd := genutilcli.CollectGenTxsCmd( + genBalIterator, + defaultNodeHome, + gentxModule.GenTxValidator, + encodingConfig.TxConfig.SigningContext().ValidatorAddressCodec(), + ) cmd.PreRunE = func(cmd *cobra.Command, args []string) error { clientCtx := client.GetClientContextFromCmd(cmd) @@ -51,7 +62,7 @@ func CollectGenTxsCmd(genBalIterator banktypes.GenesisBalancesIterator, defaultN distrGenState := distrtypes.DefaultGenesisState() distrGenState.Params = distrtypes.Params{ - CommunityTax: types.ZeroDec(), + CommunityTax: math.LegacyZeroDec(), BaseProposerReward: distrGenState.Params.BaseProposerReward, BonusProposerReward: distrGenState.Params.BonusProposerReward, WithdrawAddrEnabled: true, @@ -65,9 +76,9 @@ func CollectGenTxsCmd(genBalIterator banktypes.GenesisBalancesIterator, defaultN mintGenState := minttypes.DefaultGenesisState() mintGenState.Params = minttypes.Params{ MintDenom: scorumtypes.SCRDenom, - InflationRateChange: types.ZeroDec(), - InflationMax: types.ZeroDec(), - InflationMin: types.ZeroDec(), + InflationRateChange: math.LegacyZeroDec(), + InflationMax: math.LegacyZeroDec(), + InflationMin: math.LegacyZeroDec(), GoalBonded: mintGenState.Params.GoalBonded, BlocksPerYear: mintGenState.Params.BlocksPerYear, } diff --git a/cmd/scorumd/cmd/config.go b/cmd/scorumd/cmd/config.go deleted file mode 100644 index 47e919e..0000000 --- a/cmd/scorumd/cmd/config.go +++ /dev/null @@ -1,251 +0,0 @@ -package cmd - -const DefaultConfigTemplate = `# This is a TOML config file. -# For more information, see https://github.com/toml-lang/toml - -############################################################################### -### Base Configuration ### -############################################################################### - -# default: the last 362880 states are kept, pruning at 10 block intervals -# nothing: all historic states will be saved, nothing will be deleted (i.e. archiving node) -# everything: 2 latest states will be kept; pruning at 10 block intervals. -# custom: allow pruning options to be manually specified through 'pruning-keep-recent', and 'pruning-interval' -pruning = "{{ .BaseConfig.Pruning }}" - -# These are applied if and only if the pruning strategy is custom. -pruning-keep-recent = "{{ .BaseConfig.PruningKeepRecent }}" -pruning-interval = "{{ .BaseConfig.PruningInterval }}" - -# HaltHeight contains a non-zero block height at which a node will gracefully -# halt and shutdown that can be used to assist upgrades and testing. -# -# Note: Commitment of state will be attempted on the corresponding block. -halt-height = {{ .BaseConfig.HaltHeight }} - -# HaltTime contains a non-zero minimum block time (in Unix seconds) at which -# a node will gracefully halt and shutdown that can be used to assist upgrades -# and testing. -# -# Note: Commitment of state will be attempted on the corresponding block. -halt-time = {{ .BaseConfig.HaltTime }} - -# MinRetainBlocks defines the minimum block height offset from the current -# block being committed, such that all blocks past this offset are pruned -# from Tendermint. It is used as part of the process of determining the -# ResponseCommit.RetainHeight value during ABCI Commit. A value of 0 indicates -# that no blocks should be pruned. -# -# This configuration value is only responsible for pruning Tendermint blocks. -# It has no bearing on application state pruning which is determined by the -# "pruning-*" configurations. -# -# Note: Tendermint block pruning is dependant on this parameter in conunction -# with the unbonding (safety threshold) period, state pruning and state sync -# snapshot parameters to determine the correct minimum value of -# ResponseCommit.RetainHeight. -min-retain-blocks = {{ .BaseConfig.MinRetainBlocks }} - -# InterBlockCache enables inter-block caching. -inter-block-cache = {{ .BaseConfig.InterBlockCache }} - -# IndexEvents defines the set of events in the form {eventType}.{attributeKey}, -# which informs Tendermint what to index. If empty, all events will be indexed. -# -# Example: -# ["message.sender", "message.recipient"] -index-events = [{{ range .BaseConfig.IndexEvents }}{{ printf "%q, " . }}{{end}}] - -# IavlCacheSize set the size of the iavl tree cache. -# Default cache size is 50mb. -iavl-cache-size = {{ .BaseConfig.IAVLCacheSize }} - -# IavlDisableFastNode enables or disables the fast node feature of IAVL. -# Default is false. -iavl-disable-fastnode = {{ .BaseConfig.IAVLDisableFastNode }} - -# EXPERIMENTAL: IAVLLazyLoading enable/disable the lazy loading of iavl store. -# Default is false. -iavl-lazy-loading = {{ .BaseConfig.IAVLLazyLoading }} - -# AppDBBackend defines the database backend type to use for the application and snapshots DBs. -# An empty string indicates that a fallback will be used. -# First fallback is the deprecated compile-time types.DBBackend value. -# Second fallback (if the types.DBBackend also isn't set), is the db-backend value set in Tendermint's config.toml. -app-db-backend = "{{ .BaseConfig.AppDBBackend }}" - -############################################################################### -### Telemetry Configuration ### -############################################################################### - -[telemetry] - -# Prefixed with keys to separate services. -service-name = "{{ .Telemetry.ServiceName }}" - -# Enabled enables the application telemetry functionality. When enabled, -# an in-memory sink is also enabled by default. Operators may also enabled -# other sinks such as Prometheus. -enabled = {{ .Telemetry.Enabled }} - -# Enable prefixing gauge values with hostname. -enable-hostname = {{ .Telemetry.EnableHostname }} - -# Enable adding hostname to labels. -enable-hostname-label = {{ .Telemetry.EnableHostnameLabel }} - -# Enable adding service to labels. -enable-service-label = {{ .Telemetry.EnableServiceLabel }} - -# PrometheusRetentionTime, when positive, enables a Prometheus metrics sink. -prometheus-retention-time = {{ .Telemetry.PrometheusRetentionTime }} - -# GlobalLabels defines a global set of name/value label tuples applied to all -# metrics emitted using the wrapper functions defined in telemetry package. -# -# Example: -# [["chain_id", "cosmoshub-1"]] -global-labels = [{{ range $k, $v := .Telemetry.GlobalLabels }} - ["{{index $v 0 }}", "{{ index $v 1}}"],{{ end }} -] - -############################################################################### -### API Configuration ### -############################################################################### - -[api] - -# Enable defines if the API server should be enabled. -enable = {{ .API.Enable }} - -# Swagger defines if swagger documentation should automatically be registered. -swagger = {{ .API.Swagger }} - -# Address defines the API server to listen on. -address = "{{ .API.Address }}" - -# MaxOpenConnections defines the number of maximum open connections. -max-open-connections = {{ .API.MaxOpenConnections }} - -# RPCReadTimeout defines the Tendermint RPC read timeout (in seconds). -rpc-read-timeout = {{ .API.RPCReadTimeout }} - -# RPCWriteTimeout defines the Tendermint RPC write timeout (in seconds). -rpc-write-timeout = {{ .API.RPCWriteTimeout }} - -# RPCMaxBodyBytes defines the Tendermint maximum response body (in bytes). -rpc-max-body-bytes = {{ .API.RPCMaxBodyBytes }} - -# EnableUnsafeCORS defines if CORS should be enabled (unsafe - use it at your own risk). -enabled-unsafe-cors = {{ .API.EnableUnsafeCORS }} - -############################################################################### -### Rosetta Configuration ### -############################################################################### - -[rosetta] - -# Enable defines if the Rosetta API server should be enabled. -enable = {{ .Rosetta.Enable }} - -# Address defines the Rosetta API server to listen on. -address = "{{ .Rosetta.Address }}" - -# Network defines the name of the blockchain that will be returned by Rosetta. -blockchain = "{{ .Rosetta.Blockchain }}" - -# Network defines the name of the network that will be returned by Rosetta. -network = "{{ .Rosetta.Network }}" - -# Retries defines the number of retries when connecting to the node before failing. -retries = {{ .Rosetta.Retries }} - -# Offline defines if Rosetta server should run in offline mode. -offline = {{ .Rosetta.Offline }} - -# EnableDefaultSuggestedFee defines if the server should suggest fee by default. -# If 'construction/medata' is called without gas limit and gas price, -# suggested fee based on gas-to-suggest and denom-to-suggest will be given. -enable-fee-suggestion = {{ .Rosetta.EnableFeeSuggestion }} - -# GasToSuggest defines gas limit when calculating the fee -gas-to-suggest = {{ .Rosetta.GasToSuggest }} - -# DenomToSuggest defines the defult denom for fee suggestion. -# Price must be in minimum-gas-prices. -denom-to-suggest = "{{ .Rosetta.DenomToSuggest }}" - -############################################################################### -### gRPC Configuration ### -############################################################################### - -[grpc] - -# Enable defines if the gRPC server should be enabled. -enable = {{ .GRPC.Enable }} - -# Address defines the gRPC server address to bind to. -address = "{{ .GRPC.Address }}" - -# MaxRecvMsgSize defines the max message size in bytes the server can receive. -# The default value is 10MB. -max-recv-msg-size = "{{ .GRPC.MaxRecvMsgSize }}" - -# MaxSendMsgSize defines the max message size in bytes the server can send. -# The default value is math.MaxInt32. -max-send-msg-size = "{{ .GRPC.MaxSendMsgSize }}" - -############################################################################### -### gRPC Web Configuration ### -############################################################################### - -[grpc-web] - -# GRPCWebEnable defines if the gRPC-web should be enabled. -# NOTE: gRPC must also be enabled, otherwise, this configuration is a no-op. -enable = {{ .GRPCWeb.Enable }} - -# Address defines the gRPC-web server address to bind to. -address = "{{ .GRPCWeb.Address }}" - -# EnableUnsafeCORS defines if CORS should be enabled (unsafe - use it at your own risk). -enable-unsafe-cors = {{ .GRPCWeb.EnableUnsafeCORS }} - -############################################################################### -### State Sync Configuration ### -############################################################################### - -# State sync snapshots allow other nodes to rapidly join the network without replaying historical -# blocks, instead downloading and applying a snapshot of the application state at a given height. -[state-sync] - -# snapshot-interval specifies the block interval at which local state sync snapshots are -# taken (0 to disable). -snapshot-interval = {{ .StateSync.SnapshotInterval }} - -# snapshot-keep-recent specifies the number of recent snapshots to keep and serve (0 to keep all). -snapshot-keep-recent = {{ .StateSync.SnapshotKeepRecent }} - -############################################################################### -### Store / State Streaming ### -############################################################################### - -[store] -streamers = [{{ range .Store.Streamers }}{{ printf "%q, " . }}{{end}}] - -[streamers] -[streamers.file] -keys = [{{ range .Streamers.File.Keys }}{{ printf "%q, " . }}{{end}}] -write_dir = "{{ .Streamers.File.WriteDir }}" -prefix = "{{ .Streamers.File.Prefix }}" - -# output-metadata specifies if output the metadata file which includes the abci request/responses -# during processing the block. -output-metadata = "{{ .Streamers.File.OutputMetadata }}" - -# stop-node-on-error specifies if propagate the file streamer errors to consensus state machine. -stop-node-on-error = "{{ .Streamers.File.StopNodeOnError }}" - -# fsync specifies if call fsync after writing the files. -fsync = "{{ .Streamers.File.Fsync }}" -` diff --git a/cmd/scorumd/cmd/genaccounts.go b/cmd/scorumd/cmd/genaccounts.go index d5ec653..740e00c 100644 --- a/cmd/scorumd/cmd/genaccounts.go +++ b/cmd/scorumd/cmd/genaccounts.go @@ -100,7 +100,10 @@ contain valid denominations. Accounts may optionally be supplied with vesting pa baseAccount := authtypes.NewBaseAccount(addr, nil, 0, 0) if !vestingAmt.IsZero() { - baseVestingAccount := authvesting.NewBaseVestingAccount(baseAccount, vestingAmt.Sort(), vestingEnd) + baseVestingAccount, err := authvesting.NewBaseVestingAccount(baseAccount, vestingAmt.Sort(), vestingEnd) + if err != nil { + return err + } if (balances.Coins.IsZero() && !baseVestingAccount.OriginalVesting.IsZero()) || baseVestingAccount.OriginalVesting.IsAnyGT(balances.Coins) { diff --git a/cmd/scorumd/cmd/prune.go b/cmd/scorumd/cmd/prune.go deleted file mode 100644 index ef2d8b3..0000000 --- a/cmd/scorumd/cmd/prune.go +++ /dev/null @@ -1,121 +0,0 @@ -package cmd - -import ( - "fmt" - "os" - "path" - - "github.com/syndtr/goleveldb/leveldb" - - "github.com/syndtr/goleveldb/leveldb/util" - - db "github.com/cometbft/cometbft-db" - "github.com/cometbft/cometbft/libs/log" - "github.com/cosmos/cosmos-sdk/client" - "github.com/cosmos/cosmos-sdk/client/flags" - "github.com/cosmos/cosmos-sdk/store/iavl" - pruningtypes "github.com/cosmos/cosmos-sdk/store/pruning/types" - "github.com/cosmos/cosmos-sdk/store/rootmulti" - "github.com/cosmos/cosmos-sdk/store/types" - "github.com/scorum/cosmos-network/app" - "github.com/spf13/cobra" -) - -// AddPruneCmd prunes all states except the latest. -func AddPruneCmd(defaultNodeHome string) *cobra.Command { - cmd := &cobra.Command{ - Use: "prune", - Short: "Prune all states except the latest. Works only with levelDB.", - Args: cobra.NoArgs, - RunE: func(cmd *cobra.Command, args []string) error { - ctx := client.GetClientContextFromCmd(cmd) - if ctx.Output == nil { - ctx = ctx.WithOutput(os.Stdout) - } - logger := log.NewTMLogger(ctx.Output) - - logger.Info(fmt.Sprintf("Home dir is %s", ctx.HomeDir)) - - if err := prune(ctx, logger); err != nil { - return fmt.Errorf("failed to prune: %w", err) - } - - if err := compact(ctx, logger); err != nil { - return fmt.Errorf("failed to compact: %w", err) - } - - return nil - }, - } - - cmd.Flags().String(flags.FlagHome, defaultNodeHome, "The application home directory") - - return cmd -} - -func prune(ctx client.Context, logger log.Logger) error { - db, err := db.NewDB("application", db.GoLevelDBBackend, path.Join(ctx.HomeDir, "data")) - if err != nil { - panic(err) - } - defer db.Close() - - s := rootmulti.NewStore(db, logger) - s.SetPruning(pruningtypes.NewPruningOptions(pruningtypes.PruningEverything)) - - keys := app.GetKeys() - logger.Info(fmt.Sprintf("%d modules found", len(keys))) - - for _, k := range keys { - s.MountStoreWithDB(k, types.StoreTypeIAVL, nil) - } - - if err := s.LoadLatestVersion(); err != nil { - return fmt.Errorf("failed to load latest version: %w", err) - } - - latestVersion := s.LatestVersion() - logger.Info(fmt.Sprintf("Current version: %d", latestVersion)) - - for module, key := range keys { - logger := logger.With("module", module) - - ms := s.GetKVStore(key).(*iavl.Store) - var toPrune []int64 - for _, v := range ms.GetAllVersions() { - if int64(v) == latestVersion { - continue - } - toPrune = append(toPrune, int64(v)) - } - - logger.Info(fmt.Sprintf("%d versions to prune", len(toPrune))) - if err := ms.DeleteVersions(toPrune...); err != nil { - return fmt.Errorf("failed to delete versions: %w", err) - } - logger.Info("pruned") - } - - logger.Info("Pruning completed") - - return nil -} - -func compact(ctx client.Context, logger log.Logger) error { - logger.Info("Starting compaction") - - db, err := leveldb.OpenFile(path.Join(ctx.HomeDir, "data", "application.db"), nil) - if err != nil { - return fmt.Errorf("failed to open database: %w", err) - } - defer db.Close() - - err = db.CompactRange(util.Range{Start: nil, Limit: nil}) - if err != nil { - return err - } - - logger.Info("Compaction completed successfully") - - return nil -} diff --git a/cmd/scorumd/cmd/root.go b/cmd/scorumd/cmd/root.go index 5c785a9..437a2e6 100644 --- a/cmd/scorumd/cmd/root.go +++ b/cmd/scorumd/cmd/root.go @@ -6,18 +6,20 @@ import ( "os" "strings" - "github.com/spf13/cast" - - dbm "github.com/cometbft/cometbft-db" - tmcfg "github.com/cometbft/cometbft/config" - tmcli "github.com/cometbft/cometbft/libs/cli" - "github.com/cometbft/cometbft/libs/log" + "cosmossdk.io/log" + confixcmd "cosmossdk.io/tools/confix/cmd" + cmtcfg "github.com/cometbft/cometbft/config" + cmtcli "github.com/cometbft/cometbft/libs/cli" + dbm "github.com/cosmos/cosmos-db" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/config" "github.com/cosmos/cosmos-sdk/client/debug" "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cosmos/cosmos-sdk/client/keys" + "github.com/cosmos/cosmos-sdk/client/pruning" "github.com/cosmos/cosmos-sdk/client/rpc" + "github.com/cosmos/cosmos-sdk/client/snapshot" + "github.com/cosmos/cosmos-sdk/crypto/keyring" "github.com/cosmos/cosmos-sdk/server" serverconfig "github.com/cosmos/cosmos-sdk/server/config" servertypes "github.com/cosmos/cosmos-sdk/server/types" @@ -27,17 +29,17 @@ import ( "github.com/cosmos/cosmos-sdk/x/crisis" genutilcli "github.com/cosmos/cosmos-sdk/x/genutil/client/cli" scorumtypes "github.com/scorum/cosmos-network/x/scorum/types" + "github.com/spf13/cast" "github.com/spf13/cobra" "github.com/spf13/pflag" - - // this line is used by starport scaffolding # root/moduleImport + "github.com/spf13/viper" "github.com/scorum/cosmos-network/app" appparams "github.com/scorum/cosmos-network/app/params" ) // NewRootCmd creates a new root command for a Cosmos SDK application -func NewRootCmd() (*cobra.Command, appparams.EncodingConfig) { +func NewRootCmd() *cobra.Command { encodingConfig := app.MakeEncodingConfig() initClientCtx := client.Context{}. WithCodec(encodingConfig.Marshaler). @@ -49,6 +51,26 @@ func NewRootCmd() (*cobra.Command, appparams.EncodingConfig) { WithHomeDir(app.DefaultNodeHome). WithViper("") + // create a temporary application for use in constructing query + tx commands + initAppOptions := viper.New() + tempDir := tempDir() + initAppOptions.Set(flags.FlagHome, tempDir) + tempApplication := app.New( + log.NewNopLogger(), + dbm.NewMemDB(), + nil, + true, + nil, + tempDir, + 0, + initAppOptions, + ) + defer func() { + if err := tempApplication.Close(); err != nil { + panic(err) + } + }() + rootCmd := &cobra.Command{ Use: app.Name + "d", Short: "Start scorum node", @@ -70,9 +92,9 @@ func NewRootCmd() (*cobra.Command, appparams.EncodingConfig) { } customAppTemplate, customAppConfig := initAppConfig() - customTMConfig := initTendermintConfig() + customCMTConfig := initCometBFTConfig() return server.InterceptConfigsPreRunHandler( - cmd, customAppTemplate, customAppConfig, customTMConfig, + cmd, customAppTemplate, customAppConfig, customCMTConfig, ) }, } @@ -84,13 +106,22 @@ func NewRootCmd() (*cobra.Command, appparams.EncodingConfig) { "minimum-gas-prices": scorumtypes.GasPrice.String(), }) - return rootCmd, encodingConfig + // add keyring to autocli opts + autoCliOpts := tempApplication.AutoCliOpts() + initClientCtx, _ = config.ReadFromClientConfig(initClientCtx) + autoCliOpts.Keyring, _ = keyring.NewAutoCLIKeyring(initClientCtx.Keyring) + autoCliOpts.ClientCtx = initClientCtx + + if err := autoCliOpts.EnhanceRootCommand(rootCmd); err != nil { + panic(err) + } + return rootCmd } // initTendermintConfig helps to override default Tendermint Config values. // return tmcfg.DefaultConfig if no custom configuration is required for the application. -func initTendermintConfig() *tmcfg.Config { - cfg := tmcfg.DefaultConfig() +func initCometBFTConfig() *cmtcfg.Config { + cfg := cmtcfg.DefaultConfig() return cfg } @@ -98,43 +129,38 @@ func initRootCmd( rootCmd *cobra.Command, encodingConfig appparams.EncodingConfig, ) { - // Set config - app.InitSDKConfig() - rootCmd.AddCommand( genutilcli.InitCmd(app.ModuleBasics, app.DefaultNodeHome), - CollectGenTxsCmd(cosmosbanktypes.GenesisBalancesIterator{}, app.DefaultNodeHome), - genutilcli.MigrateGenesisCmd(), + CollectGenTxsCmd(encodingConfig, cosmosbanktypes.GenesisBalancesIterator{}, app.DefaultNodeHome), genutilcli.GenTxCmd( app.ModuleBasics, encodingConfig.TxConfig, cosmosbanktypes.GenesisBalancesIterator{}, app.DefaultNodeHome, + encodingConfig.TxConfig.SigningContext().ValidatorAddressCodec(), ), genutilcli.ValidateGenesisCmd(app.ModuleBasics), AddGenesisAccountCmd(app.DefaultNodeHome), AddGenesisSupervisorCmd(app.DefaultNodeHome), - AddPruneCmd(app.DefaultNodeHome), - tmcli.NewCompletionCmd(rootCmd, true), + cmtcli.NewCompletionCmd(rootCmd, true), debug.Cmd(), - config.Cmd(), + confixcmd.ConfigCommand(), + pruning.Cmd(newApp, app.DefaultNodeHome), + snapshot.Cmd(newApp), ) - // add server commands - server.AddCommands( - rootCmd, - app.DefaultNodeHome, - newApp, - appExport, - addModuleInitFlags, - ) + server.AddCommandsWithStartCmdOptions(rootCmd, app.DefaultNodeHome, newApp, appExport, server.StartCmdOptions{ + AddFlags: func(startCmd *cobra.Command) { + crisis.AddModuleInitFlags(startCmd) + }, + }) // add keybase, auxiliary RPC, query, and tx child commands rootCmd.AddCommand( - rpc.StatusCommand(), + server.StatusCommand(), queryCommand(), txCommand(), - keys.Commands(app.DefaultNodeHome), + keys.Commands(), ) } @@ -150,19 +176,15 @@ func queryCommand() *cobra.Command { } cmd.AddCommand( - authcmd.GetAccountCmd(), - rpc.ValidatorCommand(), - rpc.BlockCommand(), + rpc.QueryEventForTxCmd(), + server.QueryBlockCmd(), authcmd.QueryTxsByEventsCmd(), + server.QueryBlocksCmd(), authcmd.QueryTxCmd(), + server.QueryBlockResultsCmd(), + rpc.ValidatorCommand(), ) - for _, b := range app.ModuleBasics { - if moduleCmd := b.GetQueryCmd(); moduleCmd != nil { - cmd.AddCommand(moduleCmd) - } - } - cmd.PersistentFlags().String(flags.FlagChainID, "", "The network chain ID") return cmd @@ -189,22 +211,11 @@ func txCommand() *cobra.Command { authcmd.GetDecodeCommand(), ) - for _, b := range app.ModuleBasics { - if moduleCmd := b.GetTxCmd(); moduleCmd != nil { - cmd.AddCommand(moduleCmd) - } - } - cmd.PersistentFlags().String(flags.FlagChainID, "", "The network chain ID") return cmd } -func addModuleInitFlags(startCmd *cobra.Command) { - crisis.AddModuleInitFlags(startCmd) - // this line is used by starport scaffolding # root/arguments -} - func overwriteFlagDefaults(c *cobra.Command, defaults map[string]string) { set := func(s *pflag.FlagSet, key, val string) { if f := s.Lookup(key); f != nil { @@ -294,12 +305,21 @@ func initAppConfig() (string, interface{}) { // server config. srvCfg := serverconfig.DefaultConfig() srvCfg.MinGasPrices = scorumtypes.GasPrice.String() - srvCfg.Rosetta.DenomToSuggest = scorumtypes.GasDenom customAppConfig := CustomAppConfig{ Config: *srvCfg, } - customAppTemplate := DefaultConfigTemplate + customAppTemplate := serverconfig.DefaultConfigTemplate return customAppTemplate, customAppConfig } + +func tempDir() string { + dir, err := os.MkdirTemp("", "neutrond") + if err != nil { + dir = app.DefaultNodeHome + } + defer os.RemoveAll(dir) + + return dir +} diff --git a/cmd/scorumd/main.go b/cmd/scorumd/main.go index b58a299..8032d1e 100644 --- a/cmd/scorumd/main.go +++ b/cmd/scorumd/main.go @@ -1,9 +1,9 @@ package main import ( + "fmt" "os" - "github.com/cosmos/cosmos-sdk/server" svrcmd "github.com/cosmos/cosmos-sdk/server/cmd" "github.com/scorum/cosmos-network/app" @@ -11,14 +11,12 @@ import ( ) func main() { - rootCmd, _ := cmd.NewRootCmd() - if err := svrcmd.Execute(rootCmd, "", app.DefaultNodeHome); err != nil { - switch e := err.(type) { - case server.ErrorCode: - os.Exit(e.Code) + // Set config + app.InitSDKConfig() - default: - os.Exit(1) - } + rootCmd := cmd.NewRootCmd() + if err := svrcmd.Execute(rootCmd, "", app.DefaultNodeHome); err != nil { + fmt.Fprintln(rootCmd.OutOrStderr(), err) + os.Exit(1) } } diff --git a/go.mod b/go.mod index f017e05..88e417d 100644 --- a/go.mod +++ b/go.mod @@ -3,18 +3,31 @@ module github.com/scorum/cosmos-network go 1.22.2 require ( - cosmossdk.io/api v0.3.1 + cosmossdk.io/api v0.7.5 + cosmossdk.io/client/v2 v2.0.0-beta.1 + cosmossdk.io/core v0.11.0 cosmossdk.io/errors v1.0.1 + cosmossdk.io/log v1.3.1 cosmossdk.io/math v1.3.0 - github.com/cometbft/cometbft v0.37.5 - github.com/cometbft/cometbft-db v0.12.1-0.20240508134034-e9d8487735c2 - github.com/cosmos/cosmos-sdk v0.47.11 - github.com/cosmos/gogoproto v1.4.10 - github.com/cosmos/ibc-go/v7 v7.4.0 + cosmossdk.io/store v1.1.0 + cosmossdk.io/tools/confix v0.1.0 + cosmossdk.io/x/circuit v0.1.0 + cosmossdk.io/x/evidence v0.1.0 + cosmossdk.io/x/feegrant v0.1.0 + cosmossdk.io/x/nft v0.1.1 + cosmossdk.io/x/tx v0.13.3 + cosmossdk.io/x/upgrade v0.1.0 + github.com/cometbft/cometbft v0.38.7 + github.com/cosmos/cosmos-db v1.0.2 + github.com/cosmos/cosmos-proto v1.0.0-beta.5 + github.com/cosmos/cosmos-sdk v0.50.7 + github.com/cosmos/gogoproto v1.4.12 + github.com/cosmos/ibc-go/modules/capability v1.0.0 + github.com/cosmos/ibc-go/v8 v8.2.1 github.com/gogo/protobuf v1.3.3 github.com/golang/protobuf v1.5.4 github.com/google/uuid v1.6.0 - github.com/gorilla/mux v1.8.0 + github.com/gorilla/mux v1.8.1 github.com/grpc-ecosystem/grpc-gateway v1.16.0 github.com/grpc-ecosystem/grpc-gateway/v2 v2.16.0 github.com/mikluke/co-pilot v0.0.0-20231002172848-ba00fa031618 @@ -22,36 +35,35 @@ require ( github.com/spf13/cast v1.6.0 github.com/spf13/cobra v1.8.0 github.com/spf13/pflag v1.0.5 + github.com/spf13/viper v1.18.2 github.com/stretchr/testify v1.9.0 - github.com/syndtr/goleveldb v1.0.1-0.20220721030215-126854af5e6d - google.golang.org/genproto/googleapis/api v0.0.0-20240123012728-ef4313101c80 - google.golang.org/grpc v1.62.1 + google.golang.org/genproto/googleapis/api v0.0.0-20240227224415-6ceb2ff114de + google.golang.org/grpc v1.63.2 + google.golang.org/protobuf v1.33.0 gopkg.in/yaml.v2 v2.4.0 ) require ( cloud.google.com/go v0.112.0 // indirect - cloud.google.com/go/compute v1.23.3 // indirect + cloud.google.com/go/compute v1.24.0 // indirect cloud.google.com/go/compute/metadata v0.2.3 // indirect - cloud.google.com/go/iam v1.1.5 // indirect + cloud.google.com/go/iam v1.1.6 // indirect cloud.google.com/go/storage v1.36.0 // indirect - cosmossdk.io/core v0.5.1 // indirect + cosmossdk.io/collections v0.4.0 // indirect cosmossdk.io/depinject v1.0.0-alpha.4 // indirect - cosmossdk.io/log v1.3.1 // indirect - cosmossdk.io/tools/rosetta v0.2.1 // indirect filippo.io/edwards25519 v1.0.0 // indirect github.com/99designs/go-keychain v0.0.0-20191008050251-8e49817e8af4 // indirect github.com/99designs/keyring v1.2.1 // indirect - github.com/ChainSafe/go-schnorrkel v1.0.0 // indirect - github.com/DataDog/zstd v1.5.0 // indirect - github.com/armon/go-metrics v0.4.1 // indirect - github.com/aws/aws-sdk-go v1.44.203 // indirect + github.com/DataDog/datadog-go v3.2.0+incompatible // indirect + github.com/DataDog/zstd v1.5.5 // indirect + github.com/aws/aws-sdk-go v1.44.224 // indirect github.com/beorn7/perks v1.0.1 // indirect github.com/bgentry/go-netrc v0.0.0-20140422174119-9fd32a8b3d3d // indirect github.com/bgentry/speakeasy v0.1.1-0.20220910012023-760eaf8b6816 // indirect + github.com/bits-and-blooms/bitset v1.8.0 // indirect github.com/btcsuite/btcd/btcec/v2 v2.3.2 // indirect github.com/cenkalti/backoff/v4 v4.1.3 // indirect - github.com/cespare/xxhash/v2 v2.2.0 // indirect + github.com/cespare/xxhash/v2 v2.3.0 // indirect github.com/chzyer/readline v1.5.1 // indirect github.com/cockroachdb/apd/v2 v2.0.2 // indirect github.com/cockroachdb/errors v1.11.1 // indirect @@ -59,33 +71,33 @@ require ( github.com/cockroachdb/pebble v1.1.0 // indirect github.com/cockroachdb/redact v1.1.5 // indirect github.com/cockroachdb/tokenbucket v0.0.0-20230807174530-cc333fc44b06 // indirect - github.com/coinbase/rosetta-sdk-go v0.7.9 // indirect - github.com/confio/ics23/go v0.9.0 // indirect + github.com/cometbft/cometbft-db v0.12.1-0.20240508134034-e9d8487735c2 // indirect github.com/cosmos/btcutil v1.0.5 // indirect - github.com/cosmos/cosmos-proto v1.0.0-beta.5 // indirect github.com/cosmos/go-bip39 v1.0.0 // indirect github.com/cosmos/gogogateway v1.2.0 // indirect - github.com/cosmos/iavl v0.20.1 // indirect + github.com/cosmos/iavl v1.1.2 // indirect github.com/cosmos/ics23/go v0.10.0 // indirect - github.com/cosmos/ledger-cosmos-go v0.12.4 // indirect - github.com/cosmos/rosetta-sdk-go v0.10.0 // indirect - github.com/creachadair/taskgroup v0.4.2 // indirect + github.com/cosmos/ledger-cosmos-go v0.13.3 // indirect + github.com/creachadair/atomicfile v0.3.1 // indirect + github.com/creachadair/tomledit v0.0.24 // indirect github.com/danieljoos/wincred v1.1.2 // indirect github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc // indirect - github.com/decred/dcrd/dcrec/secp256k1/v4 v4.1.0 // indirect + github.com/decred/dcrd/dcrec/secp256k1/v4 v4.2.0 // indirect github.com/desertbit/timer v0.0.0-20180107155436-c41aec40b27f // indirect github.com/dgraph-io/badger/v4 v4.2.0 // indirect github.com/dgraph-io/ristretto v0.1.1 // indirect github.com/dustin/go-humanize v1.0.1 // indirect github.com/dvsekhvalnov/jose2go v1.6.0 // indirect + github.com/emicklei/dot v1.6.1 // indirect + github.com/fatih/color v1.15.0 // indirect github.com/felixge/httpsnoop v1.0.4 // indirect github.com/fsnotify/fsnotify v1.7.0 // indirect - github.com/getsentry/sentry-go v0.23.0 // indirect + github.com/getsentry/sentry-go v0.27.0 // indirect github.com/ghodss/yaml v1.0.0 // indirect github.com/go-kit/kit v0.12.0 // indirect github.com/go-kit/log v0.2.1 // indirect github.com/go-logfmt/logfmt v0.6.0 // indirect - github.com/go-logr/logr v1.3.0 // indirect + github.com/go-logr/logr v1.4.1 // indirect github.com/go-logr/stdr v1.2.2 // indirect github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2 // indirect github.com/gogo/googleapis v1.4.1 // indirect @@ -100,25 +112,28 @@ require ( github.com/google/s2a-go v0.1.7 // indirect github.com/googleapis/enterprise-certificate-proxy v0.3.2 // indirect github.com/googleapis/gax-go/v2 v2.12.0 // indirect - github.com/gorilla/handlers v1.5.1 // indirect + github.com/gorilla/handlers v1.5.2 // indirect github.com/gorilla/websocket v1.5.0 // indirect - github.com/grpc-ecosystem/go-grpc-middleware v1.3.0 // indirect + github.com/grpc-ecosystem/go-grpc-middleware v1.4.0 // indirect github.com/gsterjov/go-libsecret v0.0.0-20161001094733-a6f4afe4910c // indirect - github.com/gtank/merlin v0.1.1 // indirect - github.com/gtank/ristretto255 v0.1.2 // indirect github.com/hashicorp/go-cleanhttp v0.5.2 // indirect github.com/hashicorp/go-getter v1.7.1 // indirect + github.com/hashicorp/go-hclog v1.5.0 // indirect github.com/hashicorp/go-immutable-radix v1.3.1 // indirect + github.com/hashicorp/go-metrics v0.5.3 // indirect + github.com/hashicorp/go-plugin v1.5.2 // indirect github.com/hashicorp/go-safetemp v1.0.0 // indirect github.com/hashicorp/go-version v1.6.0 // indirect - github.com/hashicorp/golang-lru v0.5.5-0.20210104140557-80c98217689d // indirect + github.com/hashicorp/golang-lru v1.0.2 // indirect github.com/hashicorp/hcl v1.0.0 // indirect + github.com/hashicorp/yamux v0.1.1 // indirect github.com/hdevalence/ed25519consensus v0.1.0 // indirect github.com/huandu/skiplist v1.2.0 // indirect + github.com/iancoleman/strcase v0.3.0 // indirect github.com/improbable-eng/grpc-web v0.15.0 // indirect github.com/inconshreveable/mousetrap v1.1.0 // indirect github.com/jmespath/go-jmespath v0.4.0 // indirect - github.com/klauspost/compress v1.17.0 // indirect + github.com/klauspost/compress v1.17.7 // indirect github.com/kr/pretty v0.3.1 // indirect github.com/kr/text v0.2.0 // indirect github.com/lib/pq v1.10.7 // indirect @@ -128,24 +143,23 @@ require ( github.com/manifoldco/promptui v0.9.0 // indirect github.com/mattn/go-colorable v0.1.13 // indirect github.com/mattn/go-isatty v0.0.20 // indirect - github.com/matttproud/golang_protobuf_extensions v1.0.4 // indirect - github.com/mimoo/StrobeGo v0.0.0-20210601165009-122bf33a46e0 // indirect github.com/minio/highwayhash v1.0.2 // indirect github.com/mitchellh/go-homedir v1.1.0 // indirect github.com/mitchellh/go-testing-interface v1.14.1 // indirect github.com/mitchellh/mapstructure v1.5.0 // indirect github.com/mtibben/percent v0.2.1 // indirect + github.com/oasisprotocol/curve25519-voi v0.0.0-20230904125328-1f23a7beb09a // indirect + github.com/oklog/run v1.1.0 // indirect github.com/pelletier/go-toml/v2 v2.1.0 // indirect - github.com/petermattis/goid v0.0.0-20230317030725-371a4b8eda08 // indirect + github.com/petermattis/goid v0.0.0-20231207134359-e60b3f734c67 // indirect github.com/pkg/errors v0.9.1 // indirect github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 // indirect - github.com/prometheus/client_golang v1.14.0 // indirect - github.com/prometheus/client_model v0.3.0 // indirect - github.com/prometheus/common v0.42.0 // indirect - github.com/prometheus/procfs v0.9.0 // indirect - github.com/rakyll/statik v0.1.7 // indirect + github.com/prometheus/client_golang v1.19.0 // indirect + github.com/prometheus/client_model v0.6.1 // indirect + github.com/prometheus/common v0.52.2 // indirect + github.com/prometheus/procfs v0.13.0 // indirect github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475 // indirect - github.com/rogpeppe/go-internal v1.11.0 // indirect + github.com/rogpeppe/go-internal v1.12.0 // indirect github.com/rs/cors v1.8.3 // indirect github.com/rs/zerolog v1.32.0 // indirect github.com/sagikazarmark/locafero v0.4.0 // indirect @@ -153,45 +167,46 @@ require ( github.com/sasha-s/go-deadlock v0.3.1 // indirect github.com/sourcegraph/conc v0.3.0 // indirect github.com/spf13/afero v1.11.0 // indirect - github.com/spf13/viper v1.18.2 // indirect github.com/subosito/gotenv v1.6.0 // indirect + github.com/syndtr/goleveldb v1.0.1-0.20220721030215-126854af5e6d // indirect github.com/tendermint/go-amino v0.16.0 // indirect - github.com/tidwall/btree v1.6.0 // indirect + github.com/tidwall/btree v1.7.0 // indirect github.com/ulikunitz/xz v0.5.11 // indirect github.com/zondax/hid v0.9.2 // indirect github.com/zondax/ledger-go v0.14.3 // indirect go.opencensus.io v0.24.0 // indirect - go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.46.1 // indirect - go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.46.1 // indirect - go.opentelemetry.io/otel v1.21.0 // indirect - go.opentelemetry.io/otel/metric v1.21.0 // indirect - go.opentelemetry.io/otel/trace v1.21.0 // indirect - go.uber.org/atomic v1.10.0 // indirect - go.uber.org/multierr v1.9.0 // indirect - golang.org/x/crypto v0.21.0 // indirect - golang.org/x/exp v0.0.0-20230905200255-921286631fa9 // indirect - golang.org/x/net v0.23.0 // indirect - golang.org/x/oauth2 v0.16.0 // indirect - golang.org/x/sync v0.6.0 // indirect - golang.org/x/sys v0.18.0 // indirect - golang.org/x/term v0.18.0 // indirect + go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.47.0 // indirect + go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.47.0 // indirect + go.opentelemetry.io/otel v1.22.0 // indirect + go.opentelemetry.io/otel/metric v1.22.0 // indirect + go.opentelemetry.io/otel/trace v1.22.0 // indirect + go.uber.org/multierr v1.10.0 // indirect + golang.org/x/crypto v0.22.0 // indirect + golang.org/x/exp v0.0.0-20240404231335-c0f41cb1a7a0 // indirect + golang.org/x/net v0.24.0 // indirect + golang.org/x/oauth2 v0.18.0 // indirect + golang.org/x/sync v0.7.0 // indirect + golang.org/x/sys v0.19.0 // indirect + golang.org/x/term v0.19.0 // indirect golang.org/x/text v0.14.0 // indirect golang.org/x/time v0.5.0 // indirect - google.golang.org/api v0.155.0 // indirect + google.golang.org/api v0.162.0 // indirect google.golang.org/appengine v1.6.8 // indirect - google.golang.org/genproto v0.0.0-20240123012728-ef4313101c80 // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20240123012728-ef4313101c80 // indirect - google.golang.org/protobuf v1.33.0 // indirect + google.golang.org/genproto v0.0.0-20240227224415-6ceb2ff114de // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20240401170217-c3f982113cda // indirect gopkg.in/ini.v1 v1.67.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect + gotest.tools/v3 v3.5.1 // indirect nhooyr.io/websocket v1.8.6 // indirect pgregory.net/rapid v1.1.0 // indirect sigs.k8s.io/yaml v1.4.0 // indirect ) -replace github.com/gogo/protobuf => github.com/regen-network/protobuf v1.3.3-alpha.regen.1 - -replace golang.org/x/exp => golang.org/x/exp v0.0.0-20230711153332-06a737ee72cb // remove on bump to v0.50 - -// downgrade of goleveldb to avoid issues: see https://github.com/cosmos/cosmos-sdk/issues/14949 -replace github.com/syndtr/goleveldb => github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 +replace ( + github.com/99designs/keyring => github.com/cosmos/keyring v1.2.0 + // explicitely replace iavl to v1.2.0 cause sometimes go mod tidy uses not right version + github.com/cosmos/iavl => github.com/cosmos/iavl v1.2.0 + github.com/gogo/protobuf => github.com/regen-network/protobuf v1.3.3-alpha.regen.1 + github.com/prometheus/procfs => github.com/prometheus/procfs v0.12.0 + github.com/syndtr/goleveldb => github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 +) diff --git a/go.sum b/go.sum index 69a1345..b600ec3 100644 --- a/go.sum +++ b/go.sum @@ -1,13 +1,11 @@ cloud.google.com/go v0.26.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw= cloud.google.com/go v0.34.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw= cloud.google.com/go v0.38.0/go.mod h1:990N+gfupTy94rShfmMCWGDn0LpTmnzTp2qbd1dvSRU= -cloud.google.com/go v0.43.0/go.mod h1:BOSR3VbTLkk6FDC/TcffxP4NF/FFBGA5ku+jvKOP7pg= cloud.google.com/go v0.44.1/go.mod h1:iSa0KzasP4Uvy3f1mN/7PiObzGgflwredwwASm/v6AU= cloud.google.com/go v0.44.2/go.mod h1:60680Gw3Yr4ikxnPRS/oxxkBccT6SA1yMk63TGekxKY= cloud.google.com/go v0.45.1/go.mod h1:RpBamKRgapWJb87xiFSdk4g1CME7QZg3uwTez+TSTjc= cloud.google.com/go v0.46.3/go.mod h1:a6bKKbmY7er1mI7TEI4lsAkts/mkhTSZK8w33B4RAg0= cloud.google.com/go v0.50.0/go.mod h1:r9sluTvynVuxRIOHXQEHMFffphuXHOMZMycpNR5e6To= -cloud.google.com/go v0.51.0/go.mod h1:hWtGJ6gnXH+KgDv+V0zFGDvpi07n3z8ZNj3T1RW0Gcw= cloud.google.com/go v0.52.0/go.mod h1:pXajvRH/6o3+F9jDHZWQ5PbGhn+o8w9qiu/CffaVdO4= cloud.google.com/go v0.53.0/go.mod h1:fp/UouUEsRkN6ryDKNW/Upv/JBKnv6WDthjR6+vze6M= cloud.google.com/go v0.54.0/go.mod h1:1rq2OEkV3YMf6n/9ZvGWI3GWw0VoqH/1x2nd8Is/bPc= @@ -57,7 +55,6 @@ cloud.google.com/go/bigquery v1.5.0/go.mod h1:snEHRnqQbz117VIFhE8bmtwIDY80NLUZUM cloud.google.com/go/bigquery v1.7.0/go.mod h1://okPTzCYNXSlb24MZs83e2Do+h+VXtc4gLoIoXIAPc= cloud.google.com/go/bigquery v1.8.0/go.mod h1:J5hqkt3O0uAFnINi6JXValWIb1v0goeZM77hZzJN/fQ= cloud.google.com/go/bigquery v1.42.0/go.mod h1:8dRTJxhtG+vwBKzE5OseQn/hiydoQN3EedCaOdYmxRA= -cloud.google.com/go/bigtable v1.2.0/go.mod h1:JcVAOl45lrTmQfLj7T6TxyMzIN/3FGGcFm+2xVAli2o= cloud.google.com/go/billing v1.4.0/go.mod h1:g9IdKBEFlItS8bTtlrZdVLWSSdSyFUZKXNS02zKMOZY= cloud.google.com/go/billing v1.5.0/go.mod h1:mztb1tBc3QekhjSgmpf/CV4LzWXLzCArwpLmP2Gm88s= cloud.google.com/go/binaryauthorization v1.1.0/go.mod h1:xwnoWu3Y84jbuHa0zd526MJYmtnVXn0syOjaJgy4+dM= @@ -71,8 +68,8 @@ cloud.google.com/go/compute v1.6.0/go.mod h1:T29tfhtVbq1wvAPo0E3+7vhgmkOYeXjhFvz cloud.google.com/go/compute v1.6.1/go.mod h1:g85FgpzFvNULZ+S8AYq87axRKuf2Kh7deLqV/jJ3thU= cloud.google.com/go/compute v1.7.0/go.mod h1:435lt8av5oL9P3fv1OEzSbSUe+ybHXGMPQHHZWZxy9U= cloud.google.com/go/compute v1.10.0/go.mod h1:ER5CLbMxl90o2jtNbGSbtfOpQKR0t15FOtRsugnLrlU= -cloud.google.com/go/compute v1.23.3 h1:6sVlXXBmbd7jNX0Ipq0trII3e4n1/MsADLK6a+aiVlk= -cloud.google.com/go/compute v1.23.3/go.mod h1:VCgBUoMnIVIR0CscqQiPJLAG25E3ZRZMzcFZeQ+h8CI= +cloud.google.com/go/compute v1.24.0 h1:phWcR2eWzRJaL/kOiJwfFsPs4BaKq1j6vnpZrc1YlVg= +cloud.google.com/go/compute v1.24.0/go.mod h1:kw1/T+h/+tK2LJK0wiPPx1intgdAM3j/g3hFDlscY40= cloud.google.com/go/compute/metadata v0.2.3 h1:mg4jlk7mCAj6xXp9UJ4fjI9VUI5rubuGBW5aJ7UnBMY= cloud.google.com/go/compute/metadata v0.2.3/go.mod h1:VAV5nSsACxMJvgaAuX6Pk2AawlZn8kiOGuCv6gTkwuA= cloud.google.com/go/containeranalysis v0.5.1/go.mod h1:1D92jd8gRR/c0fGMlymRgxWD3Qw9C1ff6/T7mLgVL8I= @@ -112,8 +109,8 @@ cloud.google.com/go/gkehub v0.10.0/go.mod h1:UIPwxI0DsrpsVoWpLB0stwKCP+WFVG9+y97 cloud.google.com/go/grafeas v0.2.0/go.mod h1:KhxgtF2hb0P191HlY5besjYm6MqTSTj3LSI+M+ByZHc= cloud.google.com/go/iam v0.3.0/go.mod h1:XzJPvDayI+9zsASAFO68Hk07u3z+f+JrT2xXNdp4bnY= cloud.google.com/go/iam v0.5.0/go.mod h1:wPU9Vt0P4UmCux7mqtRu6jcpPAb74cP1fh50J3QpkUc= -cloud.google.com/go/iam v1.1.5 h1:1jTsCu4bcsNsE4iiqNT5SHwrDRCfRmIaaaVFhRveTJI= -cloud.google.com/go/iam v1.1.5/go.mod h1:rB6P/Ic3mykPbFio+vo7403drjlgvoWfYpJhMXEbzv8= +cloud.google.com/go/iam v1.1.6 h1:bEa06k05IO4f4uJonbB5iAgKTPpABy1ayxaIZV/GHVc= +cloud.google.com/go/iam v1.1.6/go.mod h1:O0zxdPeGBoFdWW3HWmBxJsk0pfvNM/p/qa82rWOGTwI= cloud.google.com/go/language v1.4.0/go.mod h1:F9dRpNFQmJbkaop6g0JhSBXCNlO90e1KWx5iDdxbWic= cloud.google.com/go/language v1.6.0/go.mod h1:6dJ8t3B+lUYfStgls25GusK04NLh3eDLQnWM3mdEbhI= cloud.google.com/go/lifesciences v0.5.0/go.mod h1:3oIKy8ycWGPUyZDR/8RNnTOYevhaMLqh5vLUXs9zvT8= @@ -187,11 +184,14 @@ cloud.google.com/go/webrisk v1.4.0/go.mod h1:Hn8X6Zr+ziE2aNd8SliSDWpEnSS1u4R9+xX cloud.google.com/go/webrisk v1.5.0/go.mod h1:iPG6fr52Tv7sGk0H6qUFzmL3HHZev1htXuWDEEsqMTg= cloud.google.com/go/workflows v1.6.0/go.mod h1:6t9F5h/unJz41YqfBmqSASJSXccBLtD1Vwf+KmJENM0= cloud.google.com/go/workflows v1.7.0/go.mod h1:JhSrZuVZWuiDfKEFxU0/F1PQjmpnpcoISEXH2bcHC3M= -collectd.org v0.3.0/go.mod h1:A/8DzQBkF6abtvrT2j/AU/4tiBgJWYyh0y/oB/4MlWE= -cosmossdk.io/api v0.3.1 h1:NNiOclKRR0AOlO4KIqeaG6PS6kswOMhHD0ir0SscNXE= -cosmossdk.io/api v0.3.1/go.mod h1:DfHfMkiNA2Uhy8fj0JJlOCYOBp4eWUUJ1te5zBGNyIw= -cosmossdk.io/core v0.5.1 h1:vQVtFrIYOQJDV3f7rw4pjjVqc1id4+mE0L9hHP66pyI= -cosmossdk.io/core v0.5.1/go.mod h1:KZtwHCLjcFuo0nmDc24Xy6CRNEL9Vl/MeimQ2aC7NLE= +cosmossdk.io/api v0.7.5 h1:eMPTReoNmGUm8DeiQL9DyM8sYDjEhWzL1+nLbI9DqtQ= +cosmossdk.io/api v0.7.5/go.mod h1:IcxpYS5fMemZGqyYtErK7OqvdM0C8kdW3dq8Q/XIG38= +cosmossdk.io/client/v2 v2.0.0-beta.1 h1:XkHh1lhrLYIT9zKl7cIOXUXg2hdhtjTPBUfqERNA1/Q= +cosmossdk.io/client/v2 v2.0.0-beta.1/go.mod h1:JEUSu9moNZQ4kU3ir1DKD5eU4bllmAexrGWjmb9k8qU= +cosmossdk.io/collections v0.4.0 h1:PFmwj2W8szgpD5nOd8GWH6AbYNi1f2J6akWXJ7P5t9s= +cosmossdk.io/collections v0.4.0/go.mod h1:oa5lUING2dP+gdDquow+QjlF45eL1t4TJDypgGd+tv0= +cosmossdk.io/core v0.11.0 h1:vtIafqUi+1ZNAE/oxLOQQ7Oek2n4S48SWLG8h/+wdbo= +cosmossdk.io/core v0.11.0/go.mod h1:LaTtayWBSoacF5xNzoF8tmLhehqlA9z1SWiPuNC6X1w= cosmossdk.io/depinject v1.0.0-alpha.4 h1:PLNp8ZYAMPTUKyG9IK2hsbciDWqna2z1Wsl98okJopc= cosmossdk.io/depinject v1.0.0-alpha.4/go.mod h1:HeDk7IkR5ckZ3lMGs/o91AVUc7E596vMaOmslGFM3yU= cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= @@ -200,29 +200,35 @@ cosmossdk.io/log v1.3.1 h1:UZx8nWIkfbbNEWusZqzAx3ZGvu54TZacWib3EzUYmGI= cosmossdk.io/log v1.3.1/go.mod h1:2/dIomt8mKdk6vl3OWJcPk2be3pGOS8OQaLUM/3/tCM= cosmossdk.io/math v1.3.0 h1:RC+jryuKeytIiictDslBP9i1fhkVm6ZDmZEoNP316zE= cosmossdk.io/math v1.3.0/go.mod h1:vnRTxewy+M7BtXBNFybkuhSH4WfedVAAnERHgVFhp3k= -cosmossdk.io/tools/rosetta v0.2.1 h1:ddOMatOH+pbxWbrGJKRAawdBkPYLfKXutK9IETnjYxw= -cosmossdk.io/tools/rosetta v0.2.1/go.mod h1:Pqdc1FdvkNV3LcNIkYWt2RQY6IP1ge6YWZk8MhhO9Hw= -filippo.io/edwards25519 v1.0.0-rc.1/go.mod h1:N1IkdkCkiLB6tki+MYJoSx2JTY9NUlxZE7eHn5EwJns= +cosmossdk.io/store v1.1.0 h1:LnKwgYMc9BInn9PhpTFEQVbL9UK475G2H911CGGnWHk= +cosmossdk.io/store v1.1.0/go.mod h1:oZfW/4Fc/zYqu3JmQcQdUJ3fqu5vnYTn3LZFFy8P8ng= +cosmossdk.io/tools/confix v0.1.0 h1:2OOZTtQsDT5e7P3FM5xqM0bPfluAxZlAwxqaDmYBE+E= +cosmossdk.io/tools/confix v0.1.0/go.mod h1:TdXKVYs4gEayav5wM+JHT+kTU2J7fozFNqoVaN+8CdY= +cosmossdk.io/x/circuit v0.1.0 h1:IAej8aRYeuOMritczqTlljbUVHq1E85CpBqaCTwYgXs= +cosmossdk.io/x/circuit v0.1.0/go.mod h1:YDzblVE8+E+urPYQq5kq5foRY/IzhXovSYXb4nwd39w= +cosmossdk.io/x/evidence v0.1.0 h1:J6OEyDl1rbykksdGynzPKG5R/zm6TacwW2fbLTW4nCk= +cosmossdk.io/x/evidence v0.1.0/go.mod h1:hTaiiXsoiJ3InMz1uptgF0BnGqROllAN8mwisOMMsfw= +cosmossdk.io/x/feegrant v0.1.0 h1:c7s3oAq/8/UO0EiN1H5BIjwVntujVTkYs35YPvvrdQk= +cosmossdk.io/x/feegrant v0.1.0/go.mod h1:4r+FsViJRpcZif/yhTn+E0E6OFfg4n0Lx+6cCtnZElU= +cosmossdk.io/x/nft v0.1.1 h1:pslAVS8P5NkW080+LWOamInjDcq+v2GSCo+BjN9sxZ8= +cosmossdk.io/x/nft v0.1.1/go.mod h1:Kac6F6y2gsKvoxU+fy8uvxRTi4BIhLOor2zgCNQwVgY= +cosmossdk.io/x/tx v0.13.3 h1:Ha4mNaHmxBc6RMun9aKuqul8yHiL78EKJQ8g23Zf73g= +cosmossdk.io/x/tx v0.13.3/go.mod h1:I8xaHv0rhUdIvIdptKIqzYy27+n2+zBVaxO6fscFhys= +cosmossdk.io/x/upgrade v0.1.0 h1:z1ZZG4UL9ICTNbJDYZ6jOnF9GdEK9wyoEFi4BUScHXE= +cosmossdk.io/x/upgrade v0.1.0/go.mod h1:/6jjNGbiPCNtmA1N+rBtP601sr0g4ZXuj3yC6ClPCGY= +dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU= filippo.io/edwards25519 v1.0.0 h1:0wAIcmJUqRdI8IJ/3eGi5/HwXZWPujYXXlkrQogz0Ek= filippo.io/edwards25519 v1.0.0/go.mod h1:N1IkdkCkiLB6tki+MYJoSx2JTY9NUlxZE7eHn5EwJns= -git.sr.ht/~sircmpwn/getopt v0.0.0-20191230200459-23622cc906b3/go.mod h1:wMEGFFFNuPos7vHmWXfszqImLppbc0wEhh6JBfJIUgw= -git.sr.ht/~sircmpwn/go-bare v0.0.0-20210406120253-ab86bc2846d9/go.mod h1:BVJwbDfVjCjoFiKrhkei6NdGcZYpkDkdyCdg1ukytRA= github.com/99designs/go-keychain v0.0.0-20191008050251-8e49817e8af4 h1:/vQbFIOMbk2FiG/kXiLl8BRyzTWDw7gX/Hz7Dd5eDMs= github.com/99designs/go-keychain v0.0.0-20191008050251-8e49817e8af4/go.mod h1:hN7oaIRCjzsZ2dE+yG5k+rsdt3qcwykqK6HVGcKwsw4= -github.com/99designs/keyring v1.2.1 h1:tYLp1ULvO7i3fI5vE21ReQuj99QFSs7lGm0xWyJo87o= -github.com/99designs/keyring v1.2.1/go.mod h1:fc+wB5KTk9wQ9sDx0kFXB3A0MaeGHM9AwRStKOQ5vOA= -github.com/Azure/azure-sdk-for-go/sdk/azcore v0.21.1/go.mod h1:fBF9PQNqB8scdgpZ3ufzaLntG0AG7C1WjPMsiFOmfHM= -github.com/Azure/azure-sdk-for-go/sdk/internal v0.8.3/go.mod h1:KLF4gFr6DcKFZwSuH8w8yEK6DpFl3LP5rhdvAb7Yz5I= -github.com/Azure/azure-sdk-for-go/sdk/storage/azblob v0.3.0/go.mod h1:tPaiy8S5bQ+S5sOiDlINkp7+Ef339+Nz5L5XO+cnOHo= -github.com/Azure/go-ansiterm v0.0.0-20210617225240-d185dfc1b5a1 h1:UQHMgLO+TxOElx5B5HZ4hJQsoJ/PvUvKRhJHDQXO8P8= -github.com/Azure/go-ansiterm v0.0.0-20210617225240-d185dfc1b5a1/go.mod h1:xomTg63KZ2rFqZQzSB4Vz2SUXa1BpHTVz9L5PTmPC4E= +github.com/Azure/go-ansiterm v0.0.0-20230124172434-306776ec8161 h1:L/gRVlceqvL25UVaW/CKtUDjefjrs0SPonmDGUVOYP0= +github.com/Azure/go-ansiterm v0.0.0-20230124172434-306776ec8161/go.mod h1:xomTg63KZ2rFqZQzSB4Vz2SUXa1BpHTVz9L5PTmPC4E= github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= -github.com/ChainSafe/go-schnorrkel v1.0.0 h1:3aDA67lAykLaG1y3AOjs88dMxC88PgUuHRrLeDnvGIM= -github.com/ChainSafe/go-schnorrkel v1.0.0/go.mod h1:dpzHYVxLZcp8pjlV+O+UR8K0Hp/z7vcchBSbMBEhCw4= -github.com/DATA-DOG/go-sqlmock v1.3.3/go.mod h1:f/Ixk793poVmq4qj/V1dPUg2JEAKC73Q5eFN3EC/SaM= +github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo= +github.com/DataDog/datadog-go v3.2.0+incompatible h1:qSG2N4FghB1He/r2mFrWKCaL7dXCilEuNEeAn20fdD4= github.com/DataDog/datadog-go v3.2.0+incompatible/go.mod h1:LButxg5PwREeZtORoXG3tL4fMGNddJ+vMq1mwgfaqoQ= -github.com/DataDog/zstd v1.5.0 h1:+K/VEwIAaPcHiMtQvpLD4lqW7f0Gk3xdYZmI1hD+CXo= -github.com/DataDog/zstd v1.5.0/go.mod h1:g4AWEaM3yOg3HYfnJ3YIawPnVdXJh9QME85blwSAmyw= +github.com/DataDog/zstd v1.5.5 h1:oWf5W7GtOLgp6bciQYDmhHHjdhYkALu6S/5Ni9ZgSvQ= +github.com/DataDog/zstd v1.5.5/go.mod h1:g4AWEaM3yOg3HYfnJ3YIawPnVdXJh9QME85blwSAmyw= github.com/Knetic/govaluate v3.0.1-0.20171022003610-9aa49832a739+incompatible/go.mod h1:r7JcOSlj0wfOMncg0iLm8Leh48TZaKVeNIfJntJ2wa0= github.com/Microsoft/go-winio v0.6.1 h1:9/kr64B9VUZrLm5YYwbGtUJnMgqWVOdUAXu6Migciow= github.com/Microsoft/go-winio v0.6.1/go.mod h1:LRdKpFKfdobln8UmuiYcKPot9D2v6svN5+sAH+4kjUM= @@ -231,49 +237,30 @@ github.com/Nvveen/Gotty v0.0.0-20120604004816-cd527374f1e5/go.mod h1:lmUJ/7eu/Q8 github.com/OneOfOne/xxhash v1.2.2/go.mod h1:HSdplMjZKSmBqAxg5vPj2TmRDmfkzw+cTzAElWljhcU= github.com/Shopify/sarama v1.19.0/go.mod h1:FVkBWblsNy7DGZRfXLU0O9RCGt5g3g3yEuWXgklEdEo= github.com/Shopify/toxiproxy v2.1.4+incompatible/go.mod h1:OXgGpZ6Cli1/URJOF1DMxUHB2q5Ap20/P/eIdh4G0pI= -github.com/StackExchange/wmi v0.0.0-20180116203802-5d049714c4a6/go.mod h1:3eOhrUMpNV+6aFIbp5/iudMxNCF27Vw2OZgy4xEx0Fg= -github.com/VictoriaMetrics/fastcache v1.6.0/go.mod h1:0qHz5QP0GMX4pfmMA/zt5RgfNuXJrTP0zS7DqpHGGTw= github.com/VividCortex/gohistogram v1.0.0 h1:6+hBz+qvs0JOrrNhhmR7lFxo5sINxBCGXrdtl/UvroE= github.com/VividCortex/gohistogram v1.0.0/go.mod h1:Pf5mBqqDxYaXu3hDrrU+w6nw50o/4+TcAqDqk/vUH7g= -github.com/Zilliqa/gozilliqa-sdk v1.2.1-0.20201201074141-dd0ecada1be6/go.mod h1:eSYp2T6f0apnuW8TzhV3f6Aff2SE8Dwio++U4ha4yEM= github.com/adlio/schema v1.3.3 h1:oBJn8I02PyTB466pZO1UZEn1TV5XLlifBSyMrmHl/1I= github.com/adlio/schema v1.3.3/go.mod h1:1EsRssiv9/Ce2CMzq5DoL7RiMshhuigQxrR4DMV9fHg= -github.com/aead/siphash v1.0.1/go.mod h1:Nywa3cDsYNNK3gaciGTWPwHt0wlpNV15vwmswBAUSII= github.com/afex/hystrix-go v0.0.0-20180502004556-fa1af6a1f4f5/go.mod h1:SkGFH1ia65gfNATL8TAiHDNxPzPdmEL5uirI2Uyuz6c= -github.com/ajstarks/svgo v0.0.0-20180226025133-644b8db467af/go.mod h1:K08gAheRH3/J6wwsYMMT4xOr94bZjxIelGM0+d/wbFw= github.com/alecthomas/template v0.0.0-20160405071501-a0175ee3bccc/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc= github.com/alecthomas/template v0.0.0-20190718012654-fb15b899a751/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc= github.com/alecthomas/units v0.0.0-20151022065526-2efee857e7cf/go.mod h1:ybxpYRFXyAe+OPACYpWeL0wqObRcbAqCMya13uyzqw0= github.com/alecthomas/units v0.0.0-20190717042225-c3de453c63f4/go.mod h1:ybxpYRFXyAe+OPACYpWeL0wqObRcbAqCMya13uyzqw0= github.com/alecthomas/units v0.0.0-20190924025748-f65c72e2690d/go.mod h1:rBZYJk541a8SKzHPHnH3zbiI+7dagKZ0cgpgrD7Fyho= -github.com/allegro/bigcache v1.2.1-0.20190218064605-e24eb225f156/go.mod h1:Cb/ax3seSYIx7SuZdm2G2xzfwmv3TPSk2ucNfQESPXM= -github.com/andreyvit/diff v0.0.0-20170406064948-c7f18ee00883/go.mod h1:rCTlJbsFo29Kk6CurOXKm700vrz8f0KW0JNfpkRJY/8= github.com/antihax/optional v1.0.0/go.mod h1:uupD/76wgC+ih3iEmQUL+0Ugr19nfwCT1kdvxnR2qWY= -github.com/apache/arrow/go/arrow v0.0.0-20191024131854-af6fa24be0db/go.mod h1:VTxUBvSJ3s3eHAg65PNgrsn5BtqCRPdmyXh6rAfdxN0= github.com/apache/thrift v0.12.0/go.mod h1:cp2SuWMxlEZw2r+iP2GNCdIi4C1qmUzdZFSVb+bacwQ= github.com/apache/thrift v0.13.0/go.mod h1:cp2SuWMxlEZw2r+iP2GNCdIi4C1qmUzdZFSVb+bacwQ= github.com/armon/circbuf v0.0.0-20150827004946-bbbad097214e/go.mod h1:3U/XgcO3hCbHZ8TKRvWD2dDTCfh9M9ya+I9JpbB7O8o= -github.com/armon/consul-api v0.0.0-20180202201655-eb2c6b5be1b6/go.mod h1:grANhF5doyWs3UAsr3K4I6qtAmlQcZDesFNEHPZAzj8= github.com/armon/go-metrics v0.0.0-20180917152333-f0300d1749da/go.mod h1:Q73ZrmVTwzkszR9V5SSuryQ31EELlFMUz1kKyl939pY= -github.com/armon/go-metrics v0.4.1 h1:hR91U9KYmb6bLBYLQjyM+3j+rcd/UhE+G78SFnF8gJA= -github.com/armon/go-metrics v0.4.1/go.mod h1:E6amYzXo6aW1tqzoZGT755KkbgrJsSdpwZ+3JqfkOG4= github.com/armon/go-radix v0.0.0-20180808171621-7fddfc383310/go.mod h1:ufUuZ+zHj4x4TnLV4JWEpy2hxWSpsRywHrMgIH9cCH8= github.com/aryann/difflib v0.0.0-20170710044230-e206f873d14a/go.mod h1:DAHtR1m6lCRdSC2Tm3DSWRPvIPr6xNKyeHdqDQSQT+A= github.com/aws/aws-lambda-go v1.13.3/go.mod h1:4UKl9IzQMoD+QF79YdCuzCwp8VbmG4VAQwij/eHl5CU= github.com/aws/aws-sdk-go v1.27.0/go.mod h1:KmX6BPdI08NWTb3/sm4ZGu5ShLoqVDhKgpiN924inxo= github.com/aws/aws-sdk-go v1.44.122/go.mod h1:y4AeaBuwd2Lk+GepC1E9v0qOiTws0MIWAX4oIKwKHZo= -github.com/aws/aws-sdk-go v1.44.203 h1:pcsP805b9acL3wUqa4JR2vg1k2wnItkDYNvfmcy6F+U= -github.com/aws/aws-sdk-go v1.44.203/go.mod h1:aVsgQcEevwlmQ7qHE9I3h+dtQgpqhFB+i8Phjh7fkwI= +github.com/aws/aws-sdk-go v1.44.224 h1:09CiaaF35nRmxrzWZ2uRq5v6Ghg/d2RiPjZnSgtt+RQ= +github.com/aws/aws-sdk-go v1.44.224/go.mod h1:aVsgQcEevwlmQ7qHE9I3h+dtQgpqhFB+i8Phjh7fkwI= github.com/aws/aws-sdk-go-v2 v0.18.0/go.mod h1:JWVYvqSMppoMJC0x5wdwiImzgXTI9FuZwxzkQq9wy+g= -github.com/aws/aws-sdk-go-v2 v1.2.0/go.mod h1:zEQs02YRBw1DjK0PoJv3ygDYOFTre1ejlJWl8FwAuQo= -github.com/aws/aws-sdk-go-v2/config v1.1.1/go.mod h1:0XsVy9lBI/BCXm+2Tuvt39YmdHwS5unDQmxZOYe8F5Y= -github.com/aws/aws-sdk-go-v2/credentials v1.1.1/go.mod h1:mM2iIjwl7LULWtS6JCACyInboHirisUUdkBPoTHMOUo= -github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.0.2/go.mod h1:3hGg3PpiEjHnrkrlasTfxFqUsZ2GCk/fMUn4CbKgSkM= -github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.0.2/go.mod h1:45MfaXZ0cNbeuT0KQ1XJylq8A6+OpVV2E5kvY/Kq+u8= -github.com/aws/aws-sdk-go-v2/service/route53 v1.1.1/go.mod h1:rLiOUrPLW/Er5kRcQ7NkwbjlijluLsrIbu/iyl35RO4= -github.com/aws/aws-sdk-go-v2/service/sso v1.1.1/go.mod h1:SuZJxklHxLAXgLTc1iFXbEWkXs7QRTQpCLGaKIprQW0= -github.com/aws/aws-sdk-go-v2/service/sts v1.1.1/go.mod h1:Wi0EBZwiz/K44YliU0EKxqTCJGUfYTWXrrBwkq736bM= -github.com/aws/smithy-go v1.1.0/go.mod h1:EzMw8dbp/YJL4A5/sbhGddag+NPT7q084agLbB9LgIw= +github.com/benbjohnson/clock v1.1.0/go.mod h1:J11/hYXuz8f4ySSvYwY0FKfm+ezbsZBKZxNJlLklBHA= github.com/beorn7/perks v0.0.0-20180321164747-3a771d992973/go.mod h1:Dwedo/Wpr24TaqPxmxbtue+5NUziq4I4S80YR8gNf3Q= github.com/beorn7/perks v1.0.0/go.mod h1:KWe93zE9D1o94FZ5RNwFwVgaQK1VOXiVxmqh+CedLV8= github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM= @@ -283,37 +270,16 @@ github.com/bgentry/go-netrc v0.0.0-20140422174119-9fd32a8b3d3d/go.mod h1:6QX/PXZ github.com/bgentry/speakeasy v0.1.0/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kBD4zp0CCIs= github.com/bgentry/speakeasy v0.1.1-0.20220910012023-760eaf8b6816 h1:41iFGWnSlI2gVpmOtVTJZNodLdLQLn/KsJqFvXwnd/s= github.com/bgentry/speakeasy v0.1.1-0.20220910012023-760eaf8b6816/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kBD4zp0CCIs= -github.com/bmizerany/pat v0.0.0-20170815010413-6226ea591a40/go.mod h1:8rLXio+WjiTceGBHIoTvn60HIbs7Hm7bcHjyrSqYB9c= -github.com/boltdb/bolt v1.3.1/go.mod h1:clJnj/oiGkjum5o1McbSZDSLxVThjynRyGBgiAx27Ps= -github.com/btcsuite/btcd v0.0.0-20190315201642-aa6e0f35703c/go.mod h1:DrZx5ec/dmnfpw9KyYoQyYo7d0KEvTkk/5M/vbZjAr8= -github.com/btcsuite/btcd v0.20.1-beta/go.mod h1:wVuoA8VJLEcwgqHBwHmzLRazpKxTv13Px/pDuV7OomQ= -github.com/btcsuite/btcd v0.21.0-beta.0.20201114000516-e9c7a5ac6401/go.mod h1:Sv4JPQ3/M+teHz9Bo5jBpkNcP0x6r7rdihlNL/7tTAs= -github.com/btcsuite/btcd v0.22.1 h1:CnwP9LM/M9xuRrGSCGeMVs9iv09uMqwsVX7EeIpgV2c= -github.com/btcsuite/btcd v0.22.1/go.mod h1:wqgTSL29+50LRkmOVknEdmt8ZojIzhuWvgu/iptuN7Y= -github.com/btcsuite/btcd/btcec/v2 v2.1.2/go.mod h1:ctjw4H1kknNJmRN4iP1R7bTQ+v3GJkZBd6mui8ZsAZE= +github.com/bits-and-blooms/bitset v1.8.0 h1:FD+XqgOZDUxxZ8hzoBFuV9+cGWY9CslN6d5MS5JVb4c= +github.com/bits-and-blooms/bitset v1.8.0/go.mod h1:7hO7Gc7Pp1vODcmWvKMRA9BNmbv6a/7QIWpPxHddWR8= github.com/btcsuite/btcd/btcec/v2 v2.3.2 h1:5n0X6hX0Zk+6omWcihdYvdAlGf2DfasC0GMf7DClJ3U= github.com/btcsuite/btcd/btcec/v2 v2.3.2/go.mod h1:zYzJ8etWJQIv1Ogk7OzpWjowwOdXY1W/17j2MW85J04= -github.com/btcsuite/btcd/btcutil v1.1.2 h1:XLMbX8JQEiwMcYft2EGi8zPUkoa0abKIU6/BJSRsjzQ= -github.com/btcsuite/btcd/btcutil v1.1.2/go.mod h1:UR7dsSJzJUfMmFiiLlIrMq1lS9jh9EdCV7FStZSnpi0= -github.com/btcsuite/btcd/chaincfg/chainhash v1.0.0/go.mod h1:7SFka0XMvUgj3hfZtydOrQY2mwhPclbT2snogU7SQQc= +github.com/btcsuite/btcd/btcutil v1.1.3 h1:xfbtw8lwpp0G6NwSHb+UE67ryTFHJAiNuipusjXSohQ= +github.com/btcsuite/btcd/btcutil v1.1.3/go.mod h1:UR7dsSJzJUfMmFiiLlIrMq1lS9jh9EdCV7FStZSnpi0= github.com/btcsuite/btcd/chaincfg/chainhash v1.0.1 h1:q0rUy8C/TYNBQS1+CGKw68tLOFYSNEs0TFnxxnS9+4U= github.com/btcsuite/btcd/chaincfg/chainhash v1.0.1/go.mod h1:7SFka0XMvUgj3hfZtydOrQY2mwhPclbT2snogU7SQQc= -github.com/btcsuite/btclog v0.0.0-20170628155309-84c8d2346e9f/go.mod h1:TdznJufoqS23FtqVCzL0ZqgP5MqXbb4fg/WgDys70nA= -github.com/btcsuite/btcutil v0.0.0-20190207003914-4c204d697803/go.mod h1:+5NJ2+qvTyV9exUAL/rxXi3DcLg2Ts+ymUAY5y4NvMg= -github.com/btcsuite/btcutil v0.0.0-20190425235716-9e5f4b9a998d/go.mod h1:+5NJ2+qvTyV9exUAL/rxXi3DcLg2Ts+ymUAY5y4NvMg= -github.com/btcsuite/btcutil v1.0.2/go.mod h1:j9HUFwoQRsZL3V4n+qG+CUnEGHOarIxfC3Le2Yhbcts= -github.com/btcsuite/btcutil v1.0.3-0.20201208143702-a53e38424cce/go.mod h1:0DVlHczLPewLcPGEIeUEzfOJhqGPQ0mJJRDBtD307+o= -github.com/btcsuite/go-socks v0.0.0-20170105172521-4720035b7bfd/go.mod h1:HHNXQzUsZCxOoE+CPiyCTO6x34Zs86zZUiwtpXoGdtg= -github.com/btcsuite/goleveldb v0.0.0-20160330041536-7834afc9e8cd/go.mod h1:F+uVaaLLH7j4eDXPRvw78tMflu7Ie2bzYOH4Y8rRKBY= -github.com/btcsuite/goleveldb v1.0.0/go.mod h1:QiK9vBlgftBg6rWQIj6wFzbPfRjiykIEhBH4obrXJ/I= -github.com/btcsuite/snappy-go v0.0.0-20151229074030-0bdef8d06723/go.mod h1:8woku9dyThutzjeg+3xrA5iCpBRH8XEEg3lh6TiUghc= -github.com/btcsuite/snappy-go v1.0.0/go.mod h1:8woku9dyThutzjeg+3xrA5iCpBRH8XEEg3lh6TiUghc= -github.com/btcsuite/websocket v0.0.0-20150119174127-31079b680792/go.mod h1:ghJtEyQwv5/p4Mg4C0fgbePVuGr935/5ddU9Z3TmDRY= -github.com/btcsuite/winsvc v1.0.0/go.mod h1:jsenWakMcC0zFBFurPLEAyrnc/teJEM1O46fmI40EZs= -github.com/bufbuild/protocompile v0.4.0 h1:LbFKd2XowZvQ/kajzguUp2DC9UEIQhIq77fZZlaQsNA= -github.com/bufbuild/protocompile v0.4.0/go.mod h1:3v93+mbWn/v3xzN+31nwkJfrEpAUwp+BagBSZWx+TP8= -github.com/bwesterb/go-ristretto v1.2.0/go.mod h1:fUIoIZaG73pV5biE2Blr2xEzDoMj7NFEuV9ekS419A0= -github.com/c-bata/go-prompt v0.2.2/go.mod h1:VzqtzE2ksDBcdln8G7mk2RX9QyGjH+OVqOCSiVIqS34= +github.com/bufbuild/protocompile v0.6.0 h1:Uu7WiSQ6Yj9DbkdnOe7U4mNKp58y9WDMKDn28/ZlunY= +github.com/bufbuild/protocompile v0.6.0/go.mod h1:YNP35qEYoYGme7QMtz5SBCoN4kL4g12jTtjuzRNdjpE= github.com/casbin/casbin/v2 v2.1.2/go.mod h1:YcPU1XXisHhLzuxH9coDNf2FbKpjGlbCg3n9yuLkIJQ= github.com/cenkalti/backoff v2.2.1+incompatible h1:tNowT99t7UNflLxfYYSlKYsBpXdEet03Pg2g16Swow4= github.com/cenkalti/backoff v2.2.1+incompatible/go.mod h1:90ReRw6GdpyfrHakVjL/QHaoyV4aDUVVkXQJJJ3NXXM= @@ -321,11 +287,10 @@ github.com/cenkalti/backoff/v4 v4.1.1/go.mod h1:scbssz8iZGpm3xbr14ovlUdkxfGXNInq github.com/cenkalti/backoff/v4 v4.1.3 h1:cFAlzYUlVYDysBEH2T5hyJZMh3+5+WCBvSnK6Q8UtC4= github.com/cenkalti/backoff/v4 v4.1.3/go.mod h1:scbssz8iZGpm3xbr14ovlUdkxfGXNInqkPWOWmG2CLw= github.com/census-instrumentation/opencensus-proto v0.2.1/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU= -github.com/cespare/cp v0.1.0/go.mod h1:SOGHArjBr4JWaSDEVpWpo/hNg6RoKrls6Oh40hiwW+s= github.com/cespare/xxhash v1.1.0/go.mod h1:XrSqR1VqqWfGrhpAt58auRo0WTKS1nRRg3ghfAqPWnc= github.com/cespare/xxhash/v2 v2.1.1/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= -github.com/cespare/xxhash/v2 v2.2.0 h1:DC2CZ1Ep5Y4k3ZQ899DldepgrayRUGE6BBZ/cd9Cj44= -github.com/cespare/xxhash/v2 v2.2.0/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= +github.com/cespare/xxhash/v2 v2.3.0 h1:UL815xU9SqsFlibzuggzjXhog7bL6oX9BbNZnL2UFvs= +github.com/cespare/xxhash/v2 v2.3.0/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= github.com/cheggaaa/pb v1.0.27/go.mod h1:pQciLPpbU0oxA0h+VJYYLxO+XeDQb5pZijXscXHm81s= github.com/chzyer/logex v1.1.10/go.mod h1:+Ywpsq7O8HXn0nuIou7OrIPyXbp3wmkHB+jjWRnGsAI= github.com/chzyer/logex v1.2.1 h1:XHDu3E6q+gdHgsdTPH6ImJMIp436vR6MPtH8gP05QzM= @@ -340,7 +305,6 @@ github.com/circonus-labs/circonus-gometrics v2.3.1+incompatible/go.mod h1:nmEj6D github.com/circonus-labs/circonusllhist v0.1.3/go.mod h1:kMXHVDlOchFAehlya5ePtbp5jckzBHf4XRpQvBOLI+I= github.com/clbanning/x2j v0.0.0-20191024224557-825249438eec/go.mod h1:jMjuTZXRI4dUb/I5gc9Hdhagfvm9+RyrPryS/auMzxE= github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw= -github.com/cloudflare/cloudflare-go v0.14.0/go.mod h1:EnwdgGMaFOruiPZRFSgn+TsQ3hQ7C/YWzIGLeu5c304= github.com/cncf/udpa/go v0.0.0-20191209042840-269d4d468f6f/go.mod h1:M8M6+tZqaGXZJjfX53e64911xZQV5JYwmTeXPW+k8Sc= github.com/cncf/udpa/go v0.0.0-20200629203442-efcf912fb354/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk= github.com/cncf/udpa/go v0.0.0-20201120205902-5459f2c99403/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk= @@ -368,101 +332,75 @@ github.com/cockroachdb/redact v1.1.5/go.mod h1:BVNblN9mBWFyMyqK1k3AAiSxhvhfK2oOZ github.com/cockroachdb/tokenbucket v0.0.0-20230807174530-cc333fc44b06 h1:zuQyyAKVxetITBuuhv3BI9cMrmStnpT18zmgmTxunpo= github.com/cockroachdb/tokenbucket v0.0.0-20230807174530-cc333fc44b06/go.mod h1:7nc4anLGjupUW/PeY5qiNYsdNXj7zopG+eqsS7To5IQ= github.com/codahale/hdrhistogram v0.0.0-20161010025455-3a0bb77429bd/go.mod h1:sE/e/2PUdi/liOCUjSTXgM1o87ZssimdTWN964YiIeI= -github.com/coinbase/kryptology v1.8.0/go.mod h1:RYXOAPdzOGUe3qlSFkMGn58i3xUA8hmxYHksuq+8ciI= -github.com/coinbase/rosetta-sdk-go v0.7.9 h1:lqllBjMnazTjIqYrOGv8h8jxjg9+hJazIGZr9ZvoCcA= -github.com/coinbase/rosetta-sdk-go v0.7.9/go.mod h1:0/knutI7XGVqXmmH4OQD8OckFrbQ8yMsUZTG7FXCR2M= -github.com/cometbft/cometbft v0.37.5 h1:/U/TlgMh4NdnXNo+YU9T2NMCWyhXNDF34Mx582jlvq0= -github.com/cometbft/cometbft v0.37.5/go.mod h1:QC+mU0lBhKn8r9qvmnq53Dmf3DWBt4VtkcKw2C81wxY= +github.com/cometbft/cometbft v0.38.7 h1:ULhIOJ9+LgSy6nLekhq9ae3juX3NnQUMMPyVdhZV6Hk= +github.com/cometbft/cometbft v0.38.7/go.mod h1:HIyf811dFMI73IE0F7RrnY/Fr+d1+HuJAgtkEpQjCMY= github.com/cometbft/cometbft-db v0.12.1-0.20240508134034-e9d8487735c2 h1:+Qhcg2rq2KgdAaPdlU3fTuFc9zw35KM6+Q+HyfNMq+w= github.com/cometbft/cometbft-db v0.12.1-0.20240508134034-e9d8487735c2/go.mod h1:aX2NbCrjNVd2ZajYxt1BsiFf/Z+TQ2MN0VxdicheYuw= -github.com/confio/ics23/go v0.9.0 h1:cWs+wdbS2KRPZezoaaj+qBleXgUk5WOQFMP3CQFGTr4= -github.com/confio/ics23/go v0.9.0/go.mod h1:4LPZ2NYqnYIVRklaozjNR1FScgDJ2s5Xrp+e/mYVRak= -github.com/consensys/bavard v0.1.8-0.20210406032232-f3452dc9b572/go.mod h1:Bpd0/3mZuaj6Sj+PqrmIquiOKy397AKGThQPaGzNXAQ= -github.com/consensys/bavard v0.1.8-0.20210915155054-088da2f7f54a/go.mod h1:9ItSMtA/dXMAiL7BG6bqW2m3NdSEObYWoH223nGHukI= -github.com/consensys/gnark-crypto v0.4.1-0.20210426202927-39ac3d4b3f1f/go.mod h1:815PAHg3wvysy0SyIqanF8gZ0Y1wjk/hrDHD/iT88+Q= -github.com/consensys/gnark-crypto v0.5.3/go.mod h1:hOdPlWQV1gDLp7faZVeg8Y0iEPFaOUnCc4XeCCk96p0= github.com/containerd/continuity v0.3.0 h1:nisirsYROK15TAMVukJOUyGJjz4BNQJBVsNvAXZJ/eg= github.com/containerd/continuity v0.3.0/go.mod h1:wJEAIwKOm/pBZuBd0JmeTvnLquTB1Ag8espWhkykbPM= -github.com/coreos/etcd v3.3.10+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE= -github.com/coreos/go-etcd v2.0.0+incompatible/go.mod h1:Jez6KQU2B/sWsbdaef3ED8NzMklzPG4d5KIOhIy30Tk= github.com/coreos/go-semver v0.2.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk= github.com/coreos/go-systemd v0.0.0-20180511133405-39ca1b05acc7/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4= github.com/coreos/go-systemd/v22 v22.5.0/go.mod h1:Y58oyj3AT4RCenI/lSvhwexgC+NSVTIJ3seZv2GcEnc= github.com/coreos/pkg v0.0.0-20160727233714-3ac0863d7acf/go.mod h1:E3G3o1h8I7cfcXa63jLwjI0eiQQMgzzUDFVpN/nH/eA= github.com/cosmos/btcutil v1.0.5 h1:t+ZFcX77LpKtDBhjucvnOH8C2l2ioGsBNEQ3jef8xFk= github.com/cosmos/btcutil v1.0.5/go.mod h1:IyB7iuqZMJlthe2tkIFL33xPyzbFYP0XVdS8P5lUPis= +github.com/cosmos/cosmos-db v1.0.2 h1:hwMjozuY1OlJs/uh6vddqnk9j7VamLv+0DBlbEXbAKs= +github.com/cosmos/cosmos-db v1.0.2/go.mod h1:Z8IXcFJ9PqKK6BIsVOB3QXtkKoqUOp1vRvPT39kOXEA= github.com/cosmos/cosmos-proto v1.0.0-beta.5 h1:eNcayDLpip+zVLRLYafhzLvQlSmyab+RC5W7ZfmxJLA= github.com/cosmos/cosmos-proto v1.0.0-beta.5/go.mod h1:hQGLpiIUloJBMdQMMWb/4wRApmI9hjHH05nefC0Ojec= -github.com/cosmos/cosmos-sdk v0.47.11 h1:0Qx7eORw0RJqPv+mvDuU8NQ1LV3nJJKJnPoYblWHolc= -github.com/cosmos/cosmos-sdk v0.47.11/go.mod h1:ADjORYzUQqQv/FxDi0H0K5gW/rAk1CiDR3ZKsExfJV0= -github.com/cosmos/go-bip39 v0.0.0-20180819234021-555e2067c45d/go.mod h1:tSxLoYXyBmiFeKpvmq4dzayMdCjCnu8uqmCysIGBT2Y= +github.com/cosmos/cosmos-sdk v0.50.7 h1:LsBGKxifENR/DN4E1RZaitsyL93HU44x0p8EnMHp4V4= +github.com/cosmos/cosmos-sdk v0.50.7/go.mod h1:84xDDJEHttRT7NDGwBaUOLVOMN0JNE9x7NbsYIxXs1s= github.com/cosmos/go-bip39 v1.0.0 h1:pcomnQdrdH22njcAatO0yWojsUnCO3y2tNoV1cb6hHY= github.com/cosmos/go-bip39 v1.0.0/go.mod h1:RNJv0H/pOIVgxw6KS7QeX2a0Uo0aKUlfhZ4xuwvCdJw= github.com/cosmos/gogogateway v1.2.0 h1:Ae/OivNhp8DqBi/sh2A8a1D0y638GpL3tkmLQAiKxTE= github.com/cosmos/gogogateway v1.2.0/go.mod h1:iQpLkGWxYcnCdz5iAdLcRBSw3h7NXeOkZ4GUkT+tbFI= github.com/cosmos/gogoproto v1.4.2/go.mod h1:cLxOsn1ljAHSV527CHOtaIP91kK6cCrZETRBrkzItWU= -github.com/cosmos/gogoproto v1.4.10 h1:QH/yT8X+c0F4ZDacDv3z+xE3WU1P1Z3wQoLMBRJoKuI= -github.com/cosmos/gogoproto v1.4.10/go.mod h1:3aAZzeRWpAwr+SS/LLkICX2/kDFyaYVzckBDzygIxek= -github.com/cosmos/iavl v0.20.1 h1:rM1kqeG3/HBT85vsZdoSNsehciqUQPWrR4BYmqE2+zg= -github.com/cosmos/iavl v0.20.1/go.mod h1:WO7FyvaZJoH65+HFOsDir7xU9FWk2w9cHXNW1XHcl7A= -github.com/cosmos/ibc-go/v7 v7.4.0 h1:8FqYMptvksgMvlbN4UW9jFxTXzsPyfAzEZurujXac8M= -github.com/cosmos/ibc-go/v7 v7.4.0/go.mod h1:L/KaEhzV5TGUCTfGysVgMBQtl5Dm7hHitfpk+GIeoAo= +github.com/cosmos/gogoproto v1.4.12 h1:vB6Lbe/rtnYGjQuFxkPiPYiCybqFT8QvLipDZP8JpFE= +github.com/cosmos/gogoproto v1.4.12/go.mod h1:LnZob1bXRdUoqMMtwYlcR3wjiElmlC+FkjaZRv1/eLY= +github.com/cosmos/iavl v1.2.0 h1:kVxTmjTh4k0Dh1VNL046v6BXqKziqMDzxo93oh3kOfM= +github.com/cosmos/iavl v1.2.0/go.mod h1:HidWWLVAtODJqFD6Hbne2Y0q3SdxByJepHUOeoH4LiI= +github.com/cosmos/ibc-go/modules/capability v1.0.0 h1:r/l++byFtn7jHYa09zlAdSeevo8ci1mVZNO9+V0xsLE= +github.com/cosmos/ibc-go/modules/capability v1.0.0/go.mod h1:D81ZxzjZAe0ZO5ambnvn1qedsFQ8lOwtqicG6liLBco= +github.com/cosmos/ibc-go/v8 v8.2.1 h1:MTsnZZjxvGD4Fv5pYyx5UkELafSX0rlPt6IfsE2BpTQ= +github.com/cosmos/ibc-go/v8 v8.2.1/go.mod h1:wj3qx75iC/XNnsMqbPDCIGs0G6Y3E/lo3bdqCyoCy+8= github.com/cosmos/ics23/go v0.10.0 h1:iXqLLgp2Lp+EdpIuwXTYIQU+AiHj9mOC2X9ab++bZDM= github.com/cosmos/ics23/go v0.10.0/go.mod h1:ZfJSmng/TBNTBkFemHHHj5YY7VAU/MBU980F4VU1NG0= -github.com/cosmos/ledger-cosmos-go v0.12.4 h1:drvWt+GJP7Aiw550yeb3ON/zsrgW0jgh5saFCr7pDnw= -github.com/cosmos/ledger-cosmos-go v0.12.4/go.mod h1:fjfVWRf++Xkygt9wzCsjEBdjcf7wiiY35fv3ctT+k4M= -github.com/cosmos/rosetta-sdk-go v0.10.0 h1:E5RhTruuoA7KTIXUcMicL76cffyeoyvNybzUGSKFTcM= -github.com/cosmos/rosetta-sdk-go v0.10.0/go.mod h1:SImAZkb96YbwvoRkzSMQB6noNJXFgWl/ENIznEoYQI4= -github.com/cpuguy83/go-md2man v1.0.10/go.mod h1:SmD6nW6nTyfqj6ABTjUi3V3JVMnlJmwcJI5acqYI6dE= +github.com/cosmos/keyring v1.2.0 h1:8C1lBP9xhImmIabyXW4c3vFjjLiBdGCmfLUfeZlV1Yo= +github.com/cosmos/keyring v1.2.0/go.mod h1:fc+wB5KTk9wQ9sDx0kFXB3A0MaeGHM9AwRStKOQ5vOA= +github.com/cosmos/ledger-cosmos-go v0.13.3 h1:7ehuBGuyIytsXbd4MP43mLeoN2LTOEnk5nvue4rK+yM= +github.com/cosmos/ledger-cosmos-go v0.13.3/go.mod h1:HENcEP+VtahZFw38HZ3+LS3Iv5XV6svsnkk9vdJtLr8= github.com/cpuguy83/go-md2man/v2 v2.0.0-20190314233015-f79a8a8ca69d/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU= github.com/cpuguy83/go-md2man/v2 v2.0.3/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= -github.com/creachadair/taskgroup v0.4.2 h1:jsBLdAJE42asreGss2xZGZ8fJra7WtwnHWeJFxv2Li8= -github.com/creachadair/taskgroup v0.4.2/go.mod h1:qiXUOSrbwAY3u0JPGTzObbE3yf9hcXHDKBZ2ZjpCbgM= +github.com/creachadair/atomicfile v0.3.1 h1:yQORkHjSYySh/tv5th1dkKcn02NEW5JleB84sjt+W4Q= +github.com/creachadair/atomicfile v0.3.1/go.mod h1:mwfrkRxFKwpNAflYZzytbSwxvbK6fdGRRlp0KEQc0qU= +github.com/creachadair/tomledit v0.0.24 h1:5Xjr25R2esu1rKCbQEmjZYlrhFkDspoAbAKb6QKQDhQ= +github.com/creachadair/tomledit v0.0.24/go.mod h1:9qHbShRWQzSCcn617cMzg4eab1vbLCOjOshAWSzWr8U= github.com/creack/pty v1.1.7/go.mod h1:lj5s0c3V2DBrqTV7llrYr5NG6My20zk30Fl46Y7DoTY= github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= -github.com/cyberdelia/templates v0.0.0-20141128023046-ca7fffd4298c/go.mod h1:GyV+0YP4qX0UQ7r2MoYZ+AvYDp12OF5yg4q8rGnyNh4= github.com/danieljoos/wincred v1.1.2 h1:QLdCxFs1/Yl4zduvBdcHB8goaYk9RARS2SgLLRuAyr0= github.com/danieljoos/wincred v1.1.2/go.mod h1:GijpziifJoIBfYh+S7BbkdUTU4LfM+QnGqR5Vl2tAx0= -github.com/dave/jennifer v1.2.0/go.mod h1:fIb+770HOpJ2fmN9EPPKOqm1vMGhB+TwXKMZhrIygKg= -github.com/davecgh/go-spew v0.0.0-20171005155431-ecdeabc65495/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc h1:U9qPSI2PIWSS1VwoXQT9A3Wy9MM3WgvqSxFWenqJduM= github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= -github.com/deckarep/golang-set v1.8.0/go.mod h1:5nI87KwE7wgsBU1F4GKAw2Qod7p5kyS383rP6+o6qqo= -github.com/decred/dcrd/crypto/blake256 v1.0.0 h1:/8DMNYp9SGi5f0w7uCm6d6M4OU2rGFK09Y2A4Xv7EE0= -github.com/decred/dcrd/crypto/blake256 v1.0.0/go.mod h1:sQl2p6Y26YV+ZOcSTP6thNdn47hh8kt6rqSlvmrXFAc= -github.com/decred/dcrd/dcrec/secp256k1/v4 v4.0.1/go.mod h1:hyedUtir6IdtD/7lIxGeCxkaw7y45JueMRL4DIyJDKs= -github.com/decred/dcrd/dcrec/secp256k1/v4 v4.1.0 h1:HbphB4TFFXpv7MNrT52FGrrgVXF1owhMVTHFZIlnvd4= -github.com/decred/dcrd/dcrec/secp256k1/v4 v4.1.0/go.mod h1:DZGJHZMqrU4JJqFAWUS2UO1+lbSKsdiOoYi9Zzey7Fc= -github.com/decred/dcrd/lru v1.0.0/go.mod h1:mxKOwFd7lFjN2GZYsiz/ecgqR6kkYAl+0pz0tEMk218= -github.com/deepmap/oapi-codegen v1.6.0/go.mod h1:ryDa9AgbELGeB+YEXE1dR53yAjHwFvE9iAUlWl9Al3M= -github.com/deepmap/oapi-codegen v1.8.2/go.mod h1:YLgSKSDv/bZQB7N4ws6luhozi3cEdRktEqrX88CvjIw= +github.com/decred/dcrd/crypto/blake256 v1.0.1 h1:7PltbUIQB7u/FfZ39+DGa/ShuMyJ5ilcvdfma9wOH6Y= +github.com/decred/dcrd/crypto/blake256 v1.0.1/go.mod h1:2OfgNZ5wDpcsFmHmCK5gZTPcCXqlm2ArzUIkw9czNJo= +github.com/decred/dcrd/dcrec/secp256k1/v4 v4.2.0 h1:8UrgZ3GkP4i/CLijOJx79Yu+etlyjdBU4sfcs2WYQMs= +github.com/decred/dcrd/dcrec/secp256k1/v4 v4.2.0/go.mod h1:v57UDF4pDQJcEfFUCRop3lJL149eHGSe9Jvczhzjo/0= github.com/desertbit/timer v0.0.0-20180107155436-c41aec40b27f h1:U5y3Y5UE0w7amNe7Z5G/twsBW0KEalRQXZzf8ufSh9I= github.com/desertbit/timer v0.0.0-20180107155436-c41aec40b27f/go.mod h1:xH/i4TFMt8koVQZ6WFms69WAsDWr2XsYL3Hkl7jkoLE= -github.com/dgraph-io/badger/v2 v2.2007.4/go.mod h1:vSw/ax2qojzbN6eXHIx6KPKtCSHJN/Uz0X0VPruTIhk= github.com/dgraph-io/badger/v4 v4.2.0 h1:kJrlajbXXL9DFTNuhhu9yCx7JJa4qpYWxtE8BzuWsEs= github.com/dgraph-io/badger/v4 v4.2.0/go.mod h1:qfCqhPoWDFJRx1gp5QwwyGo8xk1lbHUxvK9nK0OGAak= -github.com/dgraph-io/ristretto v0.0.3-0.20200630154024-f66de99634de/go.mod h1:KPxhHT9ZxKefz+PCeOGsrHpl1qZ7i70dGTu2u+Ahh6E= -github.com/dgraph-io/ristretto v0.0.3/go.mod h1:KPxhHT9ZxKefz+PCeOGsrHpl1qZ7i70dGTu2u+Ahh6E= github.com/dgraph-io/ristretto v0.1.1 h1:6CWw5tJNgpegArSHpNHJKldNeq03FQCwYvfMVWajOK8= github.com/dgraph-io/ristretto v0.1.1/go.mod h1:S1GPSBCYCIhmVNfcth17y2zZtQT6wzkzgwUve0VDWWA= github.com/dgrijalva/jwt-go v3.2.0+incompatible/go.mod h1:E3ru+11k8xSBh+hMPgOLZmtrrCbhqsmaPHjLKYnJCaQ= -github.com/dgryski/go-bitstream v0.0.0-20180413035011-3522498ce2c8/go.mod h1:VMaSuZ+SZcx/wljOQKvp5srsbCiKDEb6K2wC4+PiBmQ= github.com/dgryski/go-farm v0.0.0-20190423205320-6a90982ecee2/go.mod h1:SqUrOPUnsFjfmXRMNPybcSiG0BgUW2AuFH8PAnS2iTw= github.com/dgryski/go-farm v0.0.0-20200201041132-a6ae2369ad13 h1:fAjc9m62+UWV/WAFKLNi6ZS0675eEUC9y3AlwSbQu1Y= github.com/dgryski/go-farm v0.0.0-20200201041132-a6ae2369ad13/go.mod h1:SqUrOPUnsFjfmXRMNPybcSiG0BgUW2AuFH8PAnS2iTw= -github.com/dgryski/go-sip13 v0.0.0-20181026042036-e10d5fee7954/go.mod h1:vAd38F8PWV+bWy6jNmig1y/TA+kYO4g3RSRF0IAv0no= -github.com/dlclark/regexp2 v1.4.1-0.20201116162257-a2a8dda75c91/go.mod h1:2pZnwuY/m+8K6iRw6wQdMtk+rH5tNGR1i55kozfMjCc= -github.com/dnaeon/go-vcr v1.1.0/go.mod h1:M7tiix8f0r6mKKJ3Yq/kqU1OYf3MnfmBWVbPx/yU9ko= -github.com/dnaeon/go-vcr v1.2.0/go.mod h1:R4UdLID7HZT3taECzJs4YgbbH6PIGXB6W/sc5OLb6RQ= -github.com/docker/docker v1.4.2-0.20180625184442-8e610b2b55bf/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk= github.com/docker/go-connections v0.4.0 h1:El9xVISelRB7BuFusrZozjnkIM5YnzCViNKohAFqRJQ= github.com/docker/go-connections v0.4.0/go.mod h1:Gbd7IOopHjR8Iph03tsViu4nIes5XhDvyHbTtUxmeec= github.com/docker/go-units v0.5.0 h1:69rxXcBk27SvSaaxTtLh/8llcHD8vYHT7WSdRZ/jvr4= github.com/docker/go-units v0.5.0/go.mod h1:fgPhTUdO+D/Jk86RDLlptpiXQzgHJF7gydDDbaIK4Dk= -github.com/dop251/goja v0.0.0-20211011172007-d99e4b8cbf48/go.mod h1:R9ET47fwRVRPZnOGvHxxhuZcbrMCuiqOz3Rlrh4KSnk= -github.com/dop251/goja_nodejs v0.0.0-20210225215109-d91c329300e7/go.mod h1:hn7BA7c8pLvoGndExHudxTDKZ84Pyvv+90pbBjbTz0Y= github.com/dustin/go-humanize v0.0.0-20171111073723-bb3d318650d4/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk= github.com/dustin/go-humanize v1.0.0/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk= github.com/dustin/go-humanize v1.0.1 h1:GzkhY7T5VNhEkwH0PVJgjz+fX1rhBrR7pRT3mDkpeCY= @@ -472,8 +410,9 @@ github.com/dvsekhvalnov/jose2go v1.6.0/go.mod h1:QsHjhyTlD/lAVqn/NSbVZmSCGeDehTB github.com/eapache/go-resiliency v1.1.0/go.mod h1:kFI+JgMyC7bLPUVY133qvEBtVayf5mFgVsvEsIPBvNs= github.com/eapache/go-xerial-snappy v0.0.0-20180814174437-776d5712da21/go.mod h1:+020luEh2TKB4/GOp8oxxtq0Daoen/Cii55CzbTV6DU= github.com/eapache/queue v1.1.0/go.mod h1:6eCeP0CKFpHLu8blIFXhExK/dRa7WDZfr6jVFPTqq+I= -github.com/eclipse/paho.mqtt.golang v1.2.0/go.mod h1:H9keYFcgq3Qr5OUJm/JZI/i6U7joQ8SYLhZwfeOo6Ts= github.com/edsrzf/mmap-go v1.0.0/go.mod h1:YO35OhQPt3KJa3ryjFM5Bs14WD66h8eGKpfaBNrHW5M= +github.com/emicklei/dot v1.6.1 h1:ujpDlBkkwgWUY+qPId5IwapRW/xEoligRSYjioR6DFI= +github.com/emicklei/dot v1.6.1/go.mod h1:DeV7GvQtIw4h2u73RKBkkFdvVAz0D9fzeJrgPW6gy/s= github.com/envoyproxy/go-control-plane v0.6.9/go.mod h1:SBwIajubJHhxtWwsL9s8ss4safvEdbitLhGGK48rN6g= github.com/envoyproxy/go-control-plane v0.9.0/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= github.com/envoyproxy/go-control-plane v0.9.1-0.20191026205805-5f8ba28d4473/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= @@ -487,14 +426,12 @@ github.com/envoyproxy/go-control-plane v0.10.2-0.20220325020618-49ff273808a1/go. github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c= github.com/envoyproxy/protoc-gen-validate v1.0.4 h1:gVPz/FMfvh57HdSJQyvBtF00j8JU4zdyUgIUNhlgg0A= github.com/envoyproxy/protoc-gen-validate v1.0.4/go.mod h1:qys6tmnRsYrQqIhm2bvKZH4Blx/1gTIZ2UKVY1M+Yew= -github.com/ethereum/go-ethereum v1.10.17/go.mod h1:Lt5WzjM07XlXc95YzrhosmR4J9Ahd6X2wyEV2SvGhk0= github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5KwzbycvMj4= github.com/fatih/color v1.13.0/go.mod h1:kLAiJbzzSOZDVNGyDpeOxJ47H46qBXwg5ILebYFFOfk= -github.com/felixge/httpsnoop v1.0.1/go.mod h1:m8KPJKqk1gH5J9DgRY2ASl2lWCfGKXixSwevea8zH2U= +github.com/fatih/color v1.15.0 h1:kOqh6YHBtK8aywxGerMG2Eq3H6Qgoqeo13Bk2Mv/nBs= +github.com/fatih/color v1.15.0/go.mod h1:0h5ZqXfHYED7Bhv2ZJamyIOUej9KtShiJESRwBDUSsw= github.com/felixge/httpsnoop v1.0.4 h1:NFTV2Zj1bL4mc9sqWACXbQFVBBg2W3GPvqp8/ESS2Wg= github.com/felixge/httpsnoop v1.0.4/go.mod h1:m8KPJKqk1gH5J9DgRY2ASl2lWCfGKXixSwevea8zH2U= -github.com/fjl/memsize v0.0.0-20190710130421-bcb5799ab5e5/go.mod h1:VvhXpOYNQvB+uIk2RvXzuaQtkQJzzIx6lSBe1xv7hi0= -github.com/fogleman/gg v1.2.1-0.20190220221249-0403632d5b90/go.mod h1:R/bRT+9gY/C5z7JzPU0zXsXHKM4/ayA+zqcVNZzPa1k= github.com/fortytw2/leaktest v1.3.0 h1:u8491cBMTQ8ft8aeV+adlcytMZylmA5nnwwkRZjI8vw= github.com/fortytw2/leaktest v1.3.0/go.mod h1:jDsjWgpAGjm2CA7WthBh/CdZYEPF31XHquHwclZch5g= github.com/franela/goblin v0.0.0-20200105215937-c9ffbefa60db/go.mod h1:7dvUGVsVBjqR7JHJk0brhHOZYGmfBYOrK0ZhYMEtBr4= @@ -505,11 +442,8 @@ github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMo github.com/fsnotify/fsnotify v1.4.9/go.mod h1:znqG4EE+3YCdAaPaxE2ZRY/06pZUdp0tY4IgpuI1SZQ= github.com/fsnotify/fsnotify v1.7.0 h1:8JEhPFa5W2WU7YfeZzPNqzMP6Lwt7L2715Ggo0nosvA= github.com/fsnotify/fsnotify v1.7.0/go.mod h1:40Bi/Hjc2AVfZrqy+aj+yEI+/bRxZnMJyTJwOpGvigM= -github.com/gballet/go-libpcsclite v0.0.0-20190607065134-2772fd86a8ff/go.mod h1:x7DCsMOv1taUwEWCzT4cmDeAkigA5/QCwUodaVOe8Ww= -github.com/getkin/kin-openapi v0.53.0/go.mod h1:7Yn5whZr5kJi6t+kShccXS8ae1APpYTW6yheSwk8Yi4= -github.com/getkin/kin-openapi v0.61.0/go.mod h1:7Yn5whZr5kJi6t+kShccXS8ae1APpYTW6yheSwk8Yi4= -github.com/getsentry/sentry-go v0.23.0 h1:dn+QRCeJv4pPt9OjVXiMcGIBIefaTJPw/h0bZWO05nE= -github.com/getsentry/sentry-go v0.23.0/go.mod h1:lc76E2QywIyW8WuBnwl8Lc4bkmQH4+w1gwTf25trprY= +github.com/getsentry/sentry-go v0.27.0 h1:Pv98CIbtB3LkMWmXi4Joa5OOcwbmnX88sF5qbK3r3Ps= +github.com/getsentry/sentry-go v0.27.0/go.mod h1:lc76E2QywIyW8WuBnwl8Lc4bkmQH4+w1gwTf25trprY= github.com/ghodss/yaml v1.0.0 h1:wQHKEahhL6wmXdzwWG11gIVCkOv05bNOh+Rxn0yngAk= github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04= github.com/gin-contrib/sse v0.1.0 h1:Y/yl/+YNO8GZSjAhjMsSuLt29uWRFHdHYUb5lYOV9qE= @@ -517,16 +451,17 @@ github.com/gin-contrib/sse v0.1.0/go.mod h1:RHrZQHXnP2xjPF+u1gW/2HnVO7nvIa9PG3Gm github.com/gin-gonic/gin v1.6.3/go.mod h1:75u5sXoLsGZoRN5Sgbi1eraJ4GU3++wFwWzhwvtwp4M= github.com/gin-gonic/gin v1.8.1 h1:4+fr/el88TOO3ewCmQr8cx/CtZ/umlIRIs5M4NTNjf8= github.com/gin-gonic/gin v1.8.1/go.mod h1:ji8BvRH1azfM+SYow9zQ6SZMvR8qOMZHmsCuWR9tTTk= -github.com/glycerine/go-unsnap-stream v0.0.0-20180323001048-9f0cb55181dd/go.mod h1:/20jfyN9Y5QPEAprSgKAUr+glWDY39ZiUEAYOEv5dsE= -github.com/glycerine/goconvey v0.0.0-20190410193231-58a59202ab31/go.mod h1:Ogl1Tioa0aV7gstGFO7KhffUsb9M4ydbEbbxpcEDc24= -github.com/go-chi/chi/v5 v5.0.0/go.mod h1:BBug9lr0cqtdAhsu6R4AAdvufI0/XBzAQSsUqJpoZOs= github.com/go-errors/errors v1.4.2 h1:J6MZopCL4uSllY1OfXM374weqZFFItUbrImctkmUxIA= github.com/go-errors/errors v1.4.2/go.mod h1:sIVyrIiJhuEF+Pj9Ebtd6P/rEYROXFi3BopGUQ5a5Og= +github.com/go-gl/glfw v0.0.0-20190409004039-e6da0acd62b1/go.mod h1:vR7hzQXu2zJy9AVAgeJqvqgH9Q5CA+iKCZ2gyEVpxRU= +github.com/go-gl/glfw/v3.3/glfw v0.0.0-20191125211704-12ad95a8df72/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8= +github.com/go-gl/glfw/v3.3/glfw v0.0.0-20200222043503-6f7a984d4dc4/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8= github.com/go-kit/kit v0.8.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as= github.com/go-kit/kit v0.9.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as= github.com/go-kit/kit v0.10.0/go.mod h1:xUsJbQ/Fp4kEt7AFgCuvyX4a71u8h9jB8tj/ORgOZ7o= github.com/go-kit/kit v0.12.0 h1:e4o3o3IsBfAKQh5Qbbiqyfu97Ku7jrO/JbohvztANh4= github.com/go-kit/kit v0.12.0/go.mod h1:lHd+EkCZPIwYItmGDDRdhinkzX2A1sj+M9biaEaizzs= +github.com/go-kit/log v0.1.0/go.mod h1:zbhenjAZHb184qTLMA9ZjW7ThYL0H2mk7Q6pNt4vbaY= github.com/go-kit/log v0.2.1 h1:MRVx0/zhvdseW+Gza6N9rVzU/IVzaeE1SFI4raAhmBU= github.com/go-kit/log v0.2.1/go.mod h1:NwTd00d/i8cPZ3xOwwiv2PO5MOcx78fFErGNcVmBjv0= github.com/go-logfmt/logfmt v0.3.0/go.mod h1:Qt1PoO58o5twSAckw1HlFXLmHsOX5/0LbT9GBnD5lWE= @@ -535,13 +470,10 @@ github.com/go-logfmt/logfmt v0.5.0/go.mod h1:wCYkCAKZfumFQihp8CzCvQ3paCTfi41vtzG github.com/go-logfmt/logfmt v0.6.0 h1:wGYYu3uicYdqXVgoYbvnkrPVXkuLM1p1ifugDMEdRi4= github.com/go-logfmt/logfmt v0.6.0/go.mod h1:WYhtIu8zTZfxdn5+rREduYbwxfcBr/Vr6KEVveWlfTs= github.com/go-logr/logr v1.2.2/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= -github.com/go-logr/logr v1.3.0 h1:2y3SDp0ZXuc6/cjLSZ+Q3ir+QB9T/iG5yYRXqsagWSY= -github.com/go-logr/logr v1.3.0/go.mod h1:9T104GzyrTigFIr8wt5mBrctHMim0Nb2HLGrmQ40KvY= +github.com/go-logr/logr v1.4.1 h1:pKouT5E8xu9zeFC39JXRDukb6JFQPXM5p5I91188VAQ= +github.com/go-logr/logr v1.4.1/go.mod h1:9T104GzyrTigFIr8wt5mBrctHMim0Nb2HLGrmQ40KvY= github.com/go-logr/stdr v1.2.2 h1:hSWxHoqTgW2S2qGc0LTAI563KZ5YKYRhT3MFKZMbjag= github.com/go-logr/stdr v1.2.2/go.mod h1:mMo/vtBO5dYbehREoey6XUKy/eSumjCCveDpRre4VKE= -github.com/go-ole/go-ole v1.2.1/go.mod h1:7FAglXiTm7HKlQRDeOQ6ZNUHidzCWXuZWq/1dTyBNF8= -github.com/go-openapi/jsonpointer v0.19.5/go.mod h1:Pl9vOtqEWErmShwVjC8pYs9cog34VGT37dQOVbmoatg= -github.com/go-openapi/swag v0.19.5/go.mod h1:POnQmlKehdgb5mhVOsnJFsivZCEZ/vjK9gh66Z9tfKk= github.com/go-playground/assert/v2 v2.0.1/go.mod h1:VDjEfimB/XKnb+ZQfWdccd7VUvScMdVu0Titje2rxJ4= github.com/go-playground/locales v0.13.0/go.mod h1:taPMhCMXrRLJO55olJkUXHZBHCxTMfnGwq/HNwmWNS8= github.com/go-playground/locales v0.14.0 h1:u50s323jtVGugKlcYeyzC0etD1HifMjqmJqb8WugfUU= @@ -552,9 +484,7 @@ github.com/go-playground/universal-translator v0.18.0/go.mod h1:UvRDBj+xPUEGrFYl github.com/go-playground/validator/v10 v10.2.0/go.mod h1:uOYAAleCW8F/7oMFd6aG0GOhaH6EGOAJShg8Id5JGkI= github.com/go-playground/validator/v10 v10.11.1 h1:prmOlTVv+YjZjmRmNSF3VmspqJIxJWXmqUsHwfTRRkQ= github.com/go-playground/validator/v10 v10.11.1/go.mod h1:i+3WkQ1FvaUjjxh1kSvIA4dMGDBiPU55YFDl0WbKdWU= -github.com/go-sourcemap/sourcemap v2.1.3+incompatible/go.mod h1:F8jJfvm2KbVjc5NqelyYJmf/v5J0dwNLS2mL4sNA1Jg= github.com/go-sql-driver/mysql v1.4.0/go.mod h1:zAC/RDZ24gD3HViQzih4MyKcchzm+sOG5ZlKdlhCg5w= -github.com/go-sql-driver/mysql v1.4.1/go.mod h1:zAC/RDZ24gD3HViQzih4MyKcchzm+sOG5ZlKdlhCg5w= github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY= github.com/gobwas/httphead v0.0.0-20180130184737-2c6c146eadee h1:s+21KNqlpePfkah2I+gwHF8xmJWRjooY+5248k6m4A0= github.com/gobwas/httphead v0.0.0-20180130184737-2c6c146eadee/go.mod h1:L0fX3K22YWvt/FAX9NnzrNzcI4wNYi9Yku4O0LKYflo= @@ -567,14 +497,10 @@ github.com/goccy/go-json v0.9.11/go.mod h1:6MelG93GURQebXPDq3khkgXZkazVtN9CRI+MG github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2 h1:ZpnhV/YsD2/4cESfV5+Hoeu/iUR3ruzNvZ+yQfO03a0= github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2/go.mod h1:bBOAhwG1umN6/6ZUMtDFBMQR8jRg9O75tm9K00oMsK4= github.com/godbus/dbus/v5 v5.0.4/go.mod h1:xhWf0FNVPg57R7Z0UbKHbJfkEywrmjJnf7w5xrFpKfA= -github.com/gofrs/uuid v3.3.0+incompatible/go.mod h1:b2aQJv3Z4Fp6yNu3cdSllBxTCLRxnplIgP/c0N/04lM= github.com/gogo/googleapis v1.1.0/go.mod h1:gf4bu3Q80BeJ6H1S1vYPm8/ELATdvryBaNFGgqEef3s= github.com/gogo/googleapis v1.4.1-0.20201022092350-68b0159b7869/go.mod h1:5YRNX2z1oM5gXdAkurHa942MDgEJyk02w4OecKY87+c= github.com/gogo/googleapis v1.4.1 h1:1Yx4Myt7BxzvUr5ldGSbwYiZG6t9wGBZ+8/fX3Wvtq0= github.com/gogo/googleapis v1.4.1/go.mod h1:2lpHqI5OcWCtVElxXnPt+s8oJvMpySlOyM6xDCrzib4= -github.com/golang-jwt/jwt/v4 v4.3.0/go.mod h1:/xlHOz8bRuivTWchD4jCa+NbatV+wEUSzwAxVc6locg= -github.com/golang/freetype v0.0.0-20170609003504-e2365dfdc4a0/go.mod h1:E/TSTwGwJL78qG/PmXZO1EjYhfJinVAhrmmHX6Z8B9k= -github.com/golang/geo v0.0.0-20190916061304-5b978397cfec/go.mod h1:QZ0nwyI2jOfgRAoBvP+ab5aRr7c9x7lhGEJrKvBwjWI= github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q= github.com/golang/glog v1.2.0 h1:uCdmnmatrKCgMBlM4rMuJZWOkPDqdbZPnrMXDY4gI68= github.com/golang/glog v1.2.0/go.mod h1:6AhwSGph0fcJtXVM/PEHPqZlFeoLxhs7/t5UDAwmO+w= @@ -618,12 +544,10 @@ github.com/golang/snappy v0.0.0-20180518054509-2e65f85255db/go.mod h1:/XxbfmMg8l github.com/golang/snappy v0.0.3/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= github.com/golang/snappy v0.0.4 h1:yAGX7huGHXlcLOEtBnF4w7FQwA26wojNCwOYAEhLjQM= github.com/golang/snappy v0.0.4/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= -github.com/golangci/lint-1 v0.0.0-20181222135242-d2cdd8c08219/go.mod h1:/X8TswGSh1pIozq4ZwCfxS0WA5JGXguxk94ar/4c87Y= github.com/google/btree v0.0.0-20180813153112-4030bb1f1f0c/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ= github.com/google/btree v1.0.0/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ= github.com/google/btree v1.1.2 h1:xf4v41cLI2Z6FxbKm+8Bu+m8ifhj15JuZ9sa0jZCMUU= github.com/google/btree v1.1.2/go.mod h1:qOPhT0dTNdNzV6Z/lhRX0YXUafgPLFUh+gZMl761Gm4= -github.com/google/flatbuffers v1.11.0/go.mod h1:1AeVuKshWv4vARoZatz6mlQ0JxURH0Kv5+zNeJKJCa8= github.com/google/flatbuffers v1.12.1 h1:MVlul7pQNoDzWRLTw5imwYsl+usrS1TXG2H4jg6ImGw= github.com/google/flatbuffers v1.12.1/go.mod h1:1AeVuKshWv4vARoZatz6mlQ0JxURH0Kv5+zNeJKJCa8= github.com/google/go-cmp v0.2.0/go.mod h1:oXzfMopK8JAjlY9xF4vHSVASa0yLyX7SntLO5aqRK0M= @@ -645,7 +569,6 @@ github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI= github.com/google/go-cmp v0.6.0/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= github.com/google/gofuzz v0.0.0-20170612174753-24818f796faf/go.mod h1:HP5RmnzzSNb993RKQDq4+1A4ia9nllfqcQFTQJedwGI= github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= -github.com/google/gofuzz v1.1.1-0.20200604201612-c04b05f3adfa/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/gofuzz v1.2.0 h1:xRy4A+RhZaiKjJ1bPfwQ8sedCA+YS2YcCHW6ec7JMi0= github.com/google/gofuzz v1.2.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/martian v2.1.0+incompatible h1:/CP5g8u/VJHijgedC/Legn3BAbAaWPgecwXBIDzw5no= @@ -675,9 +598,7 @@ github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm4 github.com/google/s2a-go v0.1.7 h1:60BLSyTrOV4/haCDW4zb1guZItoSq8foHCXrAnjBo/o= github.com/google/s2a-go v0.1.7/go.mod h1:50CgR4k1jNlWBu4UfS4AcfhVe1r6pdZPygJ3R8F0Qdw= github.com/google/uuid v1.0.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= -github.com/google/uuid v1.1.1/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= -github.com/google/uuid v1.2.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/google/uuid v1.3.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/google/uuid v1.6.0 h1:NIvaJDMOsjHA8n1jAhLSgzrAzy1Hgr+hNrb57e+94F0= github.com/google/uuid v1.6.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= @@ -700,22 +621,20 @@ github.com/googleapis/gax-go/v2 v2.12.0/go.mod h1:y+aIqrI5eb1YGMVJfuV3185Ts/D7qK github.com/googleapis/go-type-adapters v1.0.0/go.mod h1:zHW75FOG2aur7gAO2B+MLby+cLsWGBF62rFAi7WjWO4= github.com/gopherjs/gopherjs v0.0.0-20181017120253-0766667cb4d1/go.mod h1:wJfORRmW1u3UXTncJ5qlYoELFm8eSnnEO6hX4iZ3EWY= github.com/gorilla/context v1.1.1/go.mod h1:kBGZzfjB9CEq2AlWe17Uuf7NDRt0dE0s8S51q0aT7Yg= -github.com/gorilla/handlers v1.5.1 h1:9lRY6j8DEeeBT10CvO9hGW0gmky0BprnvDI5vfhUHH4= -github.com/gorilla/handlers v1.5.1/go.mod h1:t8XrUpc4KVXb7HGyJ4/cEnwQiaxrX/hz1Zv/4g96P1Q= +github.com/gorilla/handlers v1.5.2 h1:cLTUSsNkgcwhgRqvCNmdbRWG0A3N4F+M2nWKdScwyEE= +github.com/gorilla/handlers v1.5.2/go.mod h1:dX+xVpaxdSw+q0Qek8SSsl3dfMk3jNddUkMzo0GtH0w= github.com/gorilla/mux v1.6.2/go.mod h1:1lud6UwP+6orDFRuTfBEV8e9/aOM/c4fVVCaMa2zaAs= github.com/gorilla/mux v1.7.3/go.mod h1:1lud6UwP+6orDFRuTfBEV8e9/aOM/c4fVVCaMa2zaAs= -github.com/gorilla/mux v1.8.0 h1:i40aqfkR1h2SlN9hojwV5ZA91wcXFOvkdNIeFDP5koI= -github.com/gorilla/mux v1.8.0/go.mod h1:DVbg23sWSpFRCP0SfiEN6jmj59UnW/n46BH5rLB71So= +github.com/gorilla/mux v1.8.1 h1:TuBL49tXwgrFYWhqrNgrUNEY92u81SPhu7sTdzQEiWY= +github.com/gorilla/mux v1.8.1/go.mod h1:AKf9I4AEqPTmMytcMc0KkNouC66V3BtZ4qD5fmWSiMQ= github.com/gorilla/websocket v0.0.0-20170926233335-4201258b820c/go.mod h1:E7qHFY5m1UJ88s3WnNqhKjPHQ0heANvMoAMk2YaljkQ= github.com/gorilla/websocket v1.4.1/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= -github.com/gorilla/websocket v1.4.2/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= github.com/gorilla/websocket v1.5.0 h1:PPwGk2jz7EePpoHN/+ClbZu8SPxiqlu12wZP/3sWmnc= github.com/gorilla/websocket v1.5.0/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= -github.com/graph-gophers/graphql-go v1.3.0/go.mod h1:9CQHMSxwO4MprSdzoIEobiHpoLtHm77vfxsvsIN5Vuc= github.com/grpc-ecosystem/go-grpc-middleware v1.0.1-0.20190118093823-f849b5445de4/go.mod h1:FiyG127CGDf3tlThmgyCl78X/SZQqEOJBCDaAfeWzPs= github.com/grpc-ecosystem/go-grpc-middleware v1.2.2/go.mod h1:EaizFBKfUKtMIF5iaDEhniwNedqGo9FuLFzppDr3uwI= -github.com/grpc-ecosystem/go-grpc-middleware v1.3.0 h1:+9834+KizmvFV7pXQGSXQTsaWhq2GjuNUt0aUU0YBYw= -github.com/grpc-ecosystem/go-grpc-middleware v1.3.0/go.mod h1:z0ButlSOZa5vEBq9m2m2hlwIgKw+rp3sdCBRoJY+30Y= +github.com/grpc-ecosystem/go-grpc-middleware v1.4.0 h1:UH//fgunKIs4JdUbpDl1VZCDaL56wXCB/5+wF6uHfaI= +github.com/grpc-ecosystem/go-grpc-middleware v1.4.0/go.mod h1:g5qyo/la0ALbONm6Vbp88Yd8NsDy6rZz+RcrMPxvld8= github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= github.com/grpc-ecosystem/grpc-gateway v1.9.5/go.mod h1:vNeuVxBJEsws4ogUvrchl83t/GYV9WGTSLVdBhOQFDY= github.com/grpc-ecosystem/grpc-gateway v1.16.0 h1:gmcG1KaJ57LophUzW0Hy8NmPhnMZb4M0+kPpLofRdBo= @@ -724,26 +643,26 @@ github.com/grpc-ecosystem/grpc-gateway/v2 v2.16.0 h1:YBftPWNWd4WwGqtY2yeZL2ef8rH github.com/grpc-ecosystem/grpc-gateway/v2 v2.16.0/go.mod h1:YN5jB8ie0yfIUg6VvR9Kz84aCaG7AsGZnLjhHbUqwPg= github.com/gsterjov/go-libsecret v0.0.0-20161001094733-a6f4afe4910c h1:6rhixN/i8ZofjG1Y75iExal34USq5p+wiN1tpie8IrU= github.com/gsterjov/go-libsecret v0.0.0-20161001094733-a6f4afe4910c/go.mod h1:NMPJylDgVpX0MLRlPy15sqSwOFv/U1GZ2m21JhFfek0= -github.com/gtank/merlin v0.1.1-0.20191105220539-8318aed1a79f/go.mod h1:T86dnYJhcGOh5BjZFCJWTDeTK7XW8uE+E21Cy/bIQ+s= -github.com/gtank/merlin v0.1.1 h1:eQ90iG7K9pOhtereWsmyRJ6RAwcP4tHTDBHXNg+u5is= -github.com/gtank/merlin v0.1.1/go.mod h1:T86dnYJhcGOh5BjZFCJWTDeTK7XW8uE+E21Cy/bIQ+s= -github.com/gtank/ristretto255 v0.1.2 h1:JEqUCPA1NvLq5DwYtuzigd7ss8fwbYay9fi4/5uMzcc= -github.com/gtank/ristretto255 v0.1.2/go.mod h1:Ph5OpO6c7xKUGROZfWVLiJf9icMDwUeIvY4OmlYW69o= github.com/hashicorp/consul/api v1.3.0/go.mod h1:MmDNSzIMUjNpY/mQ398R4bk2FnqQLoPndWW5VkKPlCE= github.com/hashicorp/consul/sdk v0.3.0/go.mod h1:VKf9jXwCTEY1QZP2MOLRhb5i/I/ssyNV1vwHyQBF0x8= github.com/hashicorp/errwrap v1.0.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4= -github.com/hashicorp/go-bexpr v0.1.10/go.mod h1:oxlubA2vC/gFVfX1A6JGp7ls7uCDlfJn732ehYYg+g0= github.com/hashicorp/go-cleanhttp v0.5.0/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtngrth3wmdIIUrZ80= github.com/hashicorp/go-cleanhttp v0.5.1/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtngrth3wmdIIUrZ80= github.com/hashicorp/go-cleanhttp v0.5.2 h1:035FKYIWjmULyFRBKPs8TBQoi0x6d9G4xc9neXJWAZQ= github.com/hashicorp/go-cleanhttp v0.5.2/go.mod h1:kO/YDlP8L1346E6Sodw+PrpBSV4/SoxCXGY6BqNFT48= github.com/hashicorp/go-getter v1.7.1 h1:SWiSWN/42qdpR0MdhaOc/bLR48PLuP1ZQtYLRlM69uY= github.com/hashicorp/go-getter v1.7.1/go.mod h1:W7TalhMmbPmsSMdNjD0ZskARur/9GJ17cfHTRtXV744= +github.com/hashicorp/go-hclog v1.5.0 h1:bI2ocEMgcVlz55Oj1xZNBsVi900c7II+fWDyV9o+13c= +github.com/hashicorp/go-hclog v1.5.0/go.mod h1:W4Qnvbt70Wk/zYJryRzDRU/4r0kIg0PVHBcfoyhpF5M= github.com/hashicorp/go-immutable-radix v1.0.0/go.mod h1:0y9vanUI8NX6FsYoO3zeMjhV/C5i9g4Q3DwcSNZ4P60= github.com/hashicorp/go-immutable-radix v1.3.1 h1:DKHmCUm2hRBK510BaiZlwvpD40f8bJFeZnpfm2KLowc= github.com/hashicorp/go-immutable-radix v1.3.1/go.mod h1:0y9vanUI8NX6FsYoO3zeMjhV/C5i9g4Q3DwcSNZ4P60= +github.com/hashicorp/go-metrics v0.5.3 h1:M5uADWMOGCTUNU1YuC4hfknOeHNaX54LDm4oYSucoNE= +github.com/hashicorp/go-metrics v0.5.3/go.mod h1:KEjodfebIOuBYSAe/bHTm+HChmKSxAOXPBieMLYozDE= github.com/hashicorp/go-msgpack v0.5.3/go.mod h1:ahLV/dePpqEmjfWmKiqvPkv/twdG7iPBM1vqhUKIvfM= github.com/hashicorp/go-multierror v1.0.0/go.mod h1:dHtQlpGsu+cZNNAkkCN/P3hoUDHhCYQXV3UM06sGGrk= +github.com/hashicorp/go-plugin v1.5.2 h1:aWv8eimFqWlsEiMrYZdPYl+FdHaBJSN4AWwGWfT1G2Y= +github.com/hashicorp/go-plugin v1.5.2/go.mod h1:w1sAEES3g3PuV/RzUrgow20W2uErMly84hhD3um1WL4= github.com/hashicorp/go-retryablehttp v0.5.3/go.mod h1:9B5zBasrRhHXnJnui7y6sL7es7NDiJgTc6Er0maI1Xs= github.com/hashicorp/go-rootcerts v1.0.0/go.mod h1:K6zTfqpRlCUIjkwsN4Z+hiSfzSTQa6eBIzfwKfwNnHU= github.com/hashicorp/go-safetemp v1.0.0 h1:2HR189eFNrjHQyENnQMMpCiBAsRxzbTMIgBhEyExpmo= @@ -751,34 +670,35 @@ github.com/hashicorp/go-safetemp v1.0.0/go.mod h1:oaerMy3BhqiTbVye6QuFhFtIceqFoD github.com/hashicorp/go-sockaddr v1.0.0/go.mod h1:7Xibr9yA9JjQq1JpNB2Vw7kxv8xerXegt+ozgdvDeDU= github.com/hashicorp/go-syslog v1.0.0/go.mod h1:qPfqrKkXGihmCqbJM2mZgkZGvKG1dFdvsLplgctolz4= github.com/hashicorp/go-uuid v1.0.0/go.mod h1:6SBZvOh/SIDV7/2o3Jml5SYk/TvGqwFJ/bN7x4byOro= -github.com/hashicorp/go-uuid v1.0.1 h1:fv1ep09latC32wFoVwnqcnKJGnMSdBanPczbHAYm1BE= github.com/hashicorp/go-uuid v1.0.1/go.mod h1:6SBZvOh/SIDV7/2o3Jml5SYk/TvGqwFJ/bN7x4byOro= +github.com/hashicorp/go-uuid v1.0.2 h1:cfejS+Tpcp13yd5nYHWDI6qVCny6wyX2Mt5SGur2IGE= +github.com/hashicorp/go-uuid v1.0.2/go.mod h1:6SBZvOh/SIDV7/2o3Jml5SYk/TvGqwFJ/bN7x4byOro= github.com/hashicorp/go-version v1.2.0/go.mod h1:fltr4n8CU8Ke44wwGCBoEymUuxUHl09ZGVZPK5anwXA= github.com/hashicorp/go-version v1.6.0 h1:feTTfFNnjP967rlCxM/I9g701jU+RN74YKx2mOkIeek= github.com/hashicorp/go-version v1.6.0/go.mod h1:fltr4n8CU8Ke44wwGCBoEymUuxUHl09ZGVZPK5anwXA= github.com/hashicorp/go.net v0.0.1/go.mod h1:hjKkEWcCURg++eb33jQU7oqQcI9XDCnUzHA0oac0k90= github.com/hashicorp/golang-lru v0.5.0/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8= github.com/hashicorp/golang-lru v0.5.1/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8= -github.com/hashicorp/golang-lru v0.5.5-0.20210104140557-80c98217689d h1:dg1dEPuWpEqDnvIw251EVy4zlP8gWbsGj4BsUKCRpYs= -github.com/hashicorp/golang-lru v0.5.5-0.20210104140557-80c98217689d/go.mod h1:iADmTwqILo4mZ8BN3D2Q6+9jd8WM5uGBxy+E8yxSoD4= +github.com/hashicorp/golang-lru v1.0.2 h1:dV3g9Z/unq5DpblPpw+Oqcv4dU/1omnb4Ok8iPY6p1c= +github.com/hashicorp/golang-lru v1.0.2/go.mod h1:iADmTwqILo4mZ8BN3D2Q6+9jd8WM5uGBxy+E8yxSoD4= github.com/hashicorp/hcl v1.0.0 h1:0Anlzjpi4vEasTeNFn2mLJgTSwt0+6sfsiTG8qcWGx4= github.com/hashicorp/hcl v1.0.0/go.mod h1:E5yfLk+7swimpb2L/Alb/PJmXilQ/rhwaUYs4T20WEQ= github.com/hashicorp/logutils v1.0.0/go.mod h1:QIAnNjmIWmVIIkWDTG1z5v++HQmx9WQRO+LraFDTW64= github.com/hashicorp/mdns v1.0.0/go.mod h1:tL+uN++7HEJ6SQLQ2/p+z2pH24WQKWjBPkE0mNTz8vQ= github.com/hashicorp/memberlist v0.1.3/go.mod h1:ajVTdAv/9Im8oMAAj5G31PhhMCZJV2pPBoIllUwCN7I= github.com/hashicorp/serf v0.8.2/go.mod h1:6hOLApaqBFA1NXqRQAsxw9QxuDEvNxSQRwA/JwenrHc= +github.com/hashicorp/yamux v0.1.1 h1:yrQxtgseBDrq9Y652vSRDvsKCJKOUD+GzTS4Y0Y8pvE= +github.com/hashicorp/yamux v0.1.1/go.mod h1:CtWFDAQgb7dxtzFs4tWbplKIe2jSi3+5vKbgIO0SLnQ= github.com/hdevalence/ed25519consensus v0.1.0 h1:jtBwzzcHuTmFrQN6xQZn6CQEO/V9f7HsjsjeEZ6auqU= github.com/hdevalence/ed25519consensus v0.1.0/go.mod h1:w3BHWjwJbFU29IRHL1Iqkw3sus+7FctEyM4RqDxYNzo= -github.com/holiman/bloomfilter/v2 v2.0.3/go.mod h1:zpoh+gs7qcpqrHr3dB55AMiJwo0iURXE7ZOP9L9hSkA= -github.com/holiman/uint256 v1.2.0/go.mod h1:y4ga/t+u+Xwd7CpDgZESaRcWy0I7XMlTMA25ApIH5Jw= github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpOxQnU= github.com/huandu/go-assert v1.1.5 h1:fjemmA7sSfYHJD7CUqs9qTwwfdNAx7/j2/ZlHXzNB3c= github.com/huandu/go-assert v1.1.5/go.mod h1:yOLvuqZwmcHIC5rIzrBhT7D3Q9c3GFnd0JrPVhn/06U= github.com/huandu/skiplist v1.2.0 h1:gox56QD77HzSC0w+Ws3MH3iie755GBJU1OER3h5VsYw= github.com/huandu/skiplist v1.2.0/go.mod h1:7v3iFjLcSAzO4fN5B8dvebvo/qsfumiLiDXMrPiHF9w= github.com/hudl/fargo v1.3.0/go.mod h1:y3CKSmjA+wD2gak7sUSXTAoopbhU08POFhmITJgmKTg= -github.com/huin/goupnp v1.0.3-0.20220313090229-ca81a64b4204/go.mod h1:ZxNlw5WqJj6wSsRK5+YfflQGXYfccj5VgQsMNixHM7Y= -github.com/huin/goutil v0.0.0-20170803182201-1ca381bf3150/go.mod h1:PpLOETDnJ0o3iZrZfqZzyLl6l7F3c6L1oWn7OICBi6o= +github.com/iancoleman/strcase v0.3.0 h1:nTXanmYxhfFAMjZL34Ov6gkzEsSJZ5DbhxWjvSASxEI= +github.com/iancoleman/strcase v0.3.0/go.mod h1:iwCmte+B7n89clKwxIoIXy/HfoL7AsD47ZCWhYzw7ho= github.com/ianlancetaylor/demangle v0.0.0-20181102032728-5e5cf60278f6/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= github.com/ianlancetaylor/demangle v0.0.0-20200824232613-28f6c0f3b639/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= github.com/improbable-eng/grpc-web v0.15.0 h1:BN+7z6uNXZ1tQGcNAuaU1YjsLTApzkjt2tzCixLaUPQ= @@ -786,24 +706,9 @@ github.com/improbable-eng/grpc-web v0.15.0/go.mod h1:1sy9HKV4Jt9aEs9JSnkWlRJPuPt github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8= github.com/inconshreveable/mousetrap v1.1.0 h1:wN+x4NVGpMsO7ErUn/mUI3vEoE6Jt13X2s0bqwp9tc8= github.com/inconshreveable/mousetrap v1.1.0/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLfsEA9PFc4w1p2J65bw= -github.com/influxdata/flux v0.65.1/go.mod h1:J754/zds0vvpfwuq7Gc2wRdVwEodfpCFM7mYlOw2LqY= -github.com/influxdata/influxdb v1.8.3/go.mod h1:JugdFhsvvI8gadxOI6noqNeeBHvWNTbfYGtiAn+2jhI= -github.com/influxdata/influxdb-client-go/v2 v2.4.0/go.mod h1:vLNHdxTJkIf2mSLvGrpj8TCcISApPoXkaxP8g9uRlW8= github.com/influxdata/influxdb1-client v0.0.0-20191209144304-8bf82d3c094d/go.mod h1:qj24IKcXYK6Iy9ceXlo3Tc+vtHo9lIhSX5JddghvEPo= -github.com/influxdata/influxql v1.1.1-0.20200828144457-65d3ef77d385/go.mod h1:gHp9y86a/pxhjJ+zMjNXiQAA197Xk9wLxaz+fGG+kWk= -github.com/influxdata/line-protocol v0.0.0-20180522152040-32c6aa80de5e/go.mod h1:4kt73NQhadE3daL3WhR5EJ/J2ocX0PZzwxQ0gXJ7oFE= -github.com/influxdata/line-protocol v0.0.0-20200327222509-2487e7298839/go.mod h1:xaLFMmpvUxqXtVkUJfg9QmT88cDaCJ3ZKgdZ78oO8Qo= -github.com/influxdata/line-protocol v0.0.0-20210311194329-9aa0e372d097/go.mod h1:xaLFMmpvUxqXtVkUJfg9QmT88cDaCJ3ZKgdZ78oO8Qo= -github.com/influxdata/promql/v2 v2.12.0/go.mod h1:fxOPu+DY0bqCTCECchSRtWfc+0X19ybifQhZoQNF5D8= -github.com/influxdata/roaring v0.4.13-0.20180809181101-fc520f41fab6/go.mod h1:bSgUQ7q5ZLSO+bKBGqJiCBGAl+9DxyW63zLTujjUlOE= -github.com/influxdata/tdigest v0.0.0-20181121200506-bf2b5ad3c0a9/go.mod h1:Js0mqiSBE6Ffsg94weZZ2c+v/ciT8QRHFOap7EKDrR0= -github.com/influxdata/usage-client v0.0.0-20160829180054-6d3895376368/go.mod h1:Wbbw6tYNvwa5dlB6304Sd+82Z3f7PmVZHVKU637d4po= -github.com/jackpal/go-nat-pmp v1.0.2/go.mod h1:QPH045xvCAeXUZOxsnwmrtiCoxIr9eob+4orBN1SBKc= -github.com/jedisct1/go-minisign v0.0.0-20190909160543-45766022959e/go.mod h1:G1CVv03EnqU1wYL2dFwXxW2An0az9JTl/ZsqXQeBlkU= -github.com/jessevdk/go-flags v0.0.0-20141203071132-1679536dcc89/go.mod h1:4FA24M0QyGHXBuZZK/XkWh8h0e1EYbRYJSGM75WSRxI= -github.com/jessevdk/go-flags v1.4.0/go.mod h1:4FA24M0QyGHXBuZZK/XkWh8h0e1EYbRYJSGM75WSRxI= -github.com/jhump/protoreflect v1.15.1 h1:HUMERORf3I3ZdX05WaQ6MIpd/NJ434hTp5YiKgfCL6c= -github.com/jhump/protoreflect v1.15.1/go.mod h1:jD/2GMKKE6OqX8qTjhADU1e6DShO+gavG9e0Q693nKo= +github.com/jhump/protoreflect v1.15.3 h1:6SFRuqU45u9hIZPJAoZ8c28T3nK64BNdp9w6jFonzls= +github.com/jhump/protoreflect v1.15.3/go.mod h1:4ORHmSBmlCW8fh3xHmJMGyul1zNqZK4Elxc8qKP+p1k= github.com/jmespath/go-jmespath v0.0.0-20180206201540-c2b33e8439af/go.mod h1:Nht3zPeWKUH0NzdCt2Blrr5ys8VGpn0CEB0cQHVjt7k= github.com/jmespath/go-jmespath v0.4.0 h1:BEgLn5cpjn8UN1mAw4NjwDrS35OdebyEtFe+9YPoQUg= github.com/jmespath/go-jmespath v0.4.0/go.mod h1:T8mJZnbsbmF+m6zOOFylbeCJqk5+pHWvzYPziyZiYoo= @@ -811,7 +716,6 @@ github.com/jmespath/go-jmespath/internal/testify v1.5.1 h1:shLQSRRSCCPj3f2gpwzGw github.com/jmespath/go-jmespath/internal/testify v1.5.1/go.mod h1:L3OGu8Wl2/fWfCI6z80xFu9LTZmf1ZRjMHUOPmWr69U= github.com/jonboulle/clockwork v0.1.0/go.mod h1:Ii8DK3G1RaLaWxj9trq07+26W01tbo22gdxWY5EU2bo= github.com/jpillora/backoff v1.0.0/go.mod h1:J/6gKK9jxlEcS3zixgDgUAsiuZ7yrSoa/FX5e0EB2j4= -github.com/jrick/logrotate v1.0.0/go.mod h1:LNinyqDIJnpAur+b8yyulnQw/wDuN1+BYKlTRt3OuAQ= github.com/json-iterator/go v1.1.6/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU= github.com/json-iterator/go v1.1.7/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= github.com/json-iterator/go v1.1.8/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= @@ -821,45 +725,29 @@ github.com/json-iterator/go v1.1.12 h1:PV8peI4a0ysnczrg+LtxykD8LfKY9ML6u2jnxaEnr github.com/json-iterator/go v1.1.12/go.mod h1:e30LSqwooZae/UwlEbR2852Gd8hjQvJoHmT4TnhNGBo= github.com/jstemmer/go-junit-report v0.0.0-20190106144839-af01ea7f8024/go.mod h1:6v2b51hI/fHJwM22ozAgKL4VKDeJcHhJFhtBdhmNjmU= github.com/jstemmer/go-junit-report v0.9.1/go.mod h1:Brl9GWCQeLvo8nXZwPNNblvFj/XSXhF0NWZEnDohbsk= -github.com/jsternberg/zap-logfmt v1.0.0/go.mod h1:uvPs/4X51zdkcm5jXl5SYoN+4RK21K8mysFmDaM/h+o= github.com/jtolds/gls v4.20.0+incompatible/go.mod h1:QJZ7F/aHp+rZTRtaJ1ow/lLfFfVYBRgL+9YlvaHOwJU= github.com/julienschmidt/httprouter v1.2.0/go.mod h1:SYymIcj16QtmaHHD7aYtjjsJG7VTCxuUUipMqKk8s4w= github.com/julienschmidt/httprouter v1.3.0/go.mod h1:JR6WtHb+2LUe8TCKY3cZOxFyyO8IZAc4RVcycCCAKdM= -github.com/jung-kurt/gofpdf v1.0.3-0.20190309125859-24315acbbda5/go.mod h1:7Id9E/uU8ce6rXgefFLlgrJj/GYY22cpxn+r32jIOes= -github.com/jwilder/encoding v0.0.0-20170811194829-b4e1701a28ef/go.mod h1:Ct9fl0F6iIOGgxJ5npU/IUOhOhqlVrGjyIZc8/MagT0= -github.com/karalabe/usb v0.0.2/go.mod h1:Od972xHfMJowv7NGVDiWVxk2zxnWgjLlJzE+F4F7AGU= github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8= github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= -github.com/kkdai/bstream v0.0.0-20161212061736-f391b8402d23/go.mod h1:J+Gs4SYgM6CZQHDETBtE9HaSEkGmuNXF86RwHhHUvq4= -github.com/klauspost/compress v1.4.0/go.mod h1:RyIbtBH6LamlWaDj8nUwkbUhJ87Yi3uG0guNDohfE1A= github.com/klauspost/compress v1.10.3/go.mod h1:aoV0uJVorq1K+umq18yTdKaF57EivdYsUV+/s2qKfXs= github.com/klauspost/compress v1.11.7/go.mod h1:aoV0uJVorq1K+umq18yTdKaF57EivdYsUV+/s2qKfXs= -github.com/klauspost/compress v1.12.3/go.mod h1:8dP1Hq4DHOhN9w426knH3Rhby4rFm6D8eO+e+Dq5Gzg= github.com/klauspost/compress v1.15.11/go.mod h1:QPwzmACJjUTFsnSHH934V6woptycfrDDJnH7hvFVbGM= -github.com/klauspost/compress v1.17.0 h1:Rnbp4K9EjcDuVuHtd0dgA4qNuv9yKDYKK1ulpJwgrqM= -github.com/klauspost/compress v1.17.0/go.mod h1:ntbaceVETuRiXiv4DpjP66DpAtAGkEQskQzEyD//IeE= -github.com/klauspost/cpuid v0.0.0-20170728055534-ae7887de9fa5/go.mod h1:Pj4uuM528wm8OyEC2QMXAi2YiTZ96dNQPGgoMS4s3ek= -github.com/klauspost/crc32 v0.0.0-20161016154125-cb6bfca970f6/go.mod h1:+ZoRqAPRLkC4NPOvfYeR5KNOrY6TD+/sAC3HXPZgDYg= -github.com/klauspost/pgzip v1.0.2-0.20170402124221-0bf5dcad4ada/go.mod h1:Ch1tH69qFZu15pkjo5kYi6mth2Zzwzt50oCQKQE9RUs= +github.com/klauspost/compress v1.17.7 h1:ehO88t2UGzQK66LMdE8tibEd1ErmzZjNEqWkjLAKQQg= +github.com/klauspost/compress v1.17.7/go.mod h1:Di0epgTjJY877eYKx5yC51cX2A2Vl2ibi7bDH9ttBbw= github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= github.com/konsorten/go-windows-terminal-sequences v1.0.3/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515/go.mod h1:+0opPa2QZZtGFBFZlji/RkVcI2GknAs/DXo4wKdlNEc= github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo= -github.com/kr/pretty v0.2.1/go.mod h1:ipq/a2n7PKx3OHsz4KJII5eveXtPO4qwEXGdVfWzfnI= github.com/kr/pretty v0.3.1 h1:flRD4NNwYAUpkphVc1HcthR4KEIFJ65n8Mw5qdRn3LE= github.com/kr/pretty v0.3.1/go.mod h1:hoEshYVHaxMs3cyo3Yncou5ZscifuDolrwPKZanG3xk= github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ= github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI= github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY= github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE= -github.com/kylelemons/godebug v1.1.0/go.mod h1:9/0rRGxNHcop5bhtWyNeEfOS8JIWk580+fNqagV/RAw= -github.com/labstack/echo/v4 v4.2.1/go.mod h1:AA49e0DZ8kk5jTOOCKNuPR6oTnBS0dYiM4FW1e6jwpg= -github.com/labstack/gommon v0.3.0/go.mod h1:MULnywXg0yavhxWKc+lOruYdAhDwPK9wf0OL7NoOu+k= -github.com/leanovate/gopter v0.2.9/go.mod h1:U2L/78B+KVFIx2VmW6onHJQzXtFb+p5y3y2Sh+Jxxv8= github.com/leodido/go-urn v1.2.0/go.mod h1:+8+nEpDfqqsY+g338gtMEUOtuK+4dEMhiQEgxpxOKII= github.com/leodido/go-urn v1.2.1 h1:BqpAaACuzVSgi/VLzGZIobT2z4v53pjosyNd9Yv6n/w= github.com/leodido/go-urn v1.2.1/go.mod h1:zt4jvISO2HfUBqxjfIshjdMTYS56ZS/qv49ictyFfxY= -github.com/lib/pq v1.0.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo= github.com/lib/pq v1.10.7 h1:p7ZhMD+KsSRozJr34udlUrhboJwWAgCg34+/ZZNvZZw= github.com/lib/pq v1.10.7/go.mod h1:AlVN5x4E4T544tWzH6hKfbfQvm3HdbOxrmggDNAPY9o= github.com/libp2p/go-buffer-pool v0.1.0 h1:oK4mSFcQz7cTQIfqbe4MIj9gLW+mnanjyFtc6cdF0Y8= @@ -868,27 +756,18 @@ github.com/lightstep/lightstep-tracer-common/golang/gogo v0.0.0-20190605223551-b github.com/lightstep/lightstep-tracer-go v0.18.1/go.mod h1:jlF1pusYV4pidLvZ+XD0UBX0ZE6WURAspgAczcDHrL4= github.com/linxGnu/grocksdb v1.8.14 h1:HTgyYalNwBSG/1qCQUIott44wU5b2Y9Kr3z7SK5OfGQ= github.com/linxGnu/grocksdb v1.8.14/go.mod h1:QYiYypR2d4v63Wj1adOOfzglnoII0gLj3PNh4fZkcFA= -github.com/lucasjones/reggen v0.0.0-20180717132126-cdb49ff09d77/go.mod h1:5ELEyG+X8f+meRWHuqUOewBOhvHkl7M76pdGEansxW4= github.com/lyft/protoc-gen-validate v0.0.13/go.mod h1:XbGvPuh87YZc5TdIa2/I4pLk0QoUACkjt2znoq26NVQ= -github.com/magiconair/properties v1.8.0/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czPbwD3XqdrwzmxQ= github.com/magiconair/properties v1.8.7 h1:IeQXZAiQcpL9mgcAe1Nu6cX9LLw6ExEHKjN0VQdvPDY= github.com/magiconair/properties v1.8.7/go.mod h1:Dhd985XPs7jluiymwWYZ0G4Z61jb3vdS329zhj2hYo0= -github.com/mailru/easyjson v0.0.0-20190614124828-94de47d64c63/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc= -github.com/mailru/easyjson v0.0.0-20190626092158-b2ccc519800e/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc= github.com/manifoldco/promptui v0.9.0 h1:3V4HzJk1TtXW1MTZMP7mdlwbBpIinw3HztaIlYthEiA= github.com/manifoldco/promptui v0.9.0/go.mod h1:ka04sppxSGFAtxX0qhlYQjISsg9mR4GWtQEhdbn6Pgg= -github.com/matryer/moq v0.0.0-20190312154309-6cfb0558e1bd/go.mod h1:9ELz6aaclSIGnZBoaSLZ3NAl1VTufbOrXBPvtcy6WiQ= github.com/mattn/go-colorable v0.0.9/go.mod h1:9vuHe8Xs5qXnSaW/c/ABM9alt+Vo+STaOChaDxuIBZU= -github.com/mattn/go-colorable v0.1.2/go.mod h1:U0ppj6V5qS13XJ6of8GYAs25YV2eR4EVcfRqFIhoBtE= -github.com/mattn/go-colorable v0.1.7/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc= -github.com/mattn/go-colorable v0.1.8/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc= github.com/mattn/go-colorable v0.1.9/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc= +github.com/mattn/go-colorable v0.1.12/go.mod h1:u5H1YNBxpqRaxsYJYSkiCWKzEfiAb1Gb520KVy5xxl4= github.com/mattn/go-colorable v0.1.13 h1:fFA4WZxdEF4tXPZVKMLwD8oUnCTTo08duU7wxecdEvA= github.com/mattn/go-colorable v0.1.13/go.mod h1:7S9/ev0klgBDR4GtXTXX8a3vIGJpMovkB8vQcUbaXHg= github.com/mattn/go-isatty v0.0.3/go.mod h1:M+lRXTBqGeGNdLjl/ufCoiOlB5xdOkqRJdNxMWT7Zi4= github.com/mattn/go-isatty v0.0.4/go.mod h1:M+lRXTBqGeGNdLjl/ufCoiOlB5xdOkqRJdNxMWT7Zi4= -github.com/mattn/go-isatty v0.0.8/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s= -github.com/mattn/go-isatty v0.0.9/go.mod h1:YNRxwqDuOph6SZLI9vUUz6OYw3QyUt7WiY2yME+cCiQ= github.com/mattn/go-isatty v0.0.12/go.mod h1:cbi8OIDigv2wuxKPP5vlRcQ1OAZbq2CE4Kysco4FUpU= github.com/mattn/go-isatty v0.0.14/go.mod h1:7GGIvUiUoEMVVmxf/4nioHXj79iQHKdU27kJ6hsGG94= github.com/mattn/go-isatty v0.0.16/go.mod h1:kYGgaQfpe5nmfYZH+SKPsOc2e4SrIfOl2e/yFXSvRLM= @@ -896,20 +775,11 @@ github.com/mattn/go-isatty v0.0.19/go.mod h1:W+V8PltTTMOvKvAeJH7IuucS94S2C6jfK/D github.com/mattn/go-isatty v0.0.20 h1:xfD0iDuEKnDkl03q4limB+vH+GxLEtL/jb4xVJSWWEY= github.com/mattn/go-isatty v0.0.20/go.mod h1:W+V8PltTTMOvKvAeJH7IuucS94S2C6jfK/D7dTCTo3Y= github.com/mattn/go-runewidth v0.0.2/go.mod h1:LwmH8dsx7+W8Uxz3IHJYH5QSwggIsqBzpuz5H//U1FU= -github.com/mattn/go-runewidth v0.0.3/go.mod h1:LwmH8dsx7+W8Uxz3IHJYH5QSwggIsqBzpuz5H//U1FU= github.com/mattn/go-runewidth v0.0.4/go.mod h1:LwmH8dsx7+W8Uxz3IHJYH5QSwggIsqBzpuz5H//U1FU= -github.com/mattn/go-runewidth v0.0.9/go.mod h1:H031xJmbD/WCDINGzjvQ9THkh0rPKHF+m2gUSrubnMI= -github.com/mattn/go-sqlite3 v1.11.0/go.mod h1:FPy6KqzDD04eiIsT53CuJW3U88zkxoIYsOqkbpncsNc= -github.com/mattn/go-tty v0.0.0-20180907095812-13ff1204f104/go.mod h1:XPvLUNfbS4fJH25nqRHfWLMa1ONC8Amw+mIA639KxkE= github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0= -github.com/matttproud/golang_protobuf_extensions v1.0.4 h1:mmDVorXM7PCGKw94cs5zkfA9PSy5pEvNWRP0ET0TIVo= -github.com/matttproud/golang_protobuf_extensions v1.0.4/go.mod h1:BSXmuO+STAnVfrANrmjBb36TMTDstsz7MSK+HVaYKv4= github.com/miekg/dns v1.0.14/go.mod h1:W1PPwlIAgtquWBMBEV9nkV9Cazfe8ScdGz/Lj7v3Nrg= github.com/mikluke/co-pilot v0.0.0-20231002172848-ba00fa031618 h1:nMLk4aJ5dFvsoKLKq2cg0xff2+/P6JmQ8i5Oh/MP5A4= github.com/mikluke/co-pilot v0.0.0-20231002172848-ba00fa031618/go.mod h1:c5d2OPeqM/ZnXl16TZoNlZQ+jUDG7mNVvhUvcL5pcZA= -github.com/mimoo/StrobeGo v0.0.0-20181016162300-f8f6d4d2b643/go.mod h1:43+3pMjjKimDBf5Kr4ZFNGbLql1zKkbImw+fZbw3geM= -github.com/mimoo/StrobeGo v0.0.0-20210601165009-122bf33a46e0 h1:QRUSJEgZn2Snx0EmT/QLXibWjSUDjKWvXIT19NBVp94= -github.com/mimoo/StrobeGo v0.0.0-20210601165009-122bf33a46e0/go.mod h1:43+3pMjjKimDBf5Kr4ZFNGbLql1zKkbImw+fZbw3geM= github.com/minio/highwayhash v1.0.2 h1:Aak5U0nElisjDCfPSG79Tgzkn2gl66NxOMspRrKnA/g= github.com/minio/highwayhash v1.0.2/go.mod h1:BQskDq+xkJ12lmlUUi7U0M5Swg3EWR+dLTk+kldvVxY= github.com/mitchellh/cli v1.0.0/go.mod h1:hNIlj7HEI86fIcpObd7a0FcrxTWetlwJDGcceTlRvqc= @@ -923,11 +793,8 @@ github.com/mitchellh/gox v0.4.0/go.mod h1:Sd9lOJ0+aimLBi73mGofS1ycjY8lL3uZM3JPS4 github.com/mitchellh/iochan v1.0.0/go.mod h1:JwYml1nuB7xOzsp52dPpHFffvOCDupsG0QubkSMEySY= github.com/mitchellh/mapstructure v0.0.0-20160808181253-ca63d7c062ee/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= github.com/mitchellh/mapstructure v1.1.2/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= -github.com/mitchellh/mapstructure v1.4.1/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= -github.com/mitchellh/mapstructure v1.4.3/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= github.com/mitchellh/mapstructure v1.5.0 h1:jeMsZIYE/09sWLaz43PL7Gy6RuMjD2eJVyuac5Z2hdY= github.com/mitchellh/mapstructure v1.5.0/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= -github.com/mitchellh/pointerstructure v1.2.0/go.mod h1:BRAsLI5zgXmw97Lf6s25bs8ohIXc3tViBH44KcwB2g4= github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd h1:TRLaZ9cD/w8PVh93nsPXa1VrQ6jlwL5oN8l14QlcNfg= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= @@ -935,16 +802,12 @@ github.com/modern-go/reflect2 v0.0.0-20180701023420-4b7aa43c6742/go.mod h1:bx2lN github.com/modern-go/reflect2 v1.0.1/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0= github.com/modern-go/reflect2 v1.0.2 h1:xBagoLtFs94CBntxluKeaWgTMpvLxC4ur3nMaC9Gz0M= github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk= -github.com/modocache/gover v0.0.0-20171022184752-b58185e213c5/go.mod h1:caMODM3PzxT8aQXRPkAt8xlV/e7d7w8GM5g0fa5F0D8= -github.com/mschoch/smat v0.0.0-20160514031455-90eadee771ae/go.mod h1:qAyveg+e4CE+eKJXWVjKXM4ck2QobLqTDytGJbLLhJg= github.com/mtibben/percent v0.2.1 h1:5gssi8Nqo8QU/r2pynCm+hBQHpkB/uNK7BJCFogWdzs= github.com/mtibben/percent v0.2.1/go.mod h1:KG9uO+SZkUp+VkRHsCdYQV3XSZrrSpR3O9ibNBTZrns= github.com/mwitkow/go-conntrack v0.0.0-20161129095857-cc309e4a2223/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U= github.com/mwitkow/go-conntrack v0.0.0-20190716064945-2f068394615f h1:KUppIJq7/+SVif2QVs3tOP0zanoHgBEVAwHxUSIzRqU= github.com/mwitkow/go-conntrack v0.0.0-20190716064945-2f068394615f/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U= github.com/mwitkow/grpc-proxy v0.0.0-20181017164139-0f1106ef9c76/go.mod h1:x5OoJHDHqxHS801UIuhqGl6QdSAEJvtausosHSdazIo= -github.com/naoina/go-stringutil v0.1.0/go.mod h1:XJ2SJL9jCtBh+P9q5btrd/Ylo8XwT/h1USek5+NqSA0= -github.com/naoina/toml v0.1.2-0.20170918210437-9fafd6967416/go.mod h1:NBIhNtsFMo3G2szEBne+bO4gS192HuIYRqfvOWb4i1E= github.com/nats-io/jwt v0.3.0/go.mod h1:fRYCDE99xlTsqUzISS1Bi75UBJ6ljOJQOAAu5VglpSg= github.com/nats-io/jwt v0.3.2/go.mod h1:/euKqTS1ZD+zzjYrY7pseZrTtWQSjujC7xjPc8wL6eU= github.com/nats-io/nats-server/v2 v2.1.2/go.mod h1:Afk+wRZqkMQs/p45uXdrVLuab3gwv3Z8C4HTBu8GD/k= @@ -952,28 +815,28 @@ github.com/nats-io/nats.go v1.9.1/go.mod h1:ZjDU1L/7fJ09jvUSRVBR2e7+RnLiiIQyqyzE github.com/nats-io/nkeys v0.1.0/go.mod h1:xpnFELMwJABBLVhffcfd1MZx6VsNRFpEugbxziKVo7w= github.com/nats-io/nkeys v0.1.3/go.mod h1:xpnFELMwJABBLVhffcfd1MZx6VsNRFpEugbxziKVo7w= github.com/nats-io/nuid v1.0.1/go.mod h1:19wcPz3Ph3q0Jbyiqsd0kePYG7A95tJPxeL+1OSON2c= -github.com/neilotoole/errgroup v0.1.6/go.mod h1:Q2nLGf+594h0CLBs/Mbg6qOr7GtqDK7C2S41udRnToE= github.com/niemeyer/pretty v0.0.0-20200227124842-a10e7caefd8e/go.mod h1:zD1mROLANZcx1PVRCS0qkT7pwLkGfwJo4zjcN/Tysno= github.com/nxadm/tail v1.4.4/go.mod h1:kenIhsEOeOJmVchQTgglprH7qJGnHDVpk1VPCcaMI8A= github.com/nxadm/tail v1.4.8 h1:nPr65rt6Y5JFSKQO7qToXr7pePgD6Gwiw05lkbyAQTE= github.com/nxadm/tail v1.4.8/go.mod h1:+ncqLTQzXmGhMZNUePPaPqPvBxHAIsmXswZKocGu+AU= +github.com/oasisprotocol/curve25519-voi v0.0.0-20230904125328-1f23a7beb09a h1:dlRvE5fWabOchtH7znfiFCcOvmIYgOeAS5ifBXBlh9Q= +github.com/oasisprotocol/curve25519-voi v0.0.0-20230904125328-1f23a7beb09a/go.mod h1:hVoHR2EVESiICEMbg137etN/Lx+lSrHPTD39Z/uE+2s= github.com/oklog/oklog v0.3.2/go.mod h1:FCV+B7mhrz4o+ueLpx+KqkyXRGMWOYEvfiXtdGtbWGs= github.com/oklog/run v1.0.0/go.mod h1:dlhp/R75TPv97u0XWUtDeV/lRKWPKSdTuV0TZvrmrQA= -github.com/oklog/ulid v1.3.1/go.mod h1:CirwcVhetQ6Lv90oh/F+FBtV6XMibvdAFo93nm5qn4U= +github.com/oklog/run v1.1.0 h1:GEenZ1cK0+q0+wsJew9qUg/DyD8k3JzYsZAi5gYi2mA= +github.com/oklog/run v1.1.0/go.mod h1:sVPdnTZT1zYwAJeCMu2Th4T21pA3FPOQRfWjQlk7DVU= github.com/olekukonko/tablewriter v0.0.0-20170122224234-a0225b3f23b5/go.mod h1:vsDQFd/mU46D+Z4whnwzcISnGGzXWMclvtLoiIKAKIo= -github.com/olekukonko/tablewriter v0.0.5/go.mod h1:hPp6KlRPjbx+hW8ykQs1w3UBbZlj6HuIJcUGPhkA7kY= github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= github.com/onsi/ginkgo v1.7.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= github.com/onsi/ginkgo v1.12.1/go.mod h1:zj2OWP4+oCPe1qIXoGWkgMRwljMUYCdkwsT2108oapk= github.com/onsi/ginkgo v1.14.0/go.mod h1:iSB4RoI2tjJc9BBv4NKIKWKya62Rps+oPG/Lv9klQyY= github.com/onsi/ginkgo v1.16.4 h1:29JGrr5oVBm5ulCWet69zQkzWipVXIol6ygQUe/EzNc= github.com/onsi/ginkgo v1.16.4/go.mod h1:dX+/inL/fNMqNlz0e9LfyB9TswhZpCVdJM/Z6Vvnwo0= -github.com/onsi/gomega v1.4.1/go.mod h1:C1qb7wdrVGGVU+Z6iS04AVkA3Q65CEZX59MT0QO5uiA= github.com/onsi/gomega v1.4.3/go.mod h1:ex+gbHU/CVuBBDIJjb2X0qEXbFg53c61hWP/1CpauHY= github.com/onsi/gomega v1.7.1/go.mod h1:XdKZgCCFLUoM/7CFJVPcG8C1xQ1AJ0vpAezJrB7JYyY= github.com/onsi/gomega v1.10.1/go.mod h1:iN09h71vgCQne3DLsj+A5owkum+a2tYe+TOCB1ybHNo= -github.com/onsi/gomega v1.20.0 h1:8W0cWlwFkflGPLltQvLRB7ZVD5HuP6ng320w2IS245Q= -github.com/onsi/gomega v1.20.0/go.mod h1:DtrZpjmvpn2mPm4YWQa0/ALMDj9v4YxLgojwPeREyVo= +github.com/onsi/gomega v1.26.0 h1:03cDLK28U6hWvCAns6NeydX3zIm4SF3ci69ulidS32Q= +github.com/onsi/gomega v1.26.0/go.mod h1:r+zV744Re+DiYCIPRlYOTxn0YkOLcAnW8k1xXdMPGhM= github.com/op/go-logging v0.0.0-20160315200505-970db520ece7/go.mod h1:HzydrMdWErDVzsI23lYNej1Htcns9BCg93Dk0bBINWk= github.com/opencontainers/go-digest v1.0.0 h1:apOUWs51W5PlhuyGyz9FCeeBIOUDA/6nW8Oi/yOhh5U= github.com/opencontainers/go-digest v1.0.0/go.mod h1:0JzlMkj0TRzQZfJkVvzbP0HBR3IKzErnv2BNG4W4MAM= @@ -984,7 +847,6 @@ github.com/opencontainers/runc v1.1.3/go.mod h1:1J5XiS+vdZ3wCyZybsuxXZWGrgSr8fFJ github.com/opentracing-contrib/go-observer v0.0.0-20170622124052-a52f23424492/go.mod h1:Ngi6UdF0k5OKD5t5wlmGhe/EDKPoUM3BXZSSfIuJbis= github.com/opentracing/basictracer-go v1.0.0/go.mod h1:QfBfYuafItcjQuMwinw9GhYKwFXS9KnPs5lxoYwgW74= github.com/opentracing/opentracing-go v1.0.2/go.mod h1:UkNAQd3GIcIGf0SeVgPpRdFStlNbqXla1AfSYxPUl2o= -github.com/opentracing/opentracing-go v1.0.3-0.20180606204148-bd9c31933947/go.mod h1:UkNAQd3GIcIGf0SeVgPpRdFStlNbqXla1AfSYxPUl2o= github.com/opentracing/opentracing-go v1.1.0/go.mod h1:UkNAQd3GIcIGf0SeVgPpRdFStlNbqXla1AfSYxPUl2o= github.com/openzipkin-contrib/zipkin-go-opentracing v0.4.5/go.mod h1:/wsWhb9smxSfWAKL3wpBW7V8scJMt8N8gnaMCS9E/cA= github.com/openzipkin/zipkin-go v0.1.6/go.mod h1:QgAqvLzwWbR/WpD4A3cGpPtJrZXNIiJc5AZX7/PBEpw= @@ -996,18 +858,13 @@ github.com/pact-foundation/pact-go v1.0.4/go.mod h1:uExwJY4kCzNPcHRj+hCR/HBbOOIw github.com/pascaldekloe/goe v0.0.0-20180627143212-57f6aae5913c/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc= github.com/pascaldekloe/goe v0.1.0 h1:cBOtyMzM9HTpWjXfbbunk26uA6nG3a8n06Wieeh0MwY= github.com/pascaldekloe/goe v0.1.0/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc= -github.com/paulbellamy/ratecounter v0.2.0/go.mod h1:Hfx1hDpSGoqxkVVpBi/IlYD7kChlfo5C6hzIHwPqfFE= github.com/pborman/uuid v1.2.0/go.mod h1:X/NO0urCmaxf9VXbdlT7C2Yzkj2IKimNn4k+gtPdI/k= -github.com/pelletier/go-toml v1.2.0/go.mod h1:5z9KED0ma1S8pY6P1sdut58dfprrGBbd/94hg7ilaic= github.com/pelletier/go-toml/v2 v2.1.0 h1:FnwAJ4oYMvbT/34k9zzHuZNrhlz48GB3/s6at6/MHO4= github.com/pelletier/go-toml/v2 v2.1.0/go.mod h1:tJU2Z3ZkXwnxa4DPO899bsyIoywizdUvyaeZurnPPDc= github.com/performancecopilot/speed v3.0.0+incompatible/go.mod h1:/CLtqpZ5gBg1M9iaPbIdPPGyKcA8hKdoy6hAWba7Yac= -github.com/peterh/liner v1.0.1-0.20180619022028-8c1271fcf47f/go.mod h1:xIteQHvHuaLYG9IFj6mSxM0fCKrs34IrEQUhOYuGPHc= -github.com/peterh/liner v1.1.1-0.20190123174540-a2c9a5303de7/go.mod h1:CRroGNssyjTd/qIG2FyxByd2S8JEAZXBl4qUrZf8GS0= github.com/petermattis/goid v0.0.0-20180202154549-b0b1615b78e5/go.mod h1:jvVRKCrJTQWu0XVbaOlby/2lO20uSCHEMzzplHXte1o= -github.com/petermattis/goid v0.0.0-20230317030725-371a4b8eda08 h1:hDSdbBuw3Lefr6R18ax0tZ2BJeNB3NehB3trOwYBsdU= -github.com/petermattis/goid v0.0.0-20230317030725-371a4b8eda08/go.mod h1:pxMtw7cyUw6B2bRH0ZBANSPg+AoSud1I1iyJHI69jH4= -github.com/philhofer/fwd v1.0.0/go.mod h1:gk3iGcWd9+svBvR0sR+KPcfE+RNWozjowpeBVG3ZVNU= +github.com/petermattis/goid v0.0.0-20231207134359-e60b3f734c67 h1:jik8PHtAIsPlCRJjJzl4udgEf7hawInF9texMeO2jrU= +github.com/petermattis/goid v0.0.0-20231207134359-e60b3f734c67/go.mod h1:pxMtw7cyUw6B2bRH0ZBANSPg+AoSud1I1iyJHI69jH4= github.com/pierrec/lz4 v1.0.2-0.20190131084431-473cd7ce01a1/go.mod h1:3/3N9NVKO0jef7pBehbT1qWhCMrIgbYNnFAZCqQ5LRc= github.com/pierrec/lz4 v2.0.5+incompatible/go.mod h1:pdkljMzZIN41W+lC3N2tnIh5sFi+IEE17M5jbnwPHcY= github.com/pingcap/errors v0.11.4 h1:lFuQV/oaUMGcD2tqt+01ROSmJs75VG1ToEOkZIZ4nE4= @@ -1018,7 +875,6 @@ github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINE github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/profile v1.2.1/go.mod h1:hJw3o1OdXxsrSjjVksARp5W95eeEaEfptyVZyv6JUPA= -github.com/pkg/term v0.0.0-20180730021639-bffc007b7fd5/go.mod h1:eCbImbZ95eXtAUIbLAuAVnBnwf83mjf6QIVH8SHYwqQ= github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 h1:Jamvg5psRIccs7FGNTlIRMkT8wgtp5eCXdBlqhYGL6U= github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= @@ -1029,37 +885,26 @@ github.com/prometheus/client_golang v1.0.0/go.mod h1:db9x61etRT2tGnBNRi70OPL5Fsn github.com/prometheus/client_golang v1.3.0/go.mod h1:hJaj2vgQTGQmVCsAACORcieXFeDPbaTKGT+JTgUa3og= github.com/prometheus/client_golang v1.4.0/go.mod h1:e9GMxYsXl05ICDXkRhurwBS4Q3OK1iX/F2sw+iXX5zU= github.com/prometheus/client_golang v1.7.1/go.mod h1:PY5Wy2awLA44sXw4AOSfFBetzPP4j5+D6mVACh+pe2M= -github.com/prometheus/client_golang v1.14.0 h1:nJdhIvne2eSX/XRAFV9PcvFFRbrjbcTUj0VP62TMhnw= -github.com/prometheus/client_golang v1.14.0/go.mod h1:8vpkKitgIVNcqrRBWh1C4TIUQgYNtG/XQE4E/Zae36Y= +github.com/prometheus/client_golang v1.19.0 h1:ygXvpU1AoN1MhdzckN+PyD9QJOSD4x7kmXYlnfbA6JU= +github.com/prometheus/client_golang v1.19.0/go.mod h1:ZRM9uEAypZakd+q/x7+gmsvXdURP+DABIEIjnmDdp+k= github.com/prometheus/client_model v0.0.0-20180712105110-5c3871d89910/go.mod h1:MbSGuTsp3dbXC40dX6PRTWyKYBIrTGTE9sqQNg2J8bo= github.com/prometheus/client_model v0.0.0-20190115171406-56726106282f/go.mod h1:MbSGuTsp3dbXC40dX6PRTWyKYBIrTGTE9sqQNg2J8bo= github.com/prometheus/client_model v0.0.0-20190129233127-fd36f4220a90/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= github.com/prometheus/client_model v0.0.0-20190812154241-14fe0d1b01d4/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= github.com/prometheus/client_model v0.1.0/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= github.com/prometheus/client_model v0.2.0/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= -github.com/prometheus/client_model v0.3.0 h1:UBgGFHqYdG/TPFD1B1ogZywDqEkwp3fBMvqdiQ7Xew4= -github.com/prometheus/client_model v0.3.0/go.mod h1:LDGWKZIo7rky3hgvBe+caln+Dr3dPggB5dvjtD7w9+w= -github.com/prometheus/common v0.0.0-20181113130724-41aa239b4cce/go.mod h1:daVV7qP5qjZbuso7PdcryaAu0sAZbrN9i7WWcTMWvro= +github.com/prometheus/client_model v0.6.1 h1:ZKSh/rekM+n3CeS952MLRAdFwIKqeY8b62p8ais2e9E= +github.com/prometheus/client_model v0.6.1/go.mod h1:OrxVMOVHjw3lKMa8+x6HeMGkHMQyHDk9E3jmP2AmGiY= github.com/prometheus/common v0.2.0/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4= github.com/prometheus/common v0.4.1/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4= -github.com/prometheus/common v0.6.0/go.mod h1:eBmuwkDJBwy6iBfxCBob6t6dR6ENT/y+J+Zk0j9GMYc= github.com/prometheus/common v0.7.0/go.mod h1:DjGbpBbp5NYNiECxcL/VnbXCCaQpKd3tt26CguLLsqA= github.com/prometheus/common v0.9.1/go.mod h1:yhUN8i9wzaXS3w1O07YhxHEBxD+W35wd8bs7vj7HSQ4= github.com/prometheus/common v0.10.0/go.mod h1:Tlit/dnDKsSWFlCLTWaA1cyBgKHSMdTB80sz/V91rCo= github.com/prometheus/common v0.15.0/go.mod h1:U+gB1OBLb1lF3O42bTCL+FK18tX9Oar16Clt/msog/s= -github.com/prometheus/common v0.42.0 h1:EKsfXEYo4JpWMHH5cg+KOUWeuJSov1Id8zGR8eeI1YM= -github.com/prometheus/common v0.42.0/go.mod h1:xBwqVerjNdUDjgODMpudtOMwlOwf2SaTr1yjz4b7Zbc= -github.com/prometheus/procfs v0.0.0-20181005140218-185b4288413d/go.mod h1:c3At6R/oaqEKCNdg8wHV1ftS6bRYblBhIjjI8uT2IGk= -github.com/prometheus/procfs v0.0.0-20190117184657-bf6a532e95b1/go.mod h1:c3At6R/oaqEKCNdg8wHV1ftS6bRYblBhIjjI8uT2IGk= -github.com/prometheus/procfs v0.0.2/go.mod h1:TjEm7ze935MbeOT/UhFTIMYKhuLP4wbCsTZCD3I8kEA= -github.com/prometheus/procfs v0.0.8/go.mod h1:7Qr8sr6344vo1JqZ6HhLceV9o3AJ1Ff+GxbHq6oeK9A= -github.com/prometheus/procfs v0.1.3/go.mod h1:lV6e/gmhEcM9IjHGsFOCxxuZ+z1YqCvr4OA4YeYWdaU= -github.com/prometheus/procfs v0.3.0/go.mod h1:lV6e/gmhEcM9IjHGsFOCxxuZ+z1YqCvr4OA4YeYWdaU= -github.com/prometheus/procfs v0.9.0 h1:wzCHvIvM5SxWqYvwgVL7yJY8Lz3PKn49KQtpgMYJfhI= -github.com/prometheus/procfs v0.9.0/go.mod h1:+pB4zwohETzFnmlpe6yd2lSc+0/46IYZRB/chUwxUZY= -github.com/prometheus/tsdb v0.7.1/go.mod h1:qhTCs0VvXwvX/y3TZrWD7rabWM+ijKTux40TwIPHuXU= -github.com/rakyll/statik v0.1.7 h1:OF3QCZUuyPxuGEP7B4ypUa7sB/iHtqOTDYZXGM8KOdQ= -github.com/rakyll/statik v0.1.7/go.mod h1:AlZONWzMtEnMs7W4e/1LURLiI49pIMmp6V9Unghqrcc= +github.com/prometheus/common v0.52.2 h1:LW8Vk7BccEdONfrJBDffQGRtpSzi5CQaRZGtboOO2ck= +github.com/prometheus/common v0.52.2/go.mod h1:lrWtQx+iDfn2mbH5GUzlH9TSHyfZpHkSiG1W7y3sF2Q= +github.com/prometheus/procfs v0.12.0 h1:jluTpSng7V9hY0O2R9DzzJHYb2xULk9VTR1V1R/k6Bo= +github.com/prometheus/procfs v0.12.0/go.mod h1:pcuDEFsWDnvcgNzo4EEweacyhjeA9Zk3cnaOZAZEfOo= github.com/rcrowley/go-metrics v0.0.0-20181016184325-3113b8401b8a/go.mod h1:bCqnVzQkZxMG4s8nGwiZ5l3QUCyqpo9Y+/ZMZ9VjZe4= github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475 h1:N/ElC8H3+5XpJzTSTfLsJV/mx9Q9g7kxmchpfZyxgzM= github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475/go.mod h1:bCqnVzQkZxMG4s8nGwiZ5l3QUCyqpo9Y+/ZMZ9VjZe4= @@ -1067,21 +912,18 @@ github.com/regen-network/cosmos-proto v0.3.1 h1:rV7iM4SSFAagvy8RiyhiACbWEGotmqzy github.com/regen-network/cosmos-proto v0.3.1/go.mod h1:jO0sVX6a1B36nmE8C9xBFXpNwWejXC7QqCOnH3O0+YM= github.com/regen-network/protobuf v1.3.3-alpha.regen.1 h1:OHEc+q5iIAXpqiqFKeLpu5NwTIkVXUs48vFMwzqpqY4= github.com/regen-network/protobuf v1.3.3-alpha.regen.1/go.mod h1:2DjTFR1HhMQhiWC5sZ4OhQ3+NtdbZ6oBDKQwq5Ou+FI= -github.com/retailnext/hllpp v1.0.1-0.20180308014038-101a6d2f8b52/go.mod h1:RDpi1RftBQPUCDRw6SmxeaREsAaRKnOclghuzp/WRzc= -github.com/rjeczalik/notify v0.9.1/go.mod h1:rKwnCoCGeuQnwBtTSPL9Dad03Vh2n40ePRrjvIXnJho= github.com/rogpeppe/fastuuid v0.0.0-20150106093220-6724a57986af/go.mod h1:XWv6SoW27p1b0cqNHllgS5HIMJraePCO15w5zCzIWYg= github.com/rogpeppe/fastuuid v1.2.0/go.mod h1:jVj6XXZzXRy/MSR5jhDC/2q6DgLz+nrA6LYCDYWNEvQ= github.com/rogpeppe/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4= github.com/rogpeppe/go-internal v1.9.0/go.mod h1:WtVeX8xhTBvf0smdhujwtBcq4Qrzq/fJaraNFVN+nFs= -github.com/rogpeppe/go-internal v1.11.0 h1:cWPaGQEPrBb5/AsnsZesgZZ9yb1OQ+GOISoDNXVBh4M= -github.com/rogpeppe/go-internal v1.11.0/go.mod h1:ddIwULY96R17DhadqLgMfk9H9tvdUzkipdSkR5nkCZA= +github.com/rogpeppe/go-internal v1.12.0 h1:exVL4IDcn6na9z1rAb56Vxr+CgyK3nn3O+epU5NdKM8= +github.com/rogpeppe/go-internal v1.12.0/go.mod h1:E+RYuTGaKKdloAfM02xzb0FW3Paa99yedzYV+kq4uf4= github.com/rs/cors v1.7.0/go.mod h1:gFx+x8UowdsKA9AchylcLynDq+nNFfI8FkUZdN/jGCU= github.com/rs/cors v1.8.3 h1:O+qNyWn7Z+F9M0ILBHgMVPuB1xTOucVd5gtaYyXBpRo= github.com/rs/cors v1.8.3/go.mod h1:XyqrcTp5zjWr1wsJ8PIRZssZ8b/WMcMf71DJnit4EMU= github.com/rs/xid v1.5.0/go.mod h1:trrq9SKmegXys3aeAKXMUTdJsYXVwGY3RLcfgqegfbg= github.com/rs/zerolog v1.32.0 h1:keLypqrlIjaFsbmJOBdB/qvyF8KEtCWHwobLp5l/mQ0= github.com/rs/zerolog v1.32.0/go.mod h1:/7mN4D5sKwJLZQ2b/znpjC3/GQWY/xaDXUM0kKWRHss= -github.com/russross/blackfriday v1.5.2/go.mod h1:JO/DiYxRf+HjHt06OyowR9PTA263kcR/rfWxYHBV53g= github.com/russross/blackfriday/v2 v2.0.1/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= github.com/ryanuber/columnize v0.0.0-20160712163229-9b3edd62028f/go.mod h1:sm1tb6uqfes/u+d4ooFouqFdy9/2g9QGwK3SQygK0Ts= @@ -1093,11 +935,6 @@ github.com/samuel/go-zookeeper v0.0.0-20190923202752-2cc03de413da/go.mod h1:gi+0 github.com/sasha-s/go-deadlock v0.3.1 h1:sqv7fDNShgjcaxkO0JNcOAlr8B9+cV5Ey/OB71efZx0= github.com/sasha-s/go-deadlock v0.3.1/go.mod h1:F73l+cr82YSh10GxyRI6qZiCgK64VaZjwesgfQ1/iLM= github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529/go.mod h1:DxrIzT+xaE7yg65j358z/aeFdxmN0P9QXhEzd20vsDc= -github.com/segmentio/fasthash v1.0.3/go.mod h1:waKX8l2N8yckOgmSsXJi7x1ZfdKZ4x7KRMzBtS3oedY= -github.com/segmentio/kafka-go v0.1.0/go.mod h1:X6itGqS9L4jDletMsxZ7Dz+JFWxM6JHfPOCvTvk+EJo= -github.com/segmentio/kafka-go v0.2.0/go.mod h1:X6itGqS9L4jDletMsxZ7Dz+JFWxM6JHfPOCvTvk+EJo= -github.com/sergi/go-diff v1.0.0/go.mod h1:0CfEIISq7TuYL3j771MWULgwwjU+GofnZX9QAmXWZgo= -github.com/shirou/gopsutil v3.21.4-0.20210419000835-c7a38de76ee5+incompatible/go.mod h1:5b4v6he4MtMOwMlS0TUMTu2PcXUg8+E1lC7eC3UO/RA= github.com/shurcooL/sanitized_anchor_name v1.0.0/go.mod h1:1NzhyTcUVG4SuEtjjoZeVRXNmyL/1OwPU0+IJeTBvfc= github.com/sirupsen/logrus v1.2.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo= github.com/sirupsen/logrus v1.4.2/go.mod h1:tLMulIdttU9McNUspp0xgXVQah82FyeX6MwdIuYE2rE= @@ -1112,26 +949,18 @@ github.com/sony/gobreaker v0.4.1/go.mod h1:ZKptC7FHNvhBz7dN2LGjPVBz2sZJmc0/PkyDJ github.com/sourcegraph/conc v0.3.0 h1:OQTbbt6P72L20UqAkXXuLOj79LfEanQ+YQFNpLA9ySo= github.com/sourcegraph/conc v0.3.0/go.mod h1:Sdozi7LEKbFPqYX2/J+iBAM6HpqSLTASQIKqDmF7Mt0= github.com/spaolacci/murmur3 v0.0.0-20180118202830-f09979ecbc72/go.mod h1:JwIasOWyU6f++ZhiEuf87xNszmSA2myDM2Kzu9HwQUA= -github.com/spaolacci/murmur3 v1.1.0/go.mod h1:JwIasOWyU6f++ZhiEuf87xNszmSA2myDM2Kzu9HwQUA= -github.com/spf13/afero v1.1.2/go.mod h1:j4pytiNVoe2o6bmDsKpLACNPDBIoEAkihy7loJ1B0CQ= github.com/spf13/afero v1.11.0 h1:WJQKhtpdm3v2IzqG8VMqrr6Rf3UYpEF239Jy9wNepM8= github.com/spf13/afero v1.11.0/go.mod h1:GH9Y3pIexgf1MTIWtNGyogA5MwRIDXGUr+hbWNoBjkY= -github.com/spf13/cast v1.3.0/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE= github.com/spf13/cast v1.6.0 h1:GEiTHELF+vaR5dhz3VqZfFSzZjYbgeKDpBxQVS4GYJ0= github.com/spf13/cast v1.6.0/go.mod h1:ancEpBxwJDODSW/UG4rDrAqiKolqNNh2DX3mk86cAdo= github.com/spf13/cobra v0.0.3/go.mod h1:1l0Ry5zgKvJasoi3XT1TypsSe7PqH0Sj9dhYf7v3XqQ= -github.com/spf13/cobra v0.0.5/go.mod h1:3K3wKZymM7VvHMDS9+Akkh4K60UwM26emMESw8tLCHU= github.com/spf13/cobra v1.8.0 h1:7aJaZx1B85qltLMc546zn58BxxfZdR/W22ej9CFoEf0= github.com/spf13/cobra v1.8.0/go.mod h1:WXLWApfZ71AjXPya3WOlMsY9yMs7YeiHhFVlvLyhcho= -github.com/spf13/jwalterweatherman v1.0.0/go.mod h1:cQK4TGJAtQXfYWX+Ddv3mKDzgVb68N+wFjFa4jdeBTo= github.com/spf13/pflag v1.0.1/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4= -github.com/spf13/pflag v1.0.3/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4= github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA= github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= -github.com/spf13/viper v1.3.2/go.mod h1:ZiWeW+zYFKm7srdB9IoDzzZXaJaI5eL9QjNiN/DMA2s= github.com/spf13/viper v1.18.2 h1:LUXCnvUvSM6FXAsj6nnfc8Q2tp1dIgUfY9Kc8GsSOiQ= github.com/spf13/viper v1.18.2/go.mod h1:EKmWIqdnk5lOcmR72yw6hS+8OPYcwD0jteitLMVB+yk= -github.com/status-im/keycard-go v0.0.0-20190316090335-8537d3370df4/go.mod h1:RZLeN1LMWmRsyYjvAu+I6Dm9QmlDaIIt+Y+4Kd7Tp+Q= github.com/streadway/amqp v0.0.0-20190404075320-75d898a42a94/go.mod h1:AZpEONHx3DKn8O/DFsRAY58/XVQiIPMTMB1SddzLXVw= github.com/streadway/amqp v0.0.0-20190827072141-edfb9018d271/go.mod h1:AZpEONHx3DKn8O/DFsRAY58/XVQiIPMTMB1SddzLXVw= github.com/streadway/handy v0.0.0-20190108123426-d5acb3125c2a/go.mod h1:qNTQ5P5JnDBl6z3cMAg/SywNDC5ABu5ApDIw6lUbRmI= @@ -1141,7 +970,6 @@ github.com/stretchr/objx v0.4.0/go.mod h1:YvHI0jy2hoMjB+UWwv71VJQ9isScKT/TqJzVSS github.com/stretchr/objx v0.5.0/go.mod h1:Yh+to48EsGEfYuaHDzXPcE3xhTkx73EhmCGUpEOglKo= github.com/stretchr/objx v0.5.2 h1:xuMeJ0Sdp5ZMRXx/aWO6RZxdr3beISkG5/G/aIRr3pY= github.com/stretchr/objx v0.5.2/go.mod h1:FRsXN1f5AsAjCGJKqEizvkpNtU+EGNCLh3NxZ/8L+MA= -github.com/stretchr/testify v1.2.0/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI= github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4= @@ -1149,6 +977,7 @@ github.com/stretchr/testify v1.5.1/go.mod h1:5W2xD1RspED5o8YsWQXVCued0rvSQ+mT+I5 github.com/stretchr/testify v1.6.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= +github.com/stretchr/testify v1.7.2/go.mod h1:R6va5+xMeoiuVRoj+gSkQ7d3FALtqAAGI1FQKckRals= github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU= github.com/stretchr/testify v1.8.1/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4= github.com/stretchr/testify v1.8.4/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo= @@ -1160,42 +989,21 @@ github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 h1:epCh84lMvA70 github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7/go.mod h1:q4W45IWZaF22tdD+VEXcAWRA037jwmWEB5VWYORlTpc= github.com/tendermint/go-amino v0.16.0 h1:GyhmgQKvqF82e2oZeuMSp9JTN0N09emoSZlb2lyGa2E= github.com/tendermint/go-amino v0.16.0/go.mod h1:TQU0M1i/ImAo+tYpZi73AU3V/dKeCoMC9Sphe2ZwGME= -github.com/tidwall/btree v1.6.0 h1:LDZfKfQIBHGHWSwckhXI0RPSXzlo+KYdjK7FWSqOzzg= -github.com/tidwall/btree v1.6.0/go.mod h1:twD9XRA5jj9VUQGELzDO4HPQTNJsoWWfYEL+EUQ2cKY= -github.com/tidwall/gjson v1.12.1/go.mod h1:/wbyibRr2FHMks5tjHJ5F8dMZh3AcwJEMf5vlfC0lxk= -github.com/tidwall/gjson v1.14.0/go.mod h1:/wbyibRr2FHMks5tjHJ5F8dMZh3AcwJEMf5vlfC0lxk= -github.com/tidwall/match v1.1.1/go.mod h1:eRSPERbgtNPcGhD8UCthc6PmLEQXEWd3PRB5JTxsfmM= -github.com/tidwall/pretty v1.2.0/go.mod h1:ITEVvHYasfjBbM0u2Pg8T2nJnzm8xPwvNhhsoaGGjNU= -github.com/tidwall/sjson v1.2.4/go.mod h1:098SZ494YoMWPmMO6ct4dcFnqxwj9r/gF0Etp19pSNM= -github.com/tinylib/msgp v1.0.2/go.mod h1:+d+yLhGm8mzTaHzB+wgMYrodPfmZrzkirds8fDWklFE= -github.com/tklauser/go-sysconf v0.3.5/go.mod h1:MkWzOF4RMCshBAMXuhXJs64Rte09mITnppBXY/rYEFI= -github.com/tklauser/numcpus v0.2.2/go.mod h1:x3qojaO3uyYt0i56EW/VUYs7uBvdl2fkfZFu0T9wgjM= +github.com/tidwall/btree v1.7.0 h1:L1fkJH/AuEh5zBnnBbmTwQ5Lt+bRJ5A8EWecslvo9iI= +github.com/tidwall/btree v1.7.0/go.mod h1:twD9XRA5jj9VUQGELzDO4HPQTNJsoWWfYEL+EUQ2cKY= github.com/tmc/grpc-websocket-proxy v0.0.0-20170815181823-89b8d40f7ca8/go.mod h1:ncp9v5uamzpCO7NfCPTXjqaC+bZgJeR0sMTm6dMHP7U= github.com/tv42/httpunix v0.0.0-20150427012821-b75d8614f926/go.mod h1:9ESjWnEqriFuLhtthL60Sar/7RFoluCcXsuvEwTV5KM= -github.com/tyler-smith/go-bip39 v1.0.1-0.20181017060643-dbb3b84ba2ef/go.mod h1:sJ5fKU0s6JVwZjjcUEX2zFOnvq0ASQ2K9Zr6cf67kNs= -github.com/tyler-smith/go-bip39 v1.0.2/go.mod h1:sJ5fKU0s6JVwZjjcUEX2zFOnvq0ASQ2K9Zr6cf67kNs= github.com/ugorji/go v1.1.7 h1:/68gy2h+1mWMrwZFeD1kQialdSzAb432dtpeJ42ovdo= github.com/ugorji/go v1.1.7/go.mod h1:kZn38zHttfInRq0xu/PH0az30d+z6vm202qpg1oXVMw= -github.com/ugorji/go/codec v0.0.0-20181204163529-d75b2dcb6bc8/go.mod h1:VFNgLljTbGfSG7qAOspJ7OScBnGdDN/yBr0sguwnwf0= github.com/ugorji/go/codec v1.1.7/go.mod h1:Ax+UKWsSmolVDwsd+7N3ZtXu+yMGCf907BLYF3GoBXY= -github.com/ugorji/go/codec v1.2.7 h1:YPXUKf7fYbp/y8xloBqZOw2qaVggbfwMlI8WM3wZUJ0= -github.com/ugorji/go/codec v1.2.7/go.mod h1:WGN1fab3R1fzQlVQTkfxVtIBhWDRqOviHU95kRgeqEY= +github.com/ugorji/go/codec v1.2.11 h1:BMaWp1Bb6fHwEtbplGBGJ498wD+LKlNSl25MjdZY4dU= +github.com/ugorji/go/codec v1.2.11/go.mod h1:UNopzCgEMSXjBc6AOMqYvWC1ktqTAfzJZUZgYf6w6lg= github.com/ulikunitz/xz v0.5.10/go.mod h1:nbz6k7qbPmH4IRqmfOplQw/tblSgqTqBwxkY0oWt/14= github.com/ulikunitz/xz v0.5.11 h1:kpFauv27b6ynzBNT/Xy+1k+fK4WswhN/6PN5WhFAGw8= github.com/ulikunitz/xz v0.5.11/go.mod h1:nbz6k7qbPmH4IRqmfOplQw/tblSgqTqBwxkY0oWt/14= github.com/urfave/cli v1.20.0/go.mod h1:70zkFmudgCuE/ngEzBv17Jvp/497gISqfk5gWijbERA= github.com/urfave/cli v1.22.1/go.mod h1:Gos4lmkARVdJ6EkW0WaNv/tZAAMe9V7XWyB60NtXRu0= -github.com/urfave/cli/v2 v2.3.0/go.mod h1:LJmUH05zAU44vOAcrfzZQKsZbVcdbOG8rtL3/XcUArI= -github.com/valyala/bytebufferpool v1.0.0/go.mod h1:6bBcMArwyJ5K/AmCkWv1jt77kVWyCJ6HpOuEn7z0Csc= -github.com/valyala/fasttemplate v1.0.1/go.mod h1:UQGH1tvbgY+Nz5t2n7tXsz52dQxojPUpymEIMZ47gx8= -github.com/valyala/fasttemplate v1.2.1/go.mod h1:KHLXt3tVN2HBp8eijSv/kGJopbvo7S+qRAEEKiv+SiQ= -github.com/vmihailenco/msgpack/v5 v5.3.5/go.mod h1:7xyJ9e+0+9SaZT0Wt1RGleJXzli6Q/V5KbhBonMG9jc= -github.com/vmihailenco/tagparser/v2 v2.0.0/go.mod h1:Wri+At7QHww0WTrCBeu4J6bNtoV6mEfg5OIWRZA9qds= -github.com/willf/bitset v1.1.3/go.mod h1:RjeCKbqT1RxIR/KWY6phxZiaY1IyutSBfGjNPySAYV4= github.com/xiang90/probing v0.0.0-20190116061207-43a291ad63a2/go.mod h1:UETIi67q53MR2AWcXfiuqkDkRtnGDLqkBTpCHuJHxtU= -github.com/xlab/treeprint v0.0.0-20180616005107-d6fb6747feb6/go.mod h1:ce1O1j6UtZfjr22oyGxGLbauSBp2YVXpARAosm7dHBg= -github.com/xordataexchange/crypt v0.0.3-0.20170626215501-b2862e3d0a77/go.mod h1:aYKd//L2LvnjZzWKhF00oedf4jCCReLcmhLdhm1A27Q= -github.com/ybbus/jsonrpc v2.1.2+incompatible/go.mod h1:XJrh1eMSzdIYFbM08flv0wp5G35eRniyeGut1z+LSiE= github.com/yuin/goldmark v1.1.25/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.1.32/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= @@ -1219,59 +1027,60 @@ go.opencensus.io v0.22.5/go.mod h1:5pWMHQbX5EPX2/62yrJeAkowc+lfs/XD7Uxpq3pI6kk= go.opencensus.io v0.23.0/go.mod h1:XItmlyltB5F7CS4xOC1DcqMoFqwtC6OG2xF7mCv7P7E= go.opencensus.io v0.24.0 h1:y73uSU6J157QMP2kn2r30vwW1A2W2WFwSCGnAVxeaD0= go.opencensus.io v0.24.0/go.mod h1:vNK8G9p7aAivkbmorf4v+7Hgx+Zs0yY+0fOtgBfjQKo= -go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.46.1 h1:SpGay3w+nEwMpfVnbqOLH5gY52/foP8RE8UzTZ1pdSE= -go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.46.1/go.mod h1:4UoMYEZOC0yN/sPGH76KPkkU7zgiEWYWL9vwmbnTJPE= -go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.46.1 h1:aFJWCqJMNjENlcleuuOkGAPH82y0yULBScfXcIEdS24= -go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.46.1/go.mod h1:sEGXWArGqc3tVa+ekntsN65DmVbVeW+7lTKTjZF3/Fo= -go.opentelemetry.io/otel v1.21.0 h1:hzLeKBZEL7Okw2mGzZ0cc4k/A7Fta0uoPgaJCr8fsFc= -go.opentelemetry.io/otel v1.21.0/go.mod h1:QZzNPQPm1zLX4gZK4cMi+71eaorMSGT3A4znnUvNNEo= -go.opentelemetry.io/otel/metric v1.21.0 h1:tlYWfeo+Bocx5kLEloTjbcDwBuELRrIFxwdQ36PlJu4= -go.opentelemetry.io/otel/metric v1.21.0/go.mod h1:o1p3CA8nNHW8j5yuQLdc1eeqEaPfzug24uvsyIEJRWM= +go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.47.0 h1:UNQQKPfTDe1J81ViolILjTKPr9WetKW6uei2hFgJmFs= +go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.47.0/go.mod h1:r9vWsPS/3AQItv3OSlEJ/E4mbrhUbbw18meOjArPtKQ= +go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.47.0 h1:sv9kVfal0MK0wBMCOGr+HeJm9v803BkJxGrk2au7j08= +go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.47.0/go.mod h1:SK2UL73Zy1quvRPonmOmRDiWk1KBV3LyIeeIxcEApWw= +go.opentelemetry.io/otel v1.22.0 h1:xS7Ku+7yTFvDfDraDIJVpw7XPyuHlB9MCiqqX5mcJ6Y= +go.opentelemetry.io/otel v1.22.0/go.mod h1:eoV4iAi3Ea8LkAEI9+GFT44O6T/D0GWAVFyZVCC6pMI= +go.opentelemetry.io/otel/metric v1.22.0 h1:lypMQnGyJYeuYPhOM/bgjbFM6WE44W1/T45er4d8Hhg= +go.opentelemetry.io/otel/metric v1.22.0/go.mod h1:evJGjVpZv0mQ5QBRJoBF64yMuOf4xCWdXjK8pzFvliY= go.opentelemetry.io/otel/sdk v1.21.0 h1:FTt8qirL1EysG6sTQRZ5TokkU8d0ugCj8htOgThZXQ8= go.opentelemetry.io/otel/sdk v1.21.0/go.mod h1:Nna6Yv7PWTdgJHVRD9hIYywQBRx7pbox6nwBnZIxl/E= -go.opentelemetry.io/otel/trace v1.21.0 h1:WD9i5gzvoUPuXIXH24ZNBudiarZDKuekPqi/E8fpfLc= -go.opentelemetry.io/otel/trace v1.21.0/go.mod h1:LGbsEB0f9LGjN+OZaQQ26sohbOmiMR+BaslueVtS/qQ= +go.opentelemetry.io/otel/trace v1.22.0 h1:Hg6pPujv0XG9QaVbGOBVHunyuLcCC3jN7WEhPx83XD0= +go.opentelemetry.io/otel/trace v1.22.0/go.mod h1:RbbHXVqKES9QhzZq/fE5UnOSILqRt40a21sPw2He1xo= go.opentelemetry.io/proto/otlp v0.7.0/go.mod h1:PqfVotwruBrMGOCsRd/89rSnXhoiJIqeYNgFYFoEGnI= go.uber.org/atomic v1.3.2/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= go.uber.org/atomic v1.4.0/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= go.uber.org/atomic v1.5.0/go.mod h1:sABNBOSYdrvTF6hTgEIbc7YasKWGhgEQZyfxyTvoXHQ= -go.uber.org/atomic v1.10.0 h1:9qC72Qh0+3MqyJbAn8YU5xVq1frD8bn3JtD2oXtafVQ= -go.uber.org/atomic v1.10.0/go.mod h1:LUxbIzbOniOlMKjJjyPfpl4v+PKK2cNJn91OQbhoJI0= +go.uber.org/atomic v1.7.0/go.mod h1:fEN4uk6kAWBTFdckzkM89CLk9XfWZrxpCo0nPH17wJc= +go.uber.org/goleak v1.1.10/go.mod h1:8a7PlsEVH3e/a/GLqe5IIrQx6GzcnRmZEufDUTk4A7A= go.uber.org/multierr v1.1.0/go.mod h1:wR5kodmAFQ0UK8QlbwjlSNy0Z68gJhDJUG5sjR94q/0= go.uber.org/multierr v1.3.0/go.mod h1:VgVr7evmIr6uPjLBxg28wmKNXyqE9akIJ5XnfpiKl+4= -go.uber.org/multierr v1.9.0 h1:7fIwc/ZtS0q++VgcfqFDxSBZVv/Xo49/SYnDFupUwlI= -go.uber.org/multierr v1.9.0/go.mod h1:X2jQV1h+kxSjClGpnseKVIxpmcjrj7MNnI0bnlfKTVQ= +go.uber.org/multierr v1.6.0/go.mod h1:cdWPpRnG4AhwMwsgIHip0KRBQjJy5kYEpYjJxpXp9iU= +go.uber.org/multierr v1.10.0 h1:S0h4aNzvfcFsC3dRF1jLoaov7oRaKqRGC/pUEJ2yvPQ= +go.uber.org/multierr v1.10.0/go.mod h1:20+QtiLqy0Nd6FdQB9TLXag12DsQkrbs3htMFfDN80Y= go.uber.org/tools v0.0.0-20190618225709-2cfd321de3ee/go.mod h1:vJERXedbb3MVM5f9Ejo0C68/HhF8uaILCdgjnY+goOA= -go.uber.org/zap v1.9.1/go.mod h1:vwi/ZaCAaUcBkycHslxD9B2zi4UTXhF60s6SWpuDF0Q= go.uber.org/zap v1.10.0/go.mod h1:vwi/ZaCAaUcBkycHslxD9B2zi4UTXhF60s6SWpuDF0Q= go.uber.org/zap v1.13.0/go.mod h1:zwrFLgMcdUuIBviXEYEH1YKNaOBnKXsx2IPda5bBwHM= -golang.org/x/crypto v0.0.0-20170930174604-9419663f5a44/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= +go.uber.org/zap v1.18.1/go.mod h1:xg/QME4nWcxGxrpdeYfq7UvYrLh66cuVKdrbD1XF/NI= golang.org/x/crypto v0.0.0-20180904163835-0709b304e793/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= golang.org/x/crypto v0.0.0-20181029021203-45a5f77698d3/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= -golang.org/x/crypto v0.0.0-20181203042331-505ab145d0a9/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= -golang.org/x/crypto v0.0.0-20190426145343-a29dc8fdc734/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20190510104115-cbcb75029529/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20190605123033-f99c8df09eb5/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20190701094942-4def268fd1a4/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= -golang.org/x/crypto v0.0.0-20190909091759-094676da4a83/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= -golang.org/x/crypto v0.0.0-20191206172530-e9b2fee46413/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= -golang.org/x/crypto v0.0.0-20200115085410-6d4e4cb37c7d/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= -golang.org/x/crypto v0.0.0-20200510223506-06a226fb4e37/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20200728195943-123391ffb6de/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= -golang.org/x/crypto v0.0.0-20200820211705-5c72a883971a/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= -golang.org/x/crypto v0.0.0-20201221181555-eec23a3978ad/go.mod h1:jdWPYTVW3xRLrWPugEBEK3UY2ZEsg3UU495nc5E+M+I= -golang.org/x/crypto v0.0.0-20210322153248-0c34fe9e7dc2/go.mod h1:T9bdIzuCu7OtxOm1hfPfRQxPLYneinmdGuTeoZ9dtd4= -golang.org/x/crypto v0.0.0-20210711020723-a769d52b0f97/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= -golang.org/x/crypto v0.1.0/go.mod h1:RecgLatLF4+eUMCP1PoPZQb+cVrJcOPbHkTkbkB9sbw= -golang.org/x/crypto v0.21.0 h1:X31++rzVUdKhX5sWmSOFZxx8UW/ldWx55cbf08iNAMA= -golang.org/x/crypto v0.21.0/go.mod h1:0BP7YvVV9gBbVKyeTG0Gyn+gZm94bibOW5BjDEYAOMs= -golang.org/x/exp v0.0.0-20230711153332-06a737ee72cb h1:xIApU0ow1zwMa2uL1VDNeQlNVFTWMQxZUZCMDy0Q4Us= -golang.org/x/exp v0.0.0-20230711153332-06a737ee72cb/go.mod h1:FXUEEKJgO7OQYeo8N01OfiKP8RXMtf6e8aTskBGqWdc= -golang.org/x/image v0.0.0-20180708004352-c73c2afc3b81/go.mod h1:ux5Hcp/YLpHSI86hEcLt0YII63i6oz57MZXIpbrjZUs= +golang.org/x/crypto v0.22.0 h1:g1v0xeRhjcugydODzvb3mEM9SQ0HGp9s/nh3COQ/C30= +golang.org/x/crypto v0.22.0/go.mod h1:vr6Su+7cTlO45qkww3VDJlzDn0ctJvRgYbC2NvXHt+M= +golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= +golang.org/x/exp v0.0.0-20190306152737-a1d7652674e8/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= +golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522/go.mod h1:ZjyILWgesfNpC6sMxTJOJm9Kp84zZh5NQWvqDGG3Qr8= +golang.org/x/exp v0.0.0-20190829153037-c13cbed26979/go.mod h1:86+5VVa7VpoJ4kLfm080zCjGlMRFzhUhsZKEZO7MGek= +golang.org/x/exp v0.0.0-20191030013958-a1ab85dbe136/go.mod h1:JXzH8nQsPlswgeRAPE3MuO9GYsAcnJvJ4vnMwN/5qkY= +golang.org/x/exp v0.0.0-20191129062945-2f5052295587/go.mod h1:2RIsYlXP63K8oxa1u096TMicItID8zy7Y6sNkU49FU4= +golang.org/x/exp v0.0.0-20191227195350-da58074b4299/go.mod h1:2RIsYlXP63K8oxa1u096TMicItID8zy7Y6sNkU49FU4= +golang.org/x/exp v0.0.0-20200119233911-0405dc783f0a/go.mod h1:2RIsYlXP63K8oxa1u096TMicItID8zy7Y6sNkU49FU4= +golang.org/x/exp v0.0.0-20200207192155-f17229e696bd/go.mod h1:J/WKrq2StrnmMY6+EHIKF9dgMWnmCNThgcyBT1FY9mM= +golang.org/x/exp v0.0.0-20200224162631-6cc2880d07d6/go.mod h1:3jZMyOhIsHpP37uCMkUooju7aAi5cS1Q23tOzKc+0MU= +golang.org/x/exp v0.0.0-20200331195152-e8c3332aa8e5/go.mod h1:4M0jN8W1tt0AVLNr8HDosyJCDCDuyL9N9+3m7wDWgKw= +golang.org/x/exp v0.0.0-20240404231335-c0f41cb1a7a0 h1:985EYyeCOxTpcgOTJpflJUwOeEz0CQOdPt73OzpE9F8= +golang.org/x/exp v0.0.0-20240404231335-c0f41cb1a7a0/go.mod h1:/lliqkxwWAhPjf5oSOIJup2XcqJaw8RGS6k3TGEc7GI= +golang.org/x/image v0.0.0-20190227222117-0694c2d4d067/go.mod h1:kZ7UVZpmo3dzQBMxlp+ypCbDeSB+sBbTgSJuh5dn5js= +golang.org/x/image v0.0.0-20190802002840-cff245a6509b/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0= golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE= golang.org/x/lint v0.0.0-20190227174305-5b3e6a55c961/go.mod h1:wehouNa3lNwaWXcvxsM5YxQ5yQlVC4a0KAMCusXpPoU= golang.org/x/lint v0.0.0-20190301231843-5614ed5bae6f/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE= @@ -1284,19 +1093,20 @@ golang.org/x/lint v0.0.0-20200130185559-910be7a94367/go.mod h1:3xt1FjdF8hUf6vQPI golang.org/x/lint v0.0.0-20200302205851-738671d3881b/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY= golang.org/x/lint v0.0.0-20201208152925-83fdc39ff7b5/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY= golang.org/x/lint v0.0.0-20210508222113-6edffad5e616/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY= +golang.org/x/mobile v0.0.0-20190312151609-d3739f865fa6/go.mod h1:z+o9i4GpDbdi3rU15maQ/Ox0txvL9dWGYEHz965HBQE= +golang.org/x/mobile v0.0.0-20190719004257-d2bd2a29d028/go.mod h1:E/iHnbuqvinMTCcRqshq8CkpyQDoeVncDDYHnLhea+o= golang.org/x/mod v0.0.0-20190513183733-4bf6d317e70e/go.mod h1:mXi4GBBbnImb6dmsKGUJ2LatrhH/nqhxcFungHvyanc= +golang.org/x/mod v0.1.0/go.mod h1:0QHyrYULN0/3qlju5TqG8bIK38QM8yzMo5ekMj3DlcY= golang.org/x/mod v0.1.1-0.20191105210325-c90efee705ee/go.mod h1:QqPTAvyqsEbceGzBzNggFXnrqF1CaUcvgkdR5Ot7KZg= +golang.org/x/mod v0.1.1-0.20191107180719-034126e5016b/go.mod h1:QqPTAvyqsEbceGzBzNggFXnrqF1CaUcvgkdR5Ot7KZg= golang.org/x/mod v0.2.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.1/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.2/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4/go.mod h1:jJ57K6gSWd91VN4djpZkiMVwK6gcyfeH4XE8wZrZaV4= -golang.org/x/mod v0.6.0/go.mod h1:4mET923SAdbXp2ki8ey+zGs1SLqsuM2Y0uvdZR/fUNI= -golang.org/x/mod v0.11.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= -golang.org/x/mod v0.12.0 h1:rmsUpXtvNzj340zd98LZ4KntptpfRHwpFOHG188oHXc= -golang.org/x/mod v0.12.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= -golang.org/x/net v0.0.0-20180719180050-a680a1efc54d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= +golang.org/x/mod v0.17.0 h1:zY54UmvipHiNd+pm+m0x9KhZ9hl1/7QNMyxXbc6ICqA= +golang.org/x/mod v0.17.0/go.mod h1:hTbmBsO62+eylJbnUtE2MGJUyE7QWk4xUqPFrRgJ+7c= golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20180826012351-8a410e7b638d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20180906233101-161cd47e91fd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= @@ -1334,20 +1144,16 @@ golang.org/x/net v0.0.0-20200625001655-4c5254603344/go.mod h1:/O7V0waA8r7cgGh81R golang.org/x/net v0.0.0-20200707034311-ab3426394381/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA= golang.org/x/net v0.0.0-20200813134508-3edf25e44fcc/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA= golang.org/x/net v0.0.0-20200822124328-c89045814202/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA= -golang.org/x/net v0.0.0-20201010224723-4f7140c49acb/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= golang.org/x/net v0.0.0-20201021035429-f5854403a974/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= golang.org/x/net v0.0.0-20201031054903-ff519b6c9102/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= golang.org/x/net v0.0.0-20201110031124-69a78807bb2b/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= golang.org/x/net v0.0.0-20201209123823-ac852fbbde11/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= golang.org/x/net v0.0.0-20210119194325-5f4716e94777/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= -golang.org/x/net v0.0.0-20210220033124-5f55cee0dc0d/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= golang.org/x/net v0.0.0-20210316092652-d523dce5a7f4/go.mod h1:RBQZq4jEuRlivfhVLdyRGr576XBO4/greRjx4P4O3yc= golang.org/x/net v0.0.0-20210405180319-a5a99cb37ef4/go.mod h1:p54w0d4576C0XHj96bSt6lcn1PtDYWL6XObtHCRCNQM= golang.org/x/net v0.0.0-20210503060351-7fd8e65b6420/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= -golang.org/x/net v0.0.0-20210610132358-84b48f89b13b/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= golang.org/x/net v0.0.0-20210805182204-aaa1db679c0d/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= -golang.org/x/net v0.0.0-20211015210444-4f30a5c0130f/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= golang.org/x/net v0.0.0-20220127200216-cd36cc0744dd/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= golang.org/x/net v0.0.0-20220225172249-27dd8689420f/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= golang.org/x/net v0.0.0-20220325170049-de3da57026de/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= @@ -1360,8 +1166,8 @@ golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug golang.org/x/net v0.0.0-20220909164309-bea034e7d591/go.mod h1:YDH+HFinaLZZlnHAfSS6ZXJJ9M9t4Dl22yv3iI2vPwk= golang.org/x/net v0.0.0-20221014081412-f15817d10f9b/go.mod h1:YDH+HFinaLZZlnHAfSS6ZXJJ9M9t4Dl22yv3iI2vPwk= golang.org/x/net v0.1.0/go.mod h1:Cx3nUiGt4eDBEyega/BKRp+/AlGL8hYe7U9odMt2Cco= -golang.org/x/net v0.23.0 h1:7EYJ93RZ9vYSZAIb2x3lnuvqO5zneoD6IvWjuhfxjTs= -golang.org/x/net v0.23.0/go.mod h1:JKghWKKOSdJwpW2GEx0Ja7fmaKnMsbu+MWVZTokSYmg= +golang.org/x/net v0.24.0 h1:1PcaxkF854Fu3+lvBIx5SYn9wRlBzzcnHZSiaFFAb0w= +golang.org/x/net v0.24.0/go.mod h1:2Q7sJY5mzlzWjKtYUEXSlBWCdyaioyXzRB2RtU8KVE8= golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= @@ -1387,8 +1193,8 @@ golang.org/x/oauth2 v0.0.0-20220822191816-0ebed06d0094/go.mod h1:h4gKUeWbJ4rQPri golang.org/x/oauth2 v0.0.0-20220909003341-f21342109be1/go.mod h1:h4gKUeWbJ4rQPri7E0u6Gs4e9Ri2zaLxzw5DI5XGrYg= golang.org/x/oauth2 v0.0.0-20221014153046-6fdb5e3db783/go.mod h1:h4gKUeWbJ4rQPri7E0u6Gs4e9Ri2zaLxzw5DI5XGrYg= golang.org/x/oauth2 v0.1.0/go.mod h1:G9FE4dLTsbXUu90h/Pf85g4w1D+SSAgR+q46nJZ8M4A= -golang.org/x/oauth2 v0.16.0 h1:aDkGMBSYxElaoP81NpoUoz2oo2R2wHdZpGToUxfyQrQ= -golang.org/x/oauth2 v0.16.0/go.mod h1:hqZ+0LWXsiVoZpeld6jVt06P3adbS2Uu911W1SsJv2o= +golang.org/x/oauth2 v0.18.0 h1:09qnuIAgzdx1XplqJvW6CQqMCtGZykZWcXzPMPUusvI= +golang.org/x/oauth2 v0.18.0/go.mod h1:Wf7knwG0MPoWIMMBgFlEaSUDaKskp0dCfrlJRJXbBi8= golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= @@ -1403,8 +1209,9 @@ golang.org/x/sync v0.0.0-20210220032951-036812b2e83c/go.mod h1:RxMgew5VJxzue5/jJ golang.org/x/sync v0.0.0-20220601150217-0de741cfad7f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20220929204114-8fcdb60fdcc0/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.6.0 h1:5BMeUDZ7vkXGfEr1x9B4bRcTH4lpkTkpdh0T/J+qjbQ= -golang.org/x/sync v0.6.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= +golang.org/x/sync v0.3.0/go.mod h1:FU7BRWz2tNW+3quACPkgCx/L+uEAv1htQ0V83Z9Rj+Y= +golang.org/x/sync v0.7.0 h1:YsImfSBoP9QPYL0xyKJPq0gcaJdG3rInoqxTWbfQu9M= +golang.org/x/sync v0.7.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= golang.org/x/sys v0.0.0-20180823144017-11551d06cbcc/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= @@ -1413,29 +1220,25 @@ golang.org/x/sys v0.0.0-20181026203630-95b1ffbd15a5/go.mod h1:STP8DvDyc/dI5b8T5h golang.org/x/sys v0.0.0-20181107165924-66b7b1311ac8/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20181116152217-5ac8a444bdc5/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20181122145206-62eef0e2fa9b/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20181205085412-a5c9d58dba9a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190130150945-aca44879d564/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20190222072716-a9d3bda3a223/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= +golang.org/x/sys v0.0.0-20190312061237-fead79001313/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190422165155-953cdadca894/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190502145724-3ef323f4f1fd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190507160741-ecd444e8653b/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190606165138-5da285871e9c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190624142023-c5567b49c5d0/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190626221950-04f50cda93cb/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190726091711-fc99dfbffb4e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190813064441-fde4db37ae7a/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190826190057-c7b8b68b1456/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190904154756-749cb33beabd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20191001151750-bb3f8db39f24/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191005200804-aed5e4c7ecf9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191026070338-33540a1f6037/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191120155948-bd437916bb0e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191204072324-ce4227a45e2e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191220142924-d4481acd189f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191228213918-04cbcbbfeed8/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200106162015-b016eb3dc98e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200107162124-548cf772de50/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200113162924-86b910548bc1/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200116001909-b77594299b42/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200122134326-e047566fdf82/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -1455,22 +1258,17 @@ golang.org/x/sys v0.0.0-20200615200032-f1bc736245b1/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20200625212154-ddb9806d33ae/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200803210538-64077c9b5642/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200814200057-3d37ad5750ed/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200826173525-f9321e4c35a6/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200905004654-be1d3432aa8f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20201201145000-ef89a241ccb3/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210104204734-6f8348627aad/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210119212857-b64e53b001e4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210124154548-22da62e12c0c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210220050731-9a76102bfb43/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210305230114-8fe3ee5dd75b/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210315160823-c6e025ad8005/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210316164454-77fc1eacc6aa/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210320140829-1e4c9ba3b0c4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210324051608-47abb6519492/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210330210617-4fbd30eecc44/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210420205809-ac73e9fd8988/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210514084401-e8d321eab015/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= @@ -1480,11 +1278,11 @@ golang.org/x/sys v0.0.0-20210616094352-59db8d763f22/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210806184541-e5e7981a1069/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210809222454-d867a43fc93e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20210816183151-1e6c022a8912/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210819135213-f52c844e1c1c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210823070655-63515b42dcdf/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210908233432-aa78b53d3365/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20211019181941-9d821ace8654/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20210927094055-39ccf1dd6fa6/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20211025201205-69cdffdb9359/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211124211545-fe61309f8881/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211210111614-af8b64212486/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= @@ -1508,14 +1306,13 @@ golang.org/x/sys v0.0.0-20221010170243-090e33056c14/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.1.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.12.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.18.0 h1:DBdB3niSjOA/O0blCZBqDefyWNYveAYMNF1Wum0DYQ4= -golang.org/x/sys v0.18.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= -golang.org/x/term v0.0.0-20201117132131-f5c789dd3221/go.mod h1:Nr5EML6q2oocZ2LXRh80K7BxOlk5/8JxuGnuhpl+muw= +golang.org/x/sys v0.19.0 h1:q5f1RH2jigJ1MoAWp2KTp3gm5zAGFUTarQZ5U386+4o= +golang.org/x/sys v0.19.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= golang.org/x/term v0.1.0/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= -golang.org/x/term v0.18.0 h1:FcHjZXDMxI8mM3nwhX9HlKop4C0YQvCVCdwYl2wOtE8= -golang.org/x/term v0.18.0/go.mod h1:ILwASektA3OnRv7amZ1xhE/KTR+u50pbXfZ03+6Nx58= +golang.org/x/term v0.19.0 h1:+ThwsDv+tYfnJFhF4L8jITxu1tdTWRTZpdsWgEgjL6Q= +golang.org/x/term v0.19.0/go.mod h1:2CuTdWZ7KHSQwUzKva0cbMg6q2DMI3Mmxp+gKJbskEk= golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= @@ -1533,17 +1330,14 @@ golang.org/x/time v0.0.0-20180412165947-fbb02b2291d2/go.mod h1:tRJNPiyCQ0inRvYxb golang.org/x/time v0.0.0-20181108054448-85acf8d2951c/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20191024005414-555d28b269f0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= -golang.org/x/time v0.0.0-20201208040808-7e3f01d25324/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= -golang.org/x/time v0.0.0-20210220033141-f8bda1e9f3ba/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.5.0 h1:o7cqy6amK/52YcAKIPlM3a+Fpj35zvRj2TP+e1xFSfk= golang.org/x/time v0.5.0/go.mod h1:3BpzKBy/shNhVucY/MWOyx10tF3SFh9QdLuxbVysPQM= -golang.org/x/tools v0.0.0-20180525024113-a5b4c53f6e8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20180828015842-6cd1fcedba52/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20190114222345-bf090417da8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= -golang.org/x/tools v0.0.0-20190206041539-40960b6deb8e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20190226205152-f727befe758c/go.mod h1:9Yl7xja0Znq3iFh3HoIrodX9oNMXvdceNzlUR8zjMvY= golang.org/x/tools v0.0.0-20190311212946-11955173bddd/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= +golang.org/x/tools v0.0.0-20190312151545-0bb0c0a6e846/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= golang.org/x/tools v0.0.0-20190312170243-e65039ee4138/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= golang.org/x/tools v0.0.0-20190328211700-ab21143f2384/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= golang.org/x/tools v0.0.0-20190425150028-36563e24a262/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= @@ -1552,9 +1346,12 @@ golang.org/x/tools v0.0.0-20190524140312-2c0ae7006135/go.mod h1:RgjU9mgBXZiqYHBn golang.org/x/tools v0.0.0-20190606124116-d0a3d012864b/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= golang.org/x/tools v0.0.0-20190621195816-6e04913cbbac/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= golang.org/x/tools v0.0.0-20190628153133-6cdbf07be9d0/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= +golang.org/x/tools v0.0.0-20190816200558-6889da9d5479/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20190911174233-4f2ddba30aff/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= +golang.org/x/tools v0.0.0-20191012152004-8de300cfc20a/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20191029041327-9cc4af7d6b2c/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20191029190741-b9c20aec41a5/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= +golang.org/x/tools v0.0.0-20191108193012-7d206e10da11/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20191113191852-77e3bb0ad9e7/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20191115202509-3a792d9c32b2/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= @@ -1563,11 +1360,11 @@ golang.org/x/tools v0.0.0-20191130070609-6e064ea0cf2d/go.mod h1:b+2E5dAYhXwXZwtn golang.org/x/tools v0.0.0-20191216173652-a0e659d51361/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20191227053925-7b8e75db28f4/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20200103221440-774c71fcf114/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= -golang.org/x/tools v0.0.0-20200108203644-89082a384178/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20200117161641-43d50277825c/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20200122220014-bf1340f18c4a/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20200130002326-2f3ba24bd6e7/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20200204074204-1cc6d1ef6c74/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= +golang.org/x/tools v0.0.0-20200207183749-b753a1ba74fa/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20200212150539-ea181f53ac56/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20200224181240-023911ca70b2/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20200227222343-706bc42d1f0d/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= @@ -1595,9 +1392,8 @@ golang.org/x/tools v0.1.3/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= golang.org/x/tools v0.1.4/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= golang.org/x/tools v0.1.5/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= golang.org/x/tools v0.1.12/go.mod h1:hNGJHUnrk76NpqgfD5Aqm5Crs+Hm0VOH/i9J2+nxYbc= -golang.org/x/tools v0.2.0/go.mod h1:y4OqIKeOV/fWJetJ8bXPU1sEVniLMIyDAZWeHdV+NTA= -golang.org/x/tools v0.13.0 h1:Iey4qkscZuv0VvIt8E0neZjtPVQFSc870HQ448QgEmQ= -golang.org/x/tools v0.13.0/go.mod h1:HvlwmtVNQAhOuCjW7xxvovg8wbNq7LwfXh/k7wXUl58= +golang.org/x/tools v0.20.0 h1:hz/CVckiOxybQvFw6h7b/q80NTr9IUQb4s1IIzW7KNY= +golang.org/x/tools v0.20.0/go.mod h1:WvitBU7JJf6A4jOdg4S1tviW9bhUxkgeCui/0JHctQg= golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= @@ -1607,12 +1403,6 @@ golang.org/x/xerrors v0.0.0-20220517211312-f3a8303e98df/go.mod h1:K8+ghG5WaK9qNq golang.org/x/xerrors v0.0.0-20220609144429-65e65417b02f/go.mod h1:K8+ghG5WaK9qNqU5K3HdILfMLy1f3aNYFI/wnl100a8= golang.org/x/xerrors v0.0.0-20220907171357-04be3eba64a2 h1:H2TDz8ibqkAF6YGhCdN3jS9O0/s90v0rJh3X/OLHEUk= golang.org/x/xerrors v0.0.0-20220907171357-04be3eba64a2/go.mod h1:K8+ghG5WaK9qNqU5K3HdILfMLy1f3aNYFI/wnl100a8= -gonum.org/v1/gonum v0.0.0-20180816165407-929014505bf4/go.mod h1:Y+Yx5eoAFn32cQvJDxZx5Dpnq+c3wtXuadVZAcxbbBo= -gonum.org/v1/gonum v0.0.0-20181121035319-3f7ecaa7e8ca/go.mod h1:Y+Yx5eoAFn32cQvJDxZx5Dpnq+c3wtXuadVZAcxbbBo= -gonum.org/v1/gonum v0.6.0/go.mod h1:9mxDZsDKxgMAuccQkewq682L+0eCu4dCN2yonUJTCLU= -gonum.org/v1/netlib v0.0.0-20181029234149-ec6d1f5cefe6/go.mod h1:wa6Ws7BG/ESfp6dHfk7C6KdzKA7wR7u/rKwOGE66zvw= -gonum.org/v1/netlib v0.0.0-20190313105609-8cb42192e0e0/go.mod h1:wa6Ws7BG/ESfp6dHfk7C6KdzKA7wR7u/rKwOGE66zvw= -gonum.org/v1/plot v0.0.0-20190515093506-e2840ee46a6b/go.mod h1:Wt8AAjI+ypCyYX3nZBvf6cAIx93T+c/OS2HFAYskSZc= google.golang.org/api v0.3.1/go.mod h1:6wY9I6uQWHQ8EM57III9mq/AjF+i8G65rmVagqKMtkk= google.golang.org/api v0.4.0/go.mod h1:8k5glujaEP+g9n7WNsDg8QP6cUVNI86fCNMcbazEtwE= google.golang.org/api v0.7.0/go.mod h1:WtwebWUNSVBH/HAw79HIFXZNqEvBhG+Ra+ax0hx3E3M= @@ -1662,8 +1452,8 @@ google.golang.org/api v0.96.0/go.mod h1:w7wJQLTM+wvQpNf5JyEcBoxK0RH7EDrh/L4qfsuJ google.golang.org/api v0.97.0/go.mod h1:w7wJQLTM+wvQpNf5JyEcBoxK0RH7EDrh/L4qfsuJ13s= google.golang.org/api v0.98.0/go.mod h1:w7wJQLTM+wvQpNf5JyEcBoxK0RH7EDrh/L4qfsuJ13s= google.golang.org/api v0.100.0/go.mod h1:ZE3Z2+ZOr87Rx7dqFsdRQkRBk36kDtp/h+QpHbB7a70= -google.golang.org/api v0.155.0 h1:vBmGhCYs0djJttDNynWo44zosHlPvHmA0XiN2zP2DtA= -google.golang.org/api v0.155.0/go.mod h1:GI5qK5f40kCpHfPn6+YzGAByIKWv8ujFnmoWm7Igduk= +google.golang.org/api v0.162.0 h1:Vhs54HkaEpkMBdgGdOT2P6F0csGG/vxDS0hWHJzmmps= +google.golang.org/api v0.162.0/go.mod h1:6SulDkfoBIg4NFmCuZ39XeeAgSHCPecfSUuDyYlAHs0= google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM= google.golang.org/appengine v1.2.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= @@ -1681,7 +1471,6 @@ google.golang.org/genproto v0.0.0-20190418145605-e7d98fc518a7/go.mod h1:VzzqZJRn google.golang.org/genproto v0.0.0-20190425155659-357c62f0e4bb/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE= google.golang.org/genproto v0.0.0-20190502173448-54afdca5d873/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE= google.golang.org/genproto v0.0.0-20190530194941-fb225487d101/go.mod h1:z3L6/3dTEVtUr6QSP8miRzeRqwQOioJ9I66odjN4I7s= -google.golang.org/genproto v0.0.0-20190716160619-c506a9f90610/go.mod h1:DMBHOl98Agz4BDEuKkezgsaosCRResVns1a3J2ZsMNc= google.golang.org/genproto v0.0.0-20190801165951-fa694d86fc64/go.mod h1:DMBHOl98Agz4BDEuKkezgsaosCRResVns1a3J2ZsMNc= google.golang.org/genproto v0.0.0-20190819201941-24fa4b261c55/go.mod h1:DMBHOl98Agz4BDEuKkezgsaosCRResVns1a3J2ZsMNc= google.golang.org/genproto v0.0.0-20190911173649-1774047e7e51/go.mod h1:IbNlFCBrqXvoKpeg0TB2l7cyZUmoaFKYIwrEpbDKLA8= @@ -1689,7 +1478,6 @@ google.golang.org/genproto v0.0.0-20191108220845-16a3f7862a1a/go.mod h1:n3cpQtvx google.golang.org/genproto v0.0.0-20191115194625-c23dd37a84c9/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc= google.golang.org/genproto v0.0.0-20191216164720-4f79533eabd1/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc= google.golang.org/genproto v0.0.0-20191230161307-f3c370f40bfb/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc= -google.golang.org/genproto v0.0.0-20200108215221-bd8f9a0ef82f/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc= google.golang.org/genproto v0.0.0-20200115191322-ca5a22157cba/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc= google.golang.org/genproto v0.0.0-20200122232147-0452cf42e150/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc= google.golang.org/genproto v0.0.0-20200204135345-fa8e72b47b90/go.mod h1:GmwEX6Z4W5gMy59cAlVYjN9JhxgbQH6Gn+gFDQe2lzA= @@ -1783,12 +1571,12 @@ google.golang.org/genproto v0.0.0-20221010155953-15ba04fc1c0e/go.mod h1:3526vdqw google.golang.org/genproto v0.0.0-20221014173430-6e2ab493f96b/go.mod h1:1vXfmgAz9N9Jx0QA82PqRVauvCz1SGSz739p0f183jM= google.golang.org/genproto v0.0.0-20221014213838-99cd37c6964a/go.mod h1:1vXfmgAz9N9Jx0QA82PqRVauvCz1SGSz739p0f183jM= google.golang.org/genproto v0.0.0-20221025140454-527a21cfbd71/go.mod h1:9qHF0xnpdSfF6knlcsnpzUu5y+rpwgbvsyGAZPBMg4s= -google.golang.org/genproto v0.0.0-20240123012728-ef4313101c80 h1:KAeGQVN3M9nD0/bQXnr/ClcEMJ968gUXJQ9pwfSynuQ= -google.golang.org/genproto v0.0.0-20240123012728-ef4313101c80/go.mod h1:cc8bqMqtv9gMOr0zHg2Vzff5ULhhL2IXP4sbcn32Dro= -google.golang.org/genproto/googleapis/api v0.0.0-20240123012728-ef4313101c80 h1:Lj5rbfG876hIAYFjqiJnPHfhXbv+nzTWfm04Fg/XSVU= -google.golang.org/genproto/googleapis/api v0.0.0-20240123012728-ef4313101c80/go.mod h1:4jWUdICTdgc3Ibxmr8nAJiiLHwQBY0UI0XZcEMaFKaA= -google.golang.org/genproto/googleapis/rpc v0.0.0-20240123012728-ef4313101c80 h1:AjyfHzEPEFp/NpvfN5g+KDla3EMojjhRVZc1i7cj+oM= -google.golang.org/genproto/googleapis/rpc v0.0.0-20240123012728-ef4313101c80/go.mod h1:PAREbraiVEVGVdTZsVWjSbbTtSyGbAgIIvni8a8CD5s= +google.golang.org/genproto v0.0.0-20240227224415-6ceb2ff114de h1:F6qOa9AZTYJXOUEr4jDysRDLrm4PHePlge4v4TGAlxY= +google.golang.org/genproto v0.0.0-20240227224415-6ceb2ff114de/go.mod h1:VUhTRKeHn9wwcdrk73nvdC9gF178Tzhmt/qyaFcPLSo= +google.golang.org/genproto/googleapis/api v0.0.0-20240227224415-6ceb2ff114de h1:jFNzHPIeuzhdRwVhbZdiym9q0ory/xY3sA+v2wPg8I0= +google.golang.org/genproto/googleapis/api v0.0.0-20240227224415-6ceb2ff114de/go.mod h1:5iCWqnniDlqZHrd3neWVTOwvh/v6s3232omMecelax8= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240401170217-c3f982113cda h1:LI5DOvAxUPMv/50agcLLoo+AdWc1irS9Rzz4vPuD1V4= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240401170217-c3f982113cda/go.mod h1:WtryC6hu0hhx87FDGxWCDptyssuo68sk10vYjF+T9fY= google.golang.org/grpc v1.17.0/go.mod h1:6QZJwpn2B+Zp71q/5VxRsJ6NXXVCE5NRUHRo+f3cWCs= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.0/go.mod h1:chYK+tFQF0nDUGJgXMSgLCQk3phJEuONr2DCgLDdAQM= @@ -1830,8 +1618,8 @@ google.golang.org/grpc v1.48.0/go.mod h1:vN9eftEi1UMyUsIF80+uQXhHjbXYbm0uXoFCACu google.golang.org/grpc v1.49.0/go.mod h1:ZgQEeidpAuNRZ8iRrlBKXZQP1ghovWIVhdJRyCDK+GI= google.golang.org/grpc v1.50.0/go.mod h1:ZgQEeidpAuNRZ8iRrlBKXZQP1ghovWIVhdJRyCDK+GI= google.golang.org/grpc v1.50.1/go.mod h1:ZgQEeidpAuNRZ8iRrlBKXZQP1ghovWIVhdJRyCDK+GI= -google.golang.org/grpc v1.62.1 h1:B4n+nfKzOICUXMgyrNd19h/I9oH0L1pizfk1d4zSgTk= -google.golang.org/grpc v1.62.1/go.mod h1:IWTG0VlJLCh1SkC58F7np9ka9mx/WNkjl4PGJaiq+QE= +google.golang.org/grpc v1.63.2 h1:MUeiw1B2maTVZthpU5xvASfTh3LDbxHd6IJ6QQVU+xM= +google.golang.org/grpc v1.63.2/go.mod h1:WAX/8DgncnokcFUldAxq7GeB5DXHDbMF+lLvDomNkRA= google.golang.org/grpc/cmd/protoc-gen-go-grpc v1.1.0/go.mod h1:6Kw0yEErY5E/yWrBtf03jp27GLLJujG4z/JK95pnjjw= google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8= google.golang.org/protobuf v0.0.0-20200221191635-4d8936d0db64/go.mod h1:kwYJMbMJ01Woi6D6+Kah6886xMZcty6N08ah7+eCXa0= @@ -1864,12 +1652,9 @@ gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMy gopkg.in/gcfg.v1 v1.2.3/go.mod h1:yesOnuUOFQAhST5vPY4nbZsb/huCgGGXlipJsBn0b3o= gopkg.in/ini.v1 v1.67.0 h1:Dgnx+6+nfE+IfzjUEISNeydPJh9AXNNsWbGP9KzCsOA= gopkg.in/ini.v1 v1.67.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= -gopkg.in/natefinch/npipe.v2 v2.0.0-20160621034901-c1b8fa8bdcce/go.mod h1:5AcXVHNjg+BDxry382+8OKon8SEWiKktQR07RKPsv1c= -gopkg.in/olebedev/go-duktape.v3 v3.0.0-20200619000410-60c24ae608a6/go.mod h1:uAJfkITjFhyEEuUfm7bsmCZRbW5WRq8s9EY8HZ6hCns= gopkg.in/resty.v1 v1.12.0/go.mod h1:mDo4pnntr5jdWRML875a/NmxYqAlA73dVijT2AXvQQo= gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 h1:uRGJdciOHaEIrze2W8Q3AKkepLTh2hOroT7a+7czfdQ= gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw= -gopkg.in/urfave/cli.v1 v1.20.0/go.mod h1:vuBzUtMdQeixQj8LVd+/98pzhxNGQoyuPBlsXHOQNO0= gopkg.in/warnings.v0 v0.1.2/go.mod h1:jksf8JmL6Qr/oQM2OXTHunEvvTAsrWBLb6OOjuVWRNI= gopkg.in/yaml.v2 v2.0.0-20170812160011-eb3733d160e7/go.mod h1:JAlM8MvJe8wmxCU4Bli9HhUf9+ttbYbLASfIpnQbh74= gopkg.in/yaml.v2 v2.2.1/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= @@ -1885,8 +1670,6 @@ gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= -gotest.tools v2.2.0+incompatible h1:VsBPFP1AI068pPrMxtb/S8Zkgf9xEmTLJjfM+P5UIEo= -gotest.tools v2.2.0+incompatible/go.mod h1:DsYFclhRJ6vuDpmuTbkuFWG+y2sxOXAzmJt81HFBacw= gotest.tools/v3 v3.5.1 h1:EENdUnS3pdur5nybKYIh2Vfgc8IUNBjxDPSjtiJcOzU= gotest.tools/v3 v3.5.1/go.mod h1:isy3WKz7GK6uNw/sbHzfKBLvlvXwUyV06n6brMxxopU= honnef.co/go/tools v0.0.0-20180728063816-88497007e858/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= @@ -1897,16 +1680,13 @@ honnef.co/go/tools v0.0.0-20190523083050-ea95bdfd59fc/go.mod h1:rf3lG4BRIbNafJWh honnef.co/go/tools v0.0.1-2019.2.3/go.mod h1:a3bituU0lyd329TUQxRnasdCoJDkEUEAqEt0JzvZhAg= honnef.co/go/tools v0.0.1-2020.1.3/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k= honnef.co/go/tools v0.0.1-2020.1.4/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k= -honnef.co/go/tools v0.1.3/go.mod h1:NgwopIslSNH47DimFoV78dnkksY2EFtX0ajyb3K/las= nhooyr.io/websocket v1.8.6 h1:s+C3xAMLwGmlI31Nyn/eAehUlZPwfYZu2JXM621Q5/k= nhooyr.io/websocket v1.8.6/go.mod h1:B70DZP8IakI65RVQ51MsWP/8jndNma26DVA/nFSCgW0= pgregory.net/rapid v1.1.0 h1:CMa0sjHSru3puNx+J0MIAuiiEV4N0qj8/cMWGBBCsjw= pgregory.net/rapid v1.1.0/go.mod h1:PY5XlDGj0+V1FCq0o192FdRhpKHGTRIWBgqjDBTrq04= rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8= -rsc.io/pdf v0.1.1/go.mod h1:n8OzWcQ6Sp37PL01nO98y4iUCRdTGarVfzxY20ICaU4= rsc.io/quote/v3 v3.1.0/go.mod h1:yEA65RcK8LyAZtP9Kv3t0HmxON59tX3rD+tICJqUlj0= rsc.io/sampler v1.3.0/go.mod h1:T1hPZKmBbMNahiBKFy5HrXp6adAjACjK9JXDnKaTXpA= -rsc.io/tmplfunc v0.0.3/go.mod h1:AG3sTPzElb1Io3Yg4voV9AGZJuleGAwaVRxL9M49PhA= sigs.k8s.io/yaml v1.1.0/go.mod h1:UJmg0vDUVViEyp3mgSv9WPwZCDxu4rQW1olrI1uml+o= sigs.k8s.io/yaml v1.4.0 h1:Mk1wCc2gy/F0THH0TAp1QYyJNzRm2KCLy3o5ASXVI5E= sigs.k8s.io/yaml v1.4.0/go.mod h1:Ejl7/uTz7PSA4eKMyQCUTnhZYNmLIl+5c2lQPGR2BPY= diff --git a/proto/buf.lock b/proto/buf.lock index 0888578..3b23126 100644 --- a/proto/buf.lock +++ b/proto/buf.lock @@ -9,8 +9,8 @@ deps: - remote: buf.build owner: cosmos repository: cosmos-sdk - commit: 954f7b05f38440fc8250134b15adec47 - digest: shake256:2ab4404fd04a7d1d52df0e2d0f2d477a3d83ffd88d876957bf3fedfd702c8e52833d65b3ce1d89a3c5adf2aab512616b0e4f51d8463f07eda9a8a3317ee3ac54 + commit: 5a6ab7bc14314acaa912d5e53aef1c2f + digest: shake256:02c00c73493720055f9b57553a35b5550023a3c1914123b247956288a78fb913aff70e66552777ae14d759467e119079d484af081264a5dd607a94d9fbc8116b - remote: buf.build owner: cosmos repository: gogo-proto @@ -19,5 +19,5 @@ deps: - remote: buf.build owner: googleapis repository: googleapis - commit: 522d453992234d9babc812c05f43717f + commit: f0e53af8f2fc4556b94f482688b57223 digest: shake256:de26a277fc28b8b411ecf58729d78d32fcf15090ffd998a4469225b17889bfb51442eaab04bb7a8d88d203ecdf0a9febd4ffd52c18ed1c2229160c7bd353ca95 diff --git a/proto/buf.yaml b/proto/buf.yaml index 3ea4bf4..ca6810b 100644 --- a/proto/buf.yaml +++ b/proto/buf.yaml @@ -1,7 +1,7 @@ version: v1 name: buf.build/scorum/cosmos-network deps: - - buf.build/cosmos/cosmos-sdk:v0.47.0 + - buf.build/cosmos/cosmos-sdk:v0.50.0 - buf.build/cosmos/cosmos-proto - buf.build/cosmos/gogo-proto - buf.build/googleapis/googleapis diff --git a/proto/network/aviatrix/v1/tx.proto b/proto/network/aviatrix/v1/tx.proto index 8acc0a5..b6eb119 100644 --- a/proto/network/aviatrix/v1/tx.proto +++ b/proto/network/aviatrix/v1/tx.proto @@ -2,12 +2,16 @@ syntax = "proto3"; package network.aviatrix.v1; +import "cosmos_proto/cosmos.proto"; +import "amino/amino.proto"; import "cosmos/msg/v1/msg.proto"; option go_package = "github.com/scorum/cosmos-network/x/aviatrix/types"; // Msg defines the Msg service. service Msg { + option (cosmos.msg.v1.service) = true; + rpc CreatePlane(MsgCreatePlane) returns (MsgCreatePlaneResponse); rpc UpdatePlaneExperience(MsgUpdatePlaneExperience) returns (MsgUpdatePlaneExperienceResponse); rpc AdjustPlaneExperience(MsgAdjustPlaneExperience) returns (MsgAdjustPlaneExperienceResponse); @@ -25,18 +29,20 @@ message Plane { message MsgCreatePlane { option (cosmos.msg.v1.signer) = "supervisor"; + option (amino.name) = "aviatrix/MsgCreatePlane"; string id = 1; - string supervisor = 2; - string owner = 3; + string supervisor = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + string owner = 3 [(cosmos_proto.scalar) = "cosmos.AddressString"]; PlaneMeta meta = 4; } message MsgCreatePlaneResponse {} message MsgUpdatePlaneExperience { option (cosmos.msg.v1.signer) = "supervisor"; + option (amino.name) = "aviatrix/MsgUpdatePlaneExperience"; - string supervisor = 1; + string supervisor = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; string id = 2; uint64 amount = 3; } @@ -44,8 +50,9 @@ message MsgUpdatePlaneExperienceResponse {} message MsgAdjustPlaneExperience { option (cosmos.msg.v1.signer) = "supervisor"; + option (amino.name) = "aviatrix/MsgAdjustPlaneExperience"; - string supervisor = 1; + string supervisor = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; string id = 2; int64 amount = 3; } diff --git a/proto/network/scorum/v1/params.proto b/proto/network/scorum/v1/params.proto index 013a007..4b50fa7 100644 --- a/proto/network/scorum/v1/params.proto +++ b/proto/network/scorum/v1/params.proto @@ -3,6 +3,8 @@ syntax = "proto3"; package network.scorum.v1; import "gogoproto/gogo.proto"; +import "amino/amino.proto"; +import "cosmos_proto/cosmos.proto"; import "cosmos/base/v1beta1/coin.proto"; @@ -14,9 +16,24 @@ message Params { repeated string supervisors = 1; - cosmos.base.v1beta1.IntProto gas_limit = 2 [(gogoproto.nullable) = false]; - cosmos.base.v1beta1.IntProto gas_unconditioned_amount = 3 [(gogoproto.nullable) = false]; - cosmos.base.v1beta1.DecProto gas_adjust_coefficient = 4 [(gogoproto.nullable) = false]; + bytes gas_limit = 2 [ + (cosmos_proto.scalar) = "cosmos.Int", + (gogoproto.customtype) = "cosmossdk.io/math.Int", + (gogoproto.nullable) = false, + (amino.dont_omitempty) = true + ]; + bytes gas_unconditioned_amount = 3 [ + (cosmos_proto.scalar) = "cosmos.Int", + (gogoproto.customtype) = "cosmossdk.io/math.Int", + (gogoproto.nullable) = false, + (amino.dont_omitempty) = true + ]; + bytes gas_adjust_coefficient = 4 [ + (cosmos_proto.scalar) = "cosmos.Dec", + (gogoproto.customtype) = "cosmossdk.io/math.LegacyDec", + (gogoproto.nullable) = false, + (amino.dont_omitempty) = true + ]; ValidatorsRewardParams validators_reward = 5 [(gogoproto.nullable) = false]; } diff --git a/proto/network/scorum/v1/proposal.proto b/proto/network/scorum/v1/proposal.proto deleted file mode 100644 index 7672b51..0000000 --- a/proto/network/scorum/v1/proposal.proto +++ /dev/null @@ -1,17 +0,0 @@ -syntax = "proto3"; - -package network.scorum.v1; - -import "gogoproto/gogo.proto"; -import "cosmos/base/v1beta1/coin.proto"; - -option go_package = "github.com/scorum/cosmos-network/x/scorum/types"; - -// MintProposal is a gov proposal for minting assets. -message MintProposal { - string title = 1; - string description = 2; - - string recipient = 3; - cosmos.base.v1beta1.Coin amount = 4 [(gogoproto.nullable) = false]; -} \ No newline at end of file diff --git a/proto/network/scorum/v1/tx.proto b/proto/network/scorum/v1/tx.proto index ac71e9c..14a1efc 100644 --- a/proto/network/scorum/v1/tx.proto +++ b/proto/network/scorum/v1/tx.proto @@ -5,29 +5,53 @@ package network.scorum.v1; option go_package = "github.com/scorum/cosmos-network/x/scorum/types"; import "gogoproto/gogo.proto"; +import "amino/amino.proto"; +import "cosmos_proto/cosmos.proto"; import "cosmos/msg/v1/msg.proto"; import "cosmos/base/v1beta1/coin.proto"; // Msg defines the Msg service. service Msg { + option (cosmos.msg.v1.service) = true; + rpc Burn(MsgBurn) returns (MsgBurnResponse); + rpc Mint(MsgMint) returns (MsgMintResponse); rpc MintGas(MsgMintGas) returns (MsgMintGasResponse); } message MsgBurn { option (cosmos.msg.v1.signer) = "supervisor"; + option (amino.name) = "scorum/MsgBurn"; - string supervisor = 1; + string supervisor = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; cosmos.base.v1beta1.Coin amount = 2 [(gogoproto.nullable) = false]; } message MsgBurnResponse {} message MsgMintGas { option (cosmos.msg.v1.signer) = "supervisor"; - - string supervisor = 1; - string address = 2; - cosmos.base.v1beta1.IntProto amount = 3 [(gogoproto.nullable) = false]; + option (amino.name) = "scorum/MsgMintGas"; + + string supervisor = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + string address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + bytes amount = 3 [ + (cosmos_proto.scalar) = "cosmos.Int", + (gogoproto.customtype) = "cosmossdk.io/math.Int", + (gogoproto.nullable) = false, + (amino.dont_omitempty) = true + ]; } message MsgMintGasResponse {} + +// MsgMint is a gov proposal for minting assets. +message MsgMint { + option (cosmos.msg.v1.signer) = "authority"; + option (amino.name) = "scorum/MsgMint"; + + string authority = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + string recipient = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + cosmos.base.v1beta1.Coin amount = 3 [(gogoproto.nullable) = false]; +} + +message MsgMintResponse {} \ No newline at end of file diff --git a/proto/network/scorum/v1/types.proto b/proto/network/scorum/v1/types.proto index a27b808..fab736e 100644 --- a/proto/network/scorum/v1/types.proto +++ b/proto/network/scorum/v1/types.proto @@ -3,6 +3,8 @@ syntax = "proto3"; package network.scorum.v1; import "gogoproto/gogo.proto"; +import "amino/amino.proto"; +import "cosmos_proto/cosmos.proto"; import "cosmos/base/v1beta1/coin.proto"; diff --git a/testutil/keeper/account.go b/testutil/keeper/account.go index 5c0531c..3449c80 100644 --- a/testutil/keeper/account.go +++ b/testutil/keeper/account.go @@ -7,11 +7,18 @@ import ( "github.com/cosmos/cosmos-sdk/codec" codectypes "github.com/cosmos/cosmos-sdk/codec/types" + + "github.com/stretchr/testify/require" + + "github.com/cosmos/cosmos-sdk/codec/address" + "github.com/cosmos/cosmos-sdk/runtime" + sdk "github.com/cosmos/cosmos-sdk/types" + + "cosmossdk.io/x/nft" "github.com/cosmos/cosmos-sdk/x/auth/keeper" "github.com/cosmos/cosmos-sdk/x/auth/types" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" - "github.com/cosmos/cosmos-sdk/x/nft" scorumtypes "github.com/scorum/cosmos-network/x/scorum/types" ) @@ -22,7 +29,7 @@ func AccountKeeper(t testing.TB, ctx TestContext) keeper.AccountKeeper { types.RegisterInterfaces(registry) k := keeper.NewAccountKeeper( cdc, - ctx.KVKeys[types.StoreKey], + runtime.NewKVStoreService(ctx.KVKeys[types.StoreKey]), types.ProtoBaseAccount, map[string][]string{ scorumtypes.ModuleName: {types.Minter, types.Burner}, @@ -30,12 +37,13 @@ func AccountKeeper(t testing.TB, ctx TestContext) keeper.AccountKeeper { stakingtypes.BondedPoolName: {types.Burner, types.Staking}, stakingtypes.NotBondedPoolName: {types.Burner, types.Staking}, }, - "scorum", + address.NewBech32Codec(sdk.GetConfig().GetBech32AccountAddrPrefix()), + sdk.GetConfig().GetBech32AccountAddrPrefix(), authtypes.NewModuleAddress(govtypes.ModuleName).String(), ) // Initialize params - k.SetParams(ctx.Context, types.DefaultParams()) + require.NoError(t, k.Params.Set(ctx.Context, types.DefaultParams())) return k } diff --git a/testutil/keeper/bank.go b/testutil/keeper/bank.go index 8e23ce6..22adf16 100644 --- a/testutil/keeper/bank.go +++ b/testutil/keeper/bank.go @@ -3,6 +3,11 @@ package keeper import ( "testing" + "github.com/stretchr/testify/require" + + "cosmossdk.io/log" + "github.com/cosmos/cosmos-sdk/runtime" + authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" @@ -22,19 +27,18 @@ func BankKeeper(t testing.TB, ctx TestContext) keeper.Keeper { k := keeper.NewBaseKeeper( cdc, - ctx.KVKeys[types.StoreKey], + runtime.NewKVStoreService(ctx.KVKeys[types.StoreKey]), AccountKeeper(t, ctx), (&app.App{}).BlockedModuleAccountAddrs(), authtypes.NewModuleAddress(govtypes.ModuleName).String(), + log.NewNopLogger(), ) // Initialize params - k.SetParams(ctx.Context, types.Params{ - SendEnabled: []*types.SendEnabled{ - {Denom: scorumtypes.GasDenom, Enabled: false}, - }, + require.NoError(t, k.SetParams(ctx.Context, types.Params{ DefaultSendEnabled: true, - }) + })) + k.SetSendEnabled(ctx, scorumtypes.GasDenom, false) return k } diff --git a/testutil/keeper/context.go b/testutil/keeper/context.go index 3e20cf6..f5b8a11 100644 --- a/testutil/keeper/context.go +++ b/testutil/keeper/context.go @@ -3,33 +3,35 @@ package keeper import ( "testing" - tmdb "github.com/cometbft/cometbft-db" - "github.com/cometbft/cometbft/libs/log" + "cosmossdk.io/log" + "cosmossdk.io/store" + "cosmossdk.io/store/metrics" + "cosmossdk.io/store/types" + storetypes "cosmossdk.io/store/types" + evidencetypes "cosmossdk.io/x/evidence/types" + "cosmossdk.io/x/feegrant" + "cosmossdk.io/x/nft" + upgradetypes "cosmossdk.io/x/upgrade/types" tmproto "github.com/cometbft/cometbft/proto/tendermint/types" - "github.com/cosmos/cosmos-sdk/store" - "github.com/cosmos/cosmos-sdk/store/types" + db "github.com/cosmos/cosmos-db" sdk "github.com/cosmos/cosmos-sdk/types" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" "github.com/cosmos/cosmos-sdk/x/authz" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" - capabilitytypes "github.com/cosmos/cosmos-sdk/x/capability/types" consensusparamtypes "github.com/cosmos/cosmos-sdk/x/consensus/types" crisistypes "github.com/cosmos/cosmos-sdk/x/crisis/types" distrtypes "github.com/cosmos/cosmos-sdk/x/distribution/types" - evidencetypes "github.com/cosmos/cosmos-sdk/x/evidence/types" - "github.com/cosmos/cosmos-sdk/x/feegrant" govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" "github.com/cosmos/cosmos-sdk/x/group" minttypes "github.com/cosmos/cosmos-sdk/x/mint/types" - "github.com/cosmos/cosmos-sdk/x/nft" paramstypes "github.com/cosmos/cosmos-sdk/x/params/types" slashingtypes "github.com/cosmos/cosmos-sdk/x/slashing/types" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" - upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types" - icacontrollertypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller/types" - icahosttypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/host/types" - ibcfeetypes "github.com/cosmos/ibc-go/v7/modules/apps/29-fee/types" - ibcexported "github.com/cosmos/ibc-go/v7/modules/core/exported" + capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" + icacontrollertypes "github.com/cosmos/ibc-go/v8/modules/apps/27-interchain-accounts/controller/types" + icahosttypes "github.com/cosmos/ibc-go/v8/modules/apps/27-interchain-accounts/host/types" + ibcfeetypes "github.com/cosmos/ibc-go/v8/modules/apps/29-fee/types" + ibcexported "github.com/cosmos/ibc-go/v8/modules/core/exported" aviatrixtypes "github.com/scorum/cosmos-network/x/aviatrix/types" scorumtypes "github.com/scorum/cosmos-network/x/scorum/types" "github.com/stretchr/testify/require" @@ -44,7 +46,7 @@ type TestContext struct { } func GetContext(t testing.TB) TestContext { - keys := sdk.NewKVStoreKeys( + keys := storetypes.NewKVStoreKeys( authtypes.StoreKey, authz.ModuleName, banktypes.StoreKey, stakingtypes.StoreKey, crisistypes.StoreKey, minttypes.StoreKey, distrtypes.StoreKey, slashingtypes.StoreKey, govtypes.StoreKey, paramstypes.StoreKey, upgradetypes.StoreKey, feegrant.StoreKey, evidencetypes.StoreKey, @@ -55,11 +57,11 @@ func GetContext(t testing.TB) TestContext { // scorum scorumtypes.StoreKey, aviatrixtypes.StoreKey, ) - tkeys := sdk.NewTransientStoreKeys(paramstypes.TStoreKey) - memKeys := sdk.NewMemoryStoreKeys(capabilitytypes.MemStoreKey) + tkeys := storetypes.NewTransientStoreKeys(paramstypes.TStoreKey) + memKeys := storetypes.NewMemoryStoreKeys(capabilitytypes.MemStoreKey) - db := tmdb.NewMemDB() - stateStore := store.NewCommitMultiStore(db) + db := db.NewMemDB() + stateStore := store.NewCommitMultiStore(db, log.NewNopLogger(), metrics.NewNoOpMetrics()) for _, k := range keys { stateStore.MountStoreWithDB(k, types.StoreTypeIAVL, db) diff --git a/testutil/keeper/nft.go b/testutil/keeper/nft.go index f4f80b1..339eb69 100644 --- a/testutil/keeper/nft.go +++ b/testutil/keeper/nft.go @@ -3,10 +3,12 @@ package keeper import ( "testing" + "github.com/cosmos/cosmos-sdk/runtime" + + "cosmossdk.io/x/nft" + "cosmossdk.io/x/nft/keeper" "github.com/cosmos/cosmos-sdk/codec" codectypes "github.com/cosmos/cosmos-sdk/codec/types" - "github.com/cosmos/cosmos-sdk/x/nft" - "github.com/cosmos/cosmos-sdk/x/nft/keeper" ) func NftKeeper(t testing.TB, ctx TestContext) keeper.Keeper { @@ -15,7 +17,12 @@ func NftKeeper(t testing.TB, ctx TestContext) keeper.Keeper { nft.RegisterInterfaces(registry) - k := keeper.NewKeeper(ctx.KVKeys[nft.StoreKey], cdc, AccountKeeper(t, ctx), BankKeeper(t, ctx)) + k := keeper.NewKeeper( + runtime.NewKVStoreService(ctx.KVKeys[nft.StoreKey]), + cdc, + AccountKeeper(t, ctx), + BankKeeper(t, ctx), + ) return k } diff --git a/testutil/keeper/scorum.go b/testutil/keeper/scorum.go index 4e03dc3..c4500db 100644 --- a/testutil/keeper/scorum.go +++ b/testutil/keeper/scorum.go @@ -35,6 +35,7 @@ func ScorumKeeper( BankKeeper(t, ctx), StakingKeeper(t, ctx), authtypes.FeeCollectorName, + "gov", ) // Initialize params diff --git a/testutil/keeper/staking.go b/testutil/keeper/staking.go index 37f23bb..9c1457e 100644 --- a/testutil/keeper/staking.go +++ b/testutil/keeper/staking.go @@ -5,6 +5,9 @@ import ( "github.com/cosmos/cosmos-sdk/codec" codectypes "github.com/cosmos/cosmos-sdk/codec/types" + "github.com/cosmos/cosmos-sdk/runtime" + sdk "github.com/cosmos/cosmos-sdk/types" + authcodec "github.com/cosmos/cosmos-sdk/x/auth/codec" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" "github.com/cosmos/cosmos-sdk/x/staking/keeper" @@ -19,10 +22,12 @@ func StakingKeeper(t testing.TB, ctx TestContext) *keeper.Keeper { k := keeper.NewKeeper( cdc, - ctx.KVKeys[types.StoreKey], + runtime.NewKVStoreService(ctx.KVKeys[types.StoreKey]), AccountKeeper(t, ctx), BankKeeper(t, ctx), authtypes.NewModuleAddress(govtypes.ModuleName).String(), + authcodec.NewBech32Codec(sdk.GetConfig().GetBech32ValidatorAddrPrefix()), + authcodec.NewBech32Codec(sdk.GetConfig().GetBech32ConsensusAddrPrefix()), ) // Initialize params diff --git a/x/aviatrix/keeper/keeper.go b/x/aviatrix/keeper/keeper.go index fb82c8c..79e97ab 100644 --- a/x/aviatrix/keeper/keeper.go +++ b/x/aviatrix/keeper/keeper.go @@ -3,9 +3,9 @@ package keeper import ( "fmt" - "github.com/cometbft/cometbft/libs/log" + "cosmossdk.io/log" + storetypes "cosmossdk.io/store/types" "github.com/cosmos/cosmos-sdk/codec" - storetypes "github.com/cosmos/cosmos-sdk/store/types" sdk "github.com/cosmos/cosmos-sdk/types" paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" diff --git a/x/aviatrix/keeper/keeper_test.go b/x/aviatrix/keeper/keeper_test.go index 324ead6..fe15103 100644 --- a/x/aviatrix/keeper/keeper_test.go +++ b/x/aviatrix/keeper/keeper_test.go @@ -3,6 +3,8 @@ package keeper_test import ( "testing" + "cosmossdk.io/math" + sdk "github.com/cosmos/cosmos-sdk/types" testutil "github.com/scorum/cosmos-network/testutil/keeper" "github.com/scorum/cosmos-network/testutil/sample" @@ -33,9 +35,9 @@ func setupKeeper(t testing.TB) (keeperSet, testutil.TestContext) { set.scorumKeeper.SetParams(ctx.Context, scorumtypes.Params{ Supervisors: []string{set.supervisor.String()}, - GasLimit: sdk.IntProto{Int: sdk.NewInt(1000)}, - GasUnconditionedAmount: sdk.IntProto{Int: sdk.NewInt(500)}, - GasAdjustCoefficient: sdk.DecProto{Dec: sdk.NewDec(1)}, + GasLimit: math.NewInt(1000), + GasUnconditionedAmount: math.NewInt(500), + GasAdjustCoefficient: math.LegacyNewDec(1), }) return set, ctx diff --git a/x/aviatrix/keeper/msg_server_adjust_plane_experience.go b/x/aviatrix/keeper/msg_server_adjust_plane_experience.go index 8dfcd2a..c11739f 100644 --- a/x/aviatrix/keeper/msg_server_adjust_plane_experience.go +++ b/x/aviatrix/keeper/msg_server_adjust_plane_experience.go @@ -4,10 +4,10 @@ import ( "context" errorsmod "cosmossdk.io/errors" + "cosmossdk.io/x/nft" codec "github.com/cosmos/cosmos-sdk/codec/types" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" - "github.com/cosmos/cosmos-sdk/x/nft" "github.com/scorum/cosmos-network/x/aviatrix/types" ) diff --git a/x/aviatrix/keeper/msg_server_adjust_plane_experience_test.go b/x/aviatrix/keeper/msg_server_adjust_plane_experience_test.go index 725bddc..16acdc1 100644 --- a/x/aviatrix/keeper/msg_server_adjust_plane_experience_test.go +++ b/x/aviatrix/keeper/msg_server_adjust_plane_experience_test.go @@ -3,7 +3,8 @@ package keeper_test import ( "testing" - sdk "github.com/cosmos/cosmos-sdk/types" + "cosmossdk.io/math" + "github.com/google/uuid" "github.com/stretchr/testify/require" @@ -89,9 +90,9 @@ func TestMsgServer_AdjustPlaneExperience(t *testing.T) { set, ctx := setupKeeper(t) set.scorumKeeper.SetParams(ctx.Context, scorumtypes.Params{ Supervisors: []string{supervisorAddr.String()}, - GasLimit: sdk.IntProto{Int: sdk.NewInt(1000)}, - GasUnconditionedAmount: sdk.IntProto{Int: sdk.NewInt(500)}, - GasAdjustCoefficient: sdk.DecProto{Dec: sdk.NewDec(1)}, + GasLimit: math.NewInt(1000), + GasUnconditionedAmount: math.NewInt(500), + GasAdjustCoefficient: math.LegacyNewDec(1), }) s := keeper.NewMsgServerImpl(set.keeper) diff --git a/x/aviatrix/keeper/msg_server_create.go b/x/aviatrix/keeper/msg_server_create.go index f8c2782..bfbbc94 100644 --- a/x/aviatrix/keeper/msg_server_create.go +++ b/x/aviatrix/keeper/msg_server_create.go @@ -5,10 +5,10 @@ import ( "fmt" errorsmod "cosmossdk.io/errors" + "cosmossdk.io/x/nft" codec "github.com/cosmos/cosmos-sdk/codec/types" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" - "github.com/cosmos/cosmos-sdk/x/nft" "github.com/scorum/cosmos-network/x/aviatrix/types" ) diff --git a/x/aviatrix/keeper/msg_server_set_plane_experience_test.go b/x/aviatrix/keeper/msg_server_set_plane_experience_test.go index 8406c32..d478bb9 100644 --- a/x/aviatrix/keeper/msg_server_set_plane_experience_test.go +++ b/x/aviatrix/keeper/msg_server_set_plane_experience_test.go @@ -3,7 +3,8 @@ package keeper_test import ( "testing" - sdk "github.com/cosmos/cosmos-sdk/types" + "cosmossdk.io/math" + "github.com/google/uuid" "github.com/stretchr/testify/require" @@ -67,9 +68,9 @@ func TestMsgServer_UpdatePlaneExperience(t *testing.T) { set, ctx := setupKeeper(t) set.scorumKeeper.SetParams(ctx.Context, scorumtypes.Params{ Supervisors: []string{supervisorAddr.String()}, - GasLimit: sdk.IntProto{Int: sdk.NewInt(1000)}, - GasUnconditionedAmount: sdk.IntProto{Int: sdk.NewInt(500)}, - GasAdjustCoefficient: sdk.DecProto{Dec: sdk.NewDec(1)}, + GasLimit: math.NewInt(1000), + GasUnconditionedAmount: math.NewInt(500), + GasAdjustCoefficient: math.LegacyNewDec(1), }) s := keeper.NewMsgServerImpl(set.keeper) diff --git a/x/aviatrix/keeper/plane.go b/x/aviatrix/keeper/plane.go index 669b609..b6836d8 100644 --- a/x/aviatrix/keeper/plane.go +++ b/x/aviatrix/keeper/plane.go @@ -2,10 +2,10 @@ package keeper import ( errorsmod "cosmossdk.io/errors" + "cosmossdk.io/x/nft" codec "github.com/cosmos/cosmos-sdk/codec/types" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" - "github.com/cosmos/cosmos-sdk/x/nft" "github.com/gogo/protobuf/proto" "github.com/scorum/cosmos-network/x/aviatrix/types" diff --git a/x/aviatrix/module.go b/x/aviatrix/module.go index 9519a05..856f562 100644 --- a/x/aviatrix/module.go +++ b/x/aviatrix/module.go @@ -6,10 +6,12 @@ import ( "fmt" "math/rand" + "cosmossdk.io/core/appmodule" + + nftkeeper "cosmossdk.io/x/nft/keeper" simtypes "github.com/cosmos/cosmos-sdk/types/simulation" accountkeeper "github.com/cosmos/cosmos-sdk/x/auth/keeper" bankkeeper "github.com/cosmos/cosmos-sdk/x/bank/keeper" - nftkeeper "github.com/cosmos/cosmos-sdk/x/nft/keeper" "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/scorum/cosmos-network/x/aviatrix/simulation" scorumkeeper "github.com/scorum/cosmos-network/x/scorum/keeper" @@ -28,7 +30,7 @@ import ( ) var ( - _ module.AppModule = AppModule{} + _ appmodule.AppModule = AppModule{} _ module.AppModuleBasic = AppModuleBasic{} ) @@ -152,11 +154,11 @@ func (am AppModule) ExportGenesis(ctx sdk.Context, cdc codec.JSONCodec) json.Raw func (AppModule) ConsensusVersion() uint64 { return 1 } // BeginBlock contains the logic that is automatically triggered at the beginning of each block -func (am AppModule) BeginBlock(_ sdk.Context, _ abci.RequestBeginBlock) {} +func (am AppModule) BeginBlock(_ sdk.Context) {} // EndBlock contains the logic that is automatically triggered at the end of each block -func (am AppModule) EndBlock(_ sdk.Context, _ abci.RequestEndBlock) []abci.ValidatorUpdate { - return []abci.ValidatorUpdate{} +func (am AppModule) EndBlock(ctx context.Context) ([]abci.ValidatorUpdate, error) { + return []abci.ValidatorUpdate{}, nil } // GenerateGenesisState creates a randomized GenState of the distribution module. @@ -166,7 +168,7 @@ func (AppModule) GenerateGenesisState(simState *module.SimulationState) { // ProposalContents returns all the distribution content functions used to // simulate governance proposals. -func (am AppModule) ProposalContents(simState module.SimulationState) []simtypes.WeightedProposalContent { +func (am AppModule) ProposalContents(simState module.SimulationState) []simtypes.WeightedProposalMsg { return simulation.ProposalContents(simState) } @@ -176,7 +178,7 @@ func (AppModule) RandomizedParams(r *rand.Rand) []simtypes.LegacyParamChange { } // RegisterStoreDecoder registers a decoder for distribution module's types -func (am AppModule) RegisterStoreDecoder(sdr sdk.StoreDecoderRegistry) { +func (am AppModule) RegisterStoreDecoder(sdr simtypes.StoreDecoderRegistry) { // sdr[types.StoreKey] = simulation.NewDecodeStore(am.cdc) } @@ -186,3 +188,9 @@ func (am AppModule) WeightedOperations(simState module.SimulationState) []simtyp simState, am.scorumKeeper, am.nftKeeper, am.accountKeeper, am.bankKeeper, ) } + +// IsOnePerModuleType implements the depinject.OnePerModuleType interface. +func (am AppModule) IsOnePerModuleType() {} + +// IsAppModule implements the appmodule.AppModule interface. +func (am AppModule) IsAppModule() {} diff --git a/x/aviatrix/simulation/operations.go b/x/aviatrix/simulation/operations.go index 6437be2..9b88fd6 100644 --- a/x/aviatrix/simulation/operations.go +++ b/x/aviatrix/simulation/operations.go @@ -6,13 +6,13 @@ import ( moduletestutil "github.com/cosmos/cosmos-sdk/types/module/testutil" "cosmossdk.io/math" + nftkeeper "cosmossdk.io/x/nft/keeper" "github.com/cosmos/cosmos-sdk/baseapp" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" simtypes "github.com/cosmos/cosmos-sdk/types/simulation" accountkeeper "github.com/cosmos/cosmos-sdk/x/auth/keeper" bankkeeper "github.com/cosmos/cosmos-sdk/x/bank/keeper" - nftkeeper "github.com/cosmos/cosmos-sdk/x/nft/keeper" "github.com/cosmos/cosmos-sdk/x/simulation" "github.com/google/uuid" "github.com/scorum/cosmos-network/x/aviatrix/types" @@ -45,17 +45,17 @@ func WeightedOperations( weightMsgAdjustPlaneExperience int ) - simState.AppParams.GetOrGenerate(simState.Cdc, opWeightMsgCreatePlane, &weightMsgCreatePlane, nil, + simState.AppParams.GetOrGenerate(opWeightMsgCreatePlane, &weightMsgCreatePlane, nil, func(_ *rand.Rand) { weightMsgCreatePlane = defaultWeightMsgCreatePlane }, ) - simState.AppParams.GetOrGenerate(simState.Cdc, opWeightMsgUpdatePlaneExperience, &weightMsgUpdatePlaneExperience, nil, + simState.AppParams.GetOrGenerate(opWeightMsgUpdatePlaneExperience, &weightMsgUpdatePlaneExperience, nil, func(_ *rand.Rand) { weightMsgUpdatePlaneExperience = defaultWeightMsgUpdatePlaneExperience }, ) - simState.AppParams.GetOrGenerate(simState.Cdc, opWeightMsgAdjustPlaneExperience, &weightMsgAdjustPlaneExperience, nil, + simState.AppParams.GetOrGenerate(opWeightMsgAdjustPlaneExperience, &weightMsgAdjustPlaneExperience, nil, func(_ *rand.Rand) { weightMsgAdjustPlaneExperience = defaultWeightMsgAdjustPlaneExperience }, @@ -121,7 +121,6 @@ func SimulateMsgCreatePlane( TxGen: moduletestutil.MakeTestEncodingConfig().TxConfig, Cdc: nil, Msg: msg, - MsgType: msg.Type(), Context: ctx, SimAccount: supervisorAcc, AccountKeeper: ak, @@ -179,7 +178,6 @@ func SimulateMsgUpdatePlaneExperience( TxGen: moduletestutil.MakeTestEncodingConfig().TxConfig, Cdc: nil, Msg: msg, - MsgType: msg.Type(), Context: ctx, SimAccount: supervisorAcc, AccountKeeper: ak, @@ -237,7 +235,6 @@ func SimulateMsgAdjustPlaneExperience( TxGen: moduletestutil.MakeTestEncodingConfig().TxConfig, Cdc: nil, Msg: msg, - MsgType: msg.Type(), Context: ctx, SimAccount: supervisorAcc, AccountKeeper: ak, diff --git a/x/aviatrix/simulation/proposals.go b/x/aviatrix/simulation/proposals.go index 3c7815a..58d23d2 100644 --- a/x/aviatrix/simulation/proposals.go +++ b/x/aviatrix/simulation/proposals.go @@ -5,6 +5,6 @@ import ( simtypes "github.com/cosmos/cosmos-sdk/types/simulation" ) -func ProposalContents(_ module.SimulationState) []simtypes.WeightedProposalContent { - return []simtypes.WeightedProposalContent{} +func ProposalContents(_ module.SimulationState) []simtypes.WeightedProposalMsg { + return []simtypes.WeightedProposalMsg{} } diff --git a/x/aviatrix/types/expected_keepers.go b/x/aviatrix/types/expected_keepers.go index 5326a9b..6ad105f 100644 --- a/x/aviatrix/types/expected_keepers.go +++ b/x/aviatrix/types/expected_keepers.go @@ -3,22 +3,22 @@ package types import ( "context" + "cosmossdk.io/x/nft" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/cosmos-sdk/x/nft" ) // NftKeeper defines the expected interface needed to store nft. type NftKeeper interface { - HasClass(ctx sdk.Context, classID string) bool - SaveClass(ctx sdk.Context, class nft.Class) error + HasClass(ctx context.Context, classID string) bool + SaveClass(ctx context.Context, class nft.Class) error - GetNFT(ctx sdk.Context, classID, nftID string) (nft.NFT, bool) - Mint(ctx sdk.Context, token nft.NFT, receiver sdk.AccAddress) error - Update(ctx sdk.Context, token nft.NFT) error + GetNFT(ctx context.Context, classID, nftID string) (nft.NFT, bool) + Mint(ctx context.Context, token nft.NFT, receiver sdk.AccAddress) error + Update(ctx context.Context, token nft.NFT) error - GetOwner(ctx sdk.Context, classID string, nftID string) sdk.AccAddress + GetOwner(ctx context.Context, classID string, nftID string) sdk.AccAddress - Send(goCtx context.Context, msg *nft.MsgSend) (*nft.MsgSendResponse, error) + Send(ctx context.Context, msg *nft.MsgSend) (*nft.MsgSendResponse, error) } // ScorumKeeper defines the expected interface needed to verify supervisors. diff --git a/x/aviatrix/types/query.pb.go b/x/aviatrix/types/query.pb.go index 361cb71..000d287 100644 --- a/x/aviatrix/types/query.pb.go +++ b/x/aviatrix/types/query.pb.go @@ -5,8 +5,8 @@ package types import ( context "context" + _ "cosmossdk.io/x/nft" fmt "fmt" - _ "github.com/cosmos/cosmos-sdk/x/nft" _ "github.com/cosmos/gogoproto/gogoproto" grpc1 "github.com/cosmos/gogoproto/grpc" proto "github.com/cosmos/gogoproto/proto" diff --git a/x/aviatrix/types/tx.pb.go b/x/aviatrix/types/tx.pb.go index 6c0a621..2757b50 100644 --- a/x/aviatrix/types/tx.pb.go +++ b/x/aviatrix/types/tx.pb.go @@ -6,7 +6,9 @@ package types import ( context "context" fmt "fmt" + _ "github.com/cosmos/cosmos-proto" _ "github.com/cosmos/cosmos-sdk/types/msgservice" + _ "github.com/cosmos/cosmos-sdk/types/tx/amino" grpc1 "github.com/cosmos/gogoproto/grpc" proto "github.com/cosmos/gogoproto/proto" grpc "google.golang.org/grpc" @@ -442,34 +444,39 @@ func init() { func init() { proto.RegisterFile("network/aviatrix/v1/tx.proto", fileDescriptor_bfdcccde74665549) } var fileDescriptor_bfdcccde74665549 = []byte{ - // 428 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x94, 0xc1, 0xaa, 0xd3, 0x40, - 0x14, 0x86, 0x3b, 0x49, 0xef, 0x85, 0x7b, 0x0a, 0x15, 0xa2, 0xd6, 0x50, 0x64, 0x28, 0x71, 0x53, - 0x2c, 0x4d, 0x68, 0xc5, 0x8d, 0x3b, 0x15, 0x57, 0x12, 0x90, 0x80, 0x1b, 0x37, 0x32, 0x4d, 0x86, - 0x18, 0x35, 0x99, 0x30, 0x33, 0x49, 0xe3, 0xc2, 0x8d, 0x4f, 0xe0, 0xde, 0x97, 0xf0, 0x31, 0x5c, - 0x76, 0xe9, 0x52, 0x5a, 0xc1, 0xd7, 0x10, 0x93, 0xa6, 0x4d, 0xdb, 0x89, 0x56, 0xb8, 0xcb, 0x39, - 0xe7, 0xe7, 0xfc, 0xdf, 0x9c, 0x03, 0x3f, 0xdc, 0x4d, 0xa8, 0x5c, 0x32, 0xfe, 0xce, 0x21, 0x79, - 0x44, 0x24, 0x8f, 0x0a, 0x27, 0x9f, 0x39, 0xb2, 0xb0, 0x53, 0xce, 0x24, 0x33, 0x6e, 0x6e, 0xbb, - 0x76, 0xdd, 0xb5, 0xf3, 0xd9, 0xf0, 0x8e, 0xcf, 0x44, 0xcc, 0x84, 0x13, 0x8b, 0xf0, 0x8f, 0x38, - 0x16, 0x61, 0xa5, 0xb6, 0x26, 0x70, 0xf5, 0xe2, 0x3d, 0x49, 0xa8, 0x4b, 0x25, 0x31, 0x30, 0x00, - 0x2d, 0x52, 0xca, 0x23, 0x9a, 0xf8, 0xd4, 0xd4, 0x47, 0x68, 0xdc, 0xf5, 0x1a, 0x15, 0x8b, 0xc0, - 0x45, 0x29, 0x36, 0xfa, 0xa0, 0x45, 0x81, 0x89, 0x46, 0x68, 0x7c, 0xe5, 0x69, 0x51, 0x60, 0xdc, - 0x82, 0x0b, 0xb6, 0x4c, 0x28, 0x37, 0xb5, 0xb2, 0x54, 0x3d, 0x8c, 0x39, 0x74, 0x63, 0x2a, 0x49, - 0x39, 0xa8, 0x37, 0xc7, 0xb6, 0x02, 0xcc, 0xde, 0x99, 0x7b, 0xa5, 0xd6, 0xfa, 0x82, 0xa0, 0xef, - 0x8a, 0xf0, 0x29, 0xa7, 0x44, 0x52, 0xb5, 0x19, 0x06, 0x10, 0x59, 0x4a, 0x79, 0x1e, 0x09, 0x56, - 0x3b, 0x36, 0x2a, 0x7b, 0x18, 0x5d, 0x05, 0xd3, 0x3d, 0x1f, 0xe6, 0xd1, 0x8d, 0x4f, 0xbf, 0xbe, - 0xde, 0x6f, 0x8c, 0xb6, 0x4c, 0x18, 0x1c, 0xc2, 0x79, 0x54, 0xa4, 0x2c, 0x11, 0xd4, 0x12, 0x60, - 0xba, 0x22, 0x7c, 0x99, 0x06, 0x75, 0xe7, 0xd9, 0x6e, 0x6d, 0x47, 0xc0, 0xe8, 0x04, 0xb8, 0xfa, - 0xa0, 0xb6, 0xfb, 0xe0, 0x00, 0x2e, 0x49, 0xcc, 0xb2, 0x44, 0x6e, 0x4f, 0xb0, 0x7d, 0x9d, 0xe2, - 0x58, 0x30, 0x6a, 0x33, 0x3d, 0x02, 0x7b, 0x1c, 0xbc, 0xcd, 0x84, 0xbc, 0x5e, 0x30, 0xfd, 0x5f, - 0x60, 0x4a, 0xd3, 0x1a, 0x6c, 0xfe, 0x53, 0x03, 0xdd, 0x15, 0xa1, 0xf1, 0x1a, 0x7a, 0xcd, 0x6b, - 0xdf, 0x53, 0x5e, 0xe6, 0x70, 0xeb, 0xc3, 0xc9, 0x19, 0xa2, 0xda, 0xc8, 0xf8, 0x08, 0xb7, 0xd5, - 0x77, 0x99, 0xb6, 0x4d, 0x51, 0xca, 0x87, 0x0f, 0xff, 0x4b, 0xde, 0xb4, 0x57, 0x6f, 0xbf, 0xd5, - 0x5e, 0x29, 0x6f, 0xb7, 0xff, 0xeb, 0x9a, 0x9f, 0x3c, 0xff, 0xb6, 0xc6, 0x68, 0xb5, 0xc6, 0xe8, - 0xc7, 0x1a, 0xa3, 0xcf, 0x1b, 0xdc, 0x59, 0x6d, 0x70, 0xe7, 0xfb, 0x06, 0x77, 0x5e, 0xcd, 0xc2, - 0x48, 0xbe, 0xc9, 0x16, 0xb6, 0xcf, 0x62, 0x47, 0xf8, 0x8c, 0x67, 0xb1, 0x53, 0xa5, 0xc4, 0xb4, - 0xce, 0x97, 0x62, 0x9f, 0x30, 0xf2, 0x43, 0x4a, 0xc5, 0xe2, 0xb2, 0x0c, 0x8d, 0x07, 0xbf, 0x03, - 0x00, 0x00, 0xff, 0xff, 0x43, 0xb4, 0x2a, 0x4f, 0x82, 0x04, 0x00, 0x00, + // 506 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xbc, 0x54, 0x41, 0x8b, 0xd3, 0x40, + 0x14, 0xee, 0xa4, 0xed, 0xc2, 0xbe, 0x85, 0x05, 0xe3, 0xba, 0x1b, 0x83, 0x84, 0x1a, 0x2f, 0x4b, + 0x4b, 0x13, 0x5a, 0x59, 0x90, 0xbd, 0xed, 0x8a, 0x27, 0x29, 0x48, 0xc4, 0x8b, 0x97, 0x65, 0xb6, + 0x19, 0xe2, 0xa8, 0xc9, 0x84, 0x99, 0x49, 0xb7, 0x1e, 0x04, 0xf1, 0xe8, 0xc9, 0x9f, 0x52, 0xd0, + 0x1f, 0xe1, 0x71, 0xf1, 0xe4, 0x51, 0xda, 0x43, 0x0f, 0xfb, 0x27, 0xc4, 0x64, 0x52, 0xd3, 0x32, + 0xd5, 0xf6, 0xe2, 0x25, 0x30, 0xef, 0xfb, 0x32, 0xdf, 0x7c, 0xdf, 0x7b, 0x3c, 0xb8, 0x97, 0x10, + 0x79, 0xc5, 0xf8, 0x1b, 0x1f, 0x8f, 0x28, 0x96, 0x9c, 0x8e, 0xfd, 0x51, 0xcf, 0x97, 0x63, 0x2f, + 0xe5, 0x4c, 0x32, 0xf3, 0xb6, 0x42, 0xbd, 0x12, 0xf5, 0x46, 0x3d, 0xfb, 0xee, 0x90, 0x89, 0x98, + 0x89, 0x8b, 0x9c, 0xe2, 0x17, 0x87, 0x82, 0x6f, 0xdf, 0xc2, 0x31, 0x4d, 0x98, 0x9f, 0x7f, 0x55, + 0xe9, 0xa8, 0x20, 0xf8, 0xb1, 0x88, 0x7e, 0x5f, 0x1d, 0x8b, 0xa8, 0x00, 0xdc, 0x0e, 0xec, 0x3e, + 0x7b, 0x8b, 0x13, 0x32, 0x20, 0x12, 0x9b, 0x0e, 0x00, 0x19, 0xa7, 0x84, 0x53, 0x92, 0x0c, 0x89, + 0x55, 0x6f, 0xa1, 0xe3, 0x46, 0x50, 0xa9, 0xb8, 0x18, 0x9a, 0x39, 0xd9, 0xdc, 0x07, 0x83, 0x86, + 0x16, 0x6a, 0xa1, 0xe3, 0xdd, 0xc0, 0xa0, 0xa1, 0x79, 0x00, 0x4d, 0x76, 0x95, 0x10, 0x6e, 0x19, + 0x79, 0xa9, 0x38, 0x98, 0x7d, 0x68, 0xc4, 0x44, 0xe2, 0xfc, 0xa2, 0xbd, 0xbe, 0xe3, 0x69, 0x6c, + 0x78, 0x0b, 0xf1, 0x20, 0xe7, 0xba, 0x37, 0x08, 0xf6, 0x07, 0x22, 0x7a, 0xcc, 0x09, 0x96, 0x44, + 0x2f, 0xf6, 0x08, 0x40, 0x64, 0x29, 0xe1, 0x23, 0x2a, 0x98, 0x52, 0x3c, 0xb7, 0xbe, 0x7f, 0xed, + 0x1e, 0xa8, 0x10, 0xce, 0xc2, 0x90, 0x13, 0x21, 0x9e, 0x4b, 0x4e, 0x93, 0x28, 0xa8, 0x70, 0x4d, + 0xaf, 0x7c, 0x66, 0xfd, 0x1f, 0x3f, 0xad, 0x18, 0x68, 0x6c, 0x6e, 0xe0, 0xb4, 0xf3, 0x71, 0x3e, + 0x69, 0x57, 0x44, 0x3f, 0xcd, 0x27, 0xed, 0xa3, 0x45, 0x5b, 0x97, 0xad, 0xb9, 0x16, 0x1c, 0x2e, + 0x57, 0x02, 0x22, 0x52, 0x96, 0x08, 0xe2, 0x7e, 0x41, 0x60, 0x0d, 0x44, 0xf4, 0x22, 0x0d, 0x4b, + 0xe8, 0xc9, 0xa2, 0x0f, 0x2b, 0x09, 0xa0, 0x2d, 0x12, 0x28, 0xb2, 0x34, 0x16, 0x59, 0x1e, 0xc2, + 0x0e, 0x8e, 0x59, 0x96, 0x48, 0xd5, 0x6d, 0x75, 0x3a, 0x3d, 0xd1, 0xb8, 0xb8, 0x5f, 0x75, 0xa1, + 0x7d, 0x98, 0xeb, 0x42, 0x6b, 0x1d, 0xb6, 0xea, 0xec, 0x2c, 0x7c, 0x9d, 0x09, 0xf9, 0xbf, 0x9c, + 0xd5, 0x37, 0x77, 0xa6, 0x7d, 0x98, 0x72, 0xa6, 0xc5, 0x4a, 0x67, 0xfd, 0x1b, 0x03, 0xea, 0x03, + 0x11, 0x99, 0x17, 0xb0, 0x57, 0x9d, 0xdf, 0x07, 0xda, 0xb9, 0x59, 0xee, 0xbb, 0xdd, 0xd9, 0x80, + 0x54, 0x0a, 0x99, 0xef, 0xe1, 0x8e, 0x7e, 0x30, 0xba, 0xeb, 0x6e, 0xd1, 0xd2, 0xed, 0x93, 0xad, + 0xe8, 0x55, 0x79, 0x7d, 0xf7, 0xd6, 0xca, 0x6b, 0xe9, 0xeb, 0xe5, 0xff, 0x1a, 0xb3, 0xdd, 0xfc, + 0x30, 0x9f, 0xb4, 0xd1, 0xf9, 0xd3, 0x6f, 0x53, 0x07, 0x5d, 0x4f, 0x1d, 0xf4, 0x73, 0xea, 0xa0, + 0xcf, 0x33, 0xa7, 0x76, 0x3d, 0x73, 0x6a, 0x3f, 0x66, 0x4e, 0xed, 0x65, 0x2f, 0xa2, 0xf2, 0x55, + 0x76, 0xe9, 0x0d, 0x59, 0xec, 0x8b, 0x21, 0xe3, 0x59, 0xac, 0xf6, 0x63, 0xb7, 0x5c, 0xb3, 0xe3, + 0x3f, 0x8b, 0x56, 0xbe, 0x4b, 0x89, 0xb8, 0xdc, 0xc9, 0xb7, 0xe1, 0xc3, 0x5f, 0x01, 0x00, 0x00, + 0xff, 0xff, 0x45, 0xf5, 0x7e, 0x74, 0x89, 0x05, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. diff --git a/x/nft/validation.go b/x/nft/validation.go index 3439a67..cd8fcff 100644 --- a/x/nft/validation.go +++ b/x/nft/validation.go @@ -7,7 +7,7 @@ import ( _ "unsafe" ) -//go:linkname reNFTID github.com/cosmos/cosmos-sdk/x/nft.reNFTID +//go:linkname reNFTID cosmossdk.io/x/nft.reNFTID var reNFTID *regexp.Regexp func init() { diff --git a/x/scorum/client/cli/proposal_mint.go b/x/scorum/client/cli/proposal_mint.go index b2e7f59..abb4e3d 100644 --- a/x/scorum/client/cli/proposal_mint.go +++ b/x/scorum/client/cli/proposal_mint.go @@ -2,97 +2,76 @@ package cli import ( "fmt" - "strings" - "github.com/cometbft/cometbft/libs/os" + "github.com/cosmos/cosmos-sdk/types/address" + + addresscodec "cosmossdk.io/core/address" "github.com/cosmos/cosmos-sdk/client" + "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cosmos/cosmos-sdk/client/tx" - "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/cosmos-sdk/version" - govv1beta1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1" + "github.com/cosmos/cosmos-sdk/x/gov/client/cli" "github.com/scorum/cosmos-network/x/scorum/types" "github.com/spf13/cobra" ) -func CmdSubmitMintProposal() *cobra.Command { +const ( + FlagAuthority = "authority" +) + +// CmdSubmitMintProposal implements a command handler for submitting a mint proposal transaction. +func CmdSubmitMintProposal(ac addresscodec.Codec) *cobra.Command { cmd := &cobra.Command{ - Use: "mint [proposal-file]", - Args: cobra.ExactArgs(1), + Use: "mint [receiver] [coin] [flags]", + Args: cobra.ExactArgs(2), Short: "Submit a mint proposal", - Long: strings.TrimSpace( - fmt.Sprintf(`Submit a mint proposal along with an initial deposit. -The proposal details must be supplied via a JSON file. -Example: -$ %s tx gov submit-proposal mint --from= -Where proposal.json contains: -{ - "title": "Mint burned on old blockchain coins", - "description": "Emission in the modern blockchain!", - "recipient": "scorum16rlsek5yak6avnjpuatw6psxg246nzlwruaet5", - "amount": - { - "denom": "nscr", - "amount": "100000000000" - }, - "deposit": "1000scr" -} -`, - version.AppName, - ), - ), + Long: "Submit a mint proposal along with an initial deposit.", RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientTxContext(cmd) if err != nil { return err } - proposal, err := ParseMintProposalJSON(clientCtx.LegacyAmino, args[0]) + + proposal, err := cli.ReadGovPropFlags(clientCtx, cmd.Flags()) if err != nil { return err } - from := clientCtx.GetFromAddress() - content := types.NewMintProposal( - proposal.Title, proposal.Description, proposal.Recipient, proposal.Amount, - ) - - deposit, err := sdk.ParseCoinsNormalized(proposal.Deposit) + recipient := args[0] + coin, err := sdk.ParseCoinNormalized(args[1]) if err != nil { - return err + return fmt.Errorf("invalid coin: %w", err) } - msg, err := govv1beta1.NewMsgSubmitProposal(content, deposit, from) - if err != nil { - return err + authority, _ := cmd.Flags().GetString(FlagAuthority) + if authority != "" { + if _, err = ac.StringToBytes(authority); err != nil { + return fmt.Errorf("invalid authority address: %w", err) + } + } else { + authority = sdk.AccAddress(address.Module("gov")).String() + } + + if err := proposal.SetMsgs([]sdk.Msg{ + &types.MsgMint{ + Authority: authority, + Recipient: recipient, + Amount: coin, + }, + }); err != nil { + return fmt.Errorf("failed to create submit upgrade proposal message: %w", err) } - return tx.GenerateOrBroadcastTxCLI(clientCtx, cmd.Flags(), msg) + return tx.GenerateOrBroadcastTxCLI(clientCtx, cmd.Flags(), proposal) }, } - return cmd -} - -type MintProposalJSON struct { - Title string `json:"title" yaml:"title"` - Description string `json:"description" yaml:"description"` - Deposit string `json:"deposit" yaml:"deposit"` - - Recipient sdk.AccAddress `json:"recipient" yaml:"recipient"` - Amount sdk.Coin `json:"amount" yaml:"amount"` -} + cmd.Flags().String(FlagAuthority, "", "The address of the upgrade module authority (defaults to gov)") -func ParseMintProposalJSON(cdc *codec.LegacyAmino, proposalFile string) (MintProposalJSON, error) { - proposal := MintProposalJSON{} + // add common proposal flags + flags.AddTxFlagsToCmd(cmd) + cli.AddGovPropFlagsToCmd(cmd) + cmd.MarkFlagRequired(cli.FlagTitle) - contents, err := os.ReadFile(proposalFile) - if err != nil { - return proposal, err - } - - if err := cdc.UnmarshalJSON(contents, &proposal); err != nil { - return proposal, err - } - - return proposal, nil + return cmd } diff --git a/x/scorum/client/cli/tx.go b/x/scorum/client/cli/tx.go index 9942656..0863bf6 100644 --- a/x/scorum/client/cli/tx.go +++ b/x/scorum/client/cli/tx.go @@ -3,6 +3,8 @@ package cli import ( "fmt" + addresscodec "cosmossdk.io/core/address" + "github.com/cosmos/cosmos-sdk/client" "github.com/spf13/cobra" @@ -11,7 +13,7 @@ import ( ) // GetTxCmd returns the transaction commands for this module -func GetTxCmd() *cobra.Command { +func GetTxCmd(ac addresscodec.Codec) *cobra.Command { cmd := &cobra.Command{ Use: types.ModuleName, Short: fmt.Sprintf("%s transactions subcommands", types.ModuleName), @@ -21,13 +23,13 @@ func GetTxCmd() *cobra.Command { } cmd.AddCommand( - GetSupervisorTxCmd(), + GetSupervisorTxCmd(ac), ) return cmd } -func GetSupervisorTxCmd() *cobra.Command { +func GetSupervisorTxCmd(ac addresscodec.Codec) *cobra.Command { cmd := &cobra.Command{ Use: "admin", Short: "Supervisor transactions subcommands", @@ -39,6 +41,7 @@ func GetSupervisorTxCmd() *cobra.Command { cmd.AddCommand( CmdBurn(), CmdMintGas(), + CmdSubmitMintProposal(ac), ) return cmd diff --git a/x/scorum/client/cli/tx_mint_gas.go b/x/scorum/client/cli/tx_mint_gas.go index 8e6ce41..d566696 100644 --- a/x/scorum/client/cli/tx_mint_gas.go +++ b/x/scorum/client/cli/tx_mint_gas.go @@ -3,10 +3,11 @@ package cli import ( "fmt" + "cosmossdk.io/math" + "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cosmos/cosmos-sdk/client/tx" - sdk "github.com/cosmos/cosmos-sdk/types" "github.com/spf13/cobra" "github.com/scorum/cosmos-network/x/scorum/types" @@ -23,7 +24,7 @@ func CmdMintGas() *cobra.Command { return err } - amount, ok := sdk.NewIntFromString(args[1]) + amount, ok := math.NewIntFromString(args[1]) if !ok { return fmt.Errorf("invalid amount") } diff --git a/x/scorum/client/proposal_handler.go b/x/scorum/client/proposal_handler.go deleted file mode 100644 index 6792b2b..0000000 --- a/x/scorum/client/proposal_handler.go +++ /dev/null @@ -1,9 +0,0 @@ -package client - -import ( - govclient "github.com/cosmos/cosmos-sdk/x/gov/client" - "github.com/scorum/cosmos-network/x/scorum/client/cli" -) - -// ProposalHandler is the param change proposal handler. -var ProposalHandler = govclient.NewProposalHandler(cli.CmdSubmitMintProposal) diff --git a/x/scorum/handler.go b/x/scorum/handler.go deleted file mode 100644 index 66b93e6..0000000 --- a/x/scorum/handler.go +++ /dev/null @@ -1,23 +0,0 @@ -package scorum - -import ( - errorsmod "cosmossdk.io/errors" - "github.com/scorum/cosmos-network/x/scorum/types" - - sdk "github.com/cosmos/cosmos-sdk/types" - sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" - govv1beta1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1" - "github.com/scorum/cosmos-network/x/scorum/keeper" -) - -func NewMintProposalHandler(k keeper.Keeper) govv1beta1.Handler { - return func(ctx sdk.Context, content govv1beta1.Content) error { - switch c := content.(type) { - case *types.MintProposal: - return keeper.HandleMintProposal(ctx, k, c) - - default: - return errorsmod.Wrapf(sdkerrors.ErrUnknownRequest, "unrecognized earn proposal content type: %T", c) - } - } -} diff --git a/x/scorum/keeper/gas.go b/x/scorum/keeper/gas.go index abe0549..e25539a 100644 --- a/x/scorum/keeper/gas.go +++ b/x/scorum/keeper/gas.go @@ -3,7 +3,8 @@ package keeper import ( "slices" - "github.com/cosmos/cosmos-sdk/store/prefix" + "cosmossdk.io/math" + "cosmossdk.io/store/prefix" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/scorum/cosmos-network/x/scorum/types" ) @@ -16,37 +17,41 @@ func (k Keeper) SetAddressToRestoreGas(ctx sdk.Context, addr sdk.AccAddress) { s.Set(addr.Bytes(), []byte{}) } -func (k Keeper) RestoreGasForAddress(ctx sdk.Context, addr sdk.AccAddress, avgStakedBalance sdk.Dec, params types.Params) { +func (k Keeper) RestoreGasForAddress(ctx sdk.Context, addr sdk.AccAddress, avgStakedBalance math.LegacyDec, params types.Params) { s := prefix.NewStore(ctx.KVStore(k.storeKey), gasConsumedAddressesPrefix) gasBalance := k.bankKeeper.GetBalance(ctx, addr, types.GasDenom).Amount - stakedBalance := sdk.NewInt(0) - for _, delegation := range k.stakingKeeper.GetAllDelegatorDelegations(ctx, addr) { + stakedBalance := math.NewInt(0) + delegations, err := k.stakingKeeper.GetAllDelegatorDelegations(ctx, addr) + if err != nil { + panic(err) + } + for _, delegation := range delegations { stakedBalance = stakedBalance.Add(delegation.Shares.RoundInt()) } if gasBalance.IsNil() { - gasBalance = sdk.ZeroInt() + gasBalance = math.ZeroInt() } if stakedBalance.IsNil() { - stakedBalance = sdk.ZeroInt() + stakedBalance = math.ZeroInt() } - if gasBalance.GTE(params.GasLimit.Int) { + if gasBalance.GTE(params.GasLimit) { s.Delete(addr) } gasAdjust := calculateGasAdjustAmount( - sdk.NewDecFromInt(stakedBalance), - sdk.NewDecFromInt(params.GasLimit.Int), - sdk.NewDecFromInt(params.GasUnconditionedAmount.Int), + math.LegacyNewDecFromInt(stakedBalance), + math.LegacyNewDecFromInt(params.GasLimit), + math.LegacyNewDecFromInt(params.GasUnconditionedAmount), avgStakedBalance, - params.GasAdjustCoefficient.Dec, + params.GasAdjustCoefficient, ).RoundInt() // do not overflow gasLimit - if gasBalance.Add(gasAdjust).GT(params.GasLimit.Int) { - gasAdjust = params.GasLimit.Int.Sub(gasBalance) + if gasBalance.Add(gasAdjust).GT(params.GasLimit) { + gasAdjust = params.GasLimit.Sub(gasBalance) } if gasAdjust.IsPositive() { @@ -67,18 +72,22 @@ func (k Keeper) RestoreGas(ctx sdk.Context) { } } -func calculateGasAdjustAmount(stakedBalance, gasLimit, gasUnconditionedAmount, avgStakedBalance, gasAdjustCoefficient sdk.Dec) sdk.Dec { +func calculateGasAdjustAmount(stakedBalance, gasLimit, gasUnconditionedAmount, avgStakedBalance, gasAdjustCoefficient math.LegacyDec) math.LegacyDec { // stakedBalance // adjustAmount = gasUnconditionedAmount + ------------------ * GasLimit * GasAdjustCoefficient // avgStakedBalance return gasUnconditionedAmount.Add(stakedBalance.Quo(avgStakedBalance).Mul(gasLimit).Mul(gasAdjustCoefficient)) } -func (k Keeper) GetAverageStakedBalance(ctx sdk.Context) sdk.Dec { +func (k Keeper) GetAverageStakedBalance(ctx sdk.Context) math.LegacyDec { supervisors := k.GetParams(ctx).Supervisors - total, size := sdk.ZeroDec(), int64(0) + total, size := math.LegacyZeroDec(), int64(0) - for _, delegation := range k.stakingKeeper.GetAllDelegations(ctx) { + delegations, err := k.stakingKeeper.GetAllDelegations(ctx) + if err != nil { + panic(err) + } + for _, delegation := range delegations { if slices.Contains(supervisors, delegation.DelegatorAddress) { continue } @@ -88,7 +97,7 @@ func (k Keeper) GetAverageStakedBalance(ctx sdk.Context) sdk.Dec { } if size == 0 { - return sdk.NewDec(1) + return math.LegacyNewDec(1) } return total.QuoInt64(size) diff --git a/x/scorum/keeper/keeper.go b/x/scorum/keeper/keeper.go index 2837b91..cac3291 100644 --- a/x/scorum/keeper/keeper.go +++ b/x/scorum/keeper/keeper.go @@ -3,9 +3,11 @@ package keeper import ( "fmt" - "github.com/cometbft/cometbft/libs/log" + "cosmossdk.io/x/nft" + + "cosmossdk.io/log" + storetypes "cosmossdk.io/store/types" "github.com/cosmos/cosmos-sdk/codec" - storetypes "github.com/cosmos/cosmos-sdk/store/types" sdk "github.com/cosmos/cosmos-sdk/types" paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" @@ -23,6 +25,7 @@ type ( accountKeeper types.AccountKeeper feeCollectorName string + authority string } ) @@ -34,12 +37,18 @@ func NewKeeper( bankKeeper types.BankKeeper, stakingKeeper types.StakingKeeper, feeCollectorName string, + authority string, ) Keeper { // set KeyTable if it has not already been set if !ps.HasKeyTable() { ps = ps.WithKeyTable(types.ParamKeyTable()) } + // ensure nft module account is set + if addr := accountKeeper.GetModuleAddress(nft.ModuleName); addr == nil { + panic("the nft module account has not been set") + } + return Keeper{ cdc: cdc, storeKey: storeKey, @@ -49,6 +58,7 @@ func NewKeeper( accountKeeper: accountKeeper, stakingKeeper: stakingKeeper, feeCollectorName: feeCollectorName, + authority: authority, } } diff --git a/x/scorum/keeper/keeper_test.go b/x/scorum/keeper/keeper_test.go index 33b8f08..0f616a6 100644 --- a/x/scorum/keeper/keeper_test.go +++ b/x/scorum/keeper/keeper_test.go @@ -3,6 +3,8 @@ package keeper_test import ( "testing" + "cosmossdk.io/math" + sdk "github.com/cosmos/cosmos-sdk/types" accountkeeper "github.com/cosmos/cosmos-sdk/x/auth/keeper" bankkeeper "github.com/cosmos/cosmos-sdk/x/bank/keeper" @@ -32,9 +34,9 @@ func setupKeeper(t testing.TB) (keeperSet, testutil.TestContext) { set.keeper.SetParams(ctx.Context, types.Params{ Supervisors: []string{set.supervisor.String()}, - GasLimit: sdk.IntProto{Int: sdk.NewInt(1000)}, - GasUnconditionedAmount: sdk.IntProto{Int: sdk.NewInt(500)}, - GasAdjustCoefficient: sdk.DecProto{Dec: sdk.NewDec(1)}, + GasLimit: math.NewInt(1000), + GasUnconditionedAmount: math.NewInt(500), + GasAdjustCoefficient: math.LegacyNewDec(1), }) return set, ctx diff --git a/x/scorum/keeper/msg_mint.go b/x/scorum/keeper/msg_mint.go new file mode 100644 index 0000000..67b9c62 --- /dev/null +++ b/x/scorum/keeper/msg_mint.go @@ -0,0 +1,28 @@ +package keeper + +import ( + "context" + + "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" + sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" + + "github.com/scorum/cosmos-network/x/scorum/types" +) + +func (m msgServer) Mint(ctx context.Context, msg *types.MsgMint) (*types.MsgMintResponse, error) { + if m.authority != msg.Authority { + return nil, errors.Wrapf(sdkerrors.ErrUnauthorized, "expected %s got %s", m.authority, msg.Authority) + } + + recipient, err := m.accountKeeper.AddressCodec().StringToBytes(msg.Recipient) + if err != nil { + return nil, err + } + + if err := m.Keeper.Mint(sdk.UnwrapSDKContext(ctx), recipient, msg.Amount); err != nil { + return nil, err + } + + return &types.MsgMintResponse{}, nil +} diff --git a/x/scorum/keeper/proposal_mint_test.go b/x/scorum/keeper/msg_mint_test.go similarity index 59% rename from x/scorum/keeper/proposal_mint_test.go rename to x/scorum/keeper/msg_mint_test.go index f64f0ad..c482b69 100644 --- a/x/scorum/keeper/proposal_mint_test.go +++ b/x/scorum/keeper/msg_mint_test.go @@ -3,6 +3,8 @@ package keeper_test import ( "testing" + "cosmossdk.io/math" + sdk "github.com/cosmos/cosmos-sdk/types" "github.com/scorum/cosmos-network/testutil/sample" "github.com/scorum/cosmos-network/x/scorum/keeper" @@ -10,18 +12,20 @@ import ( "github.com/stretchr/testify/require" ) -func TestProposal_Mint(t *testing.T) { +func TestMsgServer_Mint(t *testing.T) { set, ctx := setupKeeper(t) addr := sample.AccAddress() - coin := sdk.NewCoin(types.SCRDenom, sdk.NewInt(1000)) - - require.NoError(t, keeper.HandleMintProposal(ctx.Context, set.keeper, &types.MintProposal{ - Title: "test", - Description: "test description", - Recipient: addr.String(), - Amount: coin, - })) + coin := sdk.NewCoin(types.SCRDenom, math.NewInt(1000)) + + s := keeper.NewMsgServer(set.keeper) + + _, err := s.Mint(ctx.Context, &types.MsgMint{ + Authority: "gov", + Recipient: addr.String(), + Amount: coin, + }) + require.NoError(t, err) require.True(t, coin.Equal(set.bankKeeper.GetBalance(ctx.Context, addr, types.SCRDenom))) } diff --git a/x/scorum/keeper/msg_server_burn_test.go b/x/scorum/keeper/msg_server_burn_test.go index de854c3..32c4845 100644 --- a/x/scorum/keeper/msg_server_burn_test.go +++ b/x/scorum/keeper/msg_server_burn_test.go @@ -3,6 +3,8 @@ package keeper_test import ( "testing" + "cosmossdk.io/math" + sdk "github.com/cosmos/cosmos-sdk/types" "github.com/scorum/cosmos-network/testutil/sample" "github.com/scorum/cosmos-network/x/scorum/keeper" @@ -13,7 +15,7 @@ import ( func TestMsgServer_Burn(t *testing.T) { set, ctx := setupKeeper(t) - coin := sdk.NewCoin(types.SCRDenom, sdk.NewInt(1000)) + coin := sdk.NewCoin(types.SCRDenom, math.NewInt(1000)) s := keeper.NewMsgServer(set.keeper) @@ -34,7 +36,7 @@ func TestMsgServer_Burn_NotSupervisor(t *testing.T) { set, ctx := setupKeeper(t) addr := sample.AccAddress() - coin := sdk.NewCoin(types.SCRDenom, sdk.NewInt(1000)) + coin := sdk.NewCoin(types.SCRDenom, math.NewInt(1000)) s := keeper.NewMsgServer(set.keeper) diff --git a/x/scorum/keeper/msg_server_mint_gas.go b/x/scorum/keeper/msg_server_mint_gas.go index 8335e71..08a6d55 100644 --- a/x/scorum/keeper/msg_server_mint_gas.go +++ b/x/scorum/keeper/msg_server_mint_gas.go @@ -21,7 +21,7 @@ func (m msgServer) MintGas(goCtx context.Context, msg *types.MsgMintGas) (*types return nil, errorsmod.Wrapf(sdkerrors.ErrInvalidAddress, "invalid account address: %s", err) } - if err := m.Keeper.Mint(ctx, address, sdk.NewCoin(types.GasDenom, msg.Amount.Int)); err != nil { + if err := m.Keeper.Mint(ctx, address, sdk.NewCoin(types.GasDenom, msg.Amount)); err != nil { return nil, err } diff --git a/x/scorum/keeper/msg_server_mint_gas_test.go b/x/scorum/keeper/msg_server_mint_gas_test.go index f1b49e4..bfc09e9 100644 --- a/x/scorum/keeper/msg_server_mint_gas_test.go +++ b/x/scorum/keeper/msg_server_mint_gas_test.go @@ -3,6 +3,8 @@ package keeper_test import ( "testing" + "cosmossdk.io/math" + sdk "github.com/cosmos/cosmos-sdk/types" "github.com/scorum/cosmos-network/testutil/sample" "github.com/scorum/cosmos-network/x/scorum/keeper" @@ -13,7 +15,7 @@ import ( func TestMsgServer_MintGas(t *testing.T) { set, ctx := setupKeeper(t) - coin := sdk.NewCoin(types.GasDenom, sdk.NewInt(1000)) + coin := sdk.NewCoin(types.GasDenom, math.NewInt(1000)) s := keeper.NewMsgServer(set.keeper) @@ -24,7 +26,7 @@ func TestMsgServer_MintGas(t *testing.T) { _, err := s.MintGas(ctx, &types.MsgMintGas{ Supervisor: set.supervisor.String(), Address: set.supervisor.String(), - Amount: sdk.IntProto{Int: sdk.NewInt(10000000)}, + Amount: math.NewInt(10000000), }) require.NoError(t, err) @@ -35,7 +37,7 @@ func TestMsgServer_MintGas_NotSupervisor(t *testing.T) { set, ctx := setupKeeper(t) addr := sample.AccAddress() - coin := sdk.NewCoin(types.GasDenom, sdk.NewInt(1000)) + coin := sdk.NewCoin(types.GasDenom, math.NewInt(1000)) s := keeper.NewMsgServer(set.keeper) @@ -46,7 +48,7 @@ func TestMsgServer_MintGas_NotSupervisor(t *testing.T) { _, err := s.MintGas(ctx, &types.MsgMintGas{ Supervisor: addr.String(), Address: set.supervisor.String(), - Amount: sdk.IntProto{Int: sdk.NewInt(10000000)}, + Amount: math.NewInt(10000000), }) require.Error(t, err) } diff --git a/x/scorum/keeper/params_test.go b/x/scorum/keeper/params_test.go index 1f50837..aecc794 100644 --- a/x/scorum/keeper/params_test.go +++ b/x/scorum/keeper/params_test.go @@ -3,6 +3,8 @@ package keeper_test import ( "testing" + "cosmossdk.io/math" + sdk "github.com/cosmos/cosmos-sdk/types" "github.com/scorum/cosmos-network/testutil/sample" "github.com/scorum/cosmos-network/x/scorum/types" @@ -14,15 +16,15 @@ func TestGetParams(t *testing.T) { params := types.NewParams( []string{sample.AccAddress().String()}, - sdk.NewInt(1000), - sdk.NewInt(500), - sdk.NewDec(1), + math.NewInt(1000), + math.NewInt(500), + math.LegacyNewDec(1), ) params.ValidatorsReward = types.ValidatorsRewardParams{ PoolAddress: "", BlockReward: sdk.Coin{ Denom: "", - Amount: sdk.ZeroInt(), + Amount: math.ZeroInt(), }, } diff --git a/x/scorum/keeper/proposal_mint.go b/x/scorum/keeper/proposal_mint.go deleted file mode 100644 index d3769c4..0000000 --- a/x/scorum/keeper/proposal_mint.go +++ /dev/null @@ -1,19 +0,0 @@ -package keeper - -import ( - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/scorum/cosmos-network/x/scorum/types" -) - -func HandleMintProposal(ctx sdk.Context, k Keeper, c *types.MintProposal) error { - recipient, err := sdk.AccAddressFromBech32(c.Recipient) - if err != nil { - return err - } - - if err := k.Mint(ctx, recipient, c.Amount); err != nil { - return err - } - - return nil -} diff --git a/x/scorum/keeper/query_params_test.go b/x/scorum/keeper/query_params_test.go index cfd3262..f16f5c6 100644 --- a/x/scorum/keeper/query_params_test.go +++ b/x/scorum/keeper/query_params_test.go @@ -3,6 +3,8 @@ package keeper_test import ( "testing" + "cosmossdk.io/math" + sdk "github.com/cosmos/cosmos-sdk/types" "github.com/scorum/cosmos-network/testutil/sample" "github.com/scorum/cosmos-network/x/scorum/keeper" @@ -16,15 +18,15 @@ func TestQuery_GetParams(t *testing.T) { params := types.NewParams( []string{sample.AccAddress().String()}, - sdk.NewInt(1000), - sdk.NewInt(500), - sdk.NewDec(1), + math.NewInt(1000), + math.NewInt(500), + math.LegacyNewDec(1), ) params.ValidatorsReward = types.ValidatorsRewardParams{ PoolAddress: "", BlockReward: sdk.Coin{ Denom: "", - Amount: sdk.ZeroInt(), + Amount: math.ZeroInt(), }, } diff --git a/x/scorum/keeper/validator_reward.go b/x/scorum/keeper/validator_reward.go index 7182017..bedb5e4 100644 --- a/x/scorum/keeper/validator_reward.go +++ b/x/scorum/keeper/validator_reward.go @@ -8,12 +8,12 @@ import ( ) func (k Keeper) PrepareValidatorsReward(ctx sdk.Context) { - feeCollector := k.accountKeeper.GetModuleAccount(ctx, k.feeCollectorName) + feeCollectorAddr := k.accountKeeper.GetModuleAddress(k.feeCollectorName) ctx.Logger().Debug("burn collected gas from fee_collector") - b := k.bankKeeper.GetBalance(ctx, feeCollector.GetAddress(), types.GasDenom) + b := k.bankKeeper.GetBalance(ctx, feeCollectorAddr, types.GasDenom) if b.IsPositive() { - if err := k.Burn(ctx, feeCollector.GetAddress(), b); err != nil { + if err := k.Burn(ctx, feeCollectorAddr, b); err != nil { panic(fmt.Errorf("failed to burn gas coins: %w", err)) } } @@ -46,7 +46,7 @@ func (k Keeper) PrepareValidatorsReward(ctx sdk.Context) { return } - if err := k.bankKeeper.SendCoins(ctx, poolAddress, feeCollector.GetAddress(), sdk.NewCoins(blockReward)); err != nil { + if err := k.bankKeeper.SendCoins(ctx, poolAddress, feeCollectorAddr, sdk.NewCoins(blockReward)); err != nil { panic(fmt.Errorf("failed to send coins from validators reward pool to fee_collector: %w", err)) } diff --git a/x/scorum/module.go b/x/scorum/module.go index abb0dcd..2686896 100644 --- a/x/scorum/module.go +++ b/x/scorum/module.go @@ -6,6 +6,10 @@ import ( "fmt" "math/rand" + "cosmossdk.io/core/address" + + "github.com/cosmos/cosmos-sdk/types/module" + simtypes "github.com/cosmos/cosmos-sdk/types/simulation" accountkeeper "github.com/cosmos/cosmos-sdk/x/auth/keeper" bankkeeper "github.com/cosmos/cosmos-sdk/x/bank/keeper" @@ -14,11 +18,11 @@ import ( abci "github.com/cometbft/cometbft/abci/types" + "cosmossdk.io/core/appmodule" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/codec" cdctypes "github.com/cosmos/cosmos-sdk/codec/types" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/cosmos-sdk/types/module" "github.com/scorum/cosmos-network/x/scorum/client/cli" "github.com/scorum/cosmos-network/x/scorum/keeper" "github.com/scorum/cosmos-network/x/scorum/simulation" @@ -26,7 +30,7 @@ import ( ) var ( - _ module.AppModule = AppModule{} + _ appmodule.AppModule = AppModule{} _ module.AppModuleBasic = AppModuleBasic{} ) @@ -37,10 +41,11 @@ var ( // AppModuleBasic implements the AppModuleBasic interface that defines the independent methods a Cosmos SDK module needs to implement. type AppModuleBasic struct { cdc codec.BinaryCodec + ac address.Codec } -func NewAppModuleBasic(cdc codec.BinaryCodec) AppModuleBasic { - return AppModuleBasic{cdc: cdc} +func NewAppModuleBasic(cdc codec.BinaryCodec, ac address.Codec) AppModuleBasic { + return AppModuleBasic{cdc: cdc, ac: ac} } // Name returns the name of the module as a string @@ -81,7 +86,7 @@ func (AppModuleBasic) RegisterGRPCGatewayRoutes(clientCtx client.Context, mux *r // GetTxCmd returns the root Tx command for the module. The subcommands of this root command are used by end-users to generate new transactions containing messages defined in the module func (a AppModuleBasic) GetTxCmd() *cobra.Command { - return cli.GetTxCmd() + return cli.GetTxCmd(a.ac) } // GetQueryCmd returns the root query command for the module. The subcommands of this root command are used by end-users to generate new queries to the subset of the state defined by the module @@ -104,12 +109,13 @@ type AppModule struct { func NewAppModule( cdc codec.Codec, + ac address.Codec, keeper keeper.Keeper, accountKeeper accountkeeper.AccountKeeper, bankKeeper bankkeeper.Keeper, ) AppModule { return AppModule{ - AppModuleBasic: NewAppModuleBasic(cdc), + AppModuleBasic: NewAppModuleBasic(cdc, ac), keeper: keeper, accountKeeper: accountKeeper, bankKeeper: bankKeeper, @@ -146,14 +152,14 @@ func (am AppModule) ExportGenesis(ctx sdk.Context, cdc codec.JSONCodec) json.Raw func (AppModule) ConsensusVersion() uint64 { return 1 } // BeginBlock contains the logic that is automatically triggered at the beginning of each block -func (am AppModule) BeginBlock(ctx sdk.Context, _ abci.RequestBeginBlock) { +func (am AppModule) BeginBlock(ctx sdk.Context) { am.keeper.RestoreGas(ctx) am.keeper.PrepareValidatorsReward(ctx) } // EndBlock contains the logic that is automatically triggered at the end of each block -func (am AppModule) EndBlock(_ sdk.Context, _ abci.RequestEndBlock) []abci.ValidatorUpdate { - return []abci.ValidatorUpdate{} +func (am AppModule) EndBlock(ctx context.Context) ([]abci.ValidatorUpdate, error) { + return []abci.ValidatorUpdate{}, nil } // AppModuleSimulation functions @@ -163,10 +169,9 @@ func (AppModule) GenerateGenesisState(simState *module.SimulationState) { simulation.GenerateGenesisState(simState) } -// ProposalContents returns all the distribution content functions used to -// simulate governance proposals. -func (am AppModule) ProposalContents(simState module.SimulationState) []simtypes.WeightedProposalContent { - return simulation.ProposalContents(simState) +// ProposalMsgs returns msgs used for governance proposals for simulations. +func (AppModule) ProposalMsgs(simState module.SimulationState) []simtypes.WeightedProposalMsg { + return simulation.ProposalMsgs() } // RandomizedParams creates randomized distribution param changes for the simulator. @@ -175,7 +180,7 @@ func (AppModule) RandomizedParams(r *rand.Rand) []simtypes.LegacyParamChange { } // RegisterStoreDecoder registers a decoder for distribution module's types -func (am AppModule) RegisterStoreDecoder(sdr sdk.StoreDecoderRegistry) { +func (am AppModule) RegisterStoreDecoder(sdr simtypes.StoreDecoderRegistry) { // sdr[types.StoreKey] = simulation.NewDecodeStore(am.cdc) } @@ -185,3 +190,9 @@ func (am AppModule) WeightedOperations(simState module.SimulationState) []simtyp simState, am.accountKeeper, am.bankKeeper, am.keeper, ) } + +// IsOnePerModuleType implements the depinject.OnePerModuleType interface. +func (am AppModule) IsOnePerModuleType() {} + +// IsAppModule implements the appmodule.AppModule interface. +func (am AppModule) IsAppModule() {} diff --git a/x/scorum/simulation/genesis.go b/x/scorum/simulation/genesis.go index 8b70ef5..0de6bba 100644 --- a/x/scorum/simulation/genesis.go +++ b/x/scorum/simulation/genesis.go @@ -1,6 +1,7 @@ package simulation import ( + "cosmossdk.io/math" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" @@ -22,7 +23,7 @@ func GenerateGenesisState(simState *module.SimulationState) { } if len(accs) > 0 { scorumGenesis.Params.ValidatorsReward.PoolAddress = accs[0] - scorumGenesis.Params.ValidatorsReward.BlockReward = sdk.Coin{Amount: sdk.NewInt(1), Denom: types.SCRDenom} + scorumGenesis.Params.ValidatorsReward.BlockReward = sdk.Coin{Amount: math.NewInt(1), Denom: types.SCRDenom} } simState.GenState[types.ModuleName] = simState.Cdc.MustMarshalJSON(&scorumGenesis) diff --git a/x/scorum/simulation/operations.go b/x/scorum/simulation/operations.go index 79ad5c8..4454605 100644 --- a/x/scorum/simulation/operations.go +++ b/x/scorum/simulation/operations.go @@ -17,9 +17,11 @@ import ( // nolint const ( + TypeMsgBurn = "scorum/MsgBurn" opWeightMsgBurn = "op_weight_msg_burn" defaultWeightMsgBurn = 10 + TypeMsgMintGas = "scorum/MsgMintGas" opWeightMsgMintGas = "op_weight_msg_mint_gas" defaultWeightMsgMintGas = 10 ) @@ -33,12 +35,12 @@ func WeightedOperations( weightMsgMintGas int ) - simState.AppParams.GetOrGenerate(simState.Cdc, opWeightMsgBurn, &weightMsgBurn, nil, + simState.AppParams.GetOrGenerate(opWeightMsgBurn, &weightMsgBurn, nil, func(_ *rand.Rand) { weightMsgBurn = defaultWeightMsgBurn }, ) - simState.AppParams.GetOrGenerate(simState.Cdc, opWeightMsgMintGas, &weightMsgMintGas, nil, + simState.AppParams.GetOrGenerate(opWeightMsgMintGas, &weightMsgMintGas, nil, func(_ *rand.Rand) { weightMsgMintGas = defaultWeightMsgMintGas }, @@ -65,24 +67,24 @@ func SimulateMsgBurn( r *rand.Rand, app *baseapp.BaseApp, ctx sdk.Context, accs []simtypes.Account, chainID string, ) (simtypes.OperationMsg, []simtypes.FutureOperation, error) { if len(accs) == 0 { - return simtypes.NoOpMsg(types.ModuleName, types.TypeMsgBurn, "accounts are empty"), nil, nil + return simtypes.NoOpMsg(types.ModuleName, TypeMsgBurn, "accounts are empty"), nil, nil } supervisor := accs[0] if !k.IsSupervisor(ctx, supervisor.Address.String()) { - return simtypes.NoOpMsg(types.ModuleName, types.TypeMsgBurn, "first acc is not a supervisor"), nil, nil + return simtypes.NoOpMsg(types.ModuleName, TypeMsgBurn, "first acc is not a supervisor"), nil, nil } balances := bk.GetAllBalances(ctx, supervisor.Address) if len(balances) == 0 { - return simtypes.NoOpMsg(types.ModuleName, types.TypeMsgBurn, "empty balance"), nil, nil + return simtypes.NoOpMsg(types.ModuleName, TypeMsgBurn, "empty balance"), nil, nil } for _, b := range balances { - if b.Amount.GT(sdk.OneInt()) { + if b.Amount.GT(math.OneInt()) { msg := &types.MsgBurn{ Supervisor: supervisor.Address.String(), - Amount: sdk.NewCoin(b.Denom, sdk.OneInt()), + Amount: sdk.NewCoin(b.Denom, math.OneInt()), } txCtx := simulation.OperationInput{ @@ -91,7 +93,6 @@ func SimulateMsgBurn( TxGen: moduletestutil.MakeTestEncodingConfig().TxConfig, Cdc: nil, Msg: msg, - MsgType: msg.Type(), Context: ctx, SimAccount: supervisor, AccountKeeper: ak, @@ -103,7 +104,7 @@ func SimulateMsgBurn( } } - return simtypes.NoOpMsg(types.ModuleName, types.TypeMsgBurn, "empty balance"), nil, nil + return simtypes.NoOpMsg(types.ModuleName, TypeMsgBurn, "empty balance"), nil, nil } } @@ -116,24 +117,24 @@ func SimulateMsgMintGas( r *rand.Rand, app *baseapp.BaseApp, ctx sdk.Context, accs []simtypes.Account, chainID string, ) (simtypes.OperationMsg, []simtypes.FutureOperation, error) { if len(accs) == 0 { - return simtypes.NoOpMsg(types.ModuleName, types.TypeMsgBurn, "accounts are empty"), nil, nil + return simtypes.NoOpMsg(types.ModuleName, TypeMsgBurn, "accounts are empty"), nil, nil } supervisor := accs[0] if !k.IsSupervisor(ctx, supervisor.Address.String()) { - return simtypes.NoOpMsg(types.ModuleName, types.TypeMsgBurn, "first acc is not a supervisor"), nil, nil + return simtypes.NoOpMsg(types.ModuleName, TypeMsgBurn, "first acc is not a supervisor"), nil, nil } addr, _ := simtypes.RandomAcc(r, accs) amount, err := simtypes.RandPositiveInt(r, math.NewInt(1000000)) if err != nil { - return simtypes.NoOpMsg(types.ModuleName, types.TypeMsgMintGas, "failed to rand int"), nil, nil + return simtypes.NoOpMsg(types.ModuleName, TypeMsgMintGas, "failed to rand int"), nil, nil } msg := &types.MsgMintGas{ Supervisor: supervisor.Address.String(), Address: addr.Address.String(), - Amount: sdk.IntProto{Int: amount}, + Amount: amount, } txCtx := simulation.OperationInput{ @@ -142,7 +143,6 @@ func SimulateMsgMintGas( TxGen: moduletestutil.MakeTestEncodingConfig().TxConfig, Cdc: nil, Msg: msg, - MsgType: msg.Type(), Context: ctx, SimAccount: supervisor, AccountKeeper: ak, diff --git a/x/scorum/simulation/params.go b/x/scorum/simulation/params.go index 7b78a62..c2505dc 100644 --- a/x/scorum/simulation/params.go +++ b/x/scorum/simulation/params.go @@ -4,7 +4,8 @@ import ( "fmt" "math/rand" - sdk "github.com/cosmos/cosmos-sdk/types" + "cosmossdk.io/math" + simtypes "github.com/cosmos/cosmos-sdk/types/simulation" "github.com/cosmos/cosmos-sdk/x/simulation" "github.com/scorum/cosmos-network/x/scorum/types" @@ -32,7 +33,7 @@ func ParamChanges(r *rand.Rand) []simtypes.LegacyParamChange { func(r *rand.Rand) string { return fmt.Sprintf( `{"dec": "%s"}`, - sdk.NewDecWithPrec(int64(simtypes.RandIntBetween(r, 1, 2000)), 3), + math.LegacyNewDecWithPrec(int64(simtypes.RandIntBetween(r, 1, 2000)), 3), ) }, ), diff --git a/x/scorum/simulation/proposals.go b/x/scorum/simulation/proposals.go index 486fc93..e7b666d 100644 --- a/x/scorum/simulation/proposals.go +++ b/x/scorum/simulation/proposals.go @@ -1,46 +1,45 @@ package simulation import ( - "fmt" "math/rand" + "github.com/cosmos/cosmos-sdk/types/address" + "cosmossdk.io/math" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/cosmos-sdk/types/module" simtypes "github.com/cosmos/cosmos-sdk/types/simulation" "github.com/cosmos/cosmos-sdk/x/simulation" "github.com/scorum/cosmos-network/x/scorum/types" ) -// nolint +//nolint:gosec const ( - OpWeightMintProposal = "op_weight_mint_proposal" + opWeightMintProposal = "op_weight_mint_proposal" + defaultWeightMsgMint = 10 ) -func ProposalContents(_ module.SimulationState) []simtypes.WeightedProposalContent { - var ( - defaultWeightMintProposal = 5 - ) - - return []simtypes.WeightedProposalContent{ - simulation.NewWeightedProposalContent( - OpWeightMintProposal, - defaultWeightMintProposal, - SimulateMintProposalContent(), +// ProposalMsgs defines the module weighted proposals' contents +func ProposalMsgs() []simtypes.WeightedProposalMsg { + return []simtypes.WeightedProposalMsg{ + simulation.NewWeightedProposalMsg( + opWeightMintProposal, + defaultWeightMsgMint, + SimulateMsgMint, ), } } -func SimulateMintProposalContent() simtypes.ContentSimulatorFn { - numProposals := 0 - - return func(r *rand.Rand, _ sdk.Context, accounts []simtypes.Account) simtypes.Content { - title := fmt.Sprintf("title from SimulateMintProposalContent-%d", numProposals) - desc := fmt.Sprintf("desc from SimulateMintProposalContent-%d. Random short desc: %s", - numProposals, simtypes.RandStringOfLength(r, 20)) - recipient, _ := simtypes.RandomAcc(r, accounts) - amount := sdk.NewCoin(types.SCRDenom, simtypes.RandomAmount(r, math.NewInt(10000000))) - numProposals++ - return types.NewMintProposal(title, desc, recipient.Address, amount) +// SimulateMsgMint returns a random MsgMint +func SimulateMsgMint(r *rand.Rand, _ sdk.Context, accounts []simtypes.Account) sdk.Msg { + // use the default gov module account address as authority + var authority sdk.AccAddress = address.Module("gov") + + recipient, _ := simtypes.RandomAcc(r, accounts) + amount, _ := simtypes.RandPositiveInt(r, math.NewInt(10000000)) + + return &types.MsgMint{ + Authority: authority.String(), + Recipient: recipient.Address.String(), + Amount: sdk.NewCoin(types.SCRDenom, amount), } } diff --git a/x/scorum/types/codec.go b/x/scorum/types/codec.go index 84bca10..3175ca8 100644 --- a/x/scorum/types/codec.go +++ b/x/scorum/types/codec.go @@ -5,27 +5,18 @@ import ( cdctypes "github.com/cosmos/cosmos-sdk/codec/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/msgservice" - govtypes "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1" ) func RegisterCodec(cdc *codec.LegacyAmino) { - cdc.RegisterConcrete(&MintProposal{}, "scorum/MintProposal", nil) + cdc.RegisterConcrete(&MsgMint{}, "scorum/MsgMint", nil) cdc.RegisterConcrete(&MsgBurn{}, "scorum/MsgBurn", nil) } func RegisterInterfaces(registry cdctypes.InterfaceRegistry) { - registry.RegisterImplementations( - (*govtypes.Content)(nil), - &MintProposal{}, - ) registry.RegisterImplementations( (*sdk.Msg)(nil), &MsgBurn{}, - ) - registry.RegisterInterface( - "cosmos.gov.v1beta1.Content", - (*govtypes.Content)(nil), - &MintProposal{}, + &MsgMint{}, ) msgservice.RegisterMsgServiceDesc(registry, &_Msg_serviceDesc) diff --git a/x/scorum/types/expected_keepers.go b/x/scorum/types/expected_keepers.go index 0d61535..870133e 100644 --- a/x/scorum/types/expected_keepers.go +++ b/x/scorum/types/expected_keepers.go @@ -1,34 +1,40 @@ package types import ( - sdk "github.com/cosmos/cosmos-sdk/types" + "context" + "github.com/cosmos/cosmos-sdk/x/auth/types" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" + + "cosmossdk.io/core/address" + + sdk "github.com/cosmos/cosmos-sdk/types" ) type BankKeeper interface { BlockedAddr(addr sdk.AccAddress) bool - SendCoins(ctx sdk.Context, fromAddr sdk.AccAddress, toAddr sdk.AccAddress, amt sdk.Coins) error - SendCoinsFromModuleToAccount(ctx sdk.Context, senderModule string, recipientAddr sdk.AccAddress, amt sdk.Coins) error - SendCoinsFromAccountToModule(ctx sdk.Context, senderAddr sdk.AccAddress, recipientModule string, amt sdk.Coins) error - SendCoinsFromModuleToModule(ctx sdk.Context, senderModule, recipientModule string, amt sdk.Coins) error - MintCoins(ctx sdk.Context, moduleName string, amt sdk.Coins) error - BurnCoins(ctx sdk.Context, moduleName string, amt sdk.Coins) error - - GetBalance(ctx sdk.Context, addr sdk.AccAddress, denom string) sdk.Coin - IterateAllBalances(ctx sdk.Context, f func(addr sdk.AccAddress, coin sdk.Coin) (stop bool)) + SendCoins(ctx context.Context, fromAddr, toAddr sdk.AccAddress, amt sdk.Coins) error + SendCoinsFromModuleToAccount(ctx context.Context, senderModule string, recipientAddr sdk.AccAddress, amt sdk.Coins) error + SendCoinsFromAccountToModule(ctx context.Context, senderAddr sdk.AccAddress, recipientModule string, amt sdk.Coins) error + SendCoinsFromModuleToModule(ctx context.Context, senderModule, recipientModule string, amt sdk.Coins) error + MintCoins(ctx context.Context, moduleName string, amt sdk.Coins) error + BurnCoins(ctx context.Context, moduleName string, amt sdk.Coins) error + + GetBalance(ctx context.Context, addr sdk.AccAddress, denom string) sdk.Coin + IterateAllBalances(ctx context.Context, f func(addr sdk.AccAddress, coin sdk.Coin) (stop bool)) } type AccountKeeper interface { - NewAccountWithAddress(ctx sdk.Context, addr sdk.AccAddress) types.AccountI - GetAccount(sdk.Context, sdk.AccAddress) types.AccountI - HasAccount(ctx sdk.Context, addr sdk.AccAddress) bool + NewAccountWithAddress(ctx context.Context, addr sdk.AccAddress) sdk.AccountI + GetAccount(context.Context, sdk.AccAddress) sdk.AccountI + HasAccount(ctx context.Context, addr sdk.AccAddress) bool GetModulePermissions() map[string]types.PermissionsForAddress - GetModuleAccount(ctx sdk.Context, moduleName string) types.ModuleAccountI + GetModuleAddress(name string) sdk.AccAddress + AddressCodec() address.Codec } type StakingKeeper interface { - GetAllDelegatorDelegations(ctx sdk.Context, delegator sdk.AccAddress) []stakingtypes.Delegation - GetAllDelegations(ctx sdk.Context) []stakingtypes.Delegation + GetAllDelegatorDelegations(ctx context.Context, delegator sdk.AccAddress) ([]stakingtypes.Delegation, error) + GetAllDelegations(ctx context.Context) ([]stakingtypes.Delegation, error) } diff --git a/x/scorum/types/genesis_test.go b/x/scorum/types/genesis_test.go index 0b2d840..a77130f 100644 --- a/x/scorum/types/genesis_test.go +++ b/x/scorum/types/genesis_test.go @@ -3,7 +3,8 @@ package types_test import ( "testing" - sdk "github.com/cosmos/cosmos-sdk/types" + "cosmossdk.io/math" + "github.com/scorum/cosmos-network/testutil/sample" "github.com/scorum/cosmos-network/x/scorum/types" "github.com/stretchr/testify/require" @@ -25,9 +26,9 @@ func TestGenesisState_Validate(t *testing.T) { genState: &types.GenesisState{ Params: types.NewParams( []string{sample.AccAddress().String()}, - sdk.NewInt(1000), - sdk.NewInt(500), - sdk.NewDec(1), + math.NewInt(1000), + math.NewInt(500), + math.LegacyNewDec(1), ), }, valid: true, diff --git a/x/scorum/types/keys.go b/x/scorum/types/keys.go index 335e4a4..ffedddb 100644 --- a/x/scorum/types/keys.go +++ b/x/scorum/types/keys.go @@ -1,6 +1,7 @@ package types import ( + "cosmossdk.io/math" sdk "github.com/cosmos/cosmos-sdk/types" ) @@ -19,7 +20,7 @@ const ( RouterKey = ModuleName ) -var GasPrice = sdk.NewCoins(sdk.NewCoin(GasDenom, sdk.NewInt(1))) +var GasPrice = sdk.NewCoins(sdk.NewCoin(GasDenom, math.NewInt(1))) func KeyPrefix(p string) []byte { return []byte(p) diff --git a/x/scorum/types/msg_mint.go b/x/scorum/types/msg_mint.go new file mode 100644 index 0000000..1b44c88 --- /dev/null +++ b/x/scorum/types/msg_mint.go @@ -0,0 +1,56 @@ +package types + +import ( + errorsmod "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" + sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" +) + +const TypeMsgMint = "mint" + +var _ sdk.Msg = &MsgMint{} + +func NewMsgMint(authority string, recipient sdk.AccAddress, amount sdk.Coin) *MsgMint { + return &MsgMint{ + Authority: authority, + Recipient: recipient.String(), + Amount: amount, + } +} + +func (msg *MsgMint) Route() string { + return RouterKey +} + +func (msg *MsgMint) Type() string { + return TypeMsgMint +} + +func (msg *MsgMint) GetSigners() []sdk.AccAddress { + creator, err := sdk.AccAddressFromBech32(msg.Authority) + if err != nil { + panic(err) + } + return []sdk.AccAddress{creator} +} + +func (msg *MsgMint) GetSignBytes() []byte { + bz := ModuleCdc.MustMarshalJSON(msg) + return sdk.MustSortJSON(bz) +} + +func (msg *MsgMint) ValidateBasic() error { + if len(msg.Authority) == 0 { + return errorsmod.Wrapf(sdkerrors.ErrInvalidRequest, "empty authority") + } + + if !msg.Amount.IsPositive() { + return errorsmod.Wrapf(sdkerrors.ErrInvalidRequest, "invalid amount (must be positive)") + } + + if _, err := sdk.AccAddressFromBech32(msg.Recipient); err != nil { + return errorsmod.Wrapf(sdkerrors.ErrInvalidAddress, "invalid supervisor address (%s)", err) + } + + return nil +} diff --git a/x/scorum/types/msg_mint_gas.go b/x/scorum/types/msg_mint_gas.go index 2cd4eb8..3dc99e1 100644 --- a/x/scorum/types/msg_mint_gas.go +++ b/x/scorum/types/msg_mint_gas.go @@ -15,7 +15,7 @@ func NewMsgMintGas(supervisor string, address string, amount math.Int) *MsgMintG return &MsgMintGas{ Supervisor: supervisor, Address: address, - Amount: sdk.IntProto{Int: amount}, + Amount: amount, } } @@ -41,7 +41,7 @@ func (msg *MsgMintGas) GetSignBytes() []byte { } func (msg *MsgMintGas) ValidateBasic() error { - if !msg.Amount.Int.IsPositive() { + if !msg.Amount.IsPositive() { return errorsmod.Wrapf(sdkerrors.ErrInvalidRequest, "invalid amount (must be positive)") } diff --git a/x/scorum/types/params.go b/x/scorum/types/params.go index 7780077..4d36c83 100644 --- a/x/scorum/types/params.go +++ b/x/scorum/types/params.go @@ -3,7 +3,7 @@ package types import ( "fmt" - sdkmath "cosmossdk.io/math" + "cosmossdk.io/math" sdk "github.com/cosmos/cosmos-sdk/types" paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" "gopkg.in/yaml.v2" @@ -28,15 +28,15 @@ func ParamKeyTable() paramtypes.KeyTable { // NewParams creates a new Params instance func NewParams( supervisors []string, - gasLimit sdkmath.Int, - gasUnconditionedAmount sdkmath.Int, - gasAdjustCoefficient sdk.Dec, + gasLimit math.Int, + gasUnconditionedAmount math.Int, + gasAdjustCoefficient math.LegacyDec, ) Params { return Params{ Supervisors: supervisors, - GasLimit: sdk.IntProto{Int: gasLimit}, - GasUnconditionedAmount: sdk.IntProto{Int: gasUnconditionedAmount}, - GasAdjustCoefficient: sdk.DecProto{Dec: gasAdjustCoefficient}, + GasLimit: gasLimit, + GasUnconditionedAmount: gasUnconditionedAmount, + GasAdjustCoefficient: gasAdjustCoefficient, } } @@ -44,14 +44,14 @@ func NewParams( func DefaultParams() Params { return Params{ Supervisors: nil, - GasLimit: sdk.IntProto{Int: sdk.NewInt(1000000)}, - GasUnconditionedAmount: sdk.IntProto{Int: sdk.NewInt(15000)}, - GasAdjustCoefficient: sdk.DecProto{Dec: sdk.NewDec(1)}, + GasLimit: math.NewInt(1000000), + GasUnconditionedAmount: math.NewInt(15000), + GasAdjustCoefficient: math.LegacyNewDec(1), ValidatorsReward: ValidatorsRewardParams{ PoolAddress: "", BlockReward: sdk.Coin{ Denom: SCRDenom, - Amount: sdk.ZeroInt(), + Amount: math.ZeroInt(), }, }, } @@ -101,12 +101,12 @@ func (p Params) String() string { } func validateGasLimit(i interface{}) error { - s, ok := i.(sdk.IntProto) + s, ok := i.(math.Int) if !ok { return fmt.Errorf("invalid parameter type: %T", i) } - if s.Int.IsZero() || s.Int.IsNegative() { + if s.IsZero() || s.IsNegative() { return fmt.Errorf("must be positive") } @@ -114,12 +114,12 @@ func validateGasLimit(i interface{}) error { } func validateGasUnconditionedAmount(i interface{}) error { - s, ok := i.(sdk.IntProto) + s, ok := i.(math.Int) if !ok { return fmt.Errorf("invalid parameter type: %T", i) } - if s.Int.IsNegative() { + if s.IsNegative() { return fmt.Errorf("must not be negative") } @@ -127,12 +127,12 @@ func validateGasUnconditionedAmount(i interface{}) error { } func validateGasAdjustCoefficient(i interface{}) error { - s, ok := i.(sdk.DecProto) + s, ok := i.(math.LegacyDec) if !ok { return fmt.Errorf("invalid parameter type: %T", i) } - if s.Dec.IsZero() || s.Dec.IsNegative() { + if s.IsZero() || s.IsNegative() { return fmt.Errorf("must be positive") } diff --git a/x/scorum/types/params.pb.go b/x/scorum/types/params.pb.go index 4366f09..dd51057 100644 --- a/x/scorum/types/params.pb.go +++ b/x/scorum/types/params.pb.go @@ -4,8 +4,11 @@ package types import ( + cosmossdk_io_math "cosmossdk.io/math" fmt "fmt" + _ "github.com/cosmos/cosmos-proto" types "github.com/cosmos/cosmos-sdk/types" + _ "github.com/cosmos/cosmos-sdk/types/tx/amino" _ "github.com/cosmos/gogoproto/gogoproto" proto "github.com/cosmos/gogoproto/proto" io "io" @@ -26,11 +29,11 @@ const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package // Params defines the parameters for the module. type Params struct { - Supervisors []string `protobuf:"bytes,1,rep,name=supervisors,proto3" json:"supervisors,omitempty"` - GasLimit types.IntProto `protobuf:"bytes,2,opt,name=gas_limit,json=gasLimit,proto3" json:"gas_limit"` - GasUnconditionedAmount types.IntProto `protobuf:"bytes,3,opt,name=gas_unconditioned_amount,json=gasUnconditionedAmount,proto3" json:"gas_unconditioned_amount"` - GasAdjustCoefficient types.DecProto `protobuf:"bytes,4,opt,name=gas_adjust_coefficient,json=gasAdjustCoefficient,proto3" json:"gas_adjust_coefficient"` - ValidatorsReward ValidatorsRewardParams `protobuf:"bytes,5,opt,name=validators_reward,json=validatorsReward,proto3" json:"validators_reward"` + Supervisors []string `protobuf:"bytes,1,rep,name=supervisors,proto3" json:"supervisors,omitempty"` + GasLimit cosmossdk_io_math.Int `protobuf:"bytes,2,opt,name=gas_limit,json=gasLimit,proto3,customtype=cosmossdk.io/math.Int" json:"gas_limit"` + GasUnconditionedAmount cosmossdk_io_math.Int `protobuf:"bytes,3,opt,name=gas_unconditioned_amount,json=gasUnconditionedAmount,proto3,customtype=cosmossdk.io/math.Int" json:"gas_unconditioned_amount"` + GasAdjustCoefficient cosmossdk_io_math.LegacyDec `protobuf:"bytes,4,opt,name=gas_adjust_coefficient,json=gasAdjustCoefficient,proto3,customtype=cosmossdk.io/math.LegacyDec" json:"gas_adjust_coefficient"` + ValidatorsReward ValidatorsRewardParams `protobuf:"bytes,5,opt,name=validators_reward,json=validatorsReward,proto3" json:"validators_reward"` } func (m *Params) Reset() { *m = Params{} } @@ -72,27 +75,6 @@ func (m *Params) GetSupervisors() []string { return nil } -func (m *Params) GetGasLimit() types.IntProto { - if m != nil { - return m.GasLimit - } - return types.IntProto{} -} - -func (m *Params) GetGasUnconditionedAmount() types.IntProto { - if m != nil { - return m.GasUnconditionedAmount - } - return types.IntProto{} -} - -func (m *Params) GetGasAdjustCoefficient() types.DecProto { - if m != nil { - return m.GasAdjustCoefficient - } - return types.DecProto{} -} - func (m *Params) GetValidatorsReward() ValidatorsRewardParams { if m != nil { return m.ValidatorsReward @@ -160,34 +142,38 @@ func init() { func init() { proto.RegisterFile("network/scorum/v1/params.proto", fileDescriptor_bce858b8f0dc09a2) } var fileDescriptor_bce858b8f0dc09a2 = []byte{ - // 429 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x92, 0xb1, 0x6f, 0xd3, 0x40, - 0x14, 0xc6, 0x6d, 0x12, 0x2a, 0x7a, 0xe9, 0x40, 0xad, 0xaa, 0x32, 0x95, 0x70, 0x43, 0xa7, 0x32, - 0x70, 0xa7, 0xc0, 0xc6, 0x44, 0x52, 0x96, 0x4a, 0x0c, 0x55, 0x24, 0x90, 0x40, 0x20, 0xeb, 0x7c, - 0xbe, 0x9a, 0xa3, 0xf1, 0x3d, 0xeb, 0xde, 0xd9, 0x85, 0x89, 0x9d, 0x89, 0x91, 0x91, 0x3f, 0xa7, - 0x63, 0x47, 0x26, 0x84, 0x92, 0x7f, 0x04, 0xdd, 0x5d, 0x02, 0x11, 0x44, 0x88, 0xcd, 0x7a, 0xdf, - 0x7b, 0xbf, 0xef, 0xf9, 0xbe, 0x47, 0x32, 0x2d, 0xed, 0x25, 0x98, 0x0b, 0x86, 0x02, 0x4c, 0x5b, - 0xb3, 0x6e, 0xc4, 0x1a, 0x6e, 0x78, 0x8d, 0xb4, 0x31, 0x60, 0x21, 0xd9, 0x5d, 0xea, 0x34, 0xe8, - 0xb4, 0x1b, 0x1d, 0xec, 0x55, 0x50, 0x81, 0x57, 0x99, 0xfb, 0x0a, 0x8d, 0x07, 0x99, 0x00, 0xac, - 0x01, 0x59, 0xc1, 0x51, 0xb2, 0x6e, 0x54, 0x48, 0xcb, 0x47, 0x4c, 0x80, 0xd2, 0x41, 0x3f, 0xfa, - 0xd4, 0x23, 0x5b, 0x67, 0x9e, 0x9c, 0x0c, 0xc9, 0x00, 0xdb, 0x46, 0x9a, 0x4e, 0x21, 0x18, 0x4c, - 0xe3, 0x61, 0xef, 0x78, 0x7b, 0xba, 0x5e, 0x4a, 0x9e, 0x90, 0xed, 0x8a, 0x63, 0x3e, 0x53, 0xb5, - 0xb2, 0xe9, 0x8d, 0x61, 0x7c, 0x3c, 0x78, 0x78, 0x97, 0x06, 0x03, 0xea, 0x0c, 0xe8, 0xd2, 0x80, - 0x9e, 0x6a, 0x7b, 0xe6, 0xf0, 0x93, 0xfe, 0xd5, 0xf7, 0xc3, 0x68, 0x7a, 0xab, 0xe2, 0xf8, 0xcc, - 0x0d, 0x25, 0x6f, 0x48, 0xea, 0x08, 0xad, 0x16, 0xa0, 0x4b, 0x65, 0x15, 0x68, 0x59, 0xe6, 0xbc, - 0x86, 0x56, 0xdb, 0xb4, 0xf7, 0xff, 0xc0, 0xfd, 0x8a, 0xe3, 0xf3, 0x75, 0xc6, 0xd8, 0x23, 0x92, - 0x97, 0xc4, 0x29, 0x39, 0x2f, 0xdf, 0xb5, 0x68, 0x73, 0x01, 0xf2, 0xfc, 0x5c, 0x09, 0x25, 0xb5, - 0x4d, 0xfb, 0xff, 0x80, 0x3f, 0x95, 0x62, 0x1d, 0xbe, 0x57, 0x71, 0x1c, 0x7b, 0xc2, 0xc9, 0x6f, - 0x40, 0xf2, 0x9a, 0xec, 0x76, 0x7c, 0xa6, 0x4a, 0x6e, 0xc1, 0x60, 0x6e, 0xe4, 0x25, 0x37, 0x65, - 0x7a, 0xd3, 0x53, 0xef, 0xd3, 0xbf, 0xd2, 0xa0, 0x2f, 0x7e, 0xf5, 0x4e, 0x7d, 0x6b, 0x78, 0xe3, - 0xa5, 0xc3, 0xed, 0xee, 0x0f, 0xf5, 0x71, 0xff, 0xcb, 0xd7, 0xc3, 0xe8, 0xe8, 0x23, 0xd9, 0xdf, - 0x3c, 0x97, 0xdc, 0x23, 0x3b, 0x0d, 0xc0, 0x2c, 0xe7, 0x65, 0x69, 0x24, 0xba, 0x70, 0x62, 0x17, - 0x8e, 0xab, 0x8d, 0x43, 0x29, 0x99, 0x90, 0x9d, 0x62, 0x06, 0xe2, 0x62, 0xb5, 0x5b, 0xc8, 0xe7, - 0xce, 0xc6, 0x3f, 0x3e, 0x01, 0xa5, 0x97, 0xbb, 0x0c, 0xfc, 0x50, 0x30, 0x9b, 0x9c, 0x5e, 0xcd, - 0xb3, 0xf8, 0x7a, 0x9e, 0xc5, 0x3f, 0xe6, 0x59, 0xfc, 0x79, 0x91, 0x45, 0xd7, 0x8b, 0x2c, 0xfa, - 0xb6, 0xc8, 0xa2, 0x57, 0xac, 0x52, 0xf6, 0x6d, 0x5b, 0x50, 0x01, 0xf5, 0xea, 0x26, 0x03, 0xf8, - 0xc1, 0xea, 0x52, 0xdf, 0xaf, 0xea, 0xf6, 0x43, 0x23, 0xb1, 0xd8, 0xf2, 0xf7, 0xf5, 0xe8, 0x67, - 0x00, 0x00, 0x00, 0xff, 0xff, 0xb9, 0xbf, 0x06, 0x11, 0xca, 0x02, 0x00, 0x00, + // 496 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x53, 0x31, 0x6f, 0xd3, 0x4e, + 0x1c, 0x8d, 0x9b, 0xfc, 0xab, 0x7f, 0x2f, 0x19, 0x88, 0x55, 0x2a, 0xb7, 0x48, 0x4e, 0xe8, 0x14, + 0x90, 0x7a, 0x47, 0x40, 0x62, 0x60, 0x4b, 0xda, 0x25, 0x52, 0x91, 0x50, 0x24, 0x18, 0x10, 0x92, + 0x75, 0x39, 0x5f, 0xdd, 0x6b, 0xec, 0xfb, 0x59, 0x77, 0x67, 0x97, 0x4e, 0x7c, 0x05, 0x46, 0x46, + 0x46, 0x46, 0x06, 0x24, 0xbe, 0x42, 0xc7, 0x8a, 0x09, 0x31, 0x54, 0x28, 0x19, 0xf8, 0x1a, 0xc8, + 0x77, 0x0e, 0x44, 0x94, 0x89, 0xc5, 0xf2, 0xbd, 0xf7, 0xbb, 0xf7, 0x9e, 0xf5, 0x7b, 0x46, 0xa1, + 0xe4, 0xe6, 0x1c, 0xd4, 0x9c, 0x68, 0x06, 0xaa, 0xc8, 0x48, 0x39, 0x24, 0x39, 0x55, 0x34, 0xd3, + 0x38, 0x57, 0x60, 0xc0, 0xef, 0xd6, 0x3c, 0x76, 0x3c, 0x2e, 0x87, 0x7b, 0xdb, 0x09, 0x24, 0x60, + 0x59, 0x52, 0xbd, 0xb9, 0xc1, 0xbd, 0x2e, 0xcd, 0x84, 0x04, 0x62, 0x9f, 0x35, 0xb4, 0xcb, 0x40, + 0x67, 0xa0, 0x23, 0x37, 0xeb, 0x0e, 0x35, 0x15, 0xba, 0x13, 0x99, 0x51, 0xcd, 0x49, 0x39, 0x9c, + 0x71, 0x43, 0x87, 0x84, 0x81, 0x90, 0x8e, 0xdf, 0xff, 0xdc, 0x44, 0x9b, 0xcf, 0x6c, 0x0e, 0xbf, + 0x8f, 0xda, 0xba, 0xc8, 0xb9, 0x2a, 0x85, 0x06, 0xa5, 0x03, 0xaf, 0xdf, 0x1c, 0x6c, 0x4d, 0xd7, + 0x21, 0xff, 0x29, 0xda, 0x4a, 0xa8, 0x8e, 0x52, 0x91, 0x09, 0x13, 0x6c, 0xf4, 0xbd, 0x41, 0x67, + 0xfc, 0xe0, 0xf2, 0xba, 0xd7, 0xf8, 0x76, 0xdd, 0xbb, 0xed, 0x7c, 0x74, 0x3c, 0xc7, 0x02, 0x48, + 0x46, 0xcd, 0x29, 0x9e, 0x48, 0xf3, 0xe5, 0xd3, 0x01, 0xaa, 0xe3, 0x4c, 0xa4, 0xf9, 0xf0, 0xe3, + 0xe3, 0x7d, 0x6f, 0xfa, 0x7f, 0x42, 0xf5, 0x71, 0xa5, 0xe0, 0x9f, 0xa1, 0xa0, 0x92, 0x2b, 0x24, + 0x03, 0x19, 0x0b, 0x23, 0x40, 0xf2, 0x38, 0xa2, 0x19, 0x14, 0xd2, 0x04, 0xcd, 0x7f, 0x54, 0xdf, + 0x49, 0xa8, 0x7e, 0xbe, 0x2e, 0x38, 0xb2, 0x7a, 0x7e, 0x8a, 0x2a, 0x26, 0xa2, 0xf1, 0x59, 0xa1, + 0x4d, 0xc4, 0x80, 0x9f, 0x9c, 0x08, 0x26, 0xb8, 0x34, 0x41, 0xcb, 0x3a, 0x3d, 0xae, 0x9d, 0xee, + 0xdc, 0x74, 0x3a, 0xe6, 0x09, 0x65, 0x17, 0x47, 0x9c, 0xad, 0xf9, 0x1d, 0x71, 0xe6, 0xfc, 0xb6, + 0x13, 0xaa, 0x47, 0x56, 0xf4, 0xf0, 0xb7, 0xa6, 0xff, 0x0a, 0x75, 0x4b, 0x9a, 0x8a, 0x98, 0x1a, + 0x50, 0x3a, 0x52, 0xfc, 0x9c, 0xaa, 0x38, 0xf8, 0xaf, 0xef, 0x0d, 0xda, 0x0f, 0xef, 0xe1, 0x1b, + 0x8b, 0xc6, 0x2f, 0x7e, 0xcd, 0x4e, 0xed, 0xa8, 0x5b, 0xc8, 0xb8, 0x55, 0x65, 0x9a, 0xde, 0x2a, + 0xff, 0x60, 0x9f, 0xb4, 0xde, 0xbd, 0xef, 0x35, 0xf6, 0xdf, 0xa0, 0x9d, 0xbf, 0xdf, 0xf3, 0xef, + 0xa2, 0x4e, 0x0e, 0x90, 0x46, 0x34, 0x8e, 0x15, 0xd7, 0xd5, 0x26, 0xbd, 0x6a, 0x93, 0x15, 0x36, + 0x72, 0x90, 0x3f, 0x46, 0x9d, 0x59, 0x0a, 0x6c, 0xbe, 0xca, 0xb6, 0x61, 0xb3, 0xed, 0xe2, 0xfa, + 0xf3, 0xaa, 0xb6, 0xe0, 0xba, 0x2d, 0xf8, 0x10, 0x84, 0xac, 0xb3, 0xb4, 0xed, 0x25, 0x67, 0x36, + 0x9e, 0x5c, 0x2e, 0x42, 0xef, 0x6a, 0x11, 0x7a, 0xdf, 0x17, 0xa1, 0xf7, 0x76, 0x19, 0x36, 0xae, + 0x96, 0x61, 0xe3, 0xeb, 0x32, 0x6c, 0xbc, 0x24, 0x89, 0x30, 0xa7, 0xc5, 0x0c, 0x33, 0xc8, 0x56, + 0x75, 0x77, 0xc2, 0x07, 0xab, 0x9f, 0xe0, 0xf5, 0x0a, 0x37, 0x17, 0x39, 0xd7, 0xb3, 0x4d, 0x5b, + 0xc6, 0x47, 0x3f, 0x03, 0x00, 0x00, 0xff, 0xff, 0xb7, 0x34, 0xcd, 0x89, 0x25, 0x03, 0x00, 0x00, } func (m *Params) Marshal() (dAtA []byte, err error) { @@ -221,31 +207,31 @@ func (m *Params) MarshalToSizedBuffer(dAtA []byte) (int, error) { i-- dAtA[i] = 0x2a { - size, err := m.GasAdjustCoefficient.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { + size := m.GasAdjustCoefficient.Size() + i -= size + if _, err := m.GasAdjustCoefficient.MarshalTo(dAtA[i:]); err != nil { return 0, err } - i -= size i = encodeVarintParams(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x22 { - size, err := m.GasUnconditionedAmount.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { + size := m.GasUnconditionedAmount.Size() + i -= size + if _, err := m.GasUnconditionedAmount.MarshalTo(dAtA[i:]); err != nil { return 0, err } - i -= size i = encodeVarintParams(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x1a { - size, err := m.GasLimit.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { + size := m.GasLimit.Size() + i -= size + if _, err := m.GasLimit.MarshalTo(dAtA[i:]); err != nil { return 0, err } - i -= size i = encodeVarintParams(dAtA, i, uint64(size)) } i-- @@ -422,7 +408,7 @@ func (m *Params) Unmarshal(dAtA []byte) error { if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field GasLimit", wireType) } - var msglen int + var byteLen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowParams @@ -432,15 +418,15 @@ func (m *Params) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + byteLen |= int(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + if byteLen < 0 { return ErrInvalidLengthParams } - postIndex := iNdEx + msglen + postIndex := iNdEx + byteLen if postIndex < 0 { return ErrInvalidLengthParams } @@ -455,7 +441,7 @@ func (m *Params) Unmarshal(dAtA []byte) error { if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field GasUnconditionedAmount", wireType) } - var msglen int + var byteLen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowParams @@ -465,15 +451,15 @@ func (m *Params) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + byteLen |= int(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + if byteLen < 0 { return ErrInvalidLengthParams } - postIndex := iNdEx + msglen + postIndex := iNdEx + byteLen if postIndex < 0 { return ErrInvalidLengthParams } @@ -488,7 +474,7 @@ func (m *Params) Unmarshal(dAtA []byte) error { if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field GasAdjustCoefficient", wireType) } - var msglen int + var byteLen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowParams @@ -498,15 +484,15 @@ func (m *Params) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - msglen |= int(b&0x7F) << shift + byteLen |= int(b&0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + if byteLen < 0 { return ErrInvalidLengthParams } - postIndex := iNdEx + msglen + postIndex := iNdEx + byteLen if postIndex < 0 { return ErrInvalidLengthParams } diff --git a/x/scorum/types/proposal.go b/x/scorum/types/proposal.go deleted file mode 100644 index 17a4b76..0000000 --- a/x/scorum/types/proposal.go +++ /dev/null @@ -1,49 +0,0 @@ -package types - -import ( - errorsmod "cosmossdk.io/errors" - sdk "github.com/cosmos/cosmos-sdk/types" - sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" - govv1beta1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1" -) - -const ( - ProposalTypeMint = "Mint" -) - -var ( - _ govv1beta1.Content = &MintProposal{} -) - -func init() { - govv1beta1.RegisterProposalType(ProposalTypeMint) -} - -// NewMintProposal creates a new mint proposal. -func NewMintProposal(title, description string, recipient sdk.AccAddress, amount sdk.Coin) *MintProposal { - return &MintProposal{ - Title: title, - Description: description, - Recipient: recipient.String(), - Amount: amount, - } -} - -func (cdp *MintProposal) ProposalRoute() string { return RouterKey } - -func (cdp *MintProposal) ProposalType() string { - return ProposalTypeMint -} - -func (cdp *MintProposal) ValidateBasic() error { - err := govv1beta1.ValidateAbstract(cdp) - if err != nil { - return err - } - - if _, err := sdk.AccAddressFromBech32(cdp.Recipient); err != nil { - return errorsmod.Wrapf(sdkerrors.ErrInvalidAddress, "invalid receiver address (%s)", err) - } - - return cdp.Amount.Validate() -} diff --git a/x/scorum/types/proposal.pb.go b/x/scorum/types/proposal.pb.go deleted file mode 100644 index 03b7271..0000000 --- a/x/scorum/types/proposal.pb.go +++ /dev/null @@ -1,480 +0,0 @@ -// Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: network/scorum/v1/proposal.proto - -package types - -import ( - fmt "fmt" - types "github.com/cosmos/cosmos-sdk/types" - _ "github.com/cosmos/gogoproto/gogoproto" - proto "github.com/cosmos/gogoproto/proto" - io "io" - math "math" - math_bits "math/bits" -) - -// Reference imports to suppress errors if they are not otherwise used. -var _ = proto.Marshal -var _ = fmt.Errorf -var _ = math.Inf - -// This is a compile-time assertion to ensure that this generated file -// is compatible with the proto package it is being compiled against. -// A compilation error at this line likely means your copy of the -// proto package needs to be updated. -const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package - -// MintProposal is a gov proposal for minting assets. -type MintProposal struct { - Title string `protobuf:"bytes,1,opt,name=title,proto3" json:"title,omitempty"` - Description string `protobuf:"bytes,2,opt,name=description,proto3" json:"description,omitempty"` - Recipient string `protobuf:"bytes,3,opt,name=recipient,proto3" json:"recipient,omitempty"` - Amount types.Coin `protobuf:"bytes,4,opt,name=amount,proto3" json:"amount"` -} - -func (m *MintProposal) Reset() { *m = MintProposal{} } -func (m *MintProposal) String() string { return proto.CompactTextString(m) } -func (*MintProposal) ProtoMessage() {} -func (*MintProposal) Descriptor() ([]byte, []int) { - return fileDescriptor_44f7827f81ae208f, []int{0} -} -func (m *MintProposal) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *MintProposal) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - if deterministic { - return xxx_messageInfo_MintProposal.Marshal(b, m, deterministic) - } else { - b = b[:cap(b)] - n, err := m.MarshalToSizedBuffer(b) - if err != nil { - return nil, err - } - return b[:n], nil - } -} -func (m *MintProposal) XXX_Merge(src proto.Message) { - xxx_messageInfo_MintProposal.Merge(m, src) -} -func (m *MintProposal) XXX_Size() int { - return m.Size() -} -func (m *MintProposal) XXX_DiscardUnknown() { - xxx_messageInfo_MintProposal.DiscardUnknown(m) -} - -var xxx_messageInfo_MintProposal proto.InternalMessageInfo - -func (m *MintProposal) GetTitle() string { - if m != nil { - return m.Title - } - return "" -} - -func (m *MintProposal) GetDescription() string { - if m != nil { - return m.Description - } - return "" -} - -func (m *MintProposal) GetRecipient() string { - if m != nil { - return m.Recipient - } - return "" -} - -func (m *MintProposal) GetAmount() types.Coin { - if m != nil { - return m.Amount - } - return types.Coin{} -} - -func init() { - proto.RegisterType((*MintProposal)(nil), "network.scorum.v1.MintProposal") -} - -func init() { proto.RegisterFile("network/scorum/v1/proposal.proto", fileDescriptor_44f7827f81ae208f) } - -var fileDescriptor_44f7827f81ae208f = []byte{ - // 273 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x4c, 0x90, 0xb1, 0x4e, 0xc3, 0x30, - 0x10, 0x86, 0x63, 0x28, 0x95, 0xea, 0xb2, 0x10, 0x75, 0x08, 0x15, 0x32, 0x11, 0x53, 0x17, 0x6c, - 0x05, 0x06, 0xf6, 0x32, 0x31, 0x20, 0xa1, 0x8e, 0x6c, 0x89, 0xb1, 0x8a, 0x45, 0xe3, 0xb3, 0xec, - 0x4b, 0x80, 0xb7, 0xe0, 0x05, 0x78, 0x9f, 0x8e, 0x1d, 0x99, 0x10, 0x4a, 0x5e, 0x04, 0x35, 0x4e, - 0x04, 0x9b, 0xfd, 0x7f, 0x9f, 0x4e, 0xff, 0x1d, 0x4d, 0x8d, 0xc2, 0x57, 0x70, 0x2f, 0xc2, 0x4b, - 0x70, 0x55, 0x29, 0xea, 0x4c, 0x58, 0x07, 0x16, 0x7c, 0xbe, 0xe1, 0xd6, 0x01, 0x42, 0x7c, 0xd2, - 0x1b, 0x3c, 0x18, 0xbc, 0xce, 0xe6, 0xb3, 0x35, 0xac, 0xa1, 0xa3, 0x62, 0xff, 0x0a, 0xe2, 0x9c, - 0x49, 0xf0, 0x25, 0x78, 0x51, 0xe4, 0x5e, 0x89, 0x3a, 0x2b, 0x14, 0xe6, 0x99, 0x90, 0xa0, 0x4d, - 0xe0, 0x17, 0x9f, 0x84, 0x1e, 0xdf, 0x6b, 0x83, 0x0f, 0xfd, 0xfc, 0x78, 0x46, 0x8f, 0x50, 0xe3, - 0x46, 0x25, 0x24, 0x25, 0x8b, 0xc9, 0x2a, 0x7c, 0xe2, 0x94, 0x4e, 0x9f, 0x94, 0x97, 0x4e, 0x5b, - 0xd4, 0x60, 0x92, 0x83, 0x8e, 0xfd, 0x8f, 0xe2, 0x33, 0x3a, 0x71, 0x4a, 0x6a, 0xab, 0x95, 0xc1, - 0xe4, 0xb0, 0xe3, 0x7f, 0x41, 0x7c, 0x43, 0xc7, 0x79, 0x09, 0x95, 0xc1, 0x64, 0x94, 0x92, 0xc5, - 0xf4, 0xea, 0x94, 0x87, 0x5e, 0x7c, 0xdf, 0x8b, 0xf7, 0xbd, 0xf8, 0x2d, 0x68, 0xb3, 0x1c, 0x6d, - 0xbf, 0xcf, 0xa3, 0x55, 0xaf, 0x2f, 0xef, 0xb6, 0x0d, 0x23, 0xbb, 0x86, 0x91, 0x9f, 0x86, 0x91, - 0x8f, 0x96, 0x45, 0xbb, 0x96, 0x45, 0x5f, 0x2d, 0x8b, 0x1e, 0xc5, 0x5a, 0xe3, 0x73, 0x55, 0x70, - 0x09, 0xe5, 0x70, 0xa7, 0x30, 0xf3, 0x72, 0xb8, 0xde, 0xdb, 0x90, 0xe3, 0xbb, 0x55, 0xbe, 0x18, - 0x77, 0x1b, 0x5f, 0xff, 0x06, 0x00, 0x00, 0xff, 0xff, 0x4c, 0x60, 0x83, 0x43, 0x5e, 0x01, 0x00, - 0x00, -} - -func (m *MintProposal) Marshal() (dAtA []byte, err error) { - size := m.Size() - dAtA = make([]byte, size) - n, err := m.MarshalToSizedBuffer(dAtA[:size]) - if err != nil { - return nil, err - } - return dAtA[:n], nil -} - -func (m *MintProposal) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *MintProposal) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i - var l int - _ = l - { - size, err := m.Amount.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintProposal(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x22 - if len(m.Recipient) > 0 { - i -= len(m.Recipient) - copy(dAtA[i:], m.Recipient) - i = encodeVarintProposal(dAtA, i, uint64(len(m.Recipient))) - i-- - dAtA[i] = 0x1a - } - if len(m.Description) > 0 { - i -= len(m.Description) - copy(dAtA[i:], m.Description) - i = encodeVarintProposal(dAtA, i, uint64(len(m.Description))) - i-- - dAtA[i] = 0x12 - } - if len(m.Title) > 0 { - i -= len(m.Title) - copy(dAtA[i:], m.Title) - i = encodeVarintProposal(dAtA, i, uint64(len(m.Title))) - i-- - dAtA[i] = 0xa - } - return len(dAtA) - i, nil -} - -func encodeVarintProposal(dAtA []byte, offset int, v uint64) int { - offset -= sovProposal(v) - base := offset - for v >= 1<<7 { - dAtA[offset] = uint8(v&0x7f | 0x80) - v >>= 7 - offset++ - } - dAtA[offset] = uint8(v) - return base -} -func (m *MintProposal) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - l = len(m.Title) - if l > 0 { - n += 1 + l + sovProposal(uint64(l)) - } - l = len(m.Description) - if l > 0 { - n += 1 + l + sovProposal(uint64(l)) - } - l = len(m.Recipient) - if l > 0 { - n += 1 + l + sovProposal(uint64(l)) - } - l = m.Amount.Size() - n += 1 + l + sovProposal(uint64(l)) - return n -} - -func sovProposal(x uint64) (n int) { - return (math_bits.Len64(x|1) + 6) / 7 -} -func sozProposal(x uint64) (n int) { - return sovProposal(uint64((x << 1) ^ uint64((int64(x) >> 63)))) -} -func (m *MintProposal) Unmarshal(dAtA []byte) error { - l := len(dAtA) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowProposal - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: MintProposal: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: MintProposal: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Title", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowProposal - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthProposal - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthProposal - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Title = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Description", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowProposal - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthProposal - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthProposal - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Description = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Recipient", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowProposal - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - stringLen |= uint64(b&0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthProposal - } - postIndex := iNdEx + intStringLen - if postIndex < 0 { - return ErrInvalidLengthProposal - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Recipient = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 4: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Amount", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowProposal - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - msglen |= int(b&0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthProposal - } - postIndex := iNdEx + msglen - if postIndex < 0 { - return ErrInvalidLengthProposal - } - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.Amount.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipProposal(dAtA[iNdEx:]) - if err != nil { - return err - } - if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthProposal - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func skipProposal(dAtA []byte) (n int, err error) { - l := len(dAtA) - iNdEx := 0 - depth := 0 - for iNdEx < l { - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return 0, ErrIntOverflowProposal - } - if iNdEx >= l { - return 0, io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - wireType := int(wire & 0x7) - switch wireType { - case 0: - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return 0, ErrIntOverflowProposal - } - if iNdEx >= l { - return 0, io.ErrUnexpectedEOF - } - iNdEx++ - if dAtA[iNdEx-1] < 0x80 { - break - } - } - case 1: - iNdEx += 8 - case 2: - var length int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return 0, ErrIntOverflowProposal - } - if iNdEx >= l { - return 0, io.ErrUnexpectedEOF - } - b := dAtA[iNdEx] - iNdEx++ - length |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if length < 0 { - return 0, ErrInvalidLengthProposal - } - iNdEx += length - case 3: - depth++ - case 4: - if depth == 0 { - return 0, ErrUnexpectedEndOfGroupProposal - } - depth-- - case 5: - iNdEx += 4 - default: - return 0, fmt.Errorf("proto: illegal wireType %d", wireType) - } - if iNdEx < 0 { - return 0, ErrInvalidLengthProposal - } - if depth == 0 { - return iNdEx, nil - } - } - return 0, io.ErrUnexpectedEOF -} - -var ( - ErrInvalidLengthProposal = fmt.Errorf("proto: negative length found during unmarshaling") - ErrIntOverflowProposal = fmt.Errorf("proto: integer overflow") - ErrUnexpectedEndOfGroupProposal = fmt.Errorf("proto: unexpected end of group") -) diff --git a/x/scorum/types/tx.pb.go b/x/scorum/types/tx.pb.go index 26b6d9a..36a3d20 100644 --- a/x/scorum/types/tx.pb.go +++ b/x/scorum/types/tx.pb.go @@ -5,9 +5,12 @@ package types import ( context "context" + cosmossdk_io_math "cosmossdk.io/math" fmt "fmt" + _ "github.com/cosmos/cosmos-proto" types "github.com/cosmos/cosmos-sdk/types" _ "github.com/cosmos/cosmos-sdk/types/msgservice" + _ "github.com/cosmos/cosmos-sdk/types/tx/amino" _ "github.com/cosmos/gogoproto/gogoproto" grpc1 "github.com/cosmos/gogoproto/grpc" proto "github.com/cosmos/gogoproto/proto" @@ -119,9 +122,9 @@ func (m *MsgBurnResponse) XXX_DiscardUnknown() { var xxx_messageInfo_MsgBurnResponse proto.InternalMessageInfo type MsgMintGas struct { - Supervisor string `protobuf:"bytes,1,opt,name=supervisor,proto3" json:"supervisor,omitempty"` - Address string `protobuf:"bytes,2,opt,name=address,proto3" json:"address,omitempty"` - Amount types.IntProto `protobuf:"bytes,3,opt,name=amount,proto3" json:"amount"` + Supervisor string `protobuf:"bytes,1,opt,name=supervisor,proto3" json:"supervisor,omitempty"` + Address string `protobuf:"bytes,2,opt,name=address,proto3" json:"address,omitempty"` + Amount cosmossdk_io_math.Int `protobuf:"bytes,3,opt,name=amount,proto3,customtype=cosmossdk.io/math.Int" json:"amount"` } func (m *MsgMintGas) Reset() { *m = MsgMintGas{} } @@ -171,13 +174,6 @@ func (m *MsgMintGas) GetAddress() string { return "" } -func (m *MsgMintGas) GetAmount() types.IntProto { - if m != nil { - return m.Amount - } - return types.IntProto{} -} - type MsgMintGasResponse struct { } @@ -214,41 +210,150 @@ func (m *MsgMintGasResponse) XXX_DiscardUnknown() { var xxx_messageInfo_MsgMintGasResponse proto.InternalMessageInfo +// MsgMint is a gov proposal for minting assets. +type MsgMint struct { + Authority string `protobuf:"bytes,1,opt,name=authority,proto3" json:"authority,omitempty"` + Recipient string `protobuf:"bytes,2,opt,name=recipient,proto3" json:"recipient,omitempty"` + Amount types.Coin `protobuf:"bytes,3,opt,name=amount,proto3" json:"amount"` +} + +func (m *MsgMint) Reset() { *m = MsgMint{} } +func (m *MsgMint) String() string { return proto.CompactTextString(m) } +func (*MsgMint) ProtoMessage() {} +func (*MsgMint) Descriptor() ([]byte, []int) { + return fileDescriptor_ed31ca265053ca84, []int{4} +} +func (m *MsgMint) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *MsgMint) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_MsgMint.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *MsgMint) XXX_Merge(src proto.Message) { + xxx_messageInfo_MsgMint.Merge(m, src) +} +func (m *MsgMint) XXX_Size() int { + return m.Size() +} +func (m *MsgMint) XXX_DiscardUnknown() { + xxx_messageInfo_MsgMint.DiscardUnknown(m) +} + +var xxx_messageInfo_MsgMint proto.InternalMessageInfo + +func (m *MsgMint) GetAuthority() string { + if m != nil { + return m.Authority + } + return "" +} + +func (m *MsgMint) GetRecipient() string { + if m != nil { + return m.Recipient + } + return "" +} + +func (m *MsgMint) GetAmount() types.Coin { + if m != nil { + return m.Amount + } + return types.Coin{} +} + +type MsgMintResponse struct { +} + +func (m *MsgMintResponse) Reset() { *m = MsgMintResponse{} } +func (m *MsgMintResponse) String() string { return proto.CompactTextString(m) } +func (*MsgMintResponse) ProtoMessage() {} +func (*MsgMintResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_ed31ca265053ca84, []int{5} +} +func (m *MsgMintResponse) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *MsgMintResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_MsgMintResponse.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *MsgMintResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_MsgMintResponse.Merge(m, src) +} +func (m *MsgMintResponse) XXX_Size() int { + return m.Size() +} +func (m *MsgMintResponse) XXX_DiscardUnknown() { + xxx_messageInfo_MsgMintResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_MsgMintResponse proto.InternalMessageInfo + func init() { proto.RegisterType((*MsgBurn)(nil), "network.scorum.v1.MsgBurn") proto.RegisterType((*MsgBurnResponse)(nil), "network.scorum.v1.MsgBurnResponse") proto.RegisterType((*MsgMintGas)(nil), "network.scorum.v1.MsgMintGas") proto.RegisterType((*MsgMintGasResponse)(nil), "network.scorum.v1.MsgMintGasResponse") + proto.RegisterType((*MsgMint)(nil), "network.scorum.v1.MsgMint") + proto.RegisterType((*MsgMintResponse)(nil), "network.scorum.v1.MsgMintResponse") } func init() { proto.RegisterFile("network/scorum/v1/tx.proto", fileDescriptor_ed31ca265053ca84) } var fileDescriptor_ed31ca265053ca84 = []byte{ - // 375 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x84, 0x92, 0xc1, 0xca, 0xd3, 0x40, - 0x10, 0xc7, 0xb3, 0xb6, 0xb4, 0x74, 0x3d, 0x94, 0x86, 0x82, 0x35, 0xd0, 0xb5, 0x04, 0x84, 0x22, - 0xb8, 0x4b, 0xea, 0x41, 0xd0, 0x5b, 0x05, 0xa5, 0x87, 0xa0, 0xe4, 0xe8, 0x2d, 0x49, 0x97, 0x35, - 0x48, 0x76, 0x43, 0x66, 0x13, 0xeb, 0xd5, 0x27, 0xf0, 0xe0, 0xd9, 0x67, 0xf0, 0x31, 0x7a, 0xec, - 0xd1, 0x93, 0x48, 0x7b, 0xf0, 0x35, 0x24, 0xc9, 0xae, 0x16, 0xbe, 0x7e, 0x5f, 0x6f, 0xc9, 0xfc, - 0x86, 0x7f, 0x7e, 0x33, 0x19, 0xec, 0x49, 0xae, 0x3f, 0xa9, 0xf2, 0x23, 0x83, 0x54, 0x95, 0x55, - 0xce, 0xea, 0x80, 0xe9, 0x1d, 0x2d, 0x4a, 0xa5, 0x95, 0x3b, 0x31, 0x8c, 0x76, 0x8c, 0xd6, 0x81, - 0x37, 0x15, 0x4a, 0xa8, 0x96, 0xb2, 0xe6, 0xa9, 0x6b, 0xf4, 0x1e, 0xa4, 0x0a, 0x72, 0x05, 0x2c, - 0x07, 0xd1, 0x04, 0xe4, 0x20, 0x0c, 0x20, 0x06, 0x24, 0x31, 0x70, 0x56, 0x07, 0x09, 0xd7, 0x71, - 0xc0, 0x52, 0x95, 0xc9, 0x8e, 0xfb, 0x80, 0x87, 0x21, 0x88, 0x75, 0x55, 0x4a, 0x97, 0x60, 0x0c, - 0x55, 0xc1, 0xcb, 0x3a, 0x03, 0x55, 0xce, 0xd0, 0x02, 0x2d, 0x47, 0xd1, 0x59, 0xc5, 0x7d, 0x8e, - 0x07, 0x71, 0xae, 0x2a, 0xa9, 0x67, 0xf7, 0x16, 0x68, 0x79, 0x7f, 0xf5, 0x90, 0x76, 0xd9, 0xb4, - 0xc9, 0xa6, 0x26, 0x9b, 0xbe, 0x52, 0x99, 0x5c, 0xf7, 0xf7, 0xbf, 0x1e, 0x39, 0x91, 0x69, 0x7f, - 0x31, 0xfe, 0xf2, 0xe7, 0xc7, 0x93, 0xb3, 0x24, 0x7f, 0x82, 0xc7, 0xe6, 0xa3, 0x11, 0x87, 0x42, - 0x49, 0xe0, 0xfe, 0x37, 0x84, 0x71, 0x08, 0x22, 0xcc, 0xa4, 0x7e, 0x13, 0xc3, 0x55, 0x97, 0x19, - 0x1e, 0xc6, 0xdb, 0x6d, 0xc9, 0x01, 0x5a, 0x99, 0x51, 0x64, 0x5f, 0xdd, 0x97, 0xff, 0x2c, 0x7b, - 0xad, 0xe5, 0xfc, 0xa2, 0xe5, 0x46, 0xea, 0x77, 0xcd, 0xfc, 0xd7, 0x4c, 0xa7, 0xd8, 0xfd, 0x6f, - 0x65, 0x65, 0x57, 0xdf, 0x11, 0xee, 0x85, 0x20, 0xdc, 0xd7, 0xb8, 0xdf, 0x6e, 0xce, 0xa3, 0x37, - 0xfe, 0x13, 0x35, 0x03, 0x7a, 0xfe, 0xed, 0xcc, 0xe6, 0xb9, 0x6f, 0xf1, 0xd0, 0x0e, 0x3e, 0xbf, - 0xdc, 0x6e, 0xb0, 0xf7, 0xf8, 0x4e, 0x6c, 0x03, 0xd7, 0x9b, 0xfd, 0x91, 0xa0, 0xc3, 0x91, 0xa0, - 0xdf, 0x47, 0x82, 0xbe, 0x9e, 0x88, 0x73, 0x38, 0x11, 0xe7, 0xe7, 0x89, 0x38, 0xef, 0x99, 0xc8, - 0xf4, 0x87, 0x2a, 0xa1, 0xa9, 0xca, 0xed, 0xc1, 0x75, 0xfb, 0x79, 0x6a, 0xcf, 0x70, 0x67, 0xeb, - 0xfa, 0x73, 0xc1, 0x21, 0x19, 0xb4, 0x77, 0xf2, 0xec, 0x6f, 0x00, 0x00, 0x00, 0xff, 0xff, 0xcf, - 0x72, 0x80, 0x6f, 0xa7, 0x02, 0x00, 0x00, + // 538 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x54, 0x41, 0x8b, 0x13, 0x31, + 0x14, 0x6e, 0xdc, 0x75, 0xcb, 0x46, 0x51, 0x3a, 0x54, 0xec, 0x0e, 0x38, 0x5b, 0x07, 0x16, 0x4a, + 0xa1, 0x89, 0xad, 0xa0, 0xe2, 0xcd, 0x11, 0x5c, 0x7b, 0x28, 0x42, 0xbd, 0x79, 0x91, 0xe9, 0x34, + 0x4c, 0xc3, 0x32, 0xc9, 0x90, 0x64, 0xea, 0xee, 0x4d, 0x3c, 0x7a, 0xf2, 0x27, 0x78, 0xf4, 0xd8, + 0xc3, 0xfe, 0x88, 0x3d, 0x2e, 0x0b, 0x82, 0x78, 0x58, 0xa4, 0x3d, 0xf4, 0x20, 0xfe, 0x07, 0xc9, + 0x24, 0xd3, 0x16, 0xb5, 0x15, 0xf1, 0x32, 0x24, 0xf9, 0xbe, 0xf7, 0xe5, 0x7d, 0xef, 0xbd, 0x09, + 0x74, 0x19, 0x51, 0x6f, 0xb8, 0x38, 0xc2, 0x32, 0xe2, 0x22, 0x4b, 0xf0, 0xb8, 0x8d, 0xd5, 0x31, + 0x4a, 0x05, 0x57, 0xdc, 0xa9, 0x58, 0x0c, 0x19, 0x0c, 0x8d, 0xdb, 0x6e, 0x35, 0xe6, 0x31, 0xcf, + 0x51, 0xac, 0x57, 0x86, 0xe8, 0x56, 0xc2, 0x84, 0x32, 0x8e, 0xf3, 0xaf, 0x3d, 0xda, 0x8b, 0xb8, + 0x4c, 0xb8, 0x7c, 0x6d, 0xb8, 0x66, 0x63, 0xa1, 0xdb, 0x66, 0x87, 0x13, 0x19, 0xeb, 0xeb, 0x12, + 0x19, 0x5b, 0xc0, 0xb3, 0xc0, 0x20, 0x94, 0x04, 0x8f, 0xdb, 0x03, 0xa2, 0xc2, 0x36, 0x8e, 0x38, + 0x65, 0x06, 0xf7, 0x3f, 0x02, 0x58, 0xee, 0xc9, 0x38, 0xc8, 0x04, 0x73, 0x1e, 0x41, 0x28, 0xb3, + 0x94, 0x88, 0x31, 0x95, 0x5c, 0xd4, 0x40, 0x1d, 0x34, 0x76, 0x83, 0xda, 0xc5, 0x69, 0xab, 0x6a, + 0xaf, 0x7a, 0x32, 0x1c, 0x0a, 0x22, 0xe5, 0x4b, 0x25, 0x28, 0x8b, 0xfb, 0x2b, 0x5c, 0xe7, 0x21, + 0xdc, 0x09, 0x13, 0x9e, 0x31, 0x55, 0xbb, 0x52, 0x07, 0x8d, 0x6b, 0x9d, 0x3d, 0x64, 0x43, 0xf4, + 0xb5, 0xc8, 0x5e, 0x8b, 0x9e, 0x72, 0xca, 0x82, 0xed, 0xb3, 0xcb, 0xfd, 0x52, 0xdf, 0xd2, 0x1f, + 0xfb, 0xef, 0xe6, 0x93, 0xe6, 0x8a, 0xd2, 0xfb, 0xf9, 0xa4, 0x79, 0xc3, 0x96, 0xcd, 0xa6, 0xe5, + 0x57, 0xe0, 0x4d, 0xbb, 0xec, 0x13, 0x99, 0x72, 0x26, 0x89, 0xff, 0x1d, 0x40, 0xd8, 0x93, 0x71, + 0x8f, 0x32, 0x75, 0x18, 0xca, 0xff, 0x48, 0xbc, 0x03, 0xcb, 0xa1, 0x01, 0xf3, 0xcc, 0x37, 0x85, + 0x15, 0x44, 0xe7, 0xf9, 0xc2, 0xec, 0x56, 0x1d, 0x34, 0xae, 0x07, 0xf7, 0xb4, 0xa3, 0xaf, 0x97, + 0xfb, 0xb7, 0x4c, 0x98, 0x1c, 0x1e, 0x21, 0xca, 0x71, 0x12, 0xaa, 0x11, 0xea, 0x32, 0x75, 0x71, + 0xda, 0x82, 0x56, 0xaf, 0xcb, 0xd4, 0xa7, 0xf9, 0xa4, 0x09, 0x16, 0xee, 0x0f, 0xfe, 0xe0, 0xbe, + 0xb2, 0x74, 0x6f, 0xed, 0xf9, 0x55, 0xe8, 0x2c, 0x77, 0x8b, 0x1a, 0x7c, 0x36, 0x9d, 0xd3, 0xc7, + 0xce, 0x03, 0xb8, 0x1b, 0x66, 0x6a, 0xc4, 0x05, 0x55, 0x27, 0x7f, 0xf5, 0xbf, 0xa4, 0xea, 0x38, + 0x41, 0x22, 0x9a, 0x52, 0x62, 0x5b, 0xb7, 0x31, 0x6e, 0x41, 0x5d, 0xe9, 0xf7, 0xd6, 0xbf, 0xf5, + 0xfb, 0xae, 0x76, 0xbc, 0x4c, 0xe0, 0x97, 0x76, 0x6b, 0x2f, 0xb6, 0xdd, 0x7a, 0x59, 0x58, 0xed, + 0xfc, 0x00, 0x70, 0xab, 0x27, 0x63, 0xe7, 0x19, 0xdc, 0xce, 0x07, 0xd5, 0x45, 0xbf, 0xfd, 0x45, + 0xc8, 0x8e, 0x88, 0xeb, 0xaf, 0xc7, 0x0a, 0x3d, 0xad, 0x93, 0x97, 0x6d, 0x8d, 0x8e, 0xc6, 0xd6, + 0xe9, 0xac, 0xe6, 0xe5, 0xbc, 0x80, 0xe5, 0x62, 0x04, 0xef, 0xac, 0xa7, 0x1f, 0x86, 0xd2, 0x3d, + 0xd8, 0x08, 0x17, 0x82, 0xee, 0xd5, 0xb7, 0x7a, 0x3e, 0x82, 0xee, 0xd9, 0xd4, 0x03, 0xe7, 0x53, + 0x0f, 0x7c, 0x9b, 0x7a, 0xe0, 0xc3, 0xcc, 0x2b, 0x9d, 0xcf, 0xbc, 0xd2, 0x97, 0x99, 0x57, 0x7a, + 0x85, 0x63, 0xaa, 0x46, 0xd9, 0x00, 0x45, 0x3c, 0x29, 0x5e, 0x17, 0x53, 0xf9, 0x56, 0xf1, 0xe6, + 0x1c, 0x17, 0xe7, 0xea, 0x24, 0x25, 0x72, 0xb0, 0x93, 0xff, 0xe6, 0xf7, 0x7f, 0x06, 0x00, 0x00, + 0xff, 0xff, 0xe2, 0x2c, 0x36, 0xb1, 0x94, 0x04, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -264,6 +369,7 @@ const _ = grpc.SupportPackageIsVersion4 // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. type MsgClient interface { Burn(ctx context.Context, in *MsgBurn, opts ...grpc.CallOption) (*MsgBurnResponse, error) + Mint(ctx context.Context, in *MsgMint, opts ...grpc.CallOption) (*MsgMintResponse, error) MintGas(ctx context.Context, in *MsgMintGas, opts ...grpc.CallOption) (*MsgMintGasResponse, error) } @@ -284,6 +390,15 @@ func (c *msgClient) Burn(ctx context.Context, in *MsgBurn, opts ...grpc.CallOpti return out, nil } +func (c *msgClient) Mint(ctx context.Context, in *MsgMint, opts ...grpc.CallOption) (*MsgMintResponse, error) { + out := new(MsgMintResponse) + err := c.cc.Invoke(ctx, "/network.scorum.v1.Msg/Mint", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + func (c *msgClient) MintGas(ctx context.Context, in *MsgMintGas, opts ...grpc.CallOption) (*MsgMintGasResponse, error) { out := new(MsgMintGasResponse) err := c.cc.Invoke(ctx, "/network.scorum.v1.Msg/MintGas", in, out, opts...) @@ -296,6 +411,7 @@ func (c *msgClient) MintGas(ctx context.Context, in *MsgMintGas, opts ...grpc.Ca // MsgServer is the server API for Msg service. type MsgServer interface { Burn(context.Context, *MsgBurn) (*MsgBurnResponse, error) + Mint(context.Context, *MsgMint) (*MsgMintResponse, error) MintGas(context.Context, *MsgMintGas) (*MsgMintGasResponse, error) } @@ -306,6 +422,9 @@ type UnimplementedMsgServer struct { func (*UnimplementedMsgServer) Burn(ctx context.Context, req *MsgBurn) (*MsgBurnResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method Burn not implemented") } +func (*UnimplementedMsgServer) Mint(ctx context.Context, req *MsgMint) (*MsgMintResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method Mint not implemented") +} func (*UnimplementedMsgServer) MintGas(ctx context.Context, req *MsgMintGas) (*MsgMintGasResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method MintGas not implemented") } @@ -332,6 +451,24 @@ func _Msg_Burn_Handler(srv interface{}, ctx context.Context, dec func(interface{ return interceptor(ctx, in, info, handler) } +func _Msg_Mint_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgMint) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).Mint(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/network.scorum.v1.Msg/Mint", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).Mint(ctx, req.(*MsgMint)) + } + return interceptor(ctx, in, info, handler) +} + func _Msg_MintGas_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgMintGas) if err := dec(in); err != nil { @@ -358,6 +495,10 @@ var _Msg_serviceDesc = grpc.ServiceDesc{ MethodName: "Burn", Handler: _Msg_Burn_Handler, }, + { + MethodName: "Mint", + Handler: _Msg_Mint_Handler, + }, { MethodName: "MintGas", Handler: _Msg_MintGas_Handler, @@ -451,11 +592,11 @@ func (m *MsgMintGas) MarshalToSizedBuffer(dAtA []byte) (int, error) { var l int _ = l { - size, err := m.Amount.MarshalToSizedBuffer(dAtA[:i]) - if err != nil { + size := m.Amount.Size() + i -= size + if _, err := m.Amount.MarshalTo(dAtA[i:]); err != nil { return 0, err } - i -= size i = encodeVarintTx(dAtA, i, uint64(size)) } i-- @@ -500,6 +641,76 @@ func (m *MsgMintGasResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { return len(dAtA) - i, nil } +func (m *MsgMint) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *MsgMint) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *MsgMint) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + { + size, err := m.Amount.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintTx(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x1a + if len(m.Recipient) > 0 { + i -= len(m.Recipient) + copy(dAtA[i:], m.Recipient) + i = encodeVarintTx(dAtA, i, uint64(len(m.Recipient))) + i-- + dAtA[i] = 0x12 + } + if len(m.Authority) > 0 { + i -= len(m.Authority) + copy(dAtA[i:], m.Authority) + i = encodeVarintTx(dAtA, i, uint64(len(m.Authority))) + i-- + dAtA[i] = 0xa + } + return len(dAtA) - i, nil +} + +func (m *MsgMintResponse) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *MsgMintResponse) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *MsgMintResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + return len(dAtA) - i, nil +} + func encodeVarintTx(dAtA []byte, offset int, v uint64) int { offset -= sovTx(v) base := offset @@ -563,6 +774,34 @@ func (m *MsgMintGasResponse) Size() (n int) { return n } +func (m *MsgMint) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = len(m.Authority) + if l > 0 { + n += 1 + l + sovTx(uint64(l)) + } + l = len(m.Recipient) + if l > 0 { + n += 1 + l + sovTx(uint64(l)) + } + l = m.Amount.Size() + n += 1 + l + sovTx(uint64(l)) + return n +} + +func (m *MsgMintResponse) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + return n +} + func sovTx(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } @@ -827,6 +1066,203 @@ func (m *MsgMintGas) Unmarshal(dAtA []byte) error { } m.Address = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Amount", wireType) + } + var byteLen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + byteLen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if byteLen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + byteLen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Amount.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipTx(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthTx + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *MsgMintGasResponse) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: MsgMintGasResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: MsgMintGasResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := skipTx(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthTx + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *MsgMint) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: MsgMint: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: MsgMint: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Authority", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Authority = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Recipient", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Recipient = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex case 3: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Amount", wireType) @@ -881,7 +1317,7 @@ func (m *MsgMintGas) Unmarshal(dAtA []byte) error { } return nil } -func (m *MsgMintGasResponse) Unmarshal(dAtA []byte) error { +func (m *MsgMintResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { @@ -904,10 +1340,10 @@ func (m *MsgMintGasResponse) Unmarshal(dAtA []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: MsgMintGasResponse: wiretype end group for non-group") + return fmt.Errorf("proto: MsgMintResponse: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: MsgMintGasResponse: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: MsgMintResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: diff --git a/x/scorum/types/types.pb.go b/x/scorum/types/types.pb.go index abc4690..19a73f0 100644 --- a/x/scorum/types/types.pb.go +++ b/x/scorum/types/types.pb.go @@ -5,7 +5,9 @@ package types import ( fmt "fmt" + _ "github.com/cosmos/cosmos-proto" _ "github.com/cosmos/cosmos-sdk/types" + _ "github.com/cosmos/cosmos-sdk/types/tx/amino" _ "github.com/cosmos/gogoproto/gogoproto" proto "github.com/cosmos/gogoproto/proto" math "math" @@ -25,16 +27,17 @@ const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package func init() { proto.RegisterFile("network/scorum/v1/types.proto", fileDescriptor_4cd9d06b742befe6) } var fileDescriptor_4cd9d06b742befe6 = []byte{ - // 163 bytes of a gzipped FileDescriptorProto + // 183 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0xcd, 0x4b, 0x2d, 0x29, 0xcf, 0x2f, 0xca, 0xd6, 0x2f, 0x4e, 0xce, 0x2f, 0x2a, 0xcd, 0xd5, 0x2f, 0x33, 0xd4, 0x2f, 0xa9, 0x2c, 0x48, 0x2d, 0xd6, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x84, 0x4a, 0xeb, 0x41, 0xa4, 0xf5, 0xca, 0x0c, 0xa5, 0x44, 0xd2, 0xf3, 0xd3, 0xf3, 0xc1, 0xb2, 0xfa, 0x20, 0x16, 0x44, 0xa1, - 0x94, 0x5c, 0x72, 0x7e, 0x71, 0x6e, 0x7e, 0xb1, 0x7e, 0x52, 0x62, 0x71, 0xaa, 0x7e, 0x99, 0x61, - 0x52, 0x6a, 0x49, 0xa2, 0xa1, 0x7e, 0x72, 0x7e, 0x66, 0x1e, 0x44, 0xde, 0xc9, 0xf3, 0xc4, 0x23, - 0x39, 0xc6, 0x0b, 0x8f, 0xe4, 0x18, 0x1f, 0x3c, 0x92, 0x63, 0x9c, 0xf0, 0x58, 0x8e, 0xe1, 0xc2, - 0x63, 0x39, 0x86, 0x1b, 0x8f, 0xe5, 0x18, 0xa2, 0xf4, 0xd3, 0x33, 0x4b, 0x32, 0x4a, 0x93, 0xf4, - 0x92, 0xf3, 0x73, 0x61, 0x8e, 0x80, 0x98, 0xa5, 0x0b, 0x73, 0x5a, 0x05, 0x4c, 0x1c, 0xec, 0xb2, - 0x24, 0x36, 0xb0, 0x89, 0xc6, 0x80, 0x00, 0x00, 0x00, 0xff, 0xff, 0xa7, 0x8a, 0xd1, 0xdc, 0xbb, - 0x00, 0x00, 0x00, + 0x94, 0x60, 0x62, 0x6e, 0x66, 0x5e, 0xbe, 0x3e, 0x98, 0x84, 0x0a, 0x49, 0x26, 0xe7, 0x17, 0xe7, + 0xe6, 0x17, 0xc7, 0x43, 0xd4, 0x42, 0x38, 0x50, 0x29, 0x39, 0x08, 0x4f, 0x3f, 0x29, 0xb1, 0x38, + 0x55, 0xbf, 0xcc, 0x30, 0x29, 0xb5, 0x24, 0xd1, 0x50, 0x3f, 0x39, 0x3f, 0x33, 0x0f, 0x22, 0xef, + 0xe4, 0x79, 0xe2, 0x91, 0x1c, 0xe3, 0x85, 0x47, 0x72, 0x8c, 0x0f, 0x1e, 0xc9, 0x31, 0x4e, 0x78, + 0x2c, 0xc7, 0x70, 0xe1, 0xb1, 0x1c, 0xc3, 0x8d, 0xc7, 0x72, 0x0c, 0x51, 0xfa, 0xe9, 0x99, 0x25, + 0x19, 0xa5, 0x49, 0x7a, 0xc9, 0xf9, 0xb9, 0x30, 0x27, 0x43, 0xcc, 0xd2, 0x85, 0x79, 0xa4, 0x02, + 0x26, 0x0e, 0xf6, 0x47, 0x12, 0x1b, 0xd8, 0x44, 0x63, 0x40, 0x00, 0x00, 0x00, 0xff, 0xff, 0x58, + 0x59, 0x2b, 0xf6, 0xe9, 0x00, 0x00, 0x00, } diff --git a/x/scorum/wrapper/account_keeper.go b/x/scorum/wrapper/account_keeper.go index bb8d309..803d8f1 100644 --- a/x/scorum/wrapper/account_keeper.go +++ b/x/scorum/wrapper/account_keeper.go @@ -1,10 +1,9 @@ package wrap import ( + "context" "fmt" - "github.com/cosmos/cosmos-sdk/x/auth/types" - sdk "github.com/cosmos/cosmos-sdk/types" accountkeeper "github.com/cosmos/cosmos-sdk/x/auth/keeper" bankkeeper "github.com/cosmos/cosmos-sdk/x/bank/keeper" @@ -28,14 +27,18 @@ func NewAccountKeeper(ak accountkeeper.AccountKeeper, bk bankkeeper.Keeper, sk s } } -func (k AccountKeeper) SetAccount(ctx sdk.Context, acc types.AccountI) { +func (k AccountKeeper) SetAccount(ctx context.Context, acc sdk.AccountI) { + sdkCtx := sdk.UnwrapSDKContext(ctx) hasAccount := k.AccountKeeper.HasAccount(ctx, acc.GetAddress()) if !hasAccount { // must be set before minting to avoid recursion (BankKeeper calls SetAccount if it's not created yet) k.AccountKeeper.SetAccount(ctx, acc) - if err := k.sk.Mint(ctx, acc.GetAddress(), sdk.NewCoin(scorumtypes.GasDenom, k.sk.GetParams(ctx).GasLimit.Int)); err != nil { + if err := k.sk.Mint( + sdkCtx, acc.GetAddress(), + sdk.NewCoin(scorumtypes.GasDenom, k.sk.GetParams(sdkCtx).GasLimit), + ); err != nil { panic(fmt.Sprintf("failed to mint gas to new account: %s", err.Error())) } } diff --git a/x/scorum/wrapper/staking_bank_keeper.go b/x/scorum/wrapper/staking_bank_keeper.go index 0332eaf..b7175be 100644 --- a/x/scorum/wrapper/staking_bank_keeper.go +++ b/x/scorum/wrapper/staking_bank_keeper.go @@ -1,6 +1,8 @@ package wrap import ( + "context" + stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" "github.com/mikluke/co-pilot/slice" scorumkeeper "github.com/scorum/cosmos-network/x/scorum/keeper" @@ -23,17 +25,18 @@ func NewStakingBankKeeper(bk bankkeeper.Keeper, sk *scorumkeeper.Keeper) bankkee } } -func (k StakingBankKeeper) BurnCoins(ctx sdk.Context, moduleName string, amt sdk.Coins) error { +func (k StakingBankKeeper) BurnCoins(ctx context.Context, moduleName string, amt sdk.Coins) error { + sdkCtx := sdk.UnwrapSDKContext(ctx) if !slice.Contains([]string{stakingtypes.BondedPoolName, stakingtypes.NotBondedPoolName}, moduleName) { return k.Keeper.BurnCoins(ctx, moduleName, amt) } - pool := k.sk.GetParams(ctx).ValidatorsReward.PoolAddress + pool := k.sk.GetParams(sdkCtx).ValidatorsReward.PoolAddress if pool != "" { - ctx.Logger().Info("send slashed coins to validators reward pool") + sdkCtx.Logger().Info("send slashed coins to validators reward pool") return k.SendCoinsFromModuleToAccount(ctx, moduleName, sdk.MustAccAddressFromBech32(pool), amt) } - ctx.Logger().Error("staking module requested coins burning, but there is no pool to transfer it") + sdkCtx.Logger().Error("staking module requested coins burning, but there is no pool to transfer it") return k.Keeper.BurnCoins(ctx, moduleName, amt) }