diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 0e563a6e..11545427 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -5,46 +5,65 @@ name: omniflixhub # Controls when the action will run. Workflow runs when manually triggered using the UI # or API. on: - push: - branches: - - master - - main - - development - tags: - - v* pull_request: branches: - - master - - main - - development + - "**" + push: + branches: + - "main" + - "v[0-9]**" + workflow_dispatch: + +env: + GO_VERSION: "1.20.5" +concurrency: + group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} + cancel-in-progress: true # This workflow makes x86_64 binaries for mac, windows, and linux. jobs: build: + name: omniflixhub ${{ matrix.arch }} for ${{ matrix.targetos }} runs-on: ubuntu-latest strategy: matrix: arch: [ amd64, arm64 ] targetos: [ darwin, linux ] - name: omniflixhub ${{ matrix.arch }} for ${{ matrix.targetos }} + include: + - targetos: darwin + arch: arm64 + steps: - - uses: actions/checkout@v2 - - name: Setup go - uses: actions/setup-go@v1 + - name: Check out repository code + uses: actions/checkout@v4 + - name: Get git diff + uses: technote-space/get-diff-action@v6.1.2 + with: + PATTERNS: | + **/**.wasm + !tests/** + **/**.go !**/*_test.go + go.mod + go.sum + Makefile + .github/workflows/build.yml + - name: Setup Golang + uses: actions/setup-go@v4 + if: env.GIT_DIFF with: - go-version: 1.18 + go-version: ${{env.GO_VERSION}} env: GOOS: ${{ matrix.targetos }} GOARCH: ${{ matrix.arch }} - - - name: Compile + - name: Download Dependencies + if: env.GIT_DIFF + run: go mod download + - name: Build omnniflixhubd + if: env.GIT_DIFF run: | - go mod download - cd cmd/omniflixhubd - go build . - - - uses: actions/upload-artifact@v2 + GOWRK=off go build cmd/omniflixhubd/main.go + - uses: actions/upload-artifact@v3 with: name: omniflixhubd ${{ matrix.targetos }} ${{ matrix.arch }} path: cmd/omniflixhubd/omniflixhubd diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 45c1d67f..2b150a81 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -7,10 +7,20 @@ on: - master - main pull_request: + paths: + - '**.go' + +env: + GO_VERSION: '1.20.0' + permissions: contents: read # Optional: allow read access to pull request. Use with `only-new-issues` option. # pull-requests: read +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + jobs: golangci: name: lint @@ -18,10 +28,10 @@ jobs: steps: - uses: actions/setup-go@v3 with: - go-version: 1.20.0 + go-version: ${{env.GO_VERSION}} - uses: actions/checkout@v3 - name: golangci-lint uses: golangci/golangci-lint-action@v3 with: version: latest - args: --timeout 5m0s + args: --timeout 10m diff --git a/.golangci.yml b/.golangci.yml index 735ed4a0..244ce91e 100644 --- a/.golangci.yml +++ b/.golangci.yml @@ -28,13 +28,6 @@ linters: - unused issues: - gofumpt: - # Module path which contains the source code being formatted. - # Default: "" - module-path: github.com/cosmos/interchain-security - # Choose whether to use the extra rules. - # Default: false - extra-rules: true exclude-rules: - text: "Use of weak random number generator" linters: @@ -54,11 +47,20 @@ issues: - text: "leading space" linters: - nolintlint + - path: "legacy" + text: "SA1019:" + linters: + - staticcheck max-issues-per-linter: 10000 max-same-issues: 10000 linters-settings: + gosec: + excludes: + - G404 + - G101 + - G601 gocritic: disabled-checks: - appendAssign diff --git a/.goreleaser.yml b/.goreleaser.yml index 04709e66..92433837 100644 --- a/.goreleaser.yml +++ b/.goreleaser.yml @@ -6,7 +6,7 @@ env: before: hooks: - - go mod tidy -compat=1.19 + - go mod tidy -compat=1.20 builds: - main: ./cmd/omniflixhubd diff --git a/Makefile b/Makefile index fbe6b7cd..da8ce380 100644 --- a/Makefile +++ b/Makefile @@ -2,10 +2,29 @@ APP_NAME = OmniFlixHub DAEMON_NAME = omniflixhubd LEDGER_ENABLED ?= true -PACKAGES=$(shell go list ./... | grep -v '/simulation') -VERSION := $(shell echo $(shell git describe --tags --always) | sed 's/^v//') +BRANCH := $(shell git rev-parse --abbrev-ref HEAD) COMMIT := $(shell git log -1 --format='%H') -COSMOS_SDK := $(shell grep -i cosmos-sdk go.mod | awk '{print $$2}') + +# don't override user values +ifeq (,$(VERSION)) + VERSION := $(shell git describe --exact-match 2>/dev/null) + # if VERSION is empty, then populate it with branch's name and raw commit hash + ifeq (,$(VERSION)) + VERSION := $(BRANCH)-$(COMMIT) + endif +endif + +PACKAGES_SIMTEST=$(shell go list ./... | grep -v '/simulation') +LEDGER_ENABLED ?= true +SDK_PACK := $(shell go list -m github.com/cosmos/cosmos-sdk | sed 's/ /\@/g') +BFT_VERSION := $(shell go list -m github.com/cometbft/cometbft | sed 's:.* ::') +DOCKER := $(shell which docker) +BUILDDIR ?= $(CURDIR)/build + +GO_SYSTEM_VERSION = $(shell go version | cut -c 14- | cut -d' ' -f1 | cut -d'.' -f1-2) +REQUIRE_GO_VERSION = 1.20 + +export GO111MODULE = on build_tags = netgo ifeq ($(LEDGER_ENABLED),true) @@ -30,6 +49,13 @@ ifeq ($(LEDGER_ENABLED),true) endif endif endif + +ifeq (cleveldb,$(findstring cleveldb,$(OMNIFLIXHUB_BUILD_OPTIONS))) + build_tags += gcc cleveldb +else ifeq (rocksdb,$(findstring rocksdb,$(OMNIFLIXHUB_BUILD_OPTIONS))) + build_tags += gcc rocksdb +endif + build_tags += $(BUILD_TAGS) build_tags := $(strip $(build_tags)) @@ -44,19 +70,34 @@ ldflags = -X github.com/cosmos/cosmos-sdk/version.Name=${APP_NAME} \ -X github.com/cosmos/cosmos-sdk/version.AppName=${DAEMON_NAME} \ -X github.com/cosmos/cosmos-sdk/version.Version=$(VERSION) \ -X github.com/cosmos/cosmos-sdk/version.Commit=$(COMMIT) \ - -X "github.com/cosmos/cosmos-sdk/version.BuildTags=$(build_tags_comma_sep),cosmos-sdk $(COSMOS_SDK)" + -X "github.com/cosmos/cosmos-sdk/version.BuildTags=$(build_tags_comma_sep)" \ + -X github.com/cometbft/cometbft/version.TMCoreSemVer=$(BFT_VERSION) + +ifeq (cleveldb,$(findstring cleveldb,$(OMNIFLIXHUB_BUILD_OPTIONS))) + ldflags += -X github.com/cosmos/cosmos-sdk/types.DBBackend=cleveldb +else ifeq (rocksdb,$(findstring rocksdb,$(OMNIFLIXHUB_BUILD_OPTIONS))) + ldflags += -X github.com/cosmos/cosmos-sdk/types.DBBackend=rocksdb +endif + +ifeq (,$(findstring nostrip,$(OMNIFLIXHUB_BUILD_OPTIONS))) + ldflags += -w -s +endif ldflags += $(LDFLAGS) ldflags := $(strip $(ldflags)) BUILD_FLAGS := -tags "$(build_tags)" -ldflags '$(ldflags)' +ifeq (,$(findstring nostrip,$(ONFT_BUILD_OPTIONS))) + BUILD_FLAGS += -trimpath +endif + all: go.sum install install: go.sum - go install $(BUILD_FLAGS) ./cmd/omniflixhubd/ + go install -mod=readonly $(BUILD_FLAGS) ./cmd/omniflixhubd build: - go build $(BUILD_FLAGS) -o ./build/omniflixhubd ./cmd/omniflixhubd/ + go build $(BUILD_FLAGS) -o ${BUILDDIR}/${DAEMON_NAME} ./cmd/omniflixhubd go.sum: go.mod @echo "--> Ensure dependencies have not been modified" @@ -64,7 +105,7 @@ go.sum: go.mod lint: @echo "--> Running linter" - @golangci-lint run + @golangci-lint run --timeout 10m @go mod verify diff --git a/app/ante_handler.go b/app/ante_handler.go index 868bf6f3..3b55b7f9 100644 --- a/app/ante_handler.go +++ b/app/ante_handler.go @@ -1,14 +1,15 @@ package app import ( - "github.com/OmniFlix/omniflixhub/app/decorators" + errorsmod "cosmossdk.io/errors" "github.com/cosmos/cosmos-sdk/codec" + storetypes "github.com/cosmos/cosmos-sdk/store/types" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" "github.com/cosmos/cosmos-sdk/x/auth/ante" govkeeper "github.com/cosmos/cosmos-sdk/x/gov/keeper" - ibcante "github.com/cosmos/ibc-go/v4/modules/core/ante" - ibckeeper "github.com/cosmos/ibc-go/v4/modules/core/keeper" + ibcante "github.com/cosmos/ibc-go/v7/modules/core/ante" + ibckeeper "github.com/cosmos/ibc-go/v7/modules/core/keeper" ) // HandlerOptions extend the SDK's AnteHandler options by requiring the IBC @@ -18,19 +19,19 @@ type HandlerOptions struct { GovKeeper govkeeper.Keeper IBCKeeper *ibckeeper.Keeper - TxCounterStoreKey sdk.StoreKey + TxCounterStoreKey storetypes.StoreKey Codec codec.BinaryCodec } func NewAnteHandler(options HandlerOptions) (sdk.AnteHandler, error) { if options.AccountKeeper == nil { - return nil, sdkerrors.Wrap(sdkerrors.ErrLogic, "account keeper is required for AnteHandler") + return nil, errorsmod.Wrap(sdkerrors.ErrLogic, "account keeper is required for AnteHandler") } if options.BankKeeper == nil { - return nil, sdkerrors.Wrap(sdkerrors.ErrLogic, "bank keeper is required for AnteHandler") + return nil, errorsmod.Wrap(sdkerrors.ErrLogic, "bank keeper is required for AnteHandler") } if options.SignModeHandler == nil { - return nil, sdkerrors.Wrap(sdkerrors.ErrLogic, "sign mode handler is required for ante builder") + return nil, errorsmod.Wrap(sdkerrors.ErrLogic, "sign mode handler is required for ante builder") } sigGasConsumer := options.SigGasConsumer @@ -40,22 +41,24 @@ func NewAnteHandler(options HandlerOptions) (sdk.AnteHandler, error) { anteDecorators := []sdk.AnteDecorator{ ante.NewSetUpContextDecorator(), // Outermost AnteDecorator, SetUpContext must be called first - decorators.NewMinCommissionDecorator(options.Codec), - ante.NewRejectExtensionOptionsDecorator(), - decorators.NewMinimumInitialDepositDecorator(options.Codec, options.GovKeeper), - ante.NewMempoolFeeDecorator(), + ante.NewExtensionOptionsDecorator(options.ExtensionOptionChecker), ante.NewValidateBasicDecorator(), ante.NewTxTimeoutHeightDecorator(), ante.NewValidateMemoDecorator(options.AccountKeeper), ante.NewConsumeGasForTxSizeDecorator(options.AccountKeeper), - ante.NewDeductFeeDecorator(options.AccountKeeper, options.BankKeeper, options.FeegrantKeeper), + ante.NewDeductFeeDecorator( + options.AccountKeeper, + options.BankKeeper, + options.FeegrantKeeper, + options.TxFeeChecker, + ), // SetPubKeyDecorator must be called before all signature verification decorators ante.NewSetPubKeyDecorator(options.AccountKeeper), ante.NewValidateSigCountDecorator(options.AccountKeeper), ante.NewSigGasConsumeDecorator(options.AccountKeeper, sigGasConsumer), ante.NewSigVerificationDecorator(options.AccountKeeper, options.SignModeHandler), ante.NewIncrementSequenceDecorator(options.AccountKeeper), - ibcante.NewAnteDecorator(options.IBCKeeper), + ibcante.NewRedundantRelayDecorator(options.IBCKeeper), } return sdk.ChainAnteDecorators(anteDecorators...), nil diff --git a/app/app.go b/app/app.go index 6559198c..a7bf7230 100644 --- a/app/app.go +++ b/app/app.go @@ -7,44 +7,45 @@ import ( "os" "path/filepath" - "github.com/OmniFlix/omniflixhub/app/openapiconsole" - appparams "github.com/OmniFlix/omniflixhub/app/params" - customAuthRest "github.com/OmniFlix/omniflixhub/custom/auth/client/rest" - "github.com/OmniFlix/omniflixhub/docs" + autocliv1 "cosmossdk.io/api/cosmos/autocli/v1" + reflectionv1 "cosmossdk.io/api/cosmos/reflection/v1" + "github.com/OmniFlix/omniflixhub/v2/app/openapiconsole" + appparams "github.com/OmniFlix/omniflixhub/v2/app/params" + "github.com/OmniFlix/omniflixhub/v2/docs" + dbm "github.com/cometbft/cometbft-db" + abci "github.com/cometbft/cometbft/abci/types" + tmjson "github.com/cometbft/cometbft/libs/json" + "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" + nodeservice "github.com/cosmos/cosmos-sdk/client/grpc/node" "github.com/cosmos/cosmos-sdk/client/grpc/tmservice" - "github.com/cosmos/cosmos-sdk/client/rpc" "github.com/cosmos/cosmos-sdk/codec" "github.com/cosmos/cosmos-sdk/codec/types" + "github.com/cosmos/cosmos-sdk/runtime" + runtimeservices "github.com/cosmos/cosmos-sdk/runtime/services" "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/simapp" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" "github.com/cosmos/cosmos-sdk/version" "github.com/cosmos/cosmos-sdk/x/auth/ante" - authrest "github.com/cosmos/cosmos-sdk/x/auth/client/rest" authtx "github.com/cosmos/cosmos-sdk/x/auth/tx" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" "github.com/cosmos/cosmos-sdk/x/crisis" - distrclient "github.com/cosmos/cosmos-sdk/x/distribution/client" govclient "github.com/cosmos/cosmos-sdk/x/gov/client" paramsclient "github.com/cosmos/cosmos-sdk/x/params/client" paramstypes "github.com/cosmos/cosmos-sdk/x/params/types" upgradeclient "github.com/cosmos/cosmos-sdk/x/upgrade/client" - ibcclientclient "github.com/cosmos/ibc-go/v4/modules/core/02-client/client" + ibcclientclient "github.com/cosmos/ibc-go/v7/modules/core/02-client/client" "github.com/spf13/cast" - abci "github.com/tendermint/tendermint/abci/types" - tmjson "github.com/tendermint/tendermint/libs/json" - "github.com/tendermint/tendermint/libs/log" - tmos "github.com/tendermint/tendermint/libs/os" - dbm "github.com/tendermint/tm-db" - - "github.com/OmniFlix/omniflixhub/app/keepers" - "github.com/OmniFlix/omniflixhub/app/upgrades" - v012 "github.com/OmniFlix/omniflixhub/app/upgrades/v012" + + "github.com/OmniFlix/omniflixhub/v2/app/keepers" + "github.com/OmniFlix/omniflixhub/v2/app/upgrades" + v012 "github.com/OmniFlix/omniflixhub/v2/app/upgrades/v012" + v2 "github.com/OmniFlix/omniflixhub/v2/app/upgrades/v2" upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types" ) @@ -54,9 +55,8 @@ func getGovProposalHandlers() []govclient.ProposalHandler { var govProposalHandlers []govclient.ProposalHandler govProposalHandlers = append(govProposalHandlers, paramsclient.ProposalHandler, - distrclient.ProposalHandler, - upgradeclient.ProposalHandler, - upgradeclient.CancelProposalHandler, + upgradeclient.LegacyProposalHandler, + upgradeclient.LegacyCancelProposalHandler, ibcclientclient.UpdateClientProposalHandler, ibcclientclient.UpgradeProposalHandler, ) @@ -67,12 +67,12 @@ func getGovProposalHandlers() []govclient.ProposalHandler { var ( // DefaultNodeHome default home directories for the application daemon DefaultNodeHome string - Upgrades = []upgrades.Upgrade{v012.Upgrade} + Upgrades = []upgrades.Upgrade{v012.Upgrade, v2.Upgrade} Forks []upgrades.Fork ) var ( - _ simapp.App = (*OmniFlixApp)(nil) + _ runtime.AppI = (*OmniFlixApp)(nil) _ servertypes.Application = (*OmniFlixApp)(nil) ) @@ -146,6 +146,7 @@ func NewOmniFlixApp( skipUpgradeHeights, homePath, invCheckPeriod, + logger, appOpts, ) @@ -175,8 +176,7 @@ func NewOmniFlixApp( // can do so safely. app.mm.SetOrderInitGenesis(orderInitGenesis()...) - app.mm.RegisterInvariants(&app.CrisisKeeper) - app.mm.RegisterRoutes(app.Router(), app.QueryRouter(), encodingConfig.Amino) + app.mm.RegisterInvariants(app.CrisisKeeper) app.configurator = module.NewConfigurator(app.appCodec, app.MsgServiceRouter(), app.GRPCQueryRouter()) app.mm.RegisterServices(app.configurator) @@ -190,6 +190,15 @@ func NewOmniFlixApp( app.MountTransientStores(app.GetTransientStoreKey()) app.MountMemoryStores(app.GetMemoryStoreKey()) + // SDK v47 - since we do not use dep inject, this gives us access to newer gRPC services. + autocliv1.RegisterQueryServer(app.GRPCQueryRouter(), runtimeservices.NewAutoCLIQueryService(app.mm.Modules)) + + reflectionSvc, err := runtimeservices.NewReflectionService() + if err != nil { + panic(err) + } + reflectionv1.RegisterReflectionServiceServer(app.GRPCQueryRouter(), reflectionSvc) + anteHandler, err := NewAnteHandler( HandlerOptions{ HandlerOptions: ante.HandlerOptions{ @@ -303,22 +312,20 @@ func (app *OmniFlixApp) GetSubspace(moduleName string) paramstypes.Subspace { // RegisterAPIRoutes registers all application module routes with the provided // API server. -func (app *OmniFlixApp) RegisterAPIRoutes(apiSvr *api.Server, apiConfig config.APIConfig) { +func (app *OmniFlixApp) RegisterAPIRoutes(apiSvr *api.Server, _ config.APIConfig) { clientCtx := apiSvr.ClientCtx - rpc.RegisterRoutes(clientCtx, apiSvr.Router) - // Register legacy tx routes. - authrest.RegisterTxRoutes(clientCtx, apiSvr.Router) - // Register custom tx routes - customAuthRest.RegisterTxRoutes(clientCtx, apiSvr.Router) + // 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) // Register legacy and grpc-gateway routes for all modules. - ModuleBasics.RegisterRESTRoutes(clientCtx, apiSvr.Router) ModuleBasics.RegisterGRPCGatewayRoutes(clientCtx, apiSvr.GRPCGatewayRouter) + // Register nodeservice grpc-gateway routes. + nodeservice.RegisterGRPCGatewayRoutes(clientCtx, apiSvr.GRPCGatewayRouter) + // register app's OpenAPI routes. apiSvr.Router.Handle("/static/openapi.yml", http.FileServer(http.FS(docs.Docs))) apiSvr.Router.HandleFunc("/", openapiconsole.Handler(Name, "/static/openapi.yml")) @@ -335,7 +342,16 @@ func (app *OmniFlixApp) SimulationManager() *module.SimulationManager { // RegisterTendermintService implements the Application.RegisterTendermintService method. func (app *OmniFlixApp) RegisterTendermintService(clientCtx client.Context) { - tmservice.RegisterTendermintService(app.BaseApp.GRPCQueryRouter(), clientCtx, app.interfaceRegistry) + tmservice.RegisterTendermintService( + clientCtx, + app.BaseApp.GRPCQueryRouter(), + app.interfaceRegistry, + app.Query, + ) +} + +func (app *OmniFlixApp) RegisterNodeService(clientCtx client.Context) { + nodeservice.RegisterNodeService(clientCtx, app.GRPCQueryRouter()) } func (app *OmniFlixApp) setupUpgradeHandlers() { diff --git a/app/apptesting/test_suite.go b/app/apptesting/test_suite.go index d73e351c..077eaba4 100644 --- a/app/apptesting/test_suite.go +++ b/app/apptesting/test_suite.go @@ -4,27 +4,28 @@ import ( "fmt" "time" - "github.com/OmniFlix/omniflixhub/app" + "cosmossdk.io/math" + "github.com/OmniFlix/omniflixhub/v2/app" + + dbm "github.com/cometbft/cometbft-db" + abci "github.com/cometbft/cometbft/abci/types" + "github.com/cometbft/cometbft/crypto/ed25519" + "github.com/cometbft/cometbft/libs/log" + tmtypes "github.com/cometbft/cometbft/proto/tendermint/types" "github.com/cosmos/cosmos-sdk/baseapp" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/crypto/keys/secp256k1" - "github.com/cosmos/cosmos-sdk/simapp" "github.com/cosmos/cosmos-sdk/store/rootmulti" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/tx/signing" authsigning "github.com/cosmos/cosmos-sdk/x/auth/signing" + banktestutil "github.com/cosmos/cosmos-sdk/x/bank/testutil" distrtypes "github.com/cosmos/cosmos-sdk/x/distribution/types" minttypes "github.com/cosmos/cosmos-sdk/x/mint/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" "github.com/stretchr/testify/suite" - abci "github.com/tendermint/tendermint/abci/types" - "github.com/tendermint/tendermint/crypto/ed25519" - "github.com/tendermint/tendermint/libs/log" - tmtypes "github.com/tendermint/tendermint/proto/tendermint/types" - dbm "github.com/tendermint/tm-db" ) type KeeperTestHelper struct { @@ -38,7 +39,8 @@ type KeeperTestHelper struct { // Setup sets up basic environment for suite (App, Ctx, and test accounts) func (s *KeeperTestHelper) Setup() { - s.App = app.Setup(s.T(), true, 0) + t := s.T() + s.App = app.Setup(t) s.Ctx = s.App.BaseApp.NewContext(false, tmtypes.Header{Height: 1, ChainID: app.SimAppChainID, Time: time.Now().UTC()}) s.QueryHelper = &baseapp.QueryServiceTestHelper{ GRPCQueryRouter: s.App.GRPCQueryRouter(), @@ -50,7 +52,7 @@ func (s *KeeperTestHelper) Setup() { func (s *KeeperTestHelper) SetupTestForInitGenesis() { // Setting to True, leads to init genesis not running - s.App = app.Setup(s.T(), true, 0) + s.App = app.Setup(s.T()) s.Ctx = s.App.BaseApp.NewContext(true, tmtypes.Header{}) } @@ -81,13 +83,13 @@ func (s *KeeperTestHelper) Commit() { // FundAcc funds target address with specified amount. func (s *KeeperTestHelper) FundAcc(acc sdk.AccAddress, amounts sdk.Coins) { - err := simapp.FundAccount(s.App.BankKeeper, s.Ctx, acc, amounts) + err := banktestutil.FundAccount(s.App.BankKeeper, s.Ctx, acc, amounts) s.Require().NoError(err) } // FundModuleAcc funds target modules with specified amount. func (s *KeeperTestHelper) FundModuleAcc(moduleName string, amounts sdk.Coins) { - err := simapp.FundModuleAccount(s.App.BankKeeper, s.Ctx, moduleName, amounts) + err := banktestutil.FundModuleAccount(s.App.BankKeeper, s.Ctx, moduleName, amounts) s.Require().NoError(err) } @@ -105,14 +107,10 @@ func (s *KeeperTestHelper) SetupValidator(bondStatus stakingtypes.BondStatus) sd s.FundAcc(sdk.AccAddress(valAddr), selfBond) - stakingHandler := staking.NewHandler(s.App.StakingKeeper) stakingCoin := sdk.NewCoin(sdk.DefaultBondDenom, selfBond[0].Amount) ZeroCommission := stakingtypes.NewCommissionRates(sdk.ZeroDec(), sdk.ZeroDec(), sdk.ZeroDec()) - msg, err := stakingtypes.NewMsgCreateValidator(valAddr, valPub, stakingCoin, stakingtypes.Description{}, ZeroCommission, sdk.OneInt()) - s.Require().NoError(err) - res, err := stakingHandler(s.Ctx, msg) + _, err := stakingtypes.NewMsgCreateValidator(valAddr, valPub, stakingCoin, stakingtypes.Description{}, ZeroCommission, sdk.OneInt()) s.Require().NoError(err) - s.Require().NotNil(res) val, found := s.App.StakingKeeper.GetValidator(s.Ctx, valAddr) s.Require().True(found) @@ -180,7 +178,7 @@ func (s *KeeperTestHelper) BeginNewBlockWithProposer(executeNextEpoch bool, prop header := tmtypes.Header{Height: s.Ctx.BlockHeight() + 1, Time: newBlockTime} newCtx := s.Ctx.WithBlockTime(newBlockTime).WithBlockHeight(s.Ctx.BlockHeight() + 1) s.Ctx = newCtx - lastCommitInfo := abci.LastCommitInfo{ + lastCommitInfo := abci.CommitInfo{ Votes: []abci.VoteInfo{{ Validator: abci.Validator{Address: valAddr, Power: 1000}, SignedLastBlock: true, @@ -211,13 +209,13 @@ func (s *KeeperTestHelper) RunMsg(msg sdk.Msg) (*sdk.Result, error) { } // AllocateRewardsToValidator allocates reward tokens to a distribution module then allocates rewards to the validator address. -func (s *KeeperTestHelper) AllocateRewardsToValidator(valAddr sdk.ValAddress, rewardAmt sdk.Int) { +func (s *KeeperTestHelper) AllocateRewardsToValidator(valAddr sdk.ValAddress, rewardAmt math.Int) { validator, found := s.App.StakingKeeper.GetValidator(s.Ctx, valAddr) s.Require().True(found) // allocate reward tokens to distribution module coins := sdk.Coins{sdk.NewCoin(sdk.DefaultBondDenom, rewardAmt)} - err := simapp.FundModuleAccount(s.App.BankKeeper, s.Ctx, distrtypes.ModuleName, coins) + err := banktestutil.FundModuleAccount(s.App.BankKeeper, s.Ctx, distrtypes.ModuleName, coins) s.Require().NoError(err) // allocate rewards to validator diff --git a/app/decorators/min_proposal_deposit.go b/app/decorators/min_proposal_deposit.go deleted file mode 100644 index cbcf4c2f..00000000 --- a/app/decorators/min_proposal_deposit.go +++ /dev/null @@ -1,90 +0,0 @@ -package decorators - -import ( - "github.com/cosmos/cosmos-sdk/codec" - sdk "github.com/cosmos/cosmos-sdk/types" - sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" - "github.com/cosmos/cosmos-sdk/x/authz" - govkeeper "github.com/cosmos/cosmos-sdk/x/gov/keeper" - govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" -) - -var MinimumInitialDepositRate = sdk.NewDecWithPrec(10, 2) // 10% of min_deposit - -type MinimumInitialDepositDecorator struct { - govKeeper govkeeper.Keeper - cdc codec.BinaryCodec -} - -func NewMinimumInitialDepositDecorator( - cdc codec.BinaryCodec, govKeeper govkeeper.Keeper, -) MinimumInitialDepositDecorator { - return MinimumInitialDepositDecorator{ - govKeeper: govKeeper, - cdc: cdc, - } -} - -// checkProposalInitialDeposit returns error if the initial deposit amount is less than minInitialDeposit amount -func (midd MinimumInitialDepositDecorator) checkProposalInitialDeposit(ctx sdk.Context, msg sdk.Msg) error { - if msg, ok := msg.(*govtypes.MsgSubmitProposal); ok { - depositParams := midd.govKeeper.GetDepositParams(ctx) - minimumInitialDeposit := midd.calculateMinimumInitialDeposit(depositParams.MinDeposit) - if msg.InitialDeposit.IsAllLT(minimumInitialDeposit) { - return sdkerrors.Wrapf(sdkerrors.ErrUnauthorized, - "initial deposit amount is not enough. required: %v", minimumInitialDeposit) - } - } - return nil -} - -// Validate validates messages -func (midd MinimumInitialDepositDecorator) Validate(ctx sdk.Context, msgs []sdk.Msg) error { - // Check every msg in the tx, if it's a MsgExec, check the inner msgs. - // If it's a MsgSubmitProposal, check the initial deposit is enough. - for _, m := range msgs { - var innerMsg sdk.Msg - if msg, ok := m.(*authz.MsgExec); ok { - for _, v := range msg.Msgs { - err := midd.cdc.UnpackAny(v, &innerMsg) - if err != nil { - return sdkerrors.Wrapf(sdkerrors.ErrUnauthorized, "cannot unmarshal authz exec msgs") - } - - err = midd.checkProposalInitialDeposit(ctx, innerMsg) - if err != nil { - return err - } - } - } else { - err := midd.checkProposalInitialDeposit(ctx, m) - if err != nil { - return err - } - } - } - - return nil -} - -func (midd MinimumInitialDepositDecorator) AnteHandle( - ctx sdk.Context, tx sdk.Tx, simulate bool, next sdk.AnteHandler, -) (newCtx sdk.Context, err error) { - msgs := tx.GetMsgs() - if err := midd.Validate(ctx, msgs); err != nil { - return ctx, err - } - - return next(ctx, tx, simulate) -} - -func (midd MinimumInitialDepositDecorator) calculateMinimumInitialDeposit( - minDeposit sdk.Coins, -) (minimumInitialDeposit sdk.Coins) { - for _, coin := range minDeposit { - minimumInitialCoin := MinimumInitialDepositRate.MulInt(coin.Amount).RoundInt() - minimumInitialDeposit = minimumInitialDeposit.Add(sdk.NewCoin(coin.Denom, minimumInitialCoin)) - } - - return -} diff --git a/app/decorators/min_validator_commission.go b/app/decorators/min_validator_commission.go deleted file mode 100644 index 3b6e4eb2..00000000 --- a/app/decorators/min_validator_commission.go +++ /dev/null @@ -1,76 +0,0 @@ -package decorators - -import ( - "github.com/cosmos/cosmos-sdk/codec" - sdk "github.com/cosmos/cosmos-sdk/types" - sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" - - "github.com/cosmos/cosmos-sdk/x/authz" - stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" -) - -type MinCommissionDecorator struct { - codec codec.BinaryCodec -} - -func NewMinCommissionDecorator(codec codec.BinaryCodec) MinCommissionDecorator { - return MinCommissionDecorator{ - codec, - } -} - -func checkCommission(m sdk.Msg) error { - switch msg := m.(type) { - case *stakingtypes.MsgCreateValidator: - c := msg.Commission - if c.Rate.LT(sdk.NewDecWithPrec(5, 2)) { - return sdkerrors.Wrap(sdkerrors.ErrUnauthorized, "commission can not be lower than 5%") - } - case *stakingtypes.MsgEditValidator: - // if commission rate is nil, it means only other fields are being update and we must skip this validation - if msg.CommissionRate == nil { - return nil - } - if msg.CommissionRate.LT(sdk.NewDecWithPrec(5, 2)) { - return sdkerrors.Wrap(sdkerrors.ErrUnauthorized, "commission can not be lower than 5%") - } - default: - return nil - } - return nil -} - -func (dec MinCommissionDecorator) Validate(m sdk.Msg) error { - err := checkCommission(m) - if err != nil { - return err - } - if msg, ok := m.(*authz.MsgExec); ok { - for _, v := range msg.Msgs { - var wrappedMsg sdk.Msg - err := dec.codec.UnpackAny(v, &wrappedMsg) - if err != nil { - return sdkerrors.Wrapf(sdkerrors.ErrUnauthorized, "error decoding authz messages") - } - err = checkCommission(wrappedMsg) - if err != nil { - return err - } - } - } - return nil -} - -func (dec MinCommissionDecorator) AnteHandle( - ctx sdk.Context, tx sdk.Tx, - simulate bool, next sdk.AnteHandler, -) (newCtx sdk.Context, err error) { - msgs := tx.GetMsgs() - for _, m := range msgs { - err := dec.Validate(m) - if err != nil { - return ctx, err - } - } - return next(ctx, tx, simulate) -} diff --git a/app/encoding.go b/app/encoding.go index 0445b317..cc097424 100644 --- a/app/encoding.go +++ b/app/encoding.go @@ -1,7 +1,7 @@ package app import ( - "github.com/OmniFlix/omniflixhub/app/params" + "github.com/OmniFlix/omniflixhub/v2/app/params" "github.com/cosmos/cosmos-sdk/std" ) diff --git a/app/export.go b/app/export.go index 1c05ae06..fa89f43e 100644 --- a/app/export.go +++ b/app/export.go @@ -4,7 +4,7 @@ import ( "encoding/json" "log" - tmproto "github.com/tendermint/tendermint/proto/tendermint/types" + tmproto "github.com/cometbft/cometbft/proto/tendermint/types" servertypes "github.com/cosmos/cosmos-sdk/server/types" sdk "github.com/cosmos/cosmos-sdk/types" @@ -16,7 +16,7 @@ import ( // ExportAppStateAndValidators exports the state of the application for a genesis // file. func (app *OmniFlixApp) ExportAppStateAndValidators( - forZeroHeight bool, jailAllowedAddrs []string, + 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()}) @@ -29,13 +29,13 @@ func (app *OmniFlixApp) ExportAppStateAndValidators( app.prepForZeroHeightGenesis(ctx, jailAllowedAddrs) } - genState := app.mm.ExportGenesis(ctx, app.appCodec) + genState := app.mm.ExportGenesisForModules(ctx, app.appCodec, modulesToExport) appState, err := json.MarshalIndent(genState, "", " ") if err != nil { return servertypes.ExportedApp{}, err } - validators, err := staking.WriteValidators(ctx, app.StakingKeeper) + validators, err := staking.WriteValidators(ctx, app.AppKeepers.StakingKeeper) if err != nil { return servertypes.ExportedApp{}, err } diff --git a/app/helpers/mock.go b/app/helpers/mock.go index 0e2ca952..ffbfc82f 100644 --- a/app/helpers/mock.go +++ b/app/helpers/mock.go @@ -1,9 +1,9 @@ package helpers import ( - "github.com/tendermint/tendermint/crypto" - tmproto "github.com/tendermint/tendermint/proto/tendermint/types" - tmtypes "github.com/tendermint/tendermint/types" + "github.com/cometbft/cometbft/crypto" + tmproto "github.com/cometbft/cometbft/proto/tendermint/types" + tmtypes "github.com/cometbft/cometbft/types" cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" "github.com/cosmos/cosmos-sdk/crypto/keys/ed25519" diff --git a/app/keepers/keepers.go b/app/keepers/keepers.go index 6873ace8..4fc6787e 100644 --- a/app/keepers/keepers.go +++ b/app/keepers/keepers.go @@ -1,12 +1,14 @@ package keepers import ( + "github.com/cometbft/cometbft/libs/log" + tmos "github.com/cometbft/cometbft/libs/os" "github.com/cosmos/cosmos-sdk/baseapp" "github.com/cosmos/cosmos-sdk/codec" servertypes "github.com/cosmos/cosmos-sdk/server/types" "github.com/cosmos/cosmos-sdk/store/streaming" - sdk "github.com/cosmos/cosmos-sdk/types" - tmos "github.com/tendermint/tendermint/libs/os" + storetypes "github.com/cosmos/cosmos-sdk/store/types" + ibcexported "github.com/cosmos/ibc-go/v7/modules/core/exported" authkeeper "github.com/cosmos/cosmos-sdk/x/auth/keeper" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" @@ -19,10 +21,12 @@ import ( capabilitykeeper "github.com/cosmos/cosmos-sdk/x/capability/keeper" capabilitytypes "github.com/cosmos/cosmos-sdk/x/capability/types" + consensusparamkeeper "github.com/cosmos/cosmos-sdk/x/consensus/keeper" + consensusparamtypes "github.com/cosmos/cosmos-sdk/x/consensus/types" + 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" @@ -34,6 +38,7 @@ import ( govkeeper "github.com/cosmos/cosmos-sdk/x/gov/keeper" govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" + govv1beta1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1" mintkeeper "github.com/cosmos/cosmos-sdk/x/mint/keeper" minttypes "github.com/cosmos/cosmos-sdk/x/mint/types" @@ -53,34 +58,33 @@ import ( upgradekeeper "github.com/cosmos/cosmos-sdk/x/upgrade/keeper" upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types" - "github.com/cosmos/ibc-go/v4/modules/apps/transfer" - ibctransferkeeper "github.com/cosmos/ibc-go/v4/modules/apps/transfer/keeper" - ibctransfertypes "github.com/cosmos/ibc-go/v4/modules/apps/transfer/types" - ibcclient "github.com/cosmos/ibc-go/v4/modules/core/02-client" - ibcclienttypes "github.com/cosmos/ibc-go/v4/modules/core/02-client/types" - porttypes "github.com/cosmos/ibc-go/v4/modules/core/05-port/types" - ibchost "github.com/cosmos/ibc-go/v4/modules/core/24-host" - ibckeeper "github.com/cosmos/ibc-go/v4/modules/core/keeper" + "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" + ibcclient "github.com/cosmos/ibc-go/v7/modules/core/02-client" + ibcclienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" + porttypes "github.com/cosmos/ibc-go/v7/modules/core/05-port/types" + ibckeeper "github.com/cosmos/ibc-go/v7/modules/core/keeper" - icahost "github.com/cosmos/ibc-go/v4/modules/apps/27-interchain-accounts/host" - icahostkeeper "github.com/cosmos/ibc-go/v4/modules/apps/27-interchain-accounts/host/keeper" - icahosttypes "github.com/cosmos/ibc-go/v4/modules/apps/27-interchain-accounts/host/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" - packetforward "github.com/strangelove-ventures/packet-forward-middleware/v4/router" - packetforwardkeeper "github.com/strangelove-ventures/packet-forward-middleware/v4/router/keeper" - packetforwardtypes "github.com/strangelove-ventures/packet-forward-middleware/v4/router/types" + packetforward "github.com/cosmos/ibc-apps/middleware/packet-forward-middleware/v7/router" + packetforwardkeeper "github.com/cosmos/ibc-apps/middleware/packet-forward-middleware/v7/router/keeper" + packetforwardtypes "github.com/cosmos/ibc-apps/middleware/packet-forward-middleware/v7/router/types" - allockeeper "github.com/OmniFlix/omniflixhub/x/alloc/keeper" - alloctypes "github.com/OmniFlix/omniflixhub/x/alloc/types" + allockeeper "github.com/OmniFlix/omniflixhub/v2/x/alloc/keeper" + alloctypes "github.com/OmniFlix/omniflixhub/v2/x/alloc/types" onftkeeper "github.com/OmniFlix/onft/keeper" onfttypes "github.com/OmniFlix/onft/types" - marketplacekeeper "github.com/OmniFlix/omniflixhub/x/marketplace/keeper" - marketplacetypes "github.com/OmniFlix/omniflixhub/x/marketplace/types" + marketplacekeeper "github.com/OmniFlix/omniflixhub/v2/x/marketplace/keeper" + marketplacetypes "github.com/OmniFlix/omniflixhub/v2/x/marketplace/types" - itckeeper "github.com/OmniFlix/omniflixhub/x/itc/keeper" - itctypes "github.com/OmniFlix/omniflixhub/x/itc/types" + itckeeper "github.com/OmniFlix/omniflixhub/v2/x/itc/keeper" + itctypes "github.com/OmniFlix/omniflixhub/v2/x/itc/types" streampaykeeper "github.com/OmniFlix/streampay/v2/x/streampay/keeper" streampaytypes "github.com/OmniFlix/streampay/v2/x/streampay/types" @@ -88,29 +92,30 @@ import ( type AppKeepers struct { // keys to access the substores - keys map[string]*sdk.KVStoreKey - tkeys map[string]*sdk.TransientStoreKey - memKeys map[string]*sdk.MemoryStoreKey + keys map[string]*storetypes.KVStoreKey + tkeys map[string]*storetypes.TransientStoreKey + memKeys map[string]*storetypes.MemoryStoreKey // keepers - AccountKeeper authkeeper.AccountKeeper - BankKeeper bankkeeper.Keeper - CapabilityKeeper *capabilitykeeper.Keeper - StakingKeeper stakingkeeper.Keeper - SlashingKeeper slashingkeeper.Keeper - MintKeeper mintkeeper.Keeper - DistrKeeper distrkeeper.Keeper - GovKeeper govkeeper.Keeper - CrisisKeeper crisiskeeper.Keeper - UpgradeKeeper upgradekeeper.Keeper - ParamsKeeper paramskeeper.Keeper - IBCKeeper *ibckeeper.Keeper // IBC Keeper must be a pointer in the app, so we can SetRouter on it correctly - ICAHostKeeper icahostkeeper.Keeper - EvidenceKeeper evidencekeeper.Keeper - TransferKeeper ibctransferkeeper.Keeper - PacketForwardKeeper *packetforwardkeeper.Keeper - FeeGrantKeeper feegrantkeeper.Keeper - AuthzKeeper authzkeeper.Keeper + AccountKeeper authkeeper.AccountKeeper + BankKeeper bankkeeper.Keeper + CapabilityKeeper *capabilitykeeper.Keeper + StakingKeeper *stakingkeeper.Keeper + SlashingKeeper slashingkeeper.Keeper + MintKeeper mintkeeper.Keeper + DistrKeeper distrkeeper.Keeper + GovKeeper govkeeper.Keeper + CrisisKeeper *crisiskeeper.Keeper + UpgradeKeeper *upgradekeeper.Keeper + ParamsKeeper paramskeeper.Keeper + IBCKeeper *ibckeeper.Keeper // IBC Keeper must be a pointer in the app, so we can SetRouter on it correctly + ICAHostKeeper icahostkeeper.Keeper + EvidenceKeeper evidencekeeper.Keeper + TransferKeeper ibctransferkeeper.Keeper + PacketForwardKeeper *packetforwardkeeper.Keeper + FeeGrantKeeper feegrantkeeper.Keeper + AuthzKeeper authzkeeper.Keeper + ConsensusParamsKeeper consensusparamkeeper.Keeper // make scoped keepers public for test purposes ScopedIBCKeeper capabilitykeeper.ScopedKeeper @@ -134,109 +139,124 @@ func NewAppKeeper( skipUpgradeHeights map[int64]bool, homePath string, invCheckPeriod uint, + logger log.Logger, appOpts servertypes.AppOptions, ) AppKeepers { appKeepers := AppKeepers{} // Set keys KVStoreKey, TransientStoreKey, MemoryStoreKey appKeepers.GenerateKeys() + keys := appKeepers.GetKVStoreKey() + tkeys := appKeepers.GetTransientStoreKey() /* configure state listening capabilities using AppOptions we are doing nothing with the returned streamingServices and waitGroup in this case */ - if _, _, err := streaming.LoadStreamingServices(bApp, appOpts, appCodec, appKeepers.keys); err != nil { + if _, _, err := streaming.LoadStreamingServices(bApp, appOpts, appCodec, logger, appKeepers.keys); err != nil { tmos.Exit(err.Error()) } appKeepers.ParamsKeeper = initParamsKeeper( appCodec, legacyAmino, - appKeepers.keys[paramstypes.StoreKey], - appKeepers.tkeys[paramstypes.TStoreKey], + keys[paramstypes.StoreKey], + tkeys[paramstypes.TStoreKey], ) + govModAddress := authtypes.NewModuleAddress(govtypes.ModuleName).String() + // set the BaseApp's parameter store - bApp.SetParamStore( - appKeepers.ParamsKeeper.Subspace(baseapp.Paramspace).WithKeyTable(paramskeeper.ConsensusParamsKeyTable()), + appKeepers.ConsensusParamsKeeper = consensusparamkeeper.NewKeeper( + appCodec, + keys[consensusparamtypes.StoreKey], + govModAddress, ) + bApp.SetParamStore(&appKeepers.ConsensusParamsKeeper) // add capability keeper and ScopeToModule for ibc module appKeepers.CapabilityKeeper = capabilitykeeper.NewKeeper(appCodec, appKeepers.keys[capabilitytypes.StoreKey], appKeepers.memKeys[capabilitytypes.MemStoreKey]) - appKeepers.ScopedIBCKeeper = appKeepers.CapabilityKeeper.ScopeToModule(ibchost.ModuleName) + appKeepers.ScopedIBCKeeper = appKeepers.CapabilityKeeper.ScopeToModule(ibcexported.ModuleName) appKeepers.ScopedTransferKeeper = appKeepers.CapabilityKeeper.ScopeToModule(ibctransfertypes.ModuleName) appKeepers.ScopedICAHostKeeper = appKeepers.CapabilityKeeper.ScopeToModule(icahosttypes.SubModuleName) appKeepers.CapabilityKeeper.Seal() appKeepers.CrisisKeeper = crisiskeeper.NewKeeper( - appKeepers.GetSubspace(crisistypes.ModuleName), + appCodec, + keys[crisistypes.StoreKey], invCheckPeriod, appKeepers.BankKeeper, authtypes.FeeCollectorName, + govModAddress, ) - + Bech32AccountAddrPrefix := "omniflix" appKeepers.AccountKeeper = authkeeper.NewAccountKeeper( appCodec, - appKeepers.keys[authtypes.StoreKey], - appKeepers.GetSubspace(authtypes.ModuleName), + keys[authtypes.StoreKey], authtypes.ProtoBaseAccount, maccPerms, + Bech32AccountAddrPrefix, + govModAddress, ) appKeepers.BankKeeper = bankkeeper.NewBaseKeeper( appCodec, - appKeepers.keys[banktypes.StoreKey], + keys[banktypes.StoreKey], appKeepers.AccountKeeper, - appKeepers.GetSubspace(banktypes.ModuleName), blockedAddress, + govModAddress, ) appKeepers.AuthzKeeper = authzkeeper.NewKeeper( - appKeepers.keys[authzkeeper.StoreKey], + keys[authzkeeper.StoreKey], appCodec, bApp.MsgServiceRouter(), + appKeepers.AccountKeeper, ) appKeepers.FeeGrantKeeper = feegrantkeeper.NewKeeper( appCodec, - appKeepers.keys[feegrant.StoreKey], + keys[feegrant.StoreKey], appKeepers.AccountKeeper, ) - stakingKeeper := stakingkeeper.NewKeeper( + appKeepers.StakingKeeper = stakingkeeper.NewKeeper( appCodec, - appKeepers.keys[stakingtypes.StoreKey], + keys[stakingtypes.StoreKey], appKeepers.AccountKeeper, appKeepers.BankKeeper, - appKeepers.GetSubspace(stakingtypes.ModuleName), + govModAddress, ) appKeepers.MintKeeper = mintkeeper.NewKeeper( appCodec, - appKeepers.keys[minttypes.StoreKey], - appKeepers.GetSubspace(minttypes.ModuleName), - &stakingKeeper, + keys[minttypes.StoreKey], + appKeepers.StakingKeeper, appKeepers.AccountKeeper, appKeepers.BankKeeper, authtypes.FeeCollectorName, + govModAddress, ) appKeepers.DistrKeeper = distrkeeper.NewKeeper( appCodec, - appKeepers.keys[distrtypes.StoreKey], - appKeepers.GetSubspace(distrtypes.ModuleName), + keys[distrtypes.StoreKey], appKeepers.AccountKeeper, appKeepers.BankKeeper, - &stakingKeeper, + appKeepers.StakingKeeper, authtypes.FeeCollectorName, - modAccAddrs, + govModAddress, ) appKeepers.SlashingKeeper = slashingkeeper.NewKeeper( appCodec, - appKeepers.keys[slashingtypes.StoreKey], - &stakingKeeper, - appKeepers.GetSubspace(slashingtypes.ModuleName), + legacyAmino, + keys[slashingtypes.StoreKey], + appKeepers.StakingKeeper, + govModAddress, ) // register the staking hooks // NOTE: stakingKeeper above is passed by reference, so that it will contain these hooks - appKeepers.StakingKeeper = *stakingKeeper.SetHooks( - stakingtypes.NewMultiStakingHooks(appKeepers.DistrKeeper.Hooks(), appKeepers.SlashingKeeper.Hooks()), + appKeepers.StakingKeeper.SetHooks( + stakingtypes.NewMultiStakingHooks( + appKeepers.DistrKeeper.Hooks(), + appKeepers.SlashingKeeper.Hooks(), + ), ) appKeepers.UpgradeKeeper = upgradekeeper.NewKeeper( @@ -245,27 +265,59 @@ func NewAppKeeper( appCodec, homePath, bApp, + govModAddress, ) // Create IBC Keeper appKeepers.IBCKeeper = ibckeeper.NewKeeper( appCodec, - appKeepers.keys[ibchost.StoreKey], - appKeepers.GetSubspace(ibchost.ModuleName), + appKeepers.keys[ibcexported.StoreKey], + appKeepers.GetSubspace(ibcexported.ModuleName), appKeepers.StakingKeeper, appKeepers.UpgradeKeeper, appKeepers.ScopedIBCKeeper, ) - // register the proposal types - govRouter := govtypes.NewRouter() + // Create evidence Keeper for to register the IBC light client misbehaviour evidence route + evidenceKeeper := evidencekeeper.NewKeeper( + appCodec, + keys[evidencetypes.StoreKey], + appKeepers.StakingKeeper, + appKeepers.SlashingKeeper, + ) + // If evidence needs to be handled for the app, set routes in router here and seal + appKeepers.EvidenceKeeper = *evidenceKeeper + + // Register the proposal types + // Deprecated: Avoid adding new handlers, instead use the new proposal flow + // 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, govtypes.ProposalHandler). + AddRoute(govtypes.RouterKey, govv1beta1.ProposalHandler). AddRoute(paramproposal.RouterKey, params.NewParamChangeProposalHandler(appKeepers.ParamsKeeper)). - AddRoute(distrtypes.RouterKey, distr.NewCommunityPoolSpendProposalHandler(appKeepers.DistrKeeper)). AddRoute(upgradetypes.RouterKey, upgrade.NewSoftwareUpgradeProposalHandler(appKeepers.UpgradeKeeper)). AddRoute(ibcclienttypes.RouterKey, ibcclient.NewClientProposalHandler(appKeepers.IBCKeeper.ClientKeeper)) + govConfig := govtypes.DefaultConfig() + + govKeeper := govkeeper.NewKeeper( + appCodec, + keys[govtypes.StoreKey], + appKeepers.AccountKeeper, + appKeepers.BankKeeper, + appKeepers.StakingKeeper, + bApp.MsgServiceRouter(), + govConfig, + govModAddress, + ) + + appKeepers.GovKeeper.SetLegacyRouter(govRouter) + appKeepers.GovKeeper = *govKeeper.SetHooks( + govtypes.NewMultiGovHooks( + // register the governance hooks + ), + ) // initialize ibc packet forwarding middleware router appKeepers.PacketForwardKeeper = packetforwardkeeper.NewKeeper( appCodec, appKeepers.keys[packetforwardtypes.StoreKey], @@ -296,6 +348,7 @@ func NewAppKeeper( appCodec, appKeepers.keys[icahosttypes.StoreKey], appKeepers.GetSubspace(icahosttypes.SubModuleName), + nil, appKeepers.IBCKeeper.ChannelKeeper, &appKeepers.IBCKeeper.PortKeeper, appKeepers.AccountKeeper, @@ -304,25 +357,6 @@ func NewAppKeeper( ) icaHostIBCModule := icahost.NewIBCModule(appKeepers.ICAHostKeeper) - // Create evidence Keeper for to register the IBC light client misbehaviour evidence route - evidenceKeeper := evidencekeeper.NewKeeper( - appCodec, - appKeepers.keys[evidencetypes.StoreKey], - &appKeepers.StakingKeeper, - appKeepers.SlashingKeeper, - ) - // If evidence needs to be handled for the app, set routes in router here and seal - appKeepers.EvidenceKeeper = *evidenceKeeper - - appKeepers.GovKeeper = govkeeper.NewKeeper( - appCodec, - appKeepers.keys[govtypes.StoreKey], - appKeepers.GetSubspace(govtypes.ModuleName), - appKeepers.AccountKeeper, - appKeepers.BankKeeper, - &stakingKeeper, - govRouter, - ) appKeepers.AllocKeeper = *allockeeper.NewKeeper( appCodec, appKeepers.keys[alloctypes.StoreKey], @@ -332,7 +366,7 @@ func NewAppKeeper( appKeepers.BankKeeper, appKeepers.StakingKeeper, appKeepers.DistrKeeper, - appKeepers.GetSubspace(alloctypes.ModuleName), + govModAddress, ) appKeepers.ONFTKeeper = onftkeeper.NewKeeper( @@ -341,7 +375,7 @@ func NewAppKeeper( appKeepers.AccountKeeper, appKeepers.BankKeeper, appKeepers.DistrKeeper, - appKeepers.GetSubspace(onfttypes.ModuleName), + govModAddress, ) appKeepers.MarketplaceKeeper = marketplacekeeper.NewKeeper( appCodec, @@ -350,7 +384,7 @@ func NewAppKeeper( appKeepers.BankKeeper, appKeepers.ONFTKeeper, appKeepers.DistrKeeper, - appKeepers.GetSubspace(marketplacetypes.ModuleName), + govModAddress, ) appKeepers.StreamPayKeeper = *streampaykeeper.NewKeeper( @@ -360,7 +394,7 @@ func NewAppKeeper( appKeepers.AccountKeeper, appKeepers.BankKeeper, appKeepers.DistrKeeper, - appKeepers.GetSubspace(streampaytypes.ModuleName), + govModAddress, ) appKeepers.ItcKeeper = itckeeper.NewKeeper( appCodec, @@ -370,7 +404,7 @@ func NewAppKeeper( appKeepers.ONFTKeeper, appKeepers.StreamPayKeeper, appKeepers.DistrKeeper, - appKeepers.GetSubspace(itctypes.ModuleName), + govModAddress, ) var ibcStack porttypes.IBCModule @@ -401,7 +435,7 @@ func (appKeepers *AppKeepers) GetSubspace(moduleName string) paramstypes.Subspac } // initParamsKeeper init params keeper and its subspaces -func initParamsKeeper(appCodec codec.BinaryCodec, legacyAmino *codec.LegacyAmino, key, tkey sdk.StoreKey) paramskeeper.Keeper { +func initParamsKeeper(appCodec codec.BinaryCodec, legacyAmino *codec.LegacyAmino, key, tkey storetypes.StoreKey) paramskeeper.Keeper { paramsKeeper := paramskeeper.NewKeeper(appCodec, legacyAmino, key, tkey) paramsKeeper.Subspace(authtypes.ModuleName) @@ -410,12 +444,12 @@ func initParamsKeeper(appCodec codec.BinaryCodec, legacyAmino *codec.LegacyAmino paramsKeeper.Subspace(minttypes.ModuleName) paramsKeeper.Subspace(distrtypes.ModuleName) paramsKeeper.Subspace(slashingtypes.ModuleName) - paramsKeeper.Subspace(govtypes.ModuleName).WithKeyTable(govtypes.ParamKeyTable()) + paramsKeeper.Subspace(govtypes.ModuleName) paramsKeeper.Subspace(crisistypes.ModuleName) paramsKeeper.Subspace(ibctransfertypes.ModuleName) - paramsKeeper.Subspace(ibchost.ModuleName) + paramsKeeper.Subspace(ibcexported.ModuleName) paramsKeeper.Subspace(icahosttypes.SubModuleName) - paramsKeeper.Subspace(packetforwardtypes.ModuleName).WithKeyTable(packetforwardtypes.ParamKeyTable()) + paramsKeeper.Subspace(packetforwardtypes.ModuleName) paramsKeeper.Subspace(alloctypes.ModuleName) paramsKeeper.Subspace(onfttypes.ModuleName) paramsKeeper.Subspace(marketplacetypes.ModuleName) diff --git a/app/keepers/keys.go b/app/keepers/keys.go index cc9491a7..7ab61e72 100644 --- a/app/keepers/keys.go +++ b/app/keepers/keys.go @@ -1,9 +1,9 @@ package keepers import ( - alloctypes "github.com/OmniFlix/omniflixhub/x/alloc/types" - itctypes "github.com/OmniFlix/omniflixhub/x/itc/types" - marketplacetypes "github.com/OmniFlix/omniflixhub/x/marketplace/types" + alloctypes "github.com/OmniFlix/omniflixhub/v2/x/alloc/types" + itctypes "github.com/OmniFlix/omniflixhub/v2/x/itc/types" + marketplacetypes "github.com/OmniFlix/omniflixhub/v2/x/marketplace/types" onfttypes "github.com/OmniFlix/onft/types" streampaytypes "github.com/OmniFlix/streampay/v2/x/streampay/types" storetypes "github.com/cosmos/cosmos-sdk/store/types" @@ -12,6 +12,8 @@ import ( authzkeeper "github.com/cosmos/cosmos-sdk/x/authz/keeper" 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" @@ -21,10 +23,10 @@ import ( 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" - icahosttypes "github.com/cosmos/ibc-go/v4/modules/apps/27-interchain-accounts/host/types" - ibctransfertypes "github.com/cosmos/ibc-go/v4/modules/apps/transfer/types" - ibchost "github.com/cosmos/ibc-go/v4/modules/core/24-host" - packetforwardtypes "github.com/strangelove-ventures/packet-forward-middleware/v4/router/types" + packetforwardtypes "github.com/cosmos/ibc-apps/middleware/packet-forward-middleware/v7/router/types" + icahosttypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/host/types" + ibctransfertypes "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types" + ibcexported "github.com/cosmos/ibc-go/v7/modules/core/exported" ) func (appKeepers *AppKeepers) GenerateKeys() { @@ -37,13 +39,15 @@ func (appKeepers *AppKeepers) GenerateKeys() { slashingtypes.StoreKey, govtypes.StoreKey, paramstypes.StoreKey, - ibchost.StoreKey, + consensusparamtypes.StoreKey, + ibcexported.StoreKey, upgradetypes.StoreKey, evidencetypes.StoreKey, ibctransfertypes.StoreKey, icahosttypes.StoreKey, packetforwardtypes.StoreKey, capabilitytypes.StoreKey, + crisistypes.StoreKey, feegrant.StoreKey, authzkeeper.StoreKey, alloctypes.StoreKey, diff --git a/app/modules.go b/app/modules.go index aa440706..7f4dd3a4 100644 --- a/app/modules.go +++ b/app/modules.go @@ -1,12 +1,13 @@ package app import ( - appparams "github.com/OmniFlix/omniflixhub/app/params" + appparams "github.com/OmniFlix/omniflixhub/v2/app/params" "github.com/cosmos/cosmos-sdk/types/module" - "github.com/cosmos/cosmos-sdk/x/auth" authsims "github.com/cosmos/cosmos-sdk/x/auth/simulation" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" + "github.com/cosmos/cosmos-sdk/x/consensus" + consensusparamtypes "github.com/cosmos/cosmos-sdk/x/consensus/types" "github.com/cosmos/cosmos-sdk/x/auth/vesting" vestingtypes "github.com/cosmos/cosmos-sdk/x/auth/vesting/types" @@ -53,28 +54,28 @@ import ( "github.com/cosmos/cosmos-sdk/x/upgrade" upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types" - ibctransfertypes "github.com/cosmos/ibc-go/v4/modules/apps/transfer/types" - ibc "github.com/cosmos/ibc-go/v4/modules/core" - ibchost "github.com/cosmos/ibc-go/v4/modules/core/24-host" + ibctransfertypes "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types" + ibc "github.com/cosmos/ibc-go/v7/modules/core" + ibcexported "github.com/cosmos/ibc-go/v7/modules/core/exported" - ica "github.com/cosmos/ibc-go/v4/modules/apps/27-interchain-accounts" - icatypes "github.com/cosmos/ibc-go/v4/modules/apps/27-interchain-accounts/types" - "github.com/cosmos/ibc-go/v4/modules/apps/transfer" + ica "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts" + icatypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/types" + "github.com/cosmos/ibc-go/v7/modules/apps/transfer" - packetforward "github.com/strangelove-ventures/packet-forward-middleware/v4/router" - packetforwardtypes "github.com/strangelove-ventures/packet-forward-middleware/v4/router/types" + packetforward "github.com/cosmos/ibc-apps/middleware/packet-forward-middleware/v7/router" + packetforwardtypes "github.com/cosmos/ibc-apps/middleware/packet-forward-middleware/v7/router/types" - "github.com/OmniFlix/omniflixhub/x/alloc" - alloctypes "github.com/OmniFlix/omniflixhub/x/alloc/types" + "github.com/OmniFlix/omniflixhub/v2/x/alloc" + alloctypes "github.com/OmniFlix/omniflixhub/v2/x/alloc/types" "github.com/OmniFlix/onft" onfttypes "github.com/OmniFlix/onft/types" - "github.com/OmniFlix/omniflixhub/x/marketplace" - marketplacetypes "github.com/OmniFlix/omniflixhub/x/marketplace/types" + "github.com/OmniFlix/omniflixhub/v2/x/marketplace" + marketplacetypes "github.com/OmniFlix/omniflixhub/v2/x/marketplace/types" - "github.com/OmniFlix/omniflixhub/x/itc" - itctypes "github.com/OmniFlix/omniflixhub/x/itc/types" + "github.com/OmniFlix/omniflixhub/v2/x/itc" + itctypes "github.com/OmniFlix/omniflixhub/v2/x/itc/types" "github.com/OmniFlix/streampay/v2/x/streampay" streampaytypes "github.com/OmniFlix/streampay/v2/x/streampay/types" @@ -92,8 +93,9 @@ var ( staking.AppModuleBasic{}, mint.AppModuleBasic{}, distr.AppModuleBasic{}, - gov.NewAppModuleBasic(getGovProposalHandlers()...), + gov.NewAppModuleBasic(getGovProposalHandlers()), params.AppModuleBasic{}, + consensus.AppModuleBasic{}, crisis.AppModuleBasic{}, slashing.AppModuleBasic{}, ibc.AppModuleBasic{}, @@ -143,30 +145,64 @@ func appModules( app.AccountKeeper, app.StakingKeeper, app.BaseApp.DeliverTx, encodingConfig.TxConfig, ), - auth.NewAppModule(appCodec, app.AccountKeeper, nil), + auth.NewAppModule(appCodec, app.AccountKeeper, nil, app.GetSubspace(authtypes.ModuleName)), vesting.NewAppModule(app.AccountKeeper, app.BankKeeper), - bank.NewAppModule(appCodec, app.BankKeeper, app.AccountKeeper), - capability.NewAppModule(appCodec, *app.CapabilityKeeper), - crisis.NewAppModule(&app.CrisisKeeper, skipGenesisInvariants), - gov.NewAppModule(appCodec, app.GovKeeper, app.AccountKeeper, app.BankKeeper), - mint.NewAppModule(appCodec, app.MintKeeper, app.AccountKeeper), - slashing.NewAppModule(appCodec, app.SlashingKeeper, app.AccountKeeper, app.BankKeeper, app.StakingKeeper), - distr.NewAppModule(appCodec, app.DistrKeeper, app.AccountKeeper, app.BankKeeper, app.StakingKeeper), - staking.NewAppModule(appCodec, app.StakingKeeper, app.AccountKeeper, app.BankKeeper), + bank.NewAppModule(appCodec, app.BankKeeper, app.AccountKeeper, app.GetSubspace(banktypes.ModuleName)), + capability.NewAppModule(appCodec, *app.CapabilityKeeper, false), + crisis.NewAppModule(app.CrisisKeeper, skipGenesisInvariants, app.GetSubspace(crisistypes.ModuleName)), + gov.NewAppModule( + appCodec, + &app.GovKeeper, + app.AccountKeeper, + app.BankKeeper, + app.GetSubspace(govtypes.ModuleName), + ), + mint.NewAppModule(appCodec, app.MintKeeper, app.AccountKeeper, nil, app.GetSubspace(minttypes.ModuleName)), + slashing.NewAppModule( + appCodec, + app.SlashingKeeper, + app.AccountKeeper, + app.BankKeeper, + app.StakingKeeper, + app.GetSubspace(slashingtypes.ModuleName), + ), + 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), + ), feegrantmodule.NewAppModule(appCodec, app.AccountKeeper, app.BankKeeper, app.FeeGrantKeeper, app.interfaceRegistry), authzmodule.NewAppModule(appCodec, app.AuthzKeeper, app.AccountKeeper, app.BankKeeper, app.interfaceRegistry), upgrade.NewAppModule(app.UpgradeKeeper), evidence.NewAppModule(app.EvidenceKeeper), ibc.NewAppModule(app.IBCKeeper), params.NewAppModule(app.ParamsKeeper), + consensus.NewAppModule(appCodec, app.ConsensusParamsKeeper), transfer.NewAppModule(app.TransferKeeper), ica.NewAppModule(nil, &app.ICAHostKeeper), packetforward.NewAppModule(app.PacketForwardKeeper), - alloc.NewAppModule(appCodec, app.AllocKeeper), - onft.NewAppModule(appCodec, app.ONFTKeeper, app.AccountKeeper, app.BankKeeper, app.DistrKeeper), - marketplace.NewAppModule(appCodec, app.MarketplaceKeeper), - streampay.NewAppModule(appCodec, app.StreamPayKeeper), - itc.NewAppModule(appCodec, app.ItcKeeper), + alloc.NewAppModule(appCodec, app.AllocKeeper, app.GetSubspace(alloctypes.ModuleName)), + onft.NewAppModule( + appCodec, + app.ONFTKeeper, + app.AccountKeeper, + app.BankKeeper, + app.DistrKeeper, + app.GetSubspace(onfttypes.ModuleName), + ), + marketplace.NewAppModule(appCodec, app.MarketplaceKeeper, app.GetSubspace(marketplacetypes.ModuleName)), + streampay.NewAppModule(appCodec, app.StreamPayKeeper, app.GetSubspace(streampaytypes.ModuleName)), + itc.NewAppModule(appCodec, app.ItcKeeper, app.GetSubspace(itctypes.ModuleName)), } } @@ -180,16 +216,21 @@ func simulationModules( appCodec := encodingConfig.Marshaler return []module.AppModuleSimulation{ - auth.NewAppModule(appCodec, app.AccountKeeper, authsims.RandomGenesisAccounts), - bank.NewAppModule(appCodec, app.BankKeeper, app.AccountKeeper), - capability.NewAppModule(appCodec, *app.CapabilityKeeper), + auth.NewAppModule( + appCodec, + app.AccountKeeper, + authsims.RandomGenesisAccounts, + app.GetSubspace(authtypes.ModuleName), + ), + 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), authzmodule.NewAppModule(appCodec, app.AuthzKeeper, app.AccountKeeper, app.BankKeeper, app.interfaceRegistry), - gov.NewAppModule(appCodec, app.GovKeeper, app.AccountKeeper, app.BankKeeper), - mint.NewAppModule(appCodec, app.MintKeeper, app.AccountKeeper), - staking.NewAppModule(appCodec, app.StakingKeeper, app.AccountKeeper, app.BankKeeper), - distr.NewAppModule(appCodec, app.DistrKeeper, app.AccountKeeper, app.BankKeeper, app.StakingKeeper), - slashing.NewAppModule(appCodec, app.SlashingKeeper, app.AccountKeeper, app.BankKeeper, app.StakingKeeper), + gov.NewAppModule(appCodec, &app.GovKeeper, app.AccountKeeper, app.BankKeeper, app.GetSubspace(govtypes.ModuleName)), + mint.NewAppModule(appCodec, app.MintKeeper, app.AccountKeeper, nil, 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), evidence.NewAppModule(app.EvidenceKeeper), ibc.NewAppModule(app.IBCKeeper), @@ -217,11 +258,12 @@ func orderBeginBlockers() []string { slashingtypes.ModuleName, evidencetypes.ModuleName, stakingtypes.ModuleName, - ibchost.ModuleName, + ibcexported.ModuleName, vestingtypes.ModuleName, banktypes.ModuleName, govtypes.ModuleName, paramstypes.ModuleName, + consensusparamtypes.ModuleName, ibctransfertypes.ModuleName, icatypes.ModuleName, packetforwardtypes.ModuleName, @@ -250,13 +292,14 @@ func orderEndBlockers() []string { authtypes.ModuleName, vestingtypes.ModuleName, paramstypes.ModuleName, + consensusparamtypes.ModuleName, ibctransfertypes.ModuleName, icatypes.ModuleName, packetforwardtypes.ModuleName, minttypes.ModuleName, slashingtypes.ModuleName, distrtypes.ModuleName, - ibchost.ModuleName, + ibcexported.ModuleName, feegrant.ModuleName, authz.ModuleName, alloctypes.ModuleName, @@ -291,10 +334,11 @@ func orderInitGenesis() []string { evidencetypes.ModuleName, authz.ModuleName, paramstypes.ModuleName, + consensusparamtypes.ModuleName, upgradetypes.ModuleName, vestingtypes.ModuleName, feegrant.ModuleName, - ibchost.ModuleName, + ibcexported.ModuleName, ibctransfertypes.ModuleName, icatypes.ModuleName, packetforwardtypes.ModuleName, diff --git a/app/test_helpers.go b/app/test_helpers.go index 4b0ac6e0..3d68c1a5 100644 --- a/app/test_helpers.go +++ b/app/test_helpers.go @@ -2,26 +2,33 @@ package app import ( "encoding/json" + "path/filepath" "testing" "time" - apphelpers "github.com/OmniFlix/omniflixhub/app/helpers" - appparams "github.com/OmniFlix/omniflixhub/app/params" + "github.com/cosmos/cosmos-sdk/client/flags" + "github.com/cosmos/cosmos-sdk/snapshots" + + apphelpers "github.com/OmniFlix/omniflixhub/v2/app/helpers" + appparams "github.com/OmniFlix/omniflixhub/v2/app/params" + dbm "github.com/cometbft/cometbft-db" + abci "github.com/cometbft/cometbft/abci/types" + "github.com/cometbft/cometbft/crypto" + "github.com/cometbft/cometbft/crypto/ed25519" + "github.com/cometbft/cometbft/libs/log" + tmproto "github.com/cometbft/cometbft/proto/tendermint/types" + tmtypes "github.com/cometbft/cometbft/types" + baseApp "github.com/cosmos/cosmos-sdk/baseapp" codectypes "github.com/cosmos/cosmos-sdk/codec/types" cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" "github.com/cosmos/cosmos-sdk/crypto/keys/secp256k1" + snapshottypes "github.com/cosmos/cosmos-sdk/snapshots/types" + simtestutil "github.com/cosmos/cosmos-sdk/testutil/sims" sdk "github.com/cosmos/cosmos-sdk/types" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" "github.com/stretchr/testify/require" - abci "github.com/tendermint/tendermint/abci/types" - "github.com/tendermint/tendermint/crypto" - "github.com/tendermint/tendermint/crypto/ed25519" - "github.com/tendermint/tendermint/libs/log" - tmproto "github.com/tendermint/tendermint/proto/tendermint/types" - tmtypes "github.com/tendermint/tendermint/types" - dbm "github.com/tendermint/tm-db" ) // SimAppChainID hardcoded chainID for simulation @@ -38,8 +45,8 @@ func (ao EmptyBaseAppOptions) Get(_ string) interface{} { } // DefaultConsensusParams defines the default Tendermint consensus params used in OmniFlixApp testing. -var DefaultConsensusParams = &abci.ConsensusParams{ - Block: &abci.BlockParams{ +var DefaultConsensusParams = &tmproto.ConsensusParams{ + Block: &tmproto.BlockParams{ MaxBytes: 200000, MaxGas: 2000000, }, @@ -59,7 +66,7 @@ type EmptyAppOptions struct{} func (EmptyAppOptions) Get(_ string) interface{} { return nil } -func Setup(t *testing.T, _ bool, _ uint) *OmniFlixApp { +func Setup(t *testing.T) *OmniFlixApp { t.Helper() privVal := apphelpers.NewPV() @@ -94,7 +101,7 @@ func SetupWithGenesisValSet( ) *OmniFlixApp { t.Helper() - omniflixTestApp, genesisState := setup(true, 5) + omniflixTestApp, genesisState := setup(t, true) genesisState = genesisStateWithValSet(t, omniflixTestApp, genesisState, valSet, genAccs, balances...) stateBytes, err := json.MarshalIndent(genesisState, "", " ") @@ -103,27 +110,45 @@ func SetupWithGenesisValSet( // init chain will set the validator set and initialize the genesis accounts omniflixTestApp.InitChain( abci.RequestInitChain{ + ChainId: SimAppChainID, Validators: []abci.ValidatorUpdate{}, ConsensusParams: DefaultConsensusParams, AppStateBytes: stateBytes, + Time: time.Now().UTC(), + InitialHeight: 1, }, ) // commit genesis changes omniflixTestApp.Commit() omniflixTestApp.BeginBlock(abci.RequestBeginBlock{Header: tmproto.Header{ + ChainID: SimAppChainID, Height: omniflixTestApp.LastBlockHeight() + 1, AppHash: omniflixTestApp.LastCommitID().Hash, ValidatorsHash: valSet.Hash(), NextValidatorsHash: valSet.Hash(), + Time: time.Now().UTC(), }}) return omniflixTestApp } -func setup(withGenesis bool, invCheckPeriod uint) (*OmniFlixApp, GenesisState) { +func setup(t *testing.T, withGenesis bool) (*OmniFlixApp, GenesisState) { + t.Helper() + db := dbm.NewMemDB() + nodeHome := t.TempDir() encCdc := MakeEncodingConfig() + snapshotDir := filepath.Join(nodeHome, "data", "snapshots") + + snapshotDB, err := dbm.NewDB("metadata", dbm.GoLevelDBBackend, snapshotDir) + require.NoError(t, err) + t.Cleanup(func() { snapshotDB.Close() }) + snapshotStore, err := snapshots.NewStore(snapshotDB, snapshotDir) + require.NoError(t, err) + + appOptions := make(simtestutil.AppOptionsMap, 0) + appOptions[flags.FlagHome] = nodeHome // ensure unique folder app := NewOmniFlixApp( log.NewNopLogger(), @@ -132,9 +157,11 @@ func setup(withGenesis bool, invCheckPeriod uint) (*OmniFlixApp, GenesisState) { true, map[int64]bool{}, DefaultNodeHome, - invCheckPeriod, + 0, encCdc, - EmptyBaseAppOptions{}, + appOptions, + baseApp.SetChainID(SimAppChainID), + baseApp.SetSnapshot(snapshotStore, snapshottypes.SnapshotOptions{KeepRecent: 2}), ) if withGenesis { return app, NewDefaultGenesisState(encCdc.Marshaler) @@ -191,6 +218,7 @@ func genesisStateWithValSet( defaultStParams.MaxEntries, defaultStParams.HistoricalEntries, appparams.BondDenom, + defaultStParams.MinCommissionRate, ) // set validators and delegations @@ -220,6 +248,7 @@ func genesisStateWithValSet( balances, totalSupply, []banktypes.Metadata{}, + []banktypes.SendEnabled{}, ) genesisState[banktypes.ModuleName] = app.AppCodec().MustMarshalJSON(bankGenesis) diff --git a/app/upgrades/types.go b/app/upgrades/types.go index 251c63cc..a3c6e4d4 100644 --- a/app/upgrades/types.go +++ b/app/upgrades/types.go @@ -1,20 +1,20 @@ package upgrades import ( + tmproto "github.com/cometbft/cometbft/proto/tendermint/types" store "github.com/cosmos/cosmos-sdk/store/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types" - abci "github.com/tendermint/tendermint/abci/types" - "github.com/OmniFlix/omniflixhub/app/keepers" + "github.com/OmniFlix/omniflixhub/v2/app/keepers" ) // BaseAppParamManager defines an interface that BaseApp is expected to full-fill, // that allows upgrade handlers to modify BaseApp parameters. type BaseAppParamManager interface { - GetConsensusParams(ctx sdk.Context) *abci.ConsensusParams - StoreConsensusParams(ctx sdk.Context, cp *abci.ConsensusParams) + GetConsensusParams(ctx sdk.Context) *tmproto.ConsensusParams + StoreConsensusParams(ctx sdk.Context, cp *tmproto.ConsensusParams) } // Upgrade defines a struct containing necessary fields that a SoftwareUpgradeProposal diff --git a/app/upgrades/v012/constants.go b/app/upgrades/v012/constants.go index 8d0101d2..12e7ae18 100644 --- a/app/upgrades/v012/constants.go +++ b/app/upgrades/v012/constants.go @@ -1,17 +1,17 @@ package v012 import ( - "github.com/OmniFlix/omniflixhub/app/upgrades" + "github.com/OmniFlix/omniflixhub/v2/app/upgrades" store "github.com/cosmos/cosmos-sdk/store/types" - icahosttypes "github.com/cosmos/ibc-go/v4/modules/apps/27-interchain-accounts/host/types" - packetforwardtypes "github.com/strangelove-ventures/packet-forward-middleware/v4/router/types" + packetforwardtypes "github.com/cosmos/ibc-apps/middleware/packet-forward-middleware/v7/router/types" + icahosttypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/host/types" ) const UpgradeName = "v0.12.x" var Upgrade = upgrades.Upgrade{ UpgradeName: UpgradeName, - CreateUpgradeHandler: CreateUpgradeHandler, + CreateUpgradeHandler: CreateV012UpgradeHandler, StoreUpgrades: store.StoreUpgrades{ Added: []string{icahosttypes.StoreKey, packetforwardtypes.StoreKey}, }, diff --git a/app/upgrades/v012/upgrades.go b/app/upgrades/v012/upgrades.go index 1bcaf9cd..34f81db8 100644 --- a/app/upgrades/v012/upgrades.go +++ b/app/upgrades/v012/upgrades.go @@ -1,20 +1,20 @@ package v012 import ( - "github.com/OmniFlix/omniflixhub/app/keepers" - "github.com/OmniFlix/omniflixhub/app/upgrades" + "github.com/OmniFlix/omniflixhub/v2/app/keepers" + "github.com/OmniFlix/omniflixhub/v2/app/upgrades" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" distrtypes "github.com/cosmos/cosmos-sdk/x/distribution/types" - govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" + govv1beta1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types" - icahosttypes "github.com/cosmos/ibc-go/v4/modules/apps/27-interchain-accounts/host/types" - packetforwardtypes "github.com/strangelove-ventures/packet-forward-middleware/v4/router/types" + packetforwardtypes "github.com/cosmos/ibc-apps/middleware/packet-forward-middleware/v7/router/types" + icahosttypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/host/types" ) -func CreateUpgradeHandler( +func CreateV012UpgradeHandler( mm *module.Manager, cfg module.Configurator, bpm upgrades.BaseAppParamManager, @@ -43,7 +43,7 @@ func CreateUpgradeHandler( sdk.MsgTypeURL(&distrtypes.MsgWithdrawValidatorCommission{}), sdk.MsgTypeURL(&distrtypes.MsgSetWithdrawAddress{}), sdk.MsgTypeURL(&distrtypes.MsgFundCommunityPool{}), - sdk.MsgTypeURL(&govtypes.MsgVote{}), + sdk.MsgTypeURL(&govv1beta1.MsgVote{}), }, } diff --git a/app/upgrades/v2/constants.go b/app/upgrades/v2/constants.go new file mode 100644 index 00000000..c9e421e8 --- /dev/null +++ b/app/upgrades/v2/constants.go @@ -0,0 +1,21 @@ +package v2 + +import ( + "github.com/OmniFlix/omniflixhub/v2/app/upgrades" + store "github.com/cosmos/cosmos-sdk/store/types" + consensustypes "github.com/cosmos/cosmos-sdk/x/consensus/types" + crisistypes "github.com/cosmos/cosmos-sdk/x/crisis/types" +) + +const UpgradeName = "v2" + +var Upgrade = upgrades.Upgrade{ + UpgradeName: UpgradeName, + CreateUpgradeHandler: CreateV2UpgradeHandler, + StoreUpgrades: store.StoreUpgrades{ + Added: []string{ + consensustypes.ModuleName, + crisistypes.ModuleName, + }, + }, +} diff --git a/app/upgrades/v2/upgrades.go b/app/upgrades/v2/upgrades.go new file mode 100644 index 00000000..f744ff8a --- /dev/null +++ b/app/upgrades/v2/upgrades.go @@ -0,0 +1,124 @@ +package v2 + +import ( + "github.com/OmniFlix/omniflixhub/v2/app/keepers" + "github.com/OmniFlix/omniflixhub/v2/app/upgrades" + alloctypes "github.com/OmniFlix/omniflixhub/v2/x/alloc/types" + itctypes "github.com/OmniFlix/omniflixhub/v2/x/itc/types" + marketplacetypes "github.com/OmniFlix/omniflixhub/v2/x/marketplace/types" + onfttypes "github.com/OmniFlix/onft/types" + streampaytypes "github.com/OmniFlix/streampay/v2/x/streampay/types" + "github.com/cosmos/cosmos-sdk/baseapp" + sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/cosmos/cosmos-sdk/types/module" + authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" + banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" + crisistypes "github.com/cosmos/cosmos-sdk/x/crisis/types" + distrtypes "github.com/cosmos/cosmos-sdk/x/distribution/types" + govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" + govv1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1" + minttypes "github.com/cosmos/cosmos-sdk/x/mint/types" + 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" + icahosttypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/host/types" + ibctransfertypes "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types" + "github.com/cosmos/ibc-go/v7/modules/core/exported" +) + +func CreateV2UpgradeHandler( + mm *module.Manager, + cfg module.Configurator, + bpm upgrades.BaseAppParamManager, + keepers *keepers.AppKeepers, +) upgradetypes.UpgradeHandler { + return func(ctx sdk.Context, plan upgradetypes.Plan, fromVM module.VersionMap) (module.VersionMap, error) { + ctx.Logger().Info("running migrations ...") + + // https://github.com/cosmos/cosmos-sdk/pull/12363/files + // Set param key table for params module migration + for _, subspace := range keepers.ParamsKeeper.GetSubspaces() { + subspace := subspace + + var keyTable paramstypes.KeyTable + switch subspace.Name() { + case authtypes.ModuleName: + keyTable = authtypes.ParamKeyTable() //nolint:staticcheck + case banktypes.ModuleName: + keyTable = banktypes.ParamKeyTable() //nolint:staticcheck + case stakingtypes.ModuleName: + keyTable = stakingtypes.ParamKeyTable() + case minttypes.ModuleName: + keyTable = minttypes.ParamKeyTable() //nolint:staticcheck + case distrtypes.ModuleName: + keyTable = distrtypes.ParamKeyTable() //nolint:staticcheck + case slashingtypes.ModuleName: + keyTable = slashingtypes.ParamKeyTable() //nolint:staticcheck + case govtypes.ModuleName: + keyTable = govv1.ParamKeyTable() //nolint:staticcheck + case crisistypes.ModuleName: + keyTable = crisistypes.ParamKeyTable() //nolint:staticcheck + + // ibc types + case ibctransfertypes.ModuleName: + keyTable = ibctransfertypes.ParamKeyTable() + case icahosttypes.SubModuleName: + keyTable = icahosttypes.ParamKeyTable() + + // omniflix + case alloctypes.ModuleName: + keyTable = alloctypes.ParamKeyTable() + case onfttypes.ModuleName: + keyTable = onfttypes.ParamKeyTable() + case marketplacetypes.ModuleName: + keyTable = marketplacetypes.ParamKeyTable() + case itctypes.ModuleName: + keyTable = itctypes.ParamKeyTable() + case streampaytypes.ModuleName: + keyTable = streampaytypes.ParamKeyTable() + default: + continue + } + + if !subspace.HasKeyTable() { + subspace.WithKeyTable(keyTable) + } + } + + // Migrate Tendermint consensus parameters from x/params module to a deprecated x/consensus module. + // The old params module is required to still be imported in your app.go in order to handle this migration. + baseAppLegacySS := keepers.ParamsKeeper.Subspace(baseapp.Paramspace).WithKeyTable(paramstypes.ConsensusParamsKeyTable()) + baseapp.MigrateParams(ctx, baseAppLegacySS, &keepers.ConsensusParamsKeeper) + + // Run migrations before applying any other state changes. + // NOTE: DO NOT PUT ANY STATE CHANGES BEFORE RunMigrations(). + versionMap, err := mm.RunMigrations(ctx, cfg, fromVM) + if err != nil { + return nil, err + } + + // explicitly update the IBC 02-client params, adding the localhost client type + params := keepers.IBCKeeper.ClientKeeper.GetParams(ctx) + params.AllowedClients = append(params.AllowedClients, exported.Localhost) + keepers.IBCKeeper.ClientKeeper.SetParams(ctx, params) + + // set proposal's minimum initial deposit to 20% + govParams := keepers.GovKeeper.GetParams(ctx) + govParams.MinInitialDepositRatio = sdk.NewDec(20).Quo(sdk.NewDec(100)).String() + if err := keepers.GovKeeper.SetParams(ctx, govParams); err != nil { + return nil, err + } + + // set validator's minimum commission to 5% + stakingParams := keepers.StakingKeeper.GetParams(ctx) + stakingParams.MinCommissionRate = sdk.NewDecWithPrec(5, 2) + err = keepers.StakingKeeper.SetParams(ctx, stakingParams) + if err != nil { + return nil, err + } + + ctx.Logger().Info("Upgrade complete") + return versionMap, nil + } +} diff --git a/cmd/omniflixhubd/cmd/bech32_convert.go b/cmd/omniflixhubd/cmd/bech32_convert.go new file mode 100644 index 00000000..1ff087e2 --- /dev/null +++ b/cmd/omniflixhubd/cmd/bech32_convert.go @@ -0,0 +1,67 @@ +package cmd + +import ( + "fmt" + + "github.com/cosmos/cosmos-sdk/types/bech32" + + "github.com/spf13/cobra" +) + +var flagBech32Prefix = "prefix" + +// AddBech32ConvertCommand returns bech32-convert cobra Command. +func AddBech32ConvertCommand() *cobra.Command { + cmd := &cobra.Command{ + Use: "bech32-convert [address]", + Short: "Convert any bech32 string to the omniflix prefix", + Long: `Convert any bech32 string to the omniflix prefix + +Example: + omniflixhubd debug bech32-convert juno1a6zlyvpnksx8wr6wz8wemur2xe8zyh0yst53ep + + omniflixhubd debug bech32-convert cosmos1673f0t8p893rqyqe420mgwwz92ac4qv6n0nsjx --prefix omniflix + `, + Args: cobra.ExactArgs(1), + RunE: func(cmd *cobra.Command, args []string) error { + bech32prefix, err := cmd.Flags().GetString(flagBech32Prefix) + if err != nil { + return err + } + + address := args[0] + convertedAddress, err := ConvertBech32Prefix(address, bech32prefix) + if err != nil { + return fmt.Errorf("convertation failed: %s", err) + } + + cmd.Println(convertedAddress) + + return nil + }, + } + + cmd.Flags().StringP(flagBech32Prefix, "p", "cosmos", "Bech32 Prefix to encode to") + + return cmd +} + +func ConvertBech32Prefix(address, prefix string) (string, error) { + _, bz, err := bech32.DecodeAndConvert(address) + if err != nil { + return "", fmt.Errorf("cannot decode %s address: %s", address, err) + } + + convertedAddress, err := bech32.ConvertAndEncode(prefix, bz) + if err != nil { + return "", fmt.Errorf("cannot convert %s address: %s", address, err) + } + + return convertedAddress, nil +} + +// addDebugCommands adds the custom debug commands to the application. +func addDebugCommands(cmd *cobra.Command) *cobra.Command { + cmd.AddCommand(AddBech32ConvertCommand()) + return cmd +} diff --git a/cmd/omniflixhubd/cmd/genaccounts.go b/cmd/omniflixhubd/cmd/genaccounts.go deleted file mode 100644 index 97fcd564..00000000 --- a/cmd/omniflixhubd/cmd/genaccounts.go +++ /dev/null @@ -1,191 +0,0 @@ -package cmd - -import ( - "bufio" - "encoding/json" - "errors" - "fmt" - - "github.com/spf13/cobra" - - "github.com/cosmos/cosmos-sdk/client" - "github.com/cosmos/cosmos-sdk/client/flags" - "github.com/cosmos/cosmos-sdk/crypto/keyring" - "github.com/cosmos/cosmos-sdk/server" - sdk "github.com/cosmos/cosmos-sdk/types" - authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" - authvesting "github.com/cosmos/cosmos-sdk/x/auth/vesting/types" - banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" - "github.com/cosmos/cosmos-sdk/x/genutil" - genutiltypes "github.com/cosmos/cosmos-sdk/x/genutil/types" -) - -const ( - flagVestingStart = "vesting-start-time" - flagVestingEnd = "vesting-end-time" - flagVestingAmt = "vesting-amount" -) - -// AddGenesisAccountCmd returns add-genesis-account cobra Command. -func AddGenesisAccountCmd(defaultNodeHome string) *cobra.Command { - cmd := &cobra.Command{ - Use: "add-genesis-account [address_or_key_name] [coin][,[coin]]", - Short: "Add a genesis account to genesis.json", - Long: `Add a genesis account to genesis.json. The provided account must specify -the account address or key name and a list of initial coins. If a key name is given, -the address will be looked up in the local Keybase. The list of initial tokens must -contain valid denominations. Accounts may optionally be supplied with vesting parameters. -`, - Args: cobra.ExactArgs(2), - RunE: func(cmd *cobra.Command, args []string) error { - clientCtx := client.GetClientContextFromCmd(cmd) - depCdc := clientCtx.Codec - cdc := depCdc - - serverCtx := server.GetServerContextFromCmd(cmd) - config := serverCtx.Config - - config.SetRoot(clientCtx.HomeDir) - - coins, err := sdk.ParseCoinsNormalized(args[1]) - if err != nil { - return fmt.Errorf("failed to parse coins: %w", err) - } - - addr, err := sdk.AccAddressFromBech32(args[0]) - if err != nil { - inBuf := bufio.NewReader(cmd.InOrStdin()) - keyringBackend, err := cmd.Flags().GetString(flags.FlagKeyringBackend) - if err != nil { - return err - } - - // attempt to lookup address from Keybase if no address was provided - kb, err := keyring.New(sdk.KeyringServiceName(), keyringBackend, clientCtx.HomeDir, inBuf) - if err != nil { - return err - } - - info, err := kb.Key(args[0]) - if err != nil { - return fmt.Errorf("failed to get address from Keybase: %w", err) - } - - addr = info.GetAddress() - } - - vestingStart, err := cmd.Flags().GetInt64(flagVestingStart) - if err != nil { - return err - } - vestingEnd, err := cmd.Flags().GetInt64(flagVestingEnd) - if err != nil { - return err - } - vestingAmtStr, err := cmd.Flags().GetString(flagVestingAmt) - if err != nil { - return err - } - - vestingAmt, err := sdk.ParseCoinsNormalized(vestingAmtStr) - if err != nil { - return fmt.Errorf("failed to parse vesting amount: %w", err) - } - - // create concrete account type based on input parameters - var genAccount authtypes.GenesisAccount - - balances := banktypes.Balance{Address: addr.String(), Coins: coins.Sort()} - baseAccount := authtypes.NewBaseAccount(addr, nil, 0, 0) - - if !vestingAmt.IsZero() { - baseVestingAccount := authvesting.NewBaseVestingAccount(baseAccount, vestingAmt.Sort(), vestingEnd) - - if (balances.Coins.IsZero() && !baseVestingAccount.OriginalVesting.IsZero()) || - baseVestingAccount.OriginalVesting.IsAnyGT(balances.Coins) { - return errors.New("vesting amount cannot be greater than total amount") - } - - switch { - case vestingStart != 0 && vestingEnd != 0: - genAccount = authvesting.NewContinuousVestingAccountRaw(baseVestingAccount, vestingStart) - - case vestingEnd != 0: - genAccount = authvesting.NewDelayedVestingAccountRaw(baseVestingAccount) - - default: - return errors.New("invalid vesting parameters; must supply start and end time or end time") - } - } else { - genAccount = baseAccount - } - - if err := genAccount.Validate(); err != nil { - return fmt.Errorf("failed to validate new genesis account: %w", err) - } - - genFile := config.GenesisFile() - appState, genDoc, err := genutiltypes.GenesisStateFromGenFile(genFile) - if err != nil { - return fmt.Errorf("failed to unmarshal genesis state: %w", err) - } - - authGenState := authtypes.GetGenesisStateFromAppState(cdc, appState) - - accs, err := authtypes.UnpackAccounts(authGenState.Accounts) - if err != nil { - return fmt.Errorf("failed to get accounts from any: %w", err) - } - - if accs.Contains(addr) { - return fmt.Errorf("cannot add account at existing address %s", addr) - } - - // Add the new account to the set of genesis accounts and sanitize the - // accounts afterwards. - accs = append(accs, genAccount) - accs = authtypes.SanitizeGenesisAccounts(accs) - - genAccs, err := authtypes.PackAccounts(accs) - if err != nil { - return fmt.Errorf("failed to convert accounts into any's: %w", err) - } - authGenState.Accounts = genAccs - - authGenStateBz, err := cdc.MarshalJSON(&authGenState) - if err != nil { - return fmt.Errorf("failed to marshal auth genesis state: %w", err) - } - - appState[authtypes.ModuleName] = authGenStateBz - - bankGenState := banktypes.GetGenesisStateFromAppState(depCdc, appState) - bankGenState.Balances = append(bankGenState.Balances, balances) - bankGenState.Balances = banktypes.SanitizeGenesisBalances(bankGenState.Balances) - - bankGenStateBz, err := cdc.MarshalJSON(bankGenState) - if err != nil { - return fmt.Errorf("failed to marshal bank genesis state: %w", err) - } - - appState[banktypes.ModuleName] = bankGenStateBz - - appStateJSON, err := json.Marshal(appState) - if err != nil { - return fmt.Errorf("failed to marshal application genesis state: %w", err) - } - - genDoc.AppState = appStateJSON - return genutil.ExportGenesisFile(genDoc, genFile) - }, - } - - cmd.Flags().String(flags.FlagKeyringBackend, flags.DefaultKeyringBackend, "Select keyring's backend (os|file|kwallet|pass|test)") - cmd.Flags().String(flags.FlagHome, defaultNodeHome, "The application home directory") - cmd.Flags().String(flagVestingAmt, "", "amount of coins for vesting accounts") - cmd.Flags().Int64(flagVestingStart, 0, "schedule start time (unix epoch) for vesting accounts") - cmd.Flags().Int64(flagVestingEnd, 0, "schedule end time (unix epoch) for vesting accounts") - flags.AddQueryFlagsToCmd(cmd) - - return cmd -} diff --git a/cmd/omniflixhubd/cmd/root.go b/cmd/omniflixhubd/cmd/root.go index d1d0867f..e325bb89 100644 --- a/cmd/omniflixhubd/cmd/root.go +++ b/cmd/omniflixhubd/cmd/root.go @@ -4,36 +4,32 @@ import ( "errors" "io" "os" - "path/filepath" + tmcfg "github.com/cometbft/cometbft/config" "github.com/cosmos/cosmos-sdk/client/config" + "github.com/cosmos/cosmos-sdk/client/debug" + "github.com/cosmos/cosmos-sdk/client/pruning" - "github.com/OmniFlix/omniflixhub/app/params" - "github.com/cosmos/cosmos-sdk/snapshots" - - "github.com/spf13/cast" - "github.com/spf13/cobra" - tmcli "github.com/tendermint/tendermint/libs/cli" - "github.com/tendermint/tendermint/libs/log" - dbm "github.com/tendermint/tm-db" + "github.com/OmniFlix/omniflixhub/v2/app/params" - "github.com/OmniFlix/omniflixhub/app" - "github.com/cosmos/cosmos-sdk/baseapp" + "github.com/OmniFlix/omniflixhub/v2/app" + dbm "github.com/cometbft/cometbft-db" + tmcli "github.com/cometbft/cometbft/libs/cli" + "github.com/cometbft/cometbft/libs/log" "github.com/cosmos/cosmos-sdk/client" - "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/rpc" "github.com/cosmos/cosmos-sdk/server" servertypes "github.com/cosmos/cosmos-sdk/server/types" - "github.com/cosmos/cosmos-sdk/store" sdk "github.com/cosmos/cosmos-sdk/types" authcmd "github.com/cosmos/cosmos-sdk/x/auth/client/cli" "github.com/cosmos/cosmos-sdk/x/auth/types" vestingcli "github.com/cosmos/cosmos-sdk/x/auth/vesting/client/cli" - banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" "github.com/cosmos/cosmos-sdk/x/crisis" genutilcli "github.com/cosmos/cosmos-sdk/x/genutil/client/cli" + "github.com/spf13/cast" + "github.com/spf13/cobra" ) var ChainID string @@ -52,7 +48,7 @@ func NewRootCmd() (*cobra.Command, params.EncodingConfig) { WithLegacyAmino(encodingConfig.Amino). WithInput(os.Stdin). WithAccountRetriever(types.AccountRetriever{}). - WithBroadcastMode(flags.BroadcastBlock). + WithBroadcastMode(flags.BroadcastSync). WithHomeDir(app.DefaultNodeHome). WithViper("") @@ -75,7 +71,8 @@ func NewRootCmd() (*cobra.Command, params.EncodingConfig) { return err } appTemplate, appConfig := initAppConfig() - return server.InterceptConfigsPreRunHandler(cmd, appTemplate, appConfig) + customTMConfig := initTendermintConfig() + return server.InterceptConfigsPreRunHandler(cmd, appTemplate, appConfig, customTMConfig) }, } @@ -84,20 +81,30 @@ func NewRootCmd() (*cobra.Command, params.EncodingConfig) { return rootCmd, encodingConfig } +// 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() + + // these values put a higher strain on node memory + // cfg.P2P.MaxNumInboundPeers = 100 + // cfg.P2P.MaxNumOutboundPeers = 40 + + return cfg +} + func initRootCmd(rootCmd *cobra.Command, encodingConfig params.EncodingConfig) { - // To-Do Check in gaia new release - // authclient.Codec = encodingConfig.Marshaler + cfg := sdk.GetConfig() + cfg.Seal() + + ac := appCreator{encodingConfig} rootCmd.AddCommand( genutilcli.InitCmd(app.ModuleBasics, app.DefaultNodeHome), - genutilcli.CollectGenTxsCmd(banktypes.GenesisBalancesIterator{}, app.DefaultNodeHome), - genutilcli.MigrateGenesisCmd(), - genutilcli.GenTxCmd(app.ModuleBasics, encodingConfig.TxConfig, banktypes.GenesisBalancesIterator{}, app.DefaultNodeHome), - genutilcli.ValidateGenesisCmd(app.ModuleBasics), - AddGenesisAccountCmd(app.DefaultNodeHome), tmcli.NewCompletionCmd(rootCmd, true), - debug.Cmd(), + addDebugCommands(debug.Cmd()), config.Cmd(), + pruning.PruningCmd(ac.newApp), ) a := appCreator{encodingConfig} @@ -106,6 +113,7 @@ func initRootCmd(rootCmd *cobra.Command, encodingConfig params.EncodingConfig) { // add keybase, auxiliary RPC, query, and tx child commands rootCmd.AddCommand( rpc.StatusCommand(), + genesisCommand(encodingConfig), queryCommand(), txCommand(), keys.Commands(app.DefaultNodeHome), @@ -116,6 +124,15 @@ func addModuleInitFlags(startCmd *cobra.Command) { crisis.AddModuleInitFlags(startCmd) } +func genesisCommand(encodingConfig params.EncodingConfig, cmds ...*cobra.Command) *cobra.Command { + cmd := genutilcli.GenesisCoreCommand(encodingConfig.TxConfig, app.ModuleBasics, app.DefaultNodeHome) + + for _, subCmd := range cmds { + cmd.AddCommand(subCmd) + } + return cmd +} + func queryCommand() *cobra.Command { cmd := &cobra.Command{ Use: "query", @@ -158,8 +175,8 @@ func txCommand() *cobra.Command { authcmd.GetBroadcastCommand(), authcmd.GetEncodeCommand(), authcmd.GetDecodeCommand(), - flags.LineBreak, vestingcli.GetTxCmd(), + authcmd.GetAuxToFeeCommand(), ) app.ModuleBasics.AddTxCommands(cmd) @@ -174,58 +191,37 @@ type appCreator struct { // newApp is an AppCreator func (a appCreator) newApp(logger log.Logger, db dbm.DB, traceStore io.Writer, appOpts servertypes.AppOptions) servertypes.Application { - var cache sdk.MultiStorePersistentCache - - if cast.ToBool(appOpts.Get(server.FlagInterBlockCache)) { - cache = store.NewCommitKVStoreCacheManager() - } - skipUpgradeHeights := make(map[int64]bool) for _, h := range cast.ToIntSlice(appOpts.Get(server.FlagUnsafeSkipUpgrades)) { skipUpgradeHeights[int64(h)] = true } - pruningOpts, err := server.GetPruningOptionsFromFlags(appOpts) - if err != nil { - panic(err) - } - - snapshotDir := filepath.Join(cast.ToString(appOpts.Get(flags.FlagHome)), "data", "snapshots") - snapshotDB, err := sdk.NewLevelDB("metadata", snapshotDir) - if err != nil { - panic(err) - } - snapshotStore, err := snapshots.NewStore(snapshotDB, snapshotDir) - if err != nil { - panic(err) - } + baseappOptions := server.DefaultBaseappOptions(appOpts) return app.NewOmniFlixApp( - logger, db, traceStore, true, skipUpgradeHeights, + logger, + db, + traceStore, + true, + skipUpgradeHeights, cast.ToString(appOpts.Get(flags.FlagHome)), cast.ToUint(appOpts.Get(server.FlagInvCheckPeriod)), a.encCfg, appOpts, - baseapp.SetPruning(pruningOpts), - baseapp.SetMinGasPrices(cast.ToString(appOpts.Get(server.FlagMinGasPrices))), - baseapp.SetMinRetainBlocks(cast.ToUint64(appOpts.Get(server.FlagMinRetainBlocks))), - baseapp.SetHaltHeight(cast.ToUint64(appOpts.Get(server.FlagHaltHeight))), - baseapp.SetHaltTime(cast.ToUint64(appOpts.Get(server.FlagHaltTime))), - baseapp.SetInterBlockCache(cache), - baseapp.SetTrace(cast.ToBool(appOpts.Get(server.FlagTrace))), - baseapp.SetIndexEvents(cast.ToStringSlice(appOpts.Get(server.FlagIndexEvents))), - baseapp.SetSnapshotStore(snapshotStore), - baseapp.SetSnapshotInterval(cast.ToUint64(appOpts.Get(server.FlagStateSyncSnapshotInterval))), - baseapp.SetSnapshotKeepRecent(cast.ToUint32(appOpts.Get(server.FlagStateSyncSnapshotKeepRecent))), - baseapp.SetIAVLCacheSize(cast.ToInt(appOpts.Get(server.FlagIAVLCacheSize))), - baseapp.SetIAVLDisableFastNode(cast.ToBool(appOpts.Get(server.FlagDisableIAVLFastNode))), + baseappOptions..., ) } // appExport creates a new app (optionally at a given height) func (a appCreator) appExport( - logger log.Logger, db dbm.DB, traceStore io.Writer, height int64, forZeroHeight bool, jailAllowedAddrs []string, + logger log.Logger, + db dbm.DB, + traceStore io.Writer, + height int64, + forZeroHeight bool, + jailAllowedAddrs []string, appOpts servertypes.AppOptions, + modulesToExport []string, ) (servertypes.ExportedApp, error) { var anApp *app.OmniFlixApp @@ -264,5 +260,5 @@ func (a appCreator) appExport( ) } - return anApp.ExportAppStateAndValidators(forZeroHeight, jailAllowedAddrs) + return anApp.ExportAppStateAndValidators(forZeroHeight, jailAllowedAddrs, modulesToExport) } diff --git a/cmd/omniflixhubd/main.go b/cmd/omniflixhubd/main.go index 86a47047..9a403d8f 100644 --- a/cmd/omniflixhubd/main.go +++ b/cmd/omniflixhubd/main.go @@ -3,14 +3,14 @@ package main import ( "os" - "github.com/OmniFlix/omniflixhub/app" - "github.com/OmniFlix/omniflixhub/cmd/omniflixhubd/cmd" + "github.com/OmniFlix/omniflixhub/v2/app" + "github.com/OmniFlix/omniflixhub/v2/cmd/omniflixhubd/cmd" svrcmd "github.com/cosmos/cosmos-sdk/server/cmd" ) func main() { rootCmd, _ := cmd.NewRootCmd() - if err := svrcmd.Execute(rootCmd, app.DefaultNodeHome); err != nil { + if err := svrcmd.Execute(rootCmd, "", app.DefaultNodeHome); err != nil { os.Exit(1) } } diff --git a/custom/auth/client/rest/broadcast.go b/custom/auth/client/rest/broadcast.go deleted file mode 100644 index 1b582c2f..00000000 --- a/custom/auth/client/rest/broadcast.go +++ /dev/null @@ -1,120 +0,0 @@ -package rest - -import ( - "errors" - "fmt" - "io" - "net/http" - - "github.com/cosmos/cosmos-sdk/client" - clientrest "github.com/cosmos/cosmos-sdk/client/rest" - codectypes "github.com/cosmos/cosmos-sdk/codec/types" - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/cosmos-sdk/types/rest" - "github.com/cosmos/cosmos-sdk/x/auth/legacy/legacytx" -) - -// BroadcastReq defines a tx broadcasting request. -type BroadcastReq struct { - Tx legacytx.StdTx `json:"tx" yaml:"tx"` - Mode string `json:"mode" yaml:"mode"` - Sequences []uint64 `json:"sequences" yaml:"sequences"` - TimeoutHeight uint64 `json:"timeout_height" yaml:"timeout_height"` - FeeGranter string `json:"fee_granter" yaml:"fee_granter"` -} - -var _ codectypes.UnpackInterfacesMessage = BroadcastReq{} - -// UnpackInterfaces implements the UnpackInterfacesMessage interface. -func (m BroadcastReq) UnpackInterfaces(unpacker codectypes.AnyUnpacker) error { - return m.Tx.UnpackInterfaces(unpacker) -} - -// BroadcastTxRequest implements a tx broadcasting handler that is responsible -// for broadcasting a valid and signed tx to a full node. The tx can be -// broadcasted via a sync|async|block mechanism. -func BroadcastTxRequest(clientCtx client.Context) http.HandlerFunc { - return func(w http.ResponseWriter, r *http.Request) { - var req BroadcastReq - - body, err := io.ReadAll(r.Body) - if rest.CheckBadRequestError(w, err) { - return - } - - // NOTE: amino is used intentionally here, don't migrate it! - err = clientCtx.LegacyAmino.UnmarshalJSON(body, &req) - if err != nil { - err := fmt.Errorf("this transaction cannot be broadcasted via legacy REST endpoints, because it does not support"+ - " Amino serialization. Please either use CLI, gRPC, gRPC-gateway, or directly query the Tendermint RPC"+ - " endpoint to broadcast this transaction. The new REST endpoint (via gRPC-gateway) is POST /cosmos/tx/v1beta1/txs."+ - " Please also see the REST endpoints migration guide at %s for more info", clientrest.DeprecationURL) - if rest.CheckBadRequestError(w, err) { - return - } - } - - txBuilder := clientCtx.TxConfig.NewTxBuilder() - txBuilder.SetFeeAmount(req.Tx.GetFee()) - txBuilder.SetGasLimit(req.Tx.GetGas()) - txBuilder.SetMemo(req.Tx.GetMemo()) - if err := txBuilder.SetMsgs(req.Tx.GetMsgs()...); rest.CheckBadRequestError(w, err) { - return - } - - txBuilder.SetTimeoutHeight(req.Tx.GetTimeoutHeight()) - if req.FeeGranter != "" { - addr, err := sdk.AccAddressFromBech32(req.FeeGranter) - if rest.CheckBadRequestError(w, err) { - return - } - - txBuilder.SetFeeGranter(addr) - } - - signatures, err := req.Tx.GetSignaturesV2() - if rest.CheckBadRequestError(w, err) { - return - } - - // if sequence is not given, try fetch from the chain - if len(req.Sequences) == 0 { - for _, sig := range signatures { - _, seq, err := clientCtx.AccountRetriever.GetAccountNumberSequence(clientCtx, sdk.AccAddress(sig.PubKey.Address().Bytes())) - if rest.CheckBadRequestError(w, err) { - return - } - req.Sequences = append(req.Sequences, seq) - } - } - - // check the sequence nubmer is equal with the signature nubmer - if len(signatures) != len(req.Sequences) { - rest.CheckBadRequestError(w, errors.New("must provide each signers's sequence number")) - return - } - - // fill sequence number to new signature - for i, seq := range req.Sequences { - signatures[i].Sequence = seq - } - - if err := txBuilder.SetSignatures(signatures...); rest.CheckBadRequestError(w, err) { - return - } - - // compute signature bytes - txBytes, err := clientCtx.TxConfig.TxEncoder()(txBuilder.GetTx()) - if rest.CheckInternalServerError(w, err) { - return - } - - clientCtx = clientCtx.WithBroadcastMode(req.Mode) - res, err := clientCtx.BroadcastTx(txBytes) - if rest.CheckInternalServerError(w, err) { - return - } - - rest.PostProcessResponseBare(w, clientCtx, res) - } -} diff --git a/custom/auth/client/rest/rest.go b/custom/auth/client/rest/rest.go deleted file mode 100644 index 837bc0a4..00000000 --- a/custom/auth/client/rest/rest.go +++ /dev/null @@ -1,14 +0,0 @@ -package rest - -import ( - "github.com/gorilla/mux" - - "github.com/cosmos/cosmos-sdk/client" - clientrest "github.com/cosmos/cosmos-sdk/client/rest" -) - -// RegisterTxRoutes registers registers custom transaction routes on the provided router. -func RegisterTxRoutes(clientCtx client.Context, rtr *mux.Router) { - r := clientrest.WithHTTPDeprecationHeaders(rtr) - r.HandleFunc("/txs", BroadcastTxRequest(clientCtx)).Methods("POST") -} diff --git a/go.mod b/go.mod index 0799c2f7..62552d52 100644 --- a/go.mod +++ b/go.mod @@ -1,152 +1,189 @@ -module github.com/OmniFlix/omniflixhub +module github.com/OmniFlix/omniflixhub/v2 -go 1.19 +go 1.20 require ( - github.com/OmniFlix/onft v0.6.0 - github.com/OmniFlix/streampay/v2 v2.1.0 - github.com/cosmos/cosmos-sdk v0.45.16 - github.com/cosmos/ibc-go/v4 v4.4.2 - github.com/gogo/protobuf v1.3.3 - github.com/golang/protobuf v1.5.2 + github.com/OmniFlix/onft v0.6.1-0.20230923181114-30842581416b + github.com/OmniFlix/streampay/v2 v2.1.1-0.20230922163133-93e80c4663ef + github.com/cometbft/cometbft v0.37.2 + github.com/cometbft/cometbft-db v0.8.0 + github.com/cosmos/cosmos-proto v1.0.0-beta.2 + github.com/cosmos/cosmos-sdk v0.47.5 + github.com/cosmos/gogoproto v1.4.10 + github.com/cosmos/ibc-apps/middleware/packet-forward-middleware/v7 v7.0.0 + github.com/cosmos/ibc-go/v7 v7.2.0 + github.com/golang/protobuf v1.5.3 github.com/google/uuid v1.3.0 github.com/gorilla/mux v1.8.0 github.com/grpc-ecosystem/grpc-gateway v1.16.0 - github.com/spf13/cast v1.5.0 - github.com/spf13/cobra v1.6.1 + github.com/spf13/cast v1.5.1 + github.com/spf13/cobra v1.7.0 github.com/spf13/pflag v1.0.5 - github.com/strangelove-ventures/packet-forward-middleware/v4 v4.0.6 - github.com/stretchr/testify v1.8.1 - github.com/tendermint/tendermint v0.34.28 - github.com/tendermint/tm-db v0.6.7 - golang.org/x/exp v0.0.0-20221019170559-20944726eadf - google.golang.org/genproto v0.0.0-20230125152338-dcaf20b6aeaa - google.golang.org/grpc v1.52.3 - google.golang.org/protobuf v1.28.2-0.20220831092852-f930b1dc76e8 + github.com/stretchr/testify v1.8.4 + golang.org/x/exp v0.0.0-20230711153332-06a737ee72cb + google.golang.org/genproto/googleapis/api v0.0.0-20230629202037-9506855d4529 + google.golang.org/grpc v1.56.2 + google.golang.org/protobuf v1.31.0 ) require ( - cosmossdk.io/api v0.2.6 // indirect + cosmossdk.io/api v0.3.1 + cosmossdk.io/errors v1.0.0 + cosmossdk.io/math v1.1.2 + cloud.google.com/go v0.110.4 // indirect + cloud.google.com/go/compute v1.20.1 // indirect + cloud.google.com/go/compute/metadata v0.2.3 // indirect + cloud.google.com/go/iam v1.1.0 // indirect + cloud.google.com/go/storage v1.30.1 // indirect cosmossdk.io/core v0.5.1 // indirect - cosmossdk.io/depinject v1.0.0-alpha.3 // indirect - filippo.io/edwards25519 v1.0.0-rc.1 // indirect + cosmossdk.io/depinject v1.0.0-alpha.4 // indirect + cosmossdk.io/log v1.2.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/HdrHistogram/hdrhistogram-go v1.1.2 // indirect - github.com/Workiva/go-datastructures v1.0.53 // indirect + github.com/ChainSafe/go-schnorrkel v0.0.0-20200405005733-88cbf1b4c40d // indirect github.com/armon/go-metrics v0.4.1 // indirect + github.com/aws/aws-sdk-go v1.44.203 // 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/btcsuite/btcd/btcec/v2 v2.3.2 // indirect + github.com/cenkalti/backoff/v4 v4.1.3 // indirect github.com/cespare/xxhash v1.1.0 // indirect - github.com/cespare/xxhash/v2 v2.1.2 // indirect - github.com/cockroachdb/errors v1.9.1 // indirect + github.com/cespare/xxhash/v2 v2.2.0 // indirect + github.com/chzyer/readline v1.5.1 // indirect + github.com/cockroachdb/apd/v2 v2.0.2 // indirect + github.com/cockroachdb/errors v1.10.0 // indirect github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b // indirect - github.com/cockroachdb/pebble v0.0.0-20220817183557-09c6e030a677 // indirect - github.com/cockroachdb/redact v1.1.3 // indirect + github.com/cockroachdb/redact v1.1.5 // indirect github.com/coinbase/rosetta-sdk-go v0.7.9 // indirect - github.com/cometbft/cometbft-db v0.7.0 // indirect github.com/confio/ics23/go v0.9.0 // indirect - github.com/cosmos/btcutil v1.0.4 // indirect - github.com/cosmos/cosmos-db v0.0.0-20221226095112-f3c38ecb5e32 // indirect - github.com/cosmos/cosmos-proto v1.0.0-beta.1 // indirect + github.com/cosmos/btcutil v1.0.5 // indirect github.com/cosmos/go-bip39 v1.0.0 // indirect - github.com/cosmos/gorocksdb v1.2.0 // indirect - github.com/cosmos/iavl v0.19.5 // indirect + github.com/cosmos/gogogateway v1.2.0 // indirect + github.com/cosmos/iavl v0.20.0 // indirect + github.com/cosmos/ics23/go v0.10.0 // indirect github.com/cosmos/ledger-cosmos-go v0.12.2 // indirect - github.com/creachadair/taskgroup v0.3.2 // indirect + github.com/cosmos/rosetta-sdk-go v0.10.0 // indirect + github.com/creachadair/taskgroup v0.4.2 // indirect github.com/danieljoos/wincred v1.1.2 // indirect github.com/davecgh/go-spew v1.1.1 // indirect - github.com/decred/dcrd/dcrec/secp256k1/v4 v4.0.1 // indirect + github.com/decred/dcrd/dcrec/secp256k1/v4 v4.1.0 // indirect github.com/desertbit/timer v0.0.0-20180107155436-c41aec40b27f // indirect github.com/dgraph-io/badger/v2 v2.2007.4 // indirect - github.com/dgraph-io/ristretto v0.0.3 // indirect + github.com/dgraph-io/ristretto v0.1.1 // indirect github.com/dgryski/go-farm v0.0.0-20200201041132-a6ae2369ad13 // indirect - github.com/dustin/go-humanize v1.0.1-0.20200219035652-afde56e7acac // indirect + github.com/dustin/go-humanize v1.0.1 // indirect github.com/dvsekhvalnov/jose2go v1.5.0 // indirect github.com/felixge/httpsnoop v1.0.2 // indirect github.com/fsnotify/fsnotify v1.6.0 // indirect - github.com/getsentry/sentry-go v0.17.0 // indirect + github.com/getsentry/sentry-go v0.23.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.5.1 // indirect + github.com/go-logfmt/logfmt v0.6.0 // indirect github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2 // indirect - github.com/gogo/gateway v1.1.0 // indirect + github.com/gogo/googleapis v1.4.1 // indirect + github.com/gogo/protobuf v1.3.2 // indirect + github.com/golang/glog v1.1.0 // indirect + github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect + github.com/golang/mock v1.6.0 // indirect github.com/golang/snappy v0.0.4 // indirect github.com/google/btree v1.1.2 // indirect + github.com/google/go-cmp v0.5.9 // indirect github.com/google/orderedcode v0.0.1 // indirect + github.com/google/s2a-go v0.1.4 // indirect + github.com/googleapis/enterprise-certificate-proxy v0.2.3 // indirect + github.com/googleapis/gax-go/v2 v2.11.0 // indirect github.com/gorilla/handlers v1.5.1 // indirect github.com/gorilla/websocket v1.5.0 // indirect github.com/grpc-ecosystem/go-grpc-middleware v1.3.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-immutable-radix v1.3.1 // 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/hcl v1.0.0 // indirect - github.com/hdevalence/ed25519consensus v0.0.0-20220222234857-c00d1f31bab3 // indirect + github.com/hdevalence/ed25519consensus v0.1.0 // indirect + github.com/huandu/skiplist v1.2.0 // indirect github.com/iancoleman/orderedmap v0.2.0 // indirect - github.com/improbable-eng/grpc-web v0.14.1 // indirect - github.com/inconshreveable/mousetrap v1.0.1 // 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/jmhodges/levigo v1.0.0 // indirect - github.com/klauspost/compress v1.15.11 // indirect + github.com/klauspost/compress v1.16.3 // indirect github.com/kr/pretty v0.3.1 // indirect github.com/kr/text v0.2.0 // indirect - github.com/lib/pq v1.10.6 // indirect + github.com/lib/pq v1.10.7 // indirect github.com/libp2p/go-buffer-pool v0.1.0 // indirect - github.com/linxGnu/grocksdb v1.7.10 // indirect - github.com/magiconair/properties v1.8.6 // indirect + github.com/linxGnu/grocksdb v1.7.16 // indirect + github.com/magiconair/properties v1.8.7 // indirect + github.com/manifoldco/promptui v0.9.0 // indirect github.com/mattn/go-colorable v0.1.13 // indirect - github.com/mattn/go-isatty v0.0.16 // indirect - github.com/matttproud/golang_protobuf_extensions v1.0.2-0.20181231171920-c182affec369 // indirect + github.com/mattn/go-isatty v0.0.19 // 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/pelletier/go-toml v1.9.5 // indirect - github.com/pelletier/go-toml/v2 v2.0.5 // indirect - github.com/petermattis/goid v0.0.0-20180202154549-b0b1615b78e5 // indirect + github.com/pelletier/go-toml/v2 v2.0.8 // indirect + github.com/petermattis/goid v0.0.0-20230317030725-371a4b8eda08 // indirect github.com/pkg/errors v0.9.1 // indirect github.com/pmezard/go-difflib v1.0.0 // indirect github.com/prometheus/client_golang v1.14.0 // indirect github.com/prometheus/client_model v0.3.0 // indirect - github.com/prometheus/common v0.37.0 // indirect - github.com/prometheus/procfs v0.8.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/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475 // indirect - github.com/regen-network/cosmos-proto v0.3.1 // indirect - github.com/rogpeppe/go-internal v1.9.0 // indirect - github.com/rs/cors v1.8.2 // indirect - github.com/rs/zerolog v1.27.0 // indirect + github.com/rogpeppe/go-internal v1.11.0 // indirect + github.com/rs/cors v1.8.3 // indirect + github.com/rs/zerolog v1.30.0 // indirect github.com/sasha-s/go-deadlock v0.3.1 // indirect - github.com/spf13/afero v1.9.2 // indirect + github.com/spf13/afero v1.9.5 // indirect github.com/spf13/jwalterweatherman v1.1.0 // indirect - github.com/spf13/viper v1.14.0 // indirect - github.com/subosito/gotenv v1.4.1 // indirect - github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 // indirect - github.com/tecbot/gorocksdb v0.0.0-20191217155057-f0fad39f321c // indirect + github.com/spf13/viper v1.16.0 // indirect + github.com/subosito/gotenv v1.4.2 // 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.5.0 // indirect + github.com/tidwall/btree v1.6.0 // indirect + github.com/ulikunitz/xz v0.5.11 // indirect github.com/zondax/hid v0.9.1 // indirect github.com/zondax/ledger-go v0.14.1 // indirect - go.etcd.io/bbolt v1.3.6 // indirect - golang.org/x/crypto v0.5.0 // indirect - golang.org/x/net v0.7.0 // indirect - golang.org/x/sys v0.5.0 // indirect - golang.org/x/term v0.5.0 // indirect - golang.org/x/text v0.7.0 // indirect + go.etcd.io/bbolt v1.3.7 // indirect + go.opencensus.io v0.24.0 // indirect + golang.org/x/crypto v0.11.0 // indirect + golang.org/x/net v0.12.0 // indirect + golang.org/x/oauth2 v0.8.0 // indirect + golang.org/x/sys v0.11.0 // indirect + golang.org/x/term v0.10.0 // indirect + golang.org/x/text v0.12.0 // indirect + golang.org/x/xerrors v0.0.0-20220907171357-04be3eba64a2 // indirect + google.golang.org/api v0.126.0 // indirect + google.golang.org/appengine v1.6.7 // indirect + google.golang.org/genproto v0.0.0-20230706204954-ccb25ca9f130 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20230711160842-782d3b101e98 // indirect gopkg.in/ini.v1 v1.67.0 // indirect gopkg.in/yaml.v2 v2.4.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect nhooyr.io/websocket v1.8.6 // indirect + pgregory.net/rapid v0.5.5 // indirect + sigs.k8s.io/yaml v1.3.0 // indirect ) replace ( github.com/99designs/keyring => github.com/cosmos/keyring v1.2.0 - github.com/gogo/protobuf => github.com/regen-network/protobuf v1.3.3-alpha.regen.1 - // cometbft - github.com/tendermint/tendermint => github.com/cometbft/cometbft v0.34.28 - google.golang.org/grpc => google.golang.org/grpc v1.33.2 + // Fix upstream GHSA-h395-qcrw-5vmq vulnerability. + // TODO Remove it: https://github.com/cosmos/cosmos-sdk/issues/10409 + github.com/gin-gonic/gin => github.com/gin-gonic/gin v1.9.1 + + // https://github.com/cosmos/cosmos-sdk/issues/14949 + // pin the version of goleveldb to v1.0.1-0.20210819022825-2ae1ddf74ef7 required by SDK v47 upgrade guide. + github.com/syndtr/goleveldb => github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 ) diff --git a/go.sum b/go.sum index 88eac61c..07d3d9fd 100644 --- a/go.sum +++ b/go.sum @@ -1,3 +1,4 @@ +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= @@ -18,86 +19,231 @@ cloud.google.com/go v0.65.0/go.mod h1:O5N8zS7uWy9vkA9vayVHs65eM1ubvY4h553ofrNHOb cloud.google.com/go v0.72.0/go.mod h1:M+5Vjvlc2wnp6tjzE102Dw08nGShTscUx2nZMufOKPI= cloud.google.com/go v0.74.0/go.mod h1:VV1xSbzvo+9QJOxLDaJfTjx5e+MePCpCWwvftOeQmWk= cloud.google.com/go v0.75.0/go.mod h1:VGuuCn7PG0dwsd5XPVm2Mm3wlh3EL55/79EKB6hlPTY= +cloud.google.com/go v0.78.0/go.mod h1:QjdrLG0uq+YwhjoVOLsS1t7TW8fs36kLs4XO5R5ECHg= +cloud.google.com/go v0.79.0/go.mod h1:3bzgcEeQlzbuEAYu4mrWhKqWjmpprinYgKJLgKHnbb8= +cloud.google.com/go v0.81.0/go.mod h1:mk/AM35KwGk/Nm2YSeZbxXdrNK3KZOYHmLkOqC2V6E0= +cloud.google.com/go v0.83.0/go.mod h1:Z7MJUsANfY0pYPdw0lbnivPx4/vhy/e2FEkSkF7vAVY= +cloud.google.com/go v0.84.0/go.mod h1:RazrYuxIK6Kb7YrzzhPoLmCVzl7Sup4NrbKPg8KHSUM= +cloud.google.com/go v0.87.0/go.mod h1:TpDYlFy7vuLzZMMZ+B6iRiELaY7z/gJPaqbMx6mlWcY= +cloud.google.com/go v0.90.0/go.mod h1:kRX0mNRHe0e2rC6oNakvwQqzyDmg57xJ+SZU1eT2aDQ= +cloud.google.com/go v0.93.3/go.mod h1:8utlLll2EF5XMAV15woO4lSbWQlk8rer9aLOfLh7+YI= +cloud.google.com/go v0.94.1/go.mod h1:qAlAugsXlC+JWO+Bke5vCtc9ONxjQT3drlTTnAplMW4= +cloud.google.com/go v0.97.0/go.mod h1:GF7l59pYBVlXQIBLx3a761cZ41F9bBH3JUlihCt2Udc= +cloud.google.com/go v0.99.0/go.mod h1:w0Xx2nLzqWJPuozYQX+hFfCSI8WioryfRDzkoI/Y2ZA= +cloud.google.com/go v0.100.2/go.mod h1:4Xra9TjzAeYHrl5+oeLlzbM2k3mjVhZh4UqTZ//w99A= +cloud.google.com/go v0.102.0/go.mod h1:oWcCzKlqJ5zgHQt9YsaeTY9KzIvjyy0ArmiBUgpQ+nc= +cloud.google.com/go v0.102.1/go.mod h1:XZ77E9qnTEnrgEOvr4xzfdX5TRo7fB4T2F4O6+34hIU= +cloud.google.com/go v0.104.0/go.mod h1:OO6xxXdJyvuJPcEPBLN9BJPD+jep5G1+2U5B5gkRYtA= +cloud.google.com/go v0.110.4 h1:1JYyxKMN9hd5dR2MYTPWkGUgcoxVVhg0LKNKEo0qvmk= +cloud.google.com/go v0.110.4/go.mod h1:+EYjdK8e5RME/VY/qLCAtuyALQ9q67dvuum8i+H5xsI= +cloud.google.com/go/aiplatform v1.22.0/go.mod h1:ig5Nct50bZlzV6NvKaTwmplLLddFx0YReh9WfTO5jKw= +cloud.google.com/go/aiplatform v1.24.0/go.mod h1:67UUvRBKG6GTayHKV8DBv2RtR1t93YRu5B1P3x99mYY= +cloud.google.com/go/analytics v0.11.0/go.mod h1:DjEWCu41bVbYcKyvlws9Er60YE4a//bK6mnhWvQeFNI= +cloud.google.com/go/analytics v0.12.0/go.mod h1:gkfj9h6XRf9+TS4bmuhPEShsh3hH8PAZzm/41OOhQd4= +cloud.google.com/go/area120 v0.5.0/go.mod h1:DE/n4mp+iqVyvxHN41Vf1CR602GiHQjFPusMFW6bGR4= +cloud.google.com/go/area120 v0.6.0/go.mod h1:39yFJqWVgm0UZqWTOdqkLhjoC7uFfgXRC8g/ZegeAh0= +cloud.google.com/go/artifactregistry v1.6.0/go.mod h1:IYt0oBPSAGYj/kprzsBjZ/4LnG/zOcHyFHjWPCi6SAQ= +cloud.google.com/go/artifactregistry v1.7.0/go.mod h1:mqTOFOnGZx8EtSqK/ZWcsm/4U8B77rbcLP6ruDU2Ixk= +cloud.google.com/go/asset v1.5.0/go.mod h1:5mfs8UvcM5wHhqtSv8J1CtxxaQq3AdBxxQi2jGW/K4o= +cloud.google.com/go/asset v1.7.0/go.mod h1:YbENsRK4+xTiL+Ofoj5Ckf+O17kJtgp3Y3nn4uzZz5s= +cloud.google.com/go/asset v1.8.0/go.mod h1:mUNGKhiqIdbr8X7KNayoYvyc4HbbFO9URsjbytpUaW0= +cloud.google.com/go/assuredworkloads v1.5.0/go.mod h1:n8HOZ6pff6re5KYfBXcFvSViQjDwxFkAkmUFffJRbbY= +cloud.google.com/go/assuredworkloads v1.6.0/go.mod h1:yo2YOk37Yc89Rsd5QMVECvjaMKymF9OP+QXWlKXUkXw= +cloud.google.com/go/assuredworkloads v1.7.0/go.mod h1:z/736/oNmtGAyU47reJgGN+KVoYoxeLBoj4XkKYscNI= +cloud.google.com/go/automl v1.5.0/go.mod h1:34EjfoFGMZ5sgJ9EoLsRtdPSNZLcfflJR39VbVNS2M0= +cloud.google.com/go/automl v1.6.0/go.mod h1:ugf8a6Fx+zP0D59WLhqgTDsQI9w07o64uf/Is3Nh5p8= cloud.google.com/go/bigquery v1.0.1/go.mod h1:i/xbL2UlR5RvWAURpBYZTtm/cXjCha9lbfbpx4poX+o= cloud.google.com/go/bigquery v1.3.0/go.mod h1:PjpwJnslEMmckchkHFfq+HTD2DmtT67aNFKH1/VBDHE= cloud.google.com/go/bigquery v1.4.0/go.mod h1:S8dzgnTigyfTmLBfrtrhyYhwRxG72rYxvftPBK2Dvzc= cloud.google.com/go/bigquery v1.5.0/go.mod h1:snEHRnqQbz117VIFhE8bmtwIDY80NLUZUMb4Nv6dBIg= 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= +cloud.google.com/go/binaryauthorization v1.2.0/go.mod h1:86WKkJHtRcv5ViNABtYMhhNWRrD1Vpi//uKEy7aYEfI= +cloud.google.com/go/cloudtasks v1.5.0/go.mod h1:fD92REy1x5woxkKEkLdvavGnPJGEn8Uic9nWuLzqCpY= +cloud.google.com/go/cloudtasks v1.6.0/go.mod h1:C6Io+sxuke9/KNRkbQpihnW93SWDU3uXt92nu85HkYI= +cloud.google.com/go/compute v0.1.0/go.mod h1:GAesmwr110a34z04OlxYkATPBEfVhkymfTBXtfbBFow= +cloud.google.com/go/compute v1.3.0/go.mod h1:cCZiE1NHEtai4wiufUhW8I8S1JKkAnhnQJWM7YD99wM= +cloud.google.com/go/compute v1.5.0/go.mod h1:9SMHyhJlzhlkJqrPAc839t2BZFTSk6Jdj6mkzQJeu0M= +cloud.google.com/go/compute v1.6.0/go.mod h1:T29tfhtVbq1wvAPo0E3+7vhgmkOYeXjhFvz/FMzPu0s= +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.20.1 h1:6aKEtlUiwEpJzM001l0yFkpXmUVXaN8W+fbkb2AZNbg= +cloud.google.com/go/compute v1.20.1/go.mod h1:4tCnrn48xsqlwSAiLf1HXMQk8CONslYbdiEZc9FEIbM= +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= +cloud.google.com/go/containeranalysis v0.6.0/go.mod h1:HEJoiEIu+lEXM+k7+qLCci0h33lX3ZqoYFdmPcoO7s4= +cloud.google.com/go/datacatalog v1.3.0/go.mod h1:g9svFY6tuR+j+hrTw3J2dNcmI0dzmSiyOzm8kpLq0a0= +cloud.google.com/go/datacatalog v1.5.0/go.mod h1:M7GPLNQeLfWqeIm3iuiruhPzkt65+Bx8dAKvScX8jvs= +cloud.google.com/go/datacatalog v1.6.0/go.mod h1:+aEyF8JKg+uXcIdAmmaMUmZ3q1b/lKLtXCmXdnc0lbc= +cloud.google.com/go/dataflow v0.6.0/go.mod h1:9QwV89cGoxjjSR9/r7eFDqqjtvbKxAK2BaYU6PVk9UM= +cloud.google.com/go/dataflow v0.7.0/go.mod h1:PX526vb4ijFMesO1o202EaUmouZKBpjHsTlCtB4parQ= +cloud.google.com/go/dataform v0.3.0/go.mod h1:cj8uNliRlHpa6L3yVhDOBrUXH+BPAO1+KFMQQNSThKo= +cloud.google.com/go/dataform v0.4.0/go.mod h1:fwV6Y4Ty2yIFL89huYlEkwUPtS7YZinZbzzj5S9FzCE= +cloud.google.com/go/datalabeling v0.5.0/go.mod h1:TGcJ0G2NzcsXSE/97yWjIZO0bXj0KbVlINXMG9ud42I= +cloud.google.com/go/datalabeling v0.6.0/go.mod h1:WqdISuk/+WIGeMkpw/1q7bK/tFEZxsrFJOJdY2bXvTQ= +cloud.google.com/go/dataqna v0.5.0/go.mod h1:90Hyk596ft3zUQ8NkFfvICSIfHFh1Bc7C4cK3vbhkeo= +cloud.google.com/go/dataqna v0.6.0/go.mod h1:1lqNpM7rqNLVgWBJyk5NF6Uen2PHym0jtVJonplVsDA= cloud.google.com/go/datastore v1.0.0/go.mod h1:LXYbyblFSglQ5pkeyhO+Qmw7ukd3C+pD7TKLgZqpHYE= cloud.google.com/go/datastore v1.1.0/go.mod h1:umbIZjpQpHh4hmRpGhH4tLFup+FVzqBi1b3c64qFpCk= +cloud.google.com/go/datastream v1.2.0/go.mod h1:i/uTP8/fZwgATHS/XFu0TcNUhuA0twZxxQ3EyCUQMwo= +cloud.google.com/go/datastream v1.3.0/go.mod h1:cqlOX8xlyYF/uxhiKn6Hbv6WjwPPuI9W2M9SAXwaLLQ= +cloud.google.com/go/dialogflow v1.15.0/go.mod h1:HbHDWs33WOGJgn6rfzBW1Kv807BE3O1+xGbn59zZWI4= +cloud.google.com/go/dialogflow v1.16.1/go.mod h1:po6LlzGfK+smoSmTBnbkIZY2w8ffjz/RcGSS+sh1el0= +cloud.google.com/go/dialogflow v1.17.0/go.mod h1:YNP09C/kXA1aZdBgC/VtXX74G/TKn7XVCcVumTflA+8= +cloud.google.com/go/documentai v1.7.0/go.mod h1:lJvftZB5NRiFSX4moiye1SMxHx0Bc3x1+p9e/RfXYiU= +cloud.google.com/go/documentai v1.8.0/go.mod h1:xGHNEB7CtsnySCNrCFdCyyMz44RhFEEX2Q7UD0c5IhU= +cloud.google.com/go/domains v0.6.0/go.mod h1:T9Rz3GasrpYk6mEGHh4rymIhjlnIuB4ofT1wTxDeT4Y= +cloud.google.com/go/domains v0.7.0/go.mod h1:PtZeqS1xjnXuRPKE/88Iru/LdfoRyEHYA9nFQf4UKpg= +cloud.google.com/go/edgecontainer v0.1.0/go.mod h1:WgkZ9tp10bFxqO8BLPqv2LlfmQF1X8lZqwW4r1BTajk= +cloud.google.com/go/edgecontainer v0.2.0/go.mod h1:RTmLijy+lGpQ7BXuTDa4C4ssxyXT34NIuHIgKuP4s5w= +cloud.google.com/go/functions v1.6.0/go.mod h1:3H1UA3qiIPRWD7PeZKLvHZ9SaQhR26XIJcC0A5GbvAk= +cloud.google.com/go/functions v1.7.0/go.mod h1:+d+QBcWM+RsrgZfV9xo6KfA1GlzJfxcfZcRPEhDDfzg= +cloud.google.com/go/gaming v1.5.0/go.mod h1:ol7rGcxP/qHTRQE/RO4bxkXq+Fix0j6D4LFPzYTIrDM= +cloud.google.com/go/gaming v1.6.0/go.mod h1:YMU1GEvA39Qt3zWGyAVA9bpYz/yAhTvaQ1t2sK4KPUA= +cloud.google.com/go/gkeconnect v0.5.0/go.mod h1:c5lsNAg5EwAy7fkqX/+goqFsU1Da/jQFqArp+wGNr/o= +cloud.google.com/go/gkeconnect v0.6.0/go.mod h1:Mln67KyU/sHJEBY8kFZ0xTeyPtzbq9StAVvEULYK16A= +cloud.google.com/go/gkehub v0.9.0/go.mod h1:WYHN6WG8w9bXU0hqNxt8rm5uxnk8IH+lPY9J2TV7BK0= +cloud.google.com/go/gkehub v0.10.0/go.mod h1:UIPwxI0DsrpsVoWpLB0stwKCP+WFVG9+y977wO+hBH0= +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.0 h1:67gSqaPukx7O8WLLHMa0PNs3EBGd2eE4d+psbO/CO94= +cloud.google.com/go/iam v1.1.0/go.mod h1:nxdHjaKfCr7fNYx/HJMM8LgiMugmveWlkatear5gVyk= +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= +cloud.google.com/go/lifesciences v0.6.0/go.mod h1:ddj6tSX/7BOnhxCSd3ZcETvtNr8NZ6t/iPhY2Tyfu08= +cloud.google.com/go/mediatranslation v0.5.0/go.mod h1:jGPUhGTybqsPQn91pNXw0xVHfuJ3leR1wj37oU3y1f4= +cloud.google.com/go/mediatranslation v0.6.0/go.mod h1:hHdBCTYNigsBxshbznuIMFNe5QXEowAuNmmC7h8pu5w= +cloud.google.com/go/memcache v1.4.0/go.mod h1:rTOfiGZtJX1AaFUrOgsMHX5kAzaTQ8azHiuDoTPzNsE= +cloud.google.com/go/memcache v1.5.0/go.mod h1:dk3fCK7dVo0cUU2c36jKb4VqKPS22BTkf81Xq617aWM= +cloud.google.com/go/metastore v1.5.0/go.mod h1:2ZNrDcQwghfdtCwJ33nM0+GrBGlVuh8rakL3vdPY3XY= +cloud.google.com/go/metastore v1.6.0/go.mod h1:6cyQTls8CWXzk45G55x57DVQ9gWg7RiH65+YgPsNh9s= +cloud.google.com/go/networkconnectivity v1.4.0/go.mod h1:nOl7YL8odKyAOtzNX73/M5/mGZgqqMeryi6UPZTk/rA= +cloud.google.com/go/networkconnectivity v1.5.0/go.mod h1:3GzqJx7uhtlM3kln0+x5wyFvuVH1pIBJjhCpjzSt75o= +cloud.google.com/go/networksecurity v0.5.0/go.mod h1:xS6fOCoqpVC5zx15Z/MqkfDwH4+m/61A3ODiDV1xmiQ= +cloud.google.com/go/networksecurity v0.6.0/go.mod h1:Q5fjhTr9WMI5mbpRYEbiexTzROf7ZbDzvzCrNl14nyU= +cloud.google.com/go/notebooks v1.2.0/go.mod h1:9+wtppMfVPUeJ8fIWPOq1UnATHISkGXGqTkxeieQ6UY= +cloud.google.com/go/notebooks v1.3.0/go.mod h1:bFR5lj07DtCPC7YAAJ//vHskFBxA5JzYlH68kXVdk34= +cloud.google.com/go/osconfig v1.7.0/go.mod h1:oVHeCeZELfJP7XLxcBGTMBvRO+1nQ5tFG9VQTmYS2Fs= +cloud.google.com/go/osconfig v1.8.0/go.mod h1:EQqZLu5w5XA7eKizepumcvWx+m8mJUhEwiPqWiZeEdg= +cloud.google.com/go/oslogin v1.4.0/go.mod h1:YdgMXWRaElXz/lDk1Na6Fh5orF7gvmJ0FGLIs9LId4E= +cloud.google.com/go/oslogin v1.5.0/go.mod h1:D260Qj11W2qx/HVF29zBg+0fd6YCSjSqLUkY/qEenQU= +cloud.google.com/go/phishingprotection v0.5.0/go.mod h1:Y3HZknsK9bc9dMi+oE8Bim0lczMU6hrX0UpADuMefr0= +cloud.google.com/go/phishingprotection v0.6.0/go.mod h1:9Y3LBLgy0kDTcYET8ZH3bq/7qni15yVUoAxiFxnlSUA= +cloud.google.com/go/privatecatalog v0.5.0/go.mod h1:XgosMUvvPyxDjAVNDYxJ7wBW8//hLDDYmnsNcMGq1K0= +cloud.google.com/go/privatecatalog v0.6.0/go.mod h1:i/fbkZR0hLN29eEWiiwue8Pb+GforiEIBnV9yrRUOKI= cloud.google.com/go/pubsub v1.0.1/go.mod h1:R0Gpsv3s54REJCy4fxDixWD93lHJMoZTyQ2kNxGRt3I= cloud.google.com/go/pubsub v1.1.0/go.mod h1:EwwdRX2sKPjnvnqCa270oGRyludottCI76h+R3AArQw= cloud.google.com/go/pubsub v1.2.0/go.mod h1:jhfEVHT8odbXTkndysNHCcx0awwzvfOlguIAii9o8iA= cloud.google.com/go/pubsub v1.3.1/go.mod h1:i+ucay31+CNRpDW4Lu78I4xXG+O1r/MAHgjpRVR+TSU= +cloud.google.com/go/recaptchaenterprise v1.3.1/go.mod h1:OdD+q+y4XGeAlxRaMn1Y7/GveP6zmq76byL6tjPE7d4= +cloud.google.com/go/recaptchaenterprise/v2 v2.1.0/go.mod h1:w9yVqajwroDNTfGuhmOjPDN//rZGySaf6PtFVcSCa7o= +cloud.google.com/go/recaptchaenterprise/v2 v2.2.0/go.mod h1:/Zu5jisWGeERrd5HnlS3EUGb/D335f9k51B/FVil0jk= +cloud.google.com/go/recaptchaenterprise/v2 v2.3.0/go.mod h1:O9LwGCjrhGHBQET5CA7dd5NwwNQUErSgEDit1DLNTdo= +cloud.google.com/go/recommendationengine v0.5.0/go.mod h1:E5756pJcVFeVgaQv3WNpImkFP8a+RptV6dDLGPILjvg= +cloud.google.com/go/recommendationengine v0.6.0/go.mod h1:08mq2umu9oIqc7tDy8sx+MNJdLG0fUi3vaSVbztHgJ4= +cloud.google.com/go/recommender v1.5.0/go.mod h1:jdoeiBIVrJe9gQjwd759ecLJbxCDED4A6p+mqoqDvTg= +cloud.google.com/go/recommender v1.6.0/go.mod h1:+yETpm25mcoiECKh9DEScGzIRyDKpZ0cEhWGo+8bo+c= +cloud.google.com/go/redis v1.7.0/go.mod h1:V3x5Jq1jzUcg+UNsRvdmsfuFnit1cfe3Z/PGyq/lm4Y= +cloud.google.com/go/redis v1.8.0/go.mod h1:Fm2szCDavWzBk2cDKxrkmWBqoCiL1+Ctwq7EyqBCA/A= +cloud.google.com/go/retail v1.8.0/go.mod h1:QblKS8waDmNUhghY2TI9O3JLlFk8jybHeV4BF19FrE4= +cloud.google.com/go/retail v1.9.0/go.mod h1:g6jb6mKuCS1QKnH/dpu7isX253absFl6iE92nHwlBUY= +cloud.google.com/go/scheduler v1.4.0/go.mod h1:drcJBmxF3aqZJRhmkHQ9b3uSSpQoltBPGPxGAWROx6s= +cloud.google.com/go/scheduler v1.5.0/go.mod h1:ri073ym49NW3AfT6DZi21vLZrG07GXr5p3H1KxN5QlI= +cloud.google.com/go/secretmanager v1.6.0/go.mod h1:awVa/OXF6IiyaU1wQ34inzQNc4ISIDIrId8qE5QGgKA= +cloud.google.com/go/security v1.5.0/go.mod h1:lgxGdyOKKjHL4YG3/YwIL2zLqMFCKs0UbQwgyZmfJl4= +cloud.google.com/go/security v1.7.0/go.mod h1:mZklORHl6Bg7CNnnjLH//0UlAlaXqiG7Lb9PsPXLfD0= +cloud.google.com/go/security v1.8.0/go.mod h1:hAQOwgmaHhztFhiQ41CjDODdWP0+AE1B3sX4OFlq+GU= +cloud.google.com/go/securitycenter v1.13.0/go.mod h1:cv5qNAqjY84FCN6Y9z28WlkKXyWsgLO832YiWwkCWcU= +cloud.google.com/go/securitycenter v1.14.0/go.mod h1:gZLAhtyKv85n52XYWt6RmeBdydyxfPeTrpToDPw4Auc= +cloud.google.com/go/servicedirectory v1.4.0/go.mod h1:gH1MUaZCgtP7qQiI+F+A+OpeKF/HQWgtAddhTbhL2bs= +cloud.google.com/go/servicedirectory v1.5.0/go.mod h1:QMKFL0NUySbpZJ1UZs3oFAmdvVxhhxB6eJ/Vlp73dfg= +cloud.google.com/go/speech v1.6.0/go.mod h1:79tcr4FHCimOp56lwC01xnt/WPJZc4v3gzyT7FoBkCM= +cloud.google.com/go/speech v1.7.0/go.mod h1:KptqL+BAQIhMsj1kOP2la5DSEEerPDuOP/2mmkhHhZQ= cloud.google.com/go/storage v1.0.0/go.mod h1:IhtSnM/ZTZV8YYJWCY8RULGVqBDmpoyjwiyrjsg+URw= cloud.google.com/go/storage v1.5.0/go.mod h1:tpKbwo567HUNpVclU5sGELwQWBDZ8gh0ZeosJ0Rtdos= cloud.google.com/go/storage v1.6.0/go.mod h1:N7U0C8pVQ/+NIKOBQyamJIeKQKkZ+mxpohlUTyfDhBk= cloud.google.com/go/storage v1.8.0/go.mod h1:Wv1Oy7z6Yz3DshWRJFhqM/UCfaWIRTdp0RXyy7KQOVs= cloud.google.com/go/storage v1.10.0/go.mod h1:FLPqc6j+Ki4BU591ie1oL6qBQGu2Bl/tZ9ullr3+Kg0= cloud.google.com/go/storage v1.14.0/go.mod h1:GrKmX003DSIwi9o29oFT7YDnHYwZoctc3fOKtUw0Xmo= +cloud.google.com/go/storage v1.22.1/go.mod h1:S8N1cAStu7BOeFfE8KAQzmyyLkK8p/vmRq6kuBTW58Y= +cloud.google.com/go/storage v1.23.0/go.mod h1:vOEEDNFnciUMhBeT6hsJIn3ieU5cFRmzeLgDvXzfIXc= +cloud.google.com/go/storage v1.27.0/go.mod h1:x9DOL8TK/ygDUMieqwfhdpQryTeEkhGKMi80i/iqR2s= +cloud.google.com/go/storage v1.30.1 h1:uOdMxAs8HExqBlnLtnQyP0YkvbiDpdGShGKtx6U/oNM= +cloud.google.com/go/storage v1.30.1/go.mod h1:NfxhC0UJE1aXSx7CIIbCf7y9HKT7BiccwkR7+P7gN8E= +cloud.google.com/go/talent v1.1.0/go.mod h1:Vl4pt9jiHKvOgF9KoZo6Kob9oV4lwd/ZD5Cto54zDRw= +cloud.google.com/go/talent v1.2.0/go.mod h1:MoNF9bhFQbiJ6eFD3uSsg0uBALw4n4gaCaEjBw9zo8g= +cloud.google.com/go/videointelligence v1.6.0/go.mod h1:w0DIDlVRKtwPCn/C4iwZIJdvC69yInhW0cfi+p546uU= +cloud.google.com/go/videointelligence v1.7.0/go.mod h1:k8pI/1wAhjznARtVT9U1llUaFNPh7muw8QyOUpavru4= +cloud.google.com/go/vision v1.2.0/go.mod h1:SmNwgObm5DpFBme2xpyOyasvBc1aPdjvMk2bBk0tKD0= +cloud.google.com/go/vision/v2 v2.2.0/go.mod h1:uCdV4PpN1S0jyCyq8sIM42v2Y6zOLkZs+4R9LrGYwFo= +cloud.google.com/go/vision/v2 v2.3.0/go.mod h1:UO61abBx9QRMFkNBbf1D8B1LXdS2cGiiCRx0vSpZoUo= +cloud.google.com/go/webrisk v1.4.0/go.mod h1:Hn8X6Zr+ziE2aNd8SliSDWpEnSS1u4R9+xXZmFiHmGE= +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.2.6 h1:AoNwaLLapcLsphhMK6+o0kZl+D6MMUaHVqSdwinASGU= -cosmossdk.io/api v0.2.6/go.mod h1:u/d+GAxil0nWpl1XnQL8nkziQDIWuBDhv8VnDm/s6dI= +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/depinject v1.0.0-alpha.3 h1:6evFIgj//Y3w09bqOUOzEpFj5tsxBqdc5CfkO7z+zfw= -cosmossdk.io/depinject v1.0.0-alpha.3/go.mod h1:eRbcdQ7MRpIPEM5YUJh8k97nxHpYbc3sMUnEtt8HPWU= +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.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= +cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= +cosmossdk.io/log v1.2.1 h1:Xc1GgTCicniwmMiKwDxUjO4eLhPxoVdI9vtMW8Ti/uk= +cosmossdk.io/log v1.2.1/go.mod h1:GNSCc/6+DhFIj1aLn/j7Id7PaO8DzNylUZoOYBL9+I4= +cosmossdk.io/math v1.1.2 h1:ORZetZCTyWkI5GlZ6CZS28fMHi83ZYf+A2vVnHNzZBM= +cosmossdk.io/math v1.1.2/go.mod h1:l2Gnda87F0su8a/7FEKJfFdJrM0JZRXQaohlgJeyQh0= +cosmossdk.io/tools/rosetta v0.2.1 h1:ddOMatOH+pbxWbrGJKRAawdBkPYLfKXutK9IETnjYxw= +cosmossdk.io/tools/rosetta v0.2.1/go.mod h1:Pqdc1FdvkNV3LcNIkYWt2RQY6IP1ge6YWZk8MhhO9Hw= dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU= -filippo.io/edwards25519 v1.0.0-rc.1 h1:m0VOOB23frXZvAOK44usCgLWvtsxIoMCTBGJZlpmGfU= filippo.io/edwards25519 v1.0.0-rc.1/go.mod h1:N1IkdkCkiLB6tki+MYJoSx2JTY9NUlxZE7eHn5EwJns= +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/AndreasBriese/bbloom v0.0.0-20190306092124-e2d15f34fcf9/go.mod h1:bOvUY6CB00SOBii9/FifXqc0awNKxLFCL/+pkDPuyl8= 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/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo= -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/CloudyKit/fastprinter v0.0.0-20170127035650-74b38d55f37a/go.mod h1:EFZQ978U7x8IRnstaskI3IysnWY5Ao3QgZUKOXlsAdw= -github.com/CloudyKit/fastprinter v0.0.0-20200109182630-33d98a066a53/go.mod h1:+3IMCy2vIlbG1XG/0ggNQv0SvxCAIpPM5b1nCz56Xno= -github.com/CloudyKit/jet v2.1.3-0.20180809161101-62edd43e4f88+incompatible/go.mod h1:HPYO+50pSWkPoj9Q/eq0aRGByCL6ScRlUmiEX5Zgm+w= -github.com/CloudyKit/jet/v3 v3.0.0/go.mod h1:HKQPgSJmdK8hdoAbKUUWajkHyHo4RaU5rMdUywE7VMo= +github.com/ChainSafe/go-schnorrkel v0.0.0-20200405005733-88cbf1b4c40d h1:nalkkPQcITbvhmL4+C4cKA87NW0tfm3Kl9VXRoPywFg= +github.com/ChainSafe/go-schnorrkel v0.0.0-20200405005733-88cbf1b4c40d/go.mod h1:URdX5+vg25ts3aCh8H5IFZybJYKWhJHYMTnf+ULtoC4= github.com/DATA-DOG/go-sqlmock v1.3.3/go.mod h1:f/Ixk793poVmq4qj/V1dPUg2JEAKC73Q5eFN3EC/SaM= github.com/DataDog/datadog-go v3.2.0+incompatible/go.mod h1:LButxg5PwREeZtORoXG3tL4fMGNddJ+vMq1mwgfaqoQ= -github.com/DataDog/zstd v1.4.5/go.mod h1:1jcaCB/ufaK+sKp1NBhlGmpz41jOoPQ35bpF36t7BBo= -github.com/DataDog/zstd v1.5.0 h1:+K/VEwIAaPcHiMtQvpLD4lqW7f0Gk3xdYZmI1hD+CXo= github.com/DataDog/zstd v1.5.0/go.mod h1:g4AWEaM3yOg3HYfnJ3YIawPnVdXJh9QME85blwSAmyw= -github.com/HdrHistogram/hdrhistogram-go v1.1.2 h1:5IcZpTvzydCQeHzK4Ef/D5rrSqwxob0t8PQPMybUNFM= -github.com/HdrHistogram/hdrhistogram-go v1.1.2/go.mod h1:yDgFjdqOqDEKOvasDdhWNXYg9BVp4O+o5f6V/ehm6Oo= -github.com/Joker/hpp v1.0.0/go.mod h1:8x5n+M1Hp5hC0g8okX3sR3vFQwynaX/UgSOM9MeBKzY= -github.com/Joker/jade v1.0.1-0.20190614124447-d475f43051e7/go.mod h1:6E6s8o2AE4KhCrqr6GRJjdC/gNfTdxkIXvuGZZda2VM= github.com/Knetic/govaluate v3.0.1-0.20171022003610-9aa49832a739+incompatible/go.mod h1:r7JcOSlj0wfOMncg0iLm8Leh48TZaKVeNIfJntJ2wa0= github.com/Microsoft/go-winio v0.6.0 h1:slsWYD/zyx7lCXoZVlvQrj0hPTM1HI4+v1sIda2yDvg= github.com/Nvveen/Gotty v0.0.0-20120604004816-cd527374f1e5 h1:TngWCqHvy9oXAN6lEVMRuU21PR1EtLVZJmdB18Gu3Rw= -github.com/OmniFlix/onft v0.6.0 h1:RS2ACs1owt5khqURu+x1f5ahV1wbs5eMJZaMmbq3++4= -github.com/OmniFlix/onft v0.6.0/go.mod h1:RW0ooCgUtutpMElh38kbYf3Qb05BmDKK18jCRImwinI= -github.com/OmniFlix/streampay/v2 v2.1.0 h1:jdoWcAQe4RuD5o82w4tLtkVQyzLmStz4IYo2hYHOeII= -github.com/OmniFlix/streampay/v2 v2.1.0/go.mod h1:PBSVCaNWXBGwZSEIy2TKtNl5oh43QfHqrQ+kF+WcvSc= +github.com/OmniFlix/onft v0.6.1-0.20230923181114-30842581416b h1:K59wrzZyVey3GZFfE5VaODw3iIS2+nwxvC/OOTaTkKI= +github.com/OmniFlix/onft v0.6.1-0.20230923181114-30842581416b/go.mod h1:57nDQZxRTJIfyNlu/mGv7nPag5nRt4Si6mAUQCFv90M= +github.com/OmniFlix/streampay/v2 v2.1.1-0.20230922163133-93e80c4663ef h1:odIDkcCWx5PTTGM01OgKicnuIx2KaxjNAxrUqdBgtHE= +github.com/OmniFlix/streampay/v2 v2.1.1-0.20230922163133-93e80c4663ef/go.mod h1:geZrSHVaGHERqTn1tuFfoH3PIHV5TOwaRErzi4Jnbcw= github.com/OneOfOne/xxhash v1.2.2 h1:KMrpdQIwFcEqXDklaen+P1axHaj9BSKzvpUUfnHldSE= github.com/OneOfOne/xxhash v1.2.2/go.mod h1:HSdplMjZKSmBqAxg5vPj2TmRDmfkzw+cTzAElWljhcU= -github.com/Shopify/goreferrer v0.0.0-20181106222321-ec9c9a553398/go.mod h1:a1uqRtAwp2Xwc6WNPJEufxJ7fx3npB4UV/JOLmbu5I0= 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/Workiva/go-datastructures v1.0.53 h1:J6Y/52yX10Xc5JjXmGtWoSSxs3mZnGSaq37xZZh7Yig= -github.com/Workiva/go-datastructures v1.0.53/go.mod h1:1yZL+zfsztete+ePzZz/Zb1/t5BnDuE2Ya2MMGhzP6A= 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/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/ajg/form v1.5.1/go.mod h1:uL1WgH+h2mgNtvBq0339dVnzXdBETtL2LeUXaIv25UY= github.com/ajstarks/svgo v0.0.0-20180226025133-644b8db467af/go.mod h1:K08gAheRH3/J6wwsYMMT4xOr94bZjxIelGM0+d/wbFw= -github.com/alecthomas/participle/v2 v2.0.0-alpha7 h1:cK4vjj0VSgb3lN1nuKA5F7dw+1s1pWBe5bx7nNCnN+c= 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= @@ -118,6 +264,9 @@ github.com/armon/go-radix v0.0.0-20180808171621-7fddfc383310/go.mod h1:ufUuZ+zHj 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-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= @@ -128,11 +277,12 @@ github.com/aws/aws-sdk-go-v2/service/route53 v1.1.1/go.mod h1:rLiOUrPLW/Er5kRcQ7 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/aymerick/raymond v2.0.3-0.20180322193309-b565731e1464+incompatible/go.mod h1:osfaiScAUVup+UC9Nfq76eWqDhXlp+4UYaA8uhTBO6g= 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= github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6rlkpw= +github.com/bgentry/go-netrc v0.0.0-20140422174119-9fd32a8b3d3d h1:xDfNPAt8lFiC1UJrqV3uuy861HCTo708pDMbjHHdCas= +github.com/bgentry/go-netrc v0.0.0-20140422174119-9fd32a8b3d3d/go.mod h1:6QX/PXZ00z/TKoufEY6K/a0k6AhaJrQKdFe6OfVXsa4= 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= @@ -141,8 +291,8 @@ github.com/boltdb/bolt v1.3.1/go.mod h1:clJnj/oiGkjum5o1McbSZDSLxVThjynRyGBgiAx2 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 v0.22.2 h1:vBZ+lGGd1XubpOWO67ITJpAEsICWhA0YzqkcpkgNBfo= github.com/btcsuite/btcd/btcec/v2 v2.1.2/go.mod h1:ctjw4H1kknNJmRN4iP1R7bTQ+v3GJkZBd6mui8ZsAZE= 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= @@ -162,53 +312,69 @@ github.com/btcsuite/snappy-go v0.0.0-20151229074030-0bdef8d06723/go.mod h1:8woku 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/bwesterb/go-ristretto v1.2.0/go.mod h1:fUIoIZaG73pV5biE2Blr2xEzDoMj7NFEuV9ekS419A0= +github.com/bytedance/sonic v1.5.0/go.mod h1:ED5hyg4y6t3/9Ku1R6dU/4KyJ48DZ4jPhfY1O2AihPM= +github.com/bytedance/sonic v1.9.1 h1:6iJ6NqdoxCDr6mbY8h18oSO+cShGSMRGCEo7F2h0x8s= +github.com/bytedance/sonic v1.9.1/go.mod h1:i736AoUSYt75HyZLoJW9ERYxcy6eaN6h4BZXU064P/U= github.com/c-bata/go-prompt v0.2.2/go.mod h1:VzqtzE2ksDBcdln8G7mk2RX9QyGjH+OVqOCSiVIqS34= 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= +github.com/cenkalti/backoff/v4 v4.1.1/go.mod h1:scbssz8iZGpm3xbr14ovlUdkxfGXNInqkPWOWmG2CLw= +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 h1:a6HrQnmkObjyL+Gs60czilIUGqrzKutQD6XZog3p+ko= 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.1.2 h1:YRXhKfTDauu4ajMg1TPgFO5jnlC2HCbmLXMcTG5cbYE= -github.com/cespare/xxhash/v2 v2.1.2/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/cheggaaa/pb v1.0.27/go.mod h1:pQciLPpbU0oxA0h+VJYYLxO+XeDQb5pZijXscXHm81s= +github.com/chenzhuoyu/base64x v0.0.0-20211019084208-fb5309c8db06/go.mod h1:DH46F32mSOjUmXrMHnKwZdA8wcEefY7UVqBKYGjpdQY= +github.com/chenzhuoyu/base64x v0.0.0-20221115062448-fe3a3abad311 h1:qSGYFH7+jGhDF8vLC+iwCD4WpbV1EBDSzWkJODFLams= +github.com/chenzhuoyu/base64x v0.0.0-20221115062448-fe3a3abad311/go.mod h1:b583jCggY9gE99b6G5LEC39OIiVsWj+R97kbl5odCEk= github.com/chzyer/logex v1.1.10/go.mod h1:+Ywpsq7O8HXn0nuIou7OrIPyXbp3wmkHB+jjWRnGsAI= +github.com/chzyer/logex v1.2.1 h1:XHDu3E6q+gdHgsdTPH6ImJMIp436vR6MPtH8gP05QzM= +github.com/chzyer/logex v1.2.1/go.mod h1:JLbx6lG2kDbNRFnfkgvh4eRJRPX1QCoOIWomwysCBrQ= github.com/chzyer/readline v0.0.0-20180603132655-2972be24d48e/go.mod h1:nSuG5e5PlCu98SY8svDHJxuZscDgtXS6KTTbou5AhLI= +github.com/chzyer/readline v1.5.1 h1:upd/6fQk4src78LMRzh5vItIt361/o4uq553V8B5sGI= +github.com/chzyer/readline v1.5.1/go.mod h1:Eh+b79XXUwfKfcPLepksvw2tcLE/Ct21YObkaSkeBlk= github.com/chzyer/test v0.0.0-20180213035817-a1ea475d72b1/go.mod h1:Q3SI9o4m/ZMnBNeIyt5eFwwo7qiLfzFZmjNmxjkiQlU= +github.com/chzyer/test v1.0.0 h1:p3BQDXSxOhOG0P9z6/hGnII4LGiEPOYBhs8asl/fC04= +github.com/chzyer/test v1.0.0/go.mod h1:2JlltgoNkt4TW/z9V/IzDdFaMTM2JPIi26O1pF38GC8= github.com/circonus-labs/circonus-gometrics v2.3.1+incompatible/go.mod h1:nmEj6Dob7S7YxXgwXpfOuvO54S+tGdZdw9fuRZt25Ag= 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/cockroachdb/apd/v3 v3.1.0 h1:MK3Ow7LH0W8zkd5GMKA1PvS9qG3bWFI95WaVNfyZJ/w= +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= +github.com/cncf/udpa/go v0.0.0-20210930031921-04548b0d99d4/go.mod h1:6pvJx4me5XPnfI9Z40ddWsdw2W/uZgQLFXToKeRcDiI= +github.com/cncf/xds/go v0.0.0-20210312221358-fbca930ec8ed/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= +github.com/cncf/xds/go v0.0.0-20210805033703-aa0b78936158/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= +github.com/cncf/xds/go v0.0.0-20210922020428-25de7278fc84/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= +github.com/cncf/xds/go v0.0.0-20211001041855-01bcc9b48dfe/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= +github.com/cncf/xds/go v0.0.0-20211011173535-cb28da3451f1/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= +github.com/cockroachdb/apd/v2 v2.0.2 h1:weh8u7Cneje73dDh+2tEVLUvyBc89iwepWCD8b8034E= +github.com/cockroachdb/apd/v2 v2.0.2/go.mod h1:DDxRlzC2lo3/vSlmSoS7JkqbbrARPuFOGr0B9pvN3Gw= github.com/cockroachdb/datadriven v0.0.0-20190809214429-80d97fb3cbaa/go.mod h1:zn76sxSg3SzpJ0PPJaLDCu+Bu0Lg3sKTORVIj19EIF8= -github.com/cockroachdb/datadriven v1.0.0/go.mod h1:5Ib8Meh+jk1RlHIXej6Pzevx/NLlNvQB9pmSBZErGA4= -github.com/cockroachdb/datadriven v1.0.2/go.mod h1:a9RdTaap04u637JoCzcUoIcDmvwSUtcUFtT/C3kJlTU= -github.com/cockroachdb/errors v1.6.1/go.mod h1:tm6FTP5G81vwJ5lC0SizQo374JNCOPrHyXGitRJoDqM= -github.com/cockroachdb/errors v1.8.1/go.mod h1:qGwQn6JmZ+oMjuLwjWzUNqblqk0xl4CVV3SQbGwK7Ac= -github.com/cockroachdb/errors v1.9.1 h1:yFVvsI0VxmRShfawbt/laCIDy/mtTqqnvoNgiy5bEV8= -github.com/cockroachdb/errors v1.9.1/go.mod h1:2sxOtL2WIc096WSZqZ5h8fa17rdDq9HZOZLBCor4mBk= -github.com/cockroachdb/logtags v0.0.0-20190617123548-eb05cc24525f/go.mod h1:i/u985jwjWRlyHXQbwatDASoW0RMlZ/3i9yJHE2xLkI= -github.com/cockroachdb/logtags v0.0.0-20211118104740-dabe8e521a4f/go.mod h1:Vz9DsVWQQhf3vs21MhPMZpMGSht7O/2vFW2xusFUVOs= +github.com/cockroachdb/errors v1.10.0 h1:lfxS8zZz1+OjtV4MtNWgboi/W5tyLEB6VQZBXN+0VUU= +github.com/cockroachdb/errors v1.10.0/go.mod h1:lknhIsEVQ9Ss/qKDBQS/UqFSvPQjOwNq2qyKAxtHRqE= github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b h1:r6VH0faHjZeQy818SGhaone5OnYfxFR/+AzdY3sf5aE= github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b/go.mod h1:Vz9DsVWQQhf3vs21MhPMZpMGSht7O/2vFW2xusFUVOs= -github.com/cockroachdb/pebble v0.0.0-20220817183557-09c6e030a677 h1:qbb/AE938DFhOajUYh9+OXELpSF9KZw2ZivtmW6eX1Q= -github.com/cockroachdb/pebble v0.0.0-20220817183557-09c6e030a677/go.mod h1:890yq1fUb9b6dGNwssgeUO5vQV9qfXnCPxAJhBQfXw0= -github.com/cockroachdb/redact v1.0.8/go.mod h1:BVNblN9mBWFyMyqK1k3AAiSxhvhfK2oOZZ2lK+dpvRg= -github.com/cockroachdb/redact v1.1.3 h1:AKZds10rFSIj7qADf0g46UixK8NNLwWTNdCIGS5wfSQ= -github.com/cockroachdb/redact v1.1.3/go.mod h1:BVNblN9mBWFyMyqK1k3AAiSxhvhfK2oOZZ2lK+dpvRg= -github.com/cockroachdb/sentry-go v0.6.1-cockroachdb.2/go.mod h1:8BT+cPK6xvFOcRlk0R8eg+OTkcqI6baNH4xAkpiYVvQ= +github.com/cockroachdb/redact v1.1.5 h1:u1PMllDkdFfPWaNGMyLD1+so+aq3uUItthCFqzwPJ30= +github.com/cockroachdb/redact v1.1.5/go.mod h1:BVNblN9mBWFyMyqK1k3AAiSxhvhfK2oOZZ2lK+dpvRg= github.com/codahale/hdrhistogram v0.0.0-20161010025455-3a0bb77429bd/go.mod h1:sE/e/2PUdi/liOCUjSTXgM1o87ZssimdTWN964YiIeI= -github.com/codegangsta/inject v0.0.0-20150114235600-33e0aa1cb7c0/go.mod h1:4Zcjuz89kmFXt9morQgcfYZAYZ5n8WHjt81YYWIwtTM= 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.34.28 h1:gwryf55P1SWMUP4nOXpRVI2D0yPoYEzN+IBqmRBOsDc= -github.com/cometbft/cometbft v0.34.28/go.mod h1:L9shMfbkZ8B+7JlwANEr+NZbBcn+hBpwdbeYvA5rLCw= -github.com/cometbft/cometbft-db v0.7.0 h1:uBjbrBx4QzU0zOEnU8KxoDl18dMNgDh+zZRUE0ucsbo= -github.com/cometbft/cometbft-db v0.7.0/go.mod h1:yiKJIm2WKrt6x8Cyxtq9YTEcIMPcEe4XPxhgX59Fzf0= +github.com/cometbft/cometbft v0.37.2 h1:XB0yyHGT0lwmJlFmM4+rsRnczPlHoAKFX6K8Zgc2/Jc= +github.com/cometbft/cometbft v0.37.2/go.mod h1:Y2MMMN//O5K4YKd8ze4r9jmk4Y7h0ajqILXbH5JQFVs= +github.com/cometbft/cometbft-db v0.8.0 h1:vUMDaH3ApkX8m0KZvOFFy9b5DZHBAjsnEuo9AKVZpjo= +github.com/cometbft/cometbft-db v0.8.0/go.mod h1:6ASCP4pfhmrCBpfk01/9E1SI29nD3HfVHrY4PG8x5c0= 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= @@ -220,38 +386,43 @@ github.com/coreos/etcd v3.3.10+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc 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.3.3-0.20220203105225-a9a7ef127534/go.mod h1:Y58oyj3AT4RCenI/lSvhwexgC+NSVTIJ3seZv2GcEnc= +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.4 h1:n7C2ngKXo7UC9gNyMNLbzqz7Asuf+7Qv4gnX/rOdQ44= -github.com/cosmos/btcutil v1.0.4/go.mod h1:Ffqc8Hn6TJUdDgHBwIZLtrLQC1KdJ9jGJl/TvgUaxbU= -github.com/cosmos/cosmos-db v0.0.0-20221226095112-f3c38ecb5e32 h1:zlCp9n3uwQieELltZWHRmwPmPaZ8+XoL2Sj+A2YJlr8= -github.com/cosmos/cosmos-db v0.0.0-20221226095112-f3c38ecb5e32/go.mod h1:kwMlEC4wWvB48zAShGKVqboJL6w4zCLesaNQ3YLU2BQ= -github.com/cosmos/cosmos-proto v1.0.0-beta.1 h1:iDL5qh++NoXxG8hSy93FdYJut4XfgbShIocllGaXx/0= -github.com/cosmos/cosmos-proto v1.0.0-beta.1/go.mod h1:8k2GNZghi5sDRFw/scPL8gMSowT1vDA+5ouxL8GjaUE= -github.com/cosmos/cosmos-sdk v0.45.16 h1:5ba/Bh5/LE55IwHQuCU4fiG4eXeDKtSWzehXRpaKDcw= -github.com/cosmos/cosmos-sdk v0.45.16/go.mod h1:bScuNwWAP0TZJpUf+SHXRU3xGoUPp+X9nAzfeIXts40= +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-proto v1.0.0-beta.2 h1:X3OKvWgK9Gsejo0F1qs5l8Qn6xJV/AzgIWR2wZ8Nua8= +github.com/cosmos/cosmos-proto v1.0.0-beta.2/go.mod h1:+XRCLJ14pr5HFEHIUcn51IKXD1Fy3rkEQqt4WqmN4V0= +github.com/cosmos/cosmos-sdk v0.47.5 h1:n1+WjP/VM/gAEOx3TqU2/Ny734rj/MX1kpUnn7zVJP8= +github.com/cosmos/cosmos-sdk v0.47.5/go.mod h1:EHwCeN9IXonsjKcjpS12MqeStdZvIdxt3VYXhus3G3c= github.com/cosmos/go-bip39 v0.0.0-20180819234021-555e2067c45d/go.mod h1:tSxLoYXyBmiFeKpvmq4dzayMdCjCnu8uqmCysIGBT2Y= 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/gorocksdb v1.2.0 h1:d0l3jJG8M4hBouIZq0mDUHZ+zjOx044J3nGRskwTb4Y= -github.com/cosmos/gorocksdb v1.2.0/go.mod h1:aaKvKItm514hKfNJpUJXnnOWeBnk2GL4+Qw9NHizILw= -github.com/cosmos/iavl v0.19.5 h1:rGA3hOrgNxgRM5wYcSCxgQBap7fW82WZgY78V9po/iY= -github.com/cosmos/iavl v0.19.5/go.mod h1:X9PKD3J0iFxdmgNLa7b2LYWdsGd90ToV5cAONApkEPw= -github.com/cosmos/ibc-go/v4 v4.4.2 h1:PG4Yy0/bw6Hvmha3RZbc53KYzaCwuB07Ot4GLyzcBvo= -github.com/cosmos/ibc-go/v4 v4.4.2/go.mod h1:j/kD2JCIaV5ozvJvaEkWhLxM2zva7/KTM++EtKFYcB8= +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.0 h1:fTVznVlepH0KK8NyKq8w+U7c2L6jofa27aFX6YGlm38= +github.com/cosmos/iavl v0.20.0/go.mod h1:WO7FyvaZJoH65+HFOsDir7xU9FWk2w9cHXNW1XHcl7A= +github.com/cosmos/ibc-apps/middleware/packet-forward-middleware/v7 v7.0.0 h1:i9esYyZ5ExpZOgxrLMQhY2jDTVYiaD8yUeqXN9QBgbk= +github.com/cosmos/ibc-apps/middleware/packet-forward-middleware/v7 v7.0.0/go.mod h1:fctjEnz9xaBFOlmYYPdKL8Hs1Y3GUKilSwsJdqBb5QU= +github.com/cosmos/ibc-go/v7 v7.2.0 h1:dx0DLUl7rxdyZ8NiT6UsrbzKOJx/w7s+BOaewFRH6cg= +github.com/cosmos/ibc-go/v7 v7.2.0/go.mod h1:OOcjKIRku/j1Xs1RgKK0yvKRrJ5iFuZYMetR1n3yMlc= +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/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.12.2 h1:/XYaBlE2BJxtvpkHiBm97gFGSGmYGKunKyF3nNqAXZA= github.com/cosmos/ledger-cosmos-go v0.12.2/go.mod h1:ZcqYgnfNJ6lAXe4HPtWgarNEY+B74i+2/8MhZw4ziiI= +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/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.2/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= -github.com/creachadair/taskgroup v0.3.2 h1:zlfutDS+5XG40AOxcHDSThxKzns8Tnr9jnr6VqkYlkM= -github.com/creachadair/taskgroup v0.3.2/go.mod h1:wieWwecHVzsidg2CsUnFinW1faVN4+kq+TDlRJQ0Wbk= +github.com/creachadair/taskgroup v0.4.2 h1:jsBLdAJE42asreGss2xZGZ8fJra7WtwnHWeJFxv2Li8= +github.com/creachadair/taskgroup v0.4.2/go.mod h1:qiXUOSrbwAY3u0JPGTzObbE3yf9hcXHDKBZ2ZjpCbgM= 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/cucumber/common/gherkin/go/v22 v22.0.0 h1:4K8NqptbvdOrjL9DEea6HFjSpbdT9+Q5kgLpmmsHYl0= -github.com/cucumber/common/messages/go/v17 v17.1.1 h1:RNqopvIFyLWnKv0LfATh34SWBhXeoFTJnSrgm9cT/Ts= 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= @@ -263,19 +434,20 @@ github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSs 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 h1:YLtO71vCjJRCBcrPMtQ9nqBsqpA1m5sE92cU+pd5Mcc= 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/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 v1.6.0/go.mod h1:zwt7syl517jmP8s94KqSxTlM6IMsdhYy6psNgSztDR4= github.com/dgraph-io/badger/v2 v2.2007.4 h1:TRWBQg8UrlUhaFdco01nO2uXwzKS7zd+HVdwV/GHc4o= github.com/dgraph-io/badger/v2 v2.2007.4/go.mod h1:vSw/ax2qojzbN6eXHIx6KPKtCSHJN/Uz0X0VPruTIhk= 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 h1:jh22xisGBjrEVnRZ1DVTpBVQm0Xndu8sMl0CWDzSIBI= 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= @@ -292,8 +464,8 @@ github.com/dop251/goja v0.0.0-20211011172007-d99e4b8cbf48/go.mod h1:R9ET47fwRVRP 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-0.20200219035652-afde56e7acac h1:opbrjaN/L8gg6Xh5D04Tem+8xVcz6ajZlGCs49mQgyg= -github.com/dustin/go-humanize v1.0.1-0.20200219035652-afde56e7acac/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk= +github.com/dustin/go-humanize v1.0.1 h1:GzkhY7T5VNhEkwH0PVJgjz+fX1rhBrR7pRT3mDkpeCY= +github.com/dustin/go-humanize v1.0.1/go.mod h1:Mu1zIs6XwVuF/gI1OepvI0qD18qycQx+mFykh5fBlto= github.com/dvsekhvalnov/jose2go v1.5.0 h1:3j8ya4Z4kMCwT5nXIKFSV84YS+HdqSSO0VsTQxaLAeM= github.com/dvsekhvalnov/jose2go v1.5.0/go.mod h1:QsHjhyTlD/lAVqn/NSbVZmSCGeDehTB/mPZadG+mhXU= github.com/eapache/go-resiliency v1.1.0/go.mod h1:kFI+JgMyC7bLPUVY133qvEBtVayf5mFgVsvEsIPBvNs= @@ -301,52 +473,48 @@ github.com/eapache/go-xerial-snappy v0.0.0-20180814174437-776d5712da21/go.mod h1 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/eknkc/amber v0.0.0-20171010120322-cdade1c07385/go.mod h1:0vRUJqYpeSZifjYj7uP3BG/gKcuzL9xWVV/Y+cK33KM= +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= github.com/envoyproxy/go-control-plane v0.9.4/go.mod h1:6rpuAdCZL397s3pYoYcLgu1mIlRU8Am5FuJP05cCM98= +github.com/envoyproxy/go-control-plane v0.9.7/go.mod h1:cwu0lG7PUMfa9snN8LXBig5ynNVH9qI8YYLbd1fK2po= +github.com/envoyproxy/go-control-plane v0.9.9-0.20201210154907-fd9021fe5dad/go.mod h1:cXg6YxExXjJnVBQHBLXeUAgxn2UodCpnH306RInaBQk= +github.com/envoyproxy/go-control-plane v0.9.9-0.20210217033140-668b12f5399d/go.mod h1:cXg6YxExXjJnVBQHBLXeUAgxn2UodCpnH306RInaBQk= +github.com/envoyproxy/go-control-plane v0.9.9-0.20210512163311-63b5d3c536b0/go.mod h1:hliV/p42l8fGbc6Y9bQ70uLwIvmJyVE5k4iMKlh8wCQ= +github.com/envoyproxy/go-control-plane v0.9.10-0.20210907150352-cf90f659a021/go.mod h1:AFq3mo9L8Lqqiid3OhADV3RfLJnjiw63cSpi+fDTRC0= +github.com/envoyproxy/go-control-plane v0.10.2-0.20220325020618-49ff273808a1/go.mod h1:KJwIaB5Mv44NWtYuAOFCVOjcI94vtpEz2JU/D2v6IjE= github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c= -github.com/etcd-io/bbolt v1.3.3/go.mod h1:ZF2nL25h33cCyBtcyWeZ2/I3HQOfTP+0PIEvHjkjCrw= github.com/ethereum/go-ethereum v1.10.17/go.mod h1:Lt5WzjM07XlXc95YzrhosmR4J9Ahd6X2wyEV2SvGhk0= -github.com/facebookgo/ensure v0.0.0-20200202191622-63f1cf65ac4c h1:8ISkoahWXwZR41ois5lSJBSVw4D0OV19Ht/JSTzvSv0= -github.com/facebookgo/stack v0.0.0-20160209184415-751773369052 h1:JWuenKqqX8nojtoVVWjGfOF9635RETekkoH6Cc9SX0A= -github.com/facebookgo/subset v0.0.0-20200203212716-c811ad88dec4 h1:7HZCaLC5+BZpmbhCOZJ293Lz68O7PYrF2EzeiFMwCLk= -github.com/fasthttp-contrib/websocket v0.0.0-20160511215533-1f3b11f56072/go.mod h1:duJ4Jxv5lDcvg4QuQr0oowTf7dz4/CR8NtyCooz9HL8= github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5KwzbycvMj4= github.com/fatih/color v1.13.0/go.mod h1:kLAiJbzzSOZDVNGyDpeOxJ47H46qBXwg5ILebYFFOfk= -github.com/fatih/structs v1.1.0/go.mod h1:9NiDSp5zOcgEDl+j00MP/WkGVPOlPRLejGD8Ga6PJ7M= github.com/felixge/httpsnoop v1.0.1/go.mod h1:m8KPJKqk1gH5J9DgRY2ASl2lWCfGKXixSwevea8zH2U= github.com/felixge/httpsnoop v1.0.2 h1:+nS9g82KMXccJ/wp0zyRW9ZBHFETmMGtkk+2CTTrW4o= github.com/felixge/httpsnoop v1.0.2/go.mod h1:m8KPJKqk1gH5J9DgRY2ASl2lWCfGKXixSwevea8zH2U= github.com/fjl/memsize v0.0.0-20190710130421-bcb5799ab5e5/go.mod h1:VvhXpOYNQvB+uIk2RvXzuaQtkQJzzIx6lSBe1xv7hi0= -github.com/flosch/pongo2 v0.0.0-20190707114632-bbf5a6c351f4/go.mod h1:T9YF2M40nIgbVgp3rreNmTged+9HrbNTIQf1PsaIiTA= 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/franela/goblin v0.0.0-20200105215937-c9ffbefa60db/go.mod h1:7dvUGVsVBjqR7JHJk0brhHOZYGmfBYOrK0ZhYMEtBr4= github.com/franela/goreq v0.0.0-20171204163338-bcd34c9993f8/go.mod h1:ZhphrRTfi2rbfLwlschooIH4+wKKDR4Pdxhh+TRoA20= -github.com/frankban/quicktest v1.14.3 h1:FJKSZTDHjyhriyC81FLQ0LY93eSai0ZyR/ZIkd3ZUKE= +github.com/frankban/quicktest v1.14.4 h1:g2rn0vABPOOXmZUj+vbmUp0lPoXEMuhTpIluN0XL9UY= github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= github.com/fsnotify/fsnotify v1.4.9/go.mod h1:znqG4EE+3YCdAaPaxE2ZRY/06pZUdp0tY4IgpuI1SZQ= github.com/fsnotify/fsnotify v1.6.0 h1:n+5WquG0fcWoWp6xPWfHdbskMCQaFnG6PfBrh1Ky4HY= github.com/fsnotify/fsnotify v1.6.0/go.mod h1:sl3t1tCWJFWoRz9R8WJCbQihKKwmorjAbSClcnxKAGw= -github.com/gavv/httpexpect v2.0.0+incompatible/go.mod h1:x+9tiU1YnrOvnB725RkpoLv1M62hOWzwo5OXotisrKc= +github.com/gabriel-vasile/mimetype v1.4.2 h1:w5qFW6JKBz9Y393Y4q372O9A7cUSequkh1Q7OhCmWKU= +github.com/gabriel-vasile/mimetype v1.4.2/go.mod h1:zApsH/mKG4w07erKIaJPFiX0Tsq9BFQgN3qGY5GnNgA= 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.12.0/go.mod h1:NSap0JBYWzHND8oMbyi0+XZhUalc1TBdRL1M71JZW2c= -github.com/getsentry/sentry-go v0.17.0 h1:UustVWnOoDFHBS7IJUB2QK/nB5pap748ZEp0swnQJak= -github.com/getsentry/sentry-go v0.17.0/go.mod h1:B82dxtBvxG0KaPD8/hfSV+VcHD+Lg/xUS4JuQn1P4cM= -github.com/ghemawat/stream v0.0.0-20171120220530-696b145b53b9/go.mod h1:106OIgooyS7OzLDOpUGgm9fA3bQENb/cFSyyBmMoJDs= +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/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04= -github.com/gin-contrib/sse v0.0.0-20190301062529-5545eab6dad3/go.mod h1:VJ0WA2NBN22VlZ2dKZQPAPnyWw5XTlK1KymzLKsr59s= github.com/gin-contrib/sse v0.1.0 h1:Y/yl/+YNO8GZSjAhjMsSuLt29uWRFHdHYUb5lYOV9qE= github.com/gin-contrib/sse v0.1.0/go.mod h1:RHrZQHXnP2xjPF+u1gW/2HnVO7nvIa9PG3Gm+fLHvGI= -github.com/gin-gonic/gin v1.4.0/go.mod h1:OW2EZn3DO8Ln9oIKOvM++LBO+5UPHJJDH72/q/3rZdM= -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.9.1 h1:4idEAncQnU5cB7BeOkPtxjfCSye0AAm1R0RVIqJ+Jmg= +github.com/gin-gonic/gin v1.9.1/go.mod h1:hPrL7YrpYKXt5YId3A/Tnip5kqbEAP+KLuI3SUcPTeU= 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-check/check v0.0.0-20180628173108-788fd7840127/go.mod h1:9ES+weclKsC9YodN5RgxqK/VD9HM9JsCSh7rNhMZE98= github.com/go-chi/chi/v5 v5.0.0/go.mod h1:BBug9lr0cqtdAhsu6R4AAdvufI0/XBzAQSsUqJpoZOs= -github.com/go-errors/errors v1.0.1/go.mod h1:f4zRHt4oKfwPJE5k8C9vpYG+aDHdBFUsgrm6/TyX73Q= github.com/go-errors/errors v1.4.2 h1:J6MZopCL4uSllY1OfXM374weqZFFItUbrImctkmUxIA= 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= @@ -356,26 +524,23 @@ github.com/go-kit/kit v0.9.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2 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.0/go.mod h1:NwTd00d/i8cPZ3xOwwiv2PO5MOcx78fFErGNcVmBjv0= 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= github.com/go-logfmt/logfmt v0.4.0/go.mod h1:3RMwSq7FuexP4Kalkev3ejPJsZTpXXBr9+V4qmtdjCk= github.com/go-logfmt/logfmt v0.5.0/go.mod h1:wCYkCAKZfumFQihp8CzCvQ3paCTfi41vtzG1KdI/P7A= -github.com/go-logfmt/logfmt v0.5.1 h1:otpy5pqBCBZ1ng9RQ0dPu4PN7ba75Y/aA+UpowDyNVA= -github.com/go-logfmt/logfmt v0.5.1/go.mod h1:WYhtIu8zTZfxdn5+rREduYbwxfcBr/Vr6KEVveWlfTs= -github.com/go-martini/martini v0.0.0-20170121215854-22fa46961aab/go.mod h1:/P9AEU963A2AYjv4d1V5eVL1CQbEJq6aCNHDDjibzu8= +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-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= -github.com/go-playground/universal-translator v0.17.0/go.mod h1:UkSxE5sNxxRwHyU+Scu5vgOQjsIJAF8j9muTVoKLVtA= -github.com/go-playground/universal-translator v0.18.0 h1:82dyy6p4OuJq4/CByFNOn/jYrnRPArHwAcmLoJZxyho= -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/assert/v2 v2.2.0/go.mod h1:VDjEfimB/XKnb+ZQfWdccd7VUvScMdVu0Titje2rxJ4= +github.com/go-playground/locales v0.14.1 h1:EWaQ/wswjilfKLTECiXz7Rh+3BjFhfDFKv/oXslEjJA= +github.com/go-playground/locales v0.14.1/go.mod h1:hxrqLVvrK65+Rwrd5Fc6F2O76J/NuW9t0sjnWqG1slY= +github.com/go-playground/universal-translator v0.18.1 h1:Bcnm0ZwsGyWbCzImXv+pAJnYK9S473LQFuzCbDbfSFY= +github.com/go-playground/universal-translator v0.18.1/go.mod h1:xekY+UJKNuX9WP91TpwSH2VMlDf28Uj24BCp08ZFTUY= +github.com/go-playground/validator/v10 v10.14.0 h1:vgvQWe3XCz3gIeFDm/HnTIbj6UGmg/+t63MyGU2n5js= +github.com/go-playground/validator/v10 v10.14.0/go.mod h1:9iXMNT7sEkjXb0I+enO7QXmzG6QCsPWY4zveKFVRSyU= 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= @@ -386,33 +551,44 @@ github.com/gobwas/pool v0.2.0 h1:QEmUOlnSjWtnpRGHF3SauEiOsy82Cup83Vf2LcMlnc8= github.com/gobwas/pool v0.2.0/go.mod h1:q8bcK0KcYlCgd9e7WYLm9LpyS+YeLd8JVDW6WezmKEw= github.com/gobwas/ws v1.0.2 h1:CoAavW/wd/kulfZmSIBt6p24n4j7tHgNVCjsfHVNUbo= github.com/gobwas/ws v1.0.2/go.mod h1:szmBTxLgaFppYjEmNtny/v3w89xOydFnnZMcgRRu/EM= -github.com/goccy/go-json v0.9.11 h1:/pAaQDLHEoCq/5FFmSKBswWmK6H0e8g4159Kc/X/nqk= +github.com/goccy/go-json v0.10.2 h1:CrxCmQqYDkv1z7lO7Wbh2HN93uovUHgrECaO5ZrCXAU= +github.com/goccy/go-json v0.10.2/go.mod h1:6MelG93GURQebXPDq3khkgXZkazVtN9CRI+MGFi0w8I= 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/gofrs/uuid v4.3.0+incompatible h1:CaSVZxm5B+7o45rtab4jC2G37WGYX1zQfuU2i6DSvnc= -github.com/gogo/gateway v1.1.0 h1:u0SuhL9+Il+UbjM9VIE3ntfRujKbvVpFvNB4HbjeVQ0= -github.com/gogo/gateway v1.1.0/go.mod h1:S7rR8FRQyG3QFESeSv4l2WnsyzlCLG0CzBbUUo/mbic= -github.com/gogo/googleapis v0.0.0-20180223154316-0cd9801be74a/go.mod h1:gf4bu3Q80BeJ6H1S1vYPm8/ELATdvryBaNFGgqEef3s= +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/gogo/status v1.1.0/go.mod h1:BFv9nrluPLmrS0EmGVvLaPNmRosr9KapBYd5/hpY1WM= -github.com/golang-jwt/jwt v3.2.2+incompatible/go.mod h1:8pz2t5EyA70fFQQSrl6XZXzqecmYZeUEB8OUGHkxJ+I= +github.com/gogo/protobuf v1.1.1/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ= +github.com/gogo/protobuf v1.2.0/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ= +github.com/gogo/protobuf v1.2.1/go.mod h1:hp+jE20tsWTFYpLwKvXlhS1hjn+gTNwPg2I6zVXpSg4= +github.com/gogo/protobuf v1.3.1/go.mod h1:SlYgWuQ5SjCEi6WLHjHCa1yvBfUnHcTbrrZtXPKa29o= +github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q= +github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q= 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.1.0 h1:/d3pCKDPWNnvIWe0vVUpNP32qc8U3PDVxySP/y360qE= +github.com/golang/glog v1.1.0/go.mod h1:pfYeQZ3JWZoXTV5sFc986z3HTpwQs9At6P4ImfuP3NQ= github.com/golang/groupcache v0.0.0-20160516000752-02826c3e7903/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= github.com/golang/groupcache v0.0.0-20190702054246-869f871628b6/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= github.com/golang/groupcache v0.0.0-20191227052852-215e87163ea7/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= github.com/golang/groupcache v0.0.0-20200121045136-8c9f03a8e57e/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= +github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da h1:oI5xCqsCo564l8iNU+DwB5epxmsaqB+rhGL0m5jtYqE= +github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= +github.com/golang/mock v1.1.1/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A= github.com/golang/mock v1.2.0/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A= github.com/golang/mock v1.3.1/go.mod h1:sBzyDLLjw3U8JLTeZvSv8jJB+tU5PVekmnlKIyFUx0Y= github.com/golang/mock v1.4.0/go.mod h1:UOMv5ysSaYNkG+OFQykRIcU/QvvxJf3p21QfJ2Bt3cw= github.com/golang/mock v1.4.1/go.mod h1:UOMv5ysSaYNkG+OFQykRIcU/QvvxJf3p21QfJ2Bt3cw= github.com/golang/mock v1.4.3/go.mod h1:UOMv5ysSaYNkG+OFQykRIcU/QvvxJf3p21QfJ2Bt3cw= github.com/golang/mock v1.4.4/go.mod h1:l3mdAwkq5BuhzHwde/uurv3sEJeZMXNpwsxVWU71h+4= +github.com/golang/mock v1.5.0/go.mod h1:CWnOUgYIOo4TcNZ0wHX3YZCqsaM1I1Jvs6v3mP3KVu8= github.com/golang/mock v1.6.0 h1:ErTB+efbowRARo13NNdxyJji2egdxLGQhRaY+DUumQc= +github.com/golang/mock v1.6.0/go.mod h1:p6yTPP+5HYm5mzsMV8JkE6ZKdX+/wYM6Hr+LicevLPs= github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= github.com/golang/protobuf v1.3.0/go.mod h1:Qd/q+1AKNOZr9uGQzbzCmRO6sUih6GTPZv6a1/R87v0= github.com/golang/protobuf v1.3.1/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= @@ -429,14 +605,15 @@ github.com/golang/protobuf v1.4.1/go.mod h1:U8fpvMrcmy5pZrNK1lt4xCsGvpyWQ/VVv6QD github.com/golang/protobuf v1.4.2/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= github.com/golang/protobuf v1.4.3/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= github.com/golang/protobuf v1.5.0/go.mod h1:FsONVRAS9T7sI+LIUmWTfcYkHO4aIWwzhcaSAoJOfIk= -github.com/golang/protobuf v1.5.2 h1:ROPKBNFfQgOUMifHyP+KYbvpjbdoFNs+aK7DXlji0Tw= +github.com/golang/protobuf v1.5.1/go.mod h1:DopwsBzvsk0Fs44TXzsVbJyPhcCPeIwnvohx4u74HPM= github.com/golang/protobuf v1.5.2/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY= +github.com/golang/protobuf v1.5.3 h1:KhyjKVUg7Usr/dYsdSqoFveMYd5ko72D+zANwlG1mmg= +github.com/golang/protobuf v1.5.3/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY= github.com/golang/snappy v0.0.0-20180518054509-2e65f85255db/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= 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/gomodule/redigo v1.7.1-0.20190724094224-574c33c3df38/go.mod h1:B4C85qUVwatsJoIUNIfCRsp7qO0iAmpGFZ4EELWSbC4= 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= @@ -450,17 +627,24 @@ github.com/google/go-cmp v0.4.1/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/ github.com/google/go-cmp v0.5.0/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.1/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.2/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= +github.com/google/go-cmp v0.5.3/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.4/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= +github.com/google/go-cmp v0.5.6/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= +github.com/google/go-cmp v0.5.7/go.mod h1:n+brtR0CgQNWTVd5ZUFpTBC8YFBDLK/h/bpaJ8/DtOE= +github.com/google/go-cmp v0.5.8/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= github.com/google/go-cmp v0.5.9 h1:O2Tfq5qg4qc4AmwVlvv0oLiVAGB7enBSJ2x2DqQFi38= -github.com/google/go-querystring v1.0.0/go.mod h1:odCYkC5MyYFN7vkCjXpyrEuKhc/BUO6wN/zVPAxq5ck= +github.com/google/go-cmp v0.5.9/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/martian v2.1.0+incompatible h1:/CP5g8u/VJHijgedC/Legn3BAbAaWPgecwXBIDzw5no= github.com/google/martian v2.1.0+incompatible/go.mod h1:9I4somxYTbIHy5NJKHRl3wXiIaQGbYVAs8BPL6v8lEs= github.com/google/martian/v3 v3.0.0/go.mod h1:y5Zk1BBys9G+gd6Jrk0W3cC1+ELVxBWuIGO+w/tUAp0= github.com/google/martian/v3 v3.1.0/go.mod h1:y5Zk1BBys9G+gd6Jrk0W3cC1+ELVxBWuIGO+w/tUAp0= +github.com/google/martian/v3 v3.2.1/go.mod h1:oBOf6HBosgwRXnUGWUB05QECsc6uvmMiJ3+6W4l/CUk= +github.com/google/martian/v3 v3.3.2 h1:IqNFLAmvJOgVlpdEBiQbDc2EwKW77amAycfTuWKdfvw= github.com/google/orderedcode v0.0.1 h1:UzfcAexk9Vhv8+9pNOgRu41f16lHq725vPwnSeiG/Us= github.com/google/orderedcode v0.0.1/go.mod h1:iVyU4/qPKHY5h/wSd6rZZCDcLJNxiWO6dvsYES2Sb20= github.com/google/pprof v0.0.0-20181206194817-3ea8567a2e57/go.mod h1:zfwlbNMJ+OItoe0UupaVj+oy1omPYYDuagoSzA8v9mc= @@ -473,15 +657,37 @@ github.com/google/pprof v0.0.0-20200708004538-1a94d8640e99/go.mod h1:ZgVRPoUq/hf github.com/google/pprof v0.0.0-20201023163331-3e6fc7fc9c4c/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/pprof v0.0.0-20201203190320-1bf35d6f28c2/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/pprof v0.0.0-20201218002935-b9804c9f04c2/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= +github.com/google/pprof v0.0.0-20210122040257-d980be63207e/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= +github.com/google/pprof v0.0.0-20210226084205-cbba55b83ad5/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= +github.com/google/pprof v0.0.0-20210601050228-01bbb1931b22/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= +github.com/google/pprof v0.0.0-20210609004039-a478d1d731e9/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= +github.com/google/pprof v0.0.0-20210720184732-4bb14d4b1be1/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm40UhjYkI= +github.com/google/s2a-go v0.1.4 h1:1kZ/sQM3srePvKs3tXAvQzo66XfcReoqFpIpIccE7Oc= +github.com/google/s2a-go v0.1.4/go.mod h1:Ej+mSEMGRnqRzjc7VtF+jdBwYG5fuJfiZ8ELkjEwM0A= 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 h1:t6JiXgmwXMjEs8VusXIJk2BXHsn+wx8BZdTaoZ5fu7I= github.com/google/uuid v1.3.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= +github.com/googleapis/enterprise-certificate-proxy v0.0.0-20220520183353-fd19c99a87aa/go.mod h1:17drOmN3MwGY7t0e+Ei9b45FFGA3fBs3x36SsCg1hq8= +github.com/googleapis/enterprise-certificate-proxy v0.1.0/go.mod h1:17drOmN3MwGY7t0e+Ei9b45FFGA3fBs3x36SsCg1hq8= +github.com/googleapis/enterprise-certificate-proxy v0.2.0/go.mod h1:8C0jb7/mgJe/9KK8Lm7X9ctZC2t60YyIpYEI16jx0Qg= +github.com/googleapis/enterprise-certificate-proxy v0.2.3 h1:yk9/cqRKtT9wXZSsRH9aurXEpJX+U6FLtpYTdC3R06k= +github.com/googleapis/enterprise-certificate-proxy v0.2.3/go.mod h1:AwSRAtLfXpU5Nm3pW+v7rGDHp09LsPtGY9MduiEsR9k= github.com/googleapis/gax-go/v2 v2.0.4/go.mod h1:0Wqv26UfaUD9n4G6kQubkQ+KchISgw+vpHVxEJEs9eg= github.com/googleapis/gax-go/v2 v2.0.5/go.mod h1:DWXyrwAJ9X0FpwwEdw+IPEYBICEFu5mhpdKc/us6bOk= +github.com/googleapis/gax-go/v2 v2.1.0/go.mod h1:Q3nei7sK6ybPYH7twZdmQpAd1MKb7pfu6SK+H1/DsU0= +github.com/googleapis/gax-go/v2 v2.1.1/go.mod h1:hddJymUZASv3XPyGkUpKj8pPO47Rmb0eJc8R6ouapiM= +github.com/googleapis/gax-go/v2 v2.2.0/go.mod h1:as02EH8zWkzwUoLbBaFeQ+arQaj/OthfcblKl4IGNaM= +github.com/googleapis/gax-go/v2 v2.3.0/go.mod h1:b8LNqSzNabLiUpXKkY7HAR5jr6bIT99EXz9pXxye9YM= +github.com/googleapis/gax-go/v2 v2.4.0/go.mod h1:XOTVJ59hdnfJLIP/dh8n5CGryZR2LxK9wbMD5+iXC6c= +github.com/googleapis/gax-go/v2 v2.5.1/go.mod h1:h6B0KMMFNtI2ddbGJn3T3ZbwkeT6yqEF02fYlzkUCyo= +github.com/googleapis/gax-go/v2 v2.6.0/go.mod h1:1mjbznJAPHFpesgE5ucqfYEscaz5kMdcIDwU/6+DDoY= +github.com/googleapis/gax-go/v2 v2.11.0 h1:9V9PWXEsWnPpQhu/PeQIkS4eGzMlTLGgt80cUUI8Ki4= +github.com/googleapis/gax-go/v2 v2.11.0/go.mod h1:DxmR61SGKkGLa2xigwuZIQpkCI2S5iydzRfb3peWZJI= +github.com/googleapis/go-type-adapters v1.0.0/go.mod h1:zHW75FOG2aur7gAO2B+MLby+cLsWGBF62rFAi7WjWO4= github.com/googleapis/google-cloud-go-testing v0.0.0-20200911160855-bcd43fbb19e8/go.mod h1:dvDLG8qkwmyD9a/MJJN3XJcT3xFxOKAvTZGvuZmac9g= github.com/gopherjs/gopherjs v0.0.0-20181017120253-0766667cb4d1/go.mod h1:wJfORRmW1u3UXTncJ5qlYoELFm8eSnnEO6hX4iZ3EWY= github.com/gorilla/context v1.1.1/go.mod h1:kBGZzfjB9CEq2AlWe17Uuf7NDRt0dE0s8S51q0aT7Yg= @@ -492,7 +698,6 @@ github.com/gorilla/mux v1.7.3/go.mod h1:1lud6UwP+6orDFRuTfBEV8e9/aOM/c4fVVCaMa2z github.com/gorilla/mux v1.8.0 h1:i40aqfkR1h2SlN9hojwV5ZA91wcXFOvkdNIeFDP5koI= github.com/gorilla/mux v1.8.0/go.mod h1:DVbg23sWSpFRCP0SfiEN6jmj59UnW/n46BH5rLB71So= github.com/gorilla/websocket v0.0.0-20170926233335-4201258b820c/go.mod h1:E7qHFY5m1UJ88s3WnNqhKjPHQ0heANvMoAMk2YaljkQ= -github.com/gorilla/websocket v1.4.0/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= @@ -503,7 +708,6 @@ github.com/grpc-ecosystem/go-grpc-middleware v1.2.2/go.mod h1:EaizFBKfUKtMIF5iaD 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-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= -github.com/grpc-ecosystem/grpc-gateway v1.8.5/go.mod h1:vNeuVxBJEsws4ogUvrchl83t/GYV9WGTSLVdBhOQFDY= 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= github.com/grpc-ecosystem/grpc-gateway v1.16.0/go.mod h1:BDjrQk3hbvj6Nolgz8mAMFbcEtjT1g+wF4CSlocrBnw= @@ -520,6 +724,10 @@ github.com/hashicorp/errwrap v1.0.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brv 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-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= @@ -527,12 +735,15 @@ github.com/hashicorp/go-msgpack v0.5.3/go.mod h1:ahLV/dePpqEmjfWmKiqvPkv/twdG7iP github.com/hashicorp/go-multierror v1.0.0/go.mod h1:dHtQlpGsu+cZNNAkkCN/P3hoUDHhCYQXV3UM06sGGrk= 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= +github.com/hashicorp/go-safetemp v1.0.0/go.mod h1:oaerMy3BhqiTbVye6QuFhFtIceqFoDHxNAB65b+Rj1I= 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-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= @@ -545,26 +756,27 @@ github.com/hashicorp/logutils v1.0.0/go.mod h1:QIAnNjmIWmVIIkWDTG1z5v++HQmx9WQRO 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/hdevalence/ed25519consensus v0.0.0-20220222234857-c00d1f31bab3 h1:aSVUgRRRtOrZOC1fYmY9gV0e9z/Iu+xNVSASWjsuyGU= -github.com/hdevalence/ed25519consensus v0.0.0-20220222234857-c00d1f31bab3/go.mod h1:5PC6ZNPde8bBqU/ewGZig35+UIZtw9Ytxez8/q5ZyFE= +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/hydrogen18/memlistener v0.0.0-20141126152155-54553eb933fb/go.mod h1:qEIFzExnS6016fRpRfxrExeVn2gbClQA99gQhnIcdhE= -github.com/hydrogen18/memlistener v0.0.0-20200120041712-dcc25e7acd91/go.mod h1:qEIFzExnS6016fRpRfxrExeVn2gbClQA99gQhnIcdhE= github.com/iancoleman/orderedmap v0.2.0 h1:sq1N/TFpYH++aViPcaKjys3bDClUEU7s5B+z6jq8pNA= github.com/iancoleman/orderedmap v0.2.0/go.mod h1:N0Wam8K1arqPXNWjMo21EXnBPOPp36vB07FNRdD2geA= 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/imkira/go-interpol v1.1.0/go.mod h1:z0h2/2T3XF8kyEPpRgJ3kmNv+C43p+I/CoI+jC3w2iA= -github.com/improbable-eng/grpc-web v0.14.1 h1:NrN4PY71A6tAz2sKDvC5JCauENWp0ykG8Oq1H3cpFvw= -github.com/improbable-eng/grpc-web v0.14.1/go.mod h1:zEjGHa8DAlkoOXmswrNvhUGEYQA9UI7DhrGeHR1DMGU= +github.com/improbable-eng/grpc-web v0.15.0 h1:BN+7z6uNXZ1tQGcNAuaU1YjsLTApzkjt2tzCixLaUPQ= +github.com/improbable-eng/grpc-web v0.15.0/go.mod h1:1sy9HKV4Jt9aEs9JSnkWlRJPuPtwNr0l57L4f878wP8= github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8= -github.com/inconshreveable/mousetrap v1.0.1 h1:U3uMjPSQEBMNp1lFxmllqCPM6P5u/Xq7Pgzkat/bFNc= -github.com/inconshreveable/mousetrap v1.0.1/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLfsEA9PFc4w1p2J65bw= +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= @@ -577,19 +789,15 @@ github.com/influxdata/promql/v2 v2.12.0/go.mod h1:fxOPu+DY0bqCTCECchSRtWfc+0X19y 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/iris-contrib/blackfriday v2.0.0+incompatible/go.mod h1:UzZ2bDEoaSGPbkg6SAB4att1aAwTmVIx/5gCVqeyUdI= -github.com/iris-contrib/go.uuid v2.0.0+incompatible/go.mod h1:iz2lgM/1UnEf1kP0L/+fafWORmlnuysV2EMP8MW+qe0= -github.com/iris-contrib/i18n v0.0.0-20171121225848-987a633949d0/go.mod h1:pMCz62A0xJL6I+umB2YTlFRwWXaDFA0jy+5HzGiJjqI= -github.com/iris-contrib/jade v1.1.3/go.mod h1:H/geBymxJhShH5kecoiOCSssPX7QWYH7UaeZTSWddIk= -github.com/iris-contrib/pongo2 v0.0.1/go.mod h1:Ssh+00+3GAZqSQb30AvBRNxBx7rf0GqwkjqxNd0u65g= -github.com/iris-contrib/schema v0.0.1/go.mod h1:urYA3uvUNG1TIIjOSCzHr9/LmbQo8LrOcOqfqxa4hXw= 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.13.1-0.20220928232736-101791cb1b4c h1:XImQJfpJLmGEEd8ll5yPVyL/aEvmgGHW4WYTyNseLOM= +github.com/jhump/protoreflect v1.15.1 h1:HUMERORf3I3ZdX05WaQ6MIpd/NJ434hTp5YiKgfCL6c= 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= +github.com/jmespath/go-jmespath/internal/testify v1.5.1 h1:shLQSRRSCCPj3f2gpwzGwWFoC7ycTf1rcQZHOlsJ6N8= github.com/jmespath/go-jmespath/internal/testify v1.5.1/go.mod h1:L3OGu8Wl2/fWfCI6z80xFu9LTZmf1ZRjMHUOPmWr69U= github.com/jmhodges/levigo v1.0.0 h1:q5EC36kV79HWeTBWsod3mG11EgStG3qArTKcvlksN1U= github.com/jmhodges/levigo v1.0.0/go.mod h1:Q6Qx+uH3RAqyK4rFQroq9RL7mdkABMcfhEI+nNuzMJQ= @@ -601,45 +809,34 @@ github.com/json-iterator/go v1.1.7/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/u github.com/json-iterator/go v1.1.8/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= github.com/json-iterator/go v1.1.9/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= github.com/json-iterator/go v1.1.10/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= -github.com/json-iterator/go v1.1.11/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= github.com/json-iterator/go v1.1.12 h1:PV8peI4a0ysnczrg+LtxykD8LfKY9ML6u2jnxaEnrnM= 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/juju/errors v0.0.0-20181118221551-089d3ea4e4d5/go.mod h1:W54LbzXuIE0boCoNJfwqpmkKJ1O4TCTZMetAt6jGk7Q= -github.com/juju/loggo v0.0.0-20180524022052-584905176618/go.mod h1:vgyd7OREkbtVEN/8IXZe5Ooef3LQePvuBm9UWj6ZL8U= -github.com/juju/testing v0.0.0-20180920084828-472a3e8b2073/go.mod h1:63prj8cnj0tU0S9OHjGJn+b1h0ZghCndfnbQolrYTwA= 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/k0kubun/colorstring v0.0.0-20150214042306-9440f1994b88/go.mod h1:3w7q1U84EfirKl04SVQ/s7nPm1ZPhiXd34z40TNz36k= github.com/karalabe/usb v0.0.2/go.mod h1:Od972xHfMJowv7NGVDiWVxk2zxnWgjLlJzE+F4F7AGU= -github.com/kataras/golog v0.0.9/go.mod h1:12HJgwBIZFNGL0EJnMRhmvGA0PQGx8VFwrZtM4CqbAk= -github.com/kataras/golog v0.0.10/go.mod h1:yJ8YKCmyL+nWjERB90Qwn+bdyBZsaQwU3bTVFgkFIp8= -github.com/kataras/iris/v12 v12.0.1/go.mod h1:udK4vLQKkdDqMGJJVd/msuMtN6hpYJhg/lSzuxjhO+U= -github.com/kataras/iris/v12 v12.1.8/go.mod h1:LMYy4VlP67TQ3Zgriz8RE2h2kMZV2SgMYbq3UhfoFmE= -github.com/kataras/neffos v0.0.10/go.mod h1:ZYmJC07hQPW67eKuzlfY7SO3bC0mw83A3j6im82hfqw= -github.com/kataras/neffos v0.0.14/go.mod h1:8lqADm8PnbeFfL7CLXh1WHw53dG27MC3pgi2R1rmoTE= -github.com/kataras/pio v0.0.0-20190103105442-ea782b38602d/go.mod h1:NV88laa9UiiDuX9AhMbDPkGYSPugBOV6yTZB1l2K9Z0= -github.com/kataras/pio v0.0.2/go.mod h1:hAoW0t9UmXi4R5Oyq5Z4irTbaTsOemSrDGUtaTl7Dro= -github.com/kataras/sitemap v0.0.5/go.mod h1:KY2eugMKiPwsJgx7+U103YZehfvNGOXURubcGyk0Bz8= +github.com/kisielk/errcheck v1.1.0/go.mod h1:EZBBE59ingxPouuu3KfxchcWSUPOHkagtvWXihfKN4Q= +github.com/kisielk/errcheck v1.2.0/go.mod h1:/BMXB+zMLi60iA8Vv6Ksmxu/1UDYcXs4uQLJ+jE2L00= 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.8.2/go.mod h1:RyIbtBH6LamlWaDj8nUwkbUhJ87Yi3uG0guNDohfE1A= -github.com/klauspost/compress v1.9.0/go.mod h1:RyIbtBH6LamlWaDj8nUwkbUhJ87Yi3uG0guNDohfE1A= -github.com/klauspost/compress v1.9.7/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 h1:Lcadnb3RKGin4FYM/orgq0qde+nc15E5Cbqg4B9Sx9c= github.com/klauspost/compress v1.15.11/go.mod h1:QPwzmACJjUTFsnSHH934V6woptycfrDDJnH7hvFVbGM= +github.com/klauspost/compress v1.16.3 h1:XuJt9zzcnaz6a16/OU53ZjWp/v7/42WcR5t2a0PcNQY= +github.com/klauspost/compress v1.16.3/go.mod h1:ntbaceVETuRiXiv4DpjP66DpAtAGkEQskQzEyD//IeE= +github.com/klauspost/cpuid v0.0.0-20170728055534-ae7887de9fa5 h1:2U0HzY8BJ8hVwDKIzp7y4voR9CX/nvcfymLmg2UiOio= github.com/klauspost/cpuid v0.0.0-20170728055534-ae7887de9fa5/go.mod h1:Pj4uuM528wm8OyEC2QMXAi2YiTZ96dNQPGgoMS4s3ek= -github.com/klauspost/cpuid v1.2.1/go.mod h1:Pj4uuM528wm8OyEC2QMXAi2YiTZ96dNQPGgoMS4s3ek= +github.com/klauspost/cpuid/v2 v2.0.9/go.mod h1:FInQzS24/EEf25PyTYn52gqo7WaD8xa0213Md/qVLRg= +github.com/klauspost/cpuid/v2 v2.2.4 h1:acbojRNwl3o09bUq+yDCtZFc1aiwaAAxtcn8YkZXnvk= +github.com/klauspost/cpuid/v2 v2.2.4/go.mod h1:RVVoqg1df56z8g3pUjL/3lE5UfnlrJX8tyFgg4nqhuY= 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/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= @@ -648,7 +845,6 @@ github.com/kr/fs v0.1.0/go.mod h1:FFnZGqtBN9Gxj7eW1uZ42v5BccTP0vu6NEaFoC2HwRg= 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.0/go.mod h1:640gp4NfQd8pI5XOwp5fnNeVWj67G7CFk/SaSQn7NBk= 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= @@ -656,60 +852,56 @@ 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.1.11/go.mod h1:i541M3Fj6f76NZtHSj7TXnyM8n2gaodfvfxNnFqi74g= github.com/labstack/echo/v4 v4.2.1/go.mod h1:AA49e0DZ8kk5jTOOCKNuPR6oTnBS0dYiM4FW1e6jwpg= -github.com/labstack/echo/v4 v4.5.0/go.mod h1:czIriw4a0C1dFun+ObrXp7ok03xON0N1awStJ6ArI7Y= 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.4 h1:XlAE/cm/ms7TE/VMVoduSpNBoyc2dOxHs5MZSwAN63Q= +github.com/leodido/go-urn v1.2.4/go.mod h1:7ZrI8mTSeBSHl/UaRyKQW1qZeMgak41ANeCNaVckg+4= github.com/lib/pq v1.0.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo= -github.com/lib/pq v1.10.6 h1:jbk+ZieJ0D7EVGJYpL9QTz7/YW6UHbmdnZWYyK5cdBs= -github.com/lib/pq v1.10.6/go.mod h1:AlVN5x4E4T544tWzH6hKfbfQvm3HdbOxrmggDNAPY9o= +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= github.com/libp2p/go-buffer-pool v0.1.0/go.mod h1:N+vh8gMqimBzdKkSMVuydVDq+UV5QTWy5HSiZacSbPg= github.com/lightstep/lightstep-tracer-common/golang/gogo v0.0.0-20190605223551-bc2310a04743/go.mod h1:qklhhLq1aX+mtWk9cPHPzaBjWImj5ULL6C7HFJtXQMM= github.com/lightstep/lightstep-tracer-go v0.18.1/go.mod h1:jlF1pusYV4pidLvZ+XD0UBX0ZE6WURAspgAczcDHrL4= -github.com/linxGnu/grocksdb v1.7.10 h1:dz7RY7GnFUA+GJO6jodyxgkUeGMEkPp3ikt9hAcNGEw= -github.com/linxGnu/grocksdb v1.7.10/go.mod h1:0hTf+iA+GOr0jDX4CgIYyJZxqOH9XlBh6KVj8+zmF34= +github.com/linxGnu/grocksdb v1.7.16 h1:Q2co1xrpdkr5Hx3Fp+f+f7fRGhQFQhvi/+226dtLmA8= +github.com/linxGnu/grocksdb v1.7.16/go.mod h1:JkS7pl5qWpGpuVb3bPqTz8nC12X3YtPZT+Xq7+QfQo4= 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.6 h1:5ibWZ6iY0NctNGWo87LalDlEZ6R41TqbbDamhfG/Qzo= -github.com/magiconair/properties v1.8.6/go.mod h1:y3VJvCyxH9uVvJTWEGAELF3aiYNyPKd5NZ3oSwXrF60= +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.11/go.mod h1:u5H1YNBxpqRaxsYJYSkiCWKzEfiAb1Gb520KVy5xxl4= 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.7/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s= 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 h1:bq3VjFmv/sOjHtdEhmkEV4x1AJtvUvOJ2PFAZ5+peKQ= github.com/mattn/go-isatty v0.0.16/go.mod h1:kYGgaQfpe5nmfYZH+SKPsOc2e4SrIfOl2e/yFXSvRLM= +github.com/mattn/go-isatty v0.0.19 h1:JITubQf0MOLdlGRuRq+jtsDlekdYPia9ZFsB8h/APPA= +github.com/mattn/go-isatty v0.0.19/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/mattn/goveralls v0.0.2/go.mod h1:8d1ZMHsd7fW6IRPKQh46F2WRpyib5/X4FOpevwGNQEw= github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0= -github.com/matttproud/golang_protobuf_extensions v1.0.2-0.20181231171920-c182affec369 h1:I0XW9+e1XWDxdcEniV4rQAIOPUGDq67JSCiRCgGCZLI= -github.com/matttproud/golang_protobuf_extensions v1.0.2-0.20181231171920-c182affec369/go.mod h1:BSXmuO+STAnVfrANrmjBb36TMTDstsz7MSK+HVaYKv4= -github.com/mediocregopher/mediocre-go-lib v0.0.0-20181029021733-cb65787f37ed/go.mod h1:dSsfyI2zABAdhcbvkXqgxOxrCsbYeHCPgrZkku60dSg= -github.com/mediocregopher/radix/v3 v3.3.0/go.mod h1:EmfVyvspXz1uZEyPBMyGK+kjWiKQGvsUt6O3Pj+LDCQ= -github.com/mediocregopher/radix/v3 v3.4.2/go.mod h1:8FL3F6UQRXHXIBSPUs5h0RybMF8i4n7wVopoX3x7Bv8= -github.com/microcosm-cc/bluemonday v1.0.2/go.mod h1:iVP4YcDBq+n/5fb23BhYFvIMq/leAFZyRl6bYmGDlGc= +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/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= @@ -718,8 +910,11 @@ github.com/minio/highwayhash v1.0.2 h1:Aak5U0nElisjDCfPSG79Tgzkn2gl66NxOMspRrKnA 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= github.com/mitchellh/go-homedir v1.0.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0= +github.com/mitchellh/go-homedir v1.1.0 h1:lukF9ziXFxDFPkA1vsr5zpc1XuPDn/wFntq5mG+4E0Y= github.com/mitchellh/go-homedir v1.1.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0= github.com/mitchellh/go-testing-interface v1.0.0/go.mod h1:kRemZodwjscx+RGhAo8eIhFbs2+BFgRtFPeD/KE+zxI= +github.com/mitchellh/go-testing-interface v1.14.1 h1:jrgshOhYAUVNMAJiKbEu7EqAwgJJ2JqpQmpLJOu07cU= +github.com/mitchellh/go-testing-interface v1.14.1/go.mod h1:gfgS7OtZj6MA4U1UrDRp04twqAjfvlZyCfX3sDjEym8= github.com/mitchellh/gox v0.4.0/go.mod h1:Sd9lOJ0+aimLBi73mGofS1ycjY8lL3uZM3JPS42BGNg= github.com/mitchellh/iochan v1.0.0/go.mod h1:JwYml1nuB7xOzsp52dPpHFffvOCDupsG0QubkSMEySY= github.com/mitchellh/mapstructure v0.0.0-20160808181253-ca63d7c062ee/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= @@ -737,7 +932,6 @@ github.com/modern-go/reflect2 v1.0.1/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3Rllmb 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/moul/http2curl v1.0.0/go.mod h1:8UbvGypXm98wA/IqH45anm5Y2Z6ep6O31QGOAZ3H0fQ= 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= @@ -750,16 +944,14 @@ github.com/naoina/toml v0.1.2-0.20170918210437-9fafd6967416/go.mod h1:NBIhNtsFMo 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= -github.com/nats-io/nats.go v1.8.1/go.mod h1:BrFz9vVn0fU3AcH9Vn4Kd7W0NpJ651tD5omQ3M8LwxM= github.com/nats-io/nats.go v1.9.1/go.mod h1:ZjDU1L/7fJ09jvUSRVBR2e7+RnLiiIQyqyzEE/Zbp4w= -github.com/nats-io/nkeys v0.0.2/go.mod h1:dab7URMsZm6Z/jp9Z5UGa87Uutgc2mVpXLC4B7TDb/4= 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 h1:DQuhQpB1tVlglWS2hLQ5OV6B5r8aGxSrPc5Qo6uTN78= github.com/nxadm/tail v1.4.4/go.mod h1:kenIhsEOeOJmVchQTgglprH7qJGnHDVpk1VPCcaMI8A= +github.com/nxadm/tail v1.4.8 h1:nPr65rt6Y5JFSKQO7qToXr7pePgD6Gwiw05lkbyAQTE= 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= @@ -767,16 +959,14 @@ github.com/olekukonko/tablewriter v0.0.0-20170122224234-a0225b3f23b5/go.mod h1:v 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.10.3/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= github.com/onsi/ginkgo v1.12.1/go.mod h1:zj2OWP4+oCPe1qIXoGWkgMRwljMUYCdkwsT2108oapk= -github.com/onsi/ginkgo v1.13.0/go.mod h1:+REjRxOmWfHCjfv9TTWB1jD1Frx4XydAD3zm1lskyM0= -github.com/onsi/ginkgo v1.14.0 h1:2mOpI4JVVPBN+WQRa0WKH2eXR+Ey+uK4n7Zj0aYpIQA= 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/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 h1:o0+MgICZLuZ7xjH7Vx6zS/zcu93/BEp1VwkIW1mEXCE= 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/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/image-spec v1.1.0-rc2 h1:2zx/Stx4Wc5pIPDvIxHXvXtQFW/7XWJGmnM7r3wg034= @@ -791,7 +981,6 @@ github.com/openzipkin/zipkin-go v0.1.6/go.mod h1:QgAqvLzwWbR/WpD4A3cGpPtJrZXNIiJ github.com/openzipkin/zipkin-go v0.2.1/go.mod h1:NaW6tEwdmWMaCDZzg8sh+IBNOxHMPnhQw8ySjnjRyN4= github.com/openzipkin/zipkin-go v0.2.2/go.mod h1:NaW6tEwdmWMaCDZzg8sh+IBNOxHMPnhQw8ySjnjRyN4= github.com/ory/dockertest v3.3.5+incompatible h1:iLLK6SQwIhcbrG783Dghaaa3WPzGc+4Emza6EbVUUGA= -github.com/otiai10/copy v1.6.0 h1:IinKAryFFuPONZ7cm6T6E2QX/vcJwSnlaA5lfoaXIiQ= github.com/pact-foundation/pact-go v1.0.4/go.mod h1:uExwJY4kCzNPcHRj+hCR/HBbOOIwwtUjcrb0b5/5kLM= github.com/pascaldekloe/goe v0.0.0-20180627143212-57f6aae5913c/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc= github.com/pascaldekloe/goe v0.1.0 h1:cBOtyMzM9HTpWjXfbbunk26uA6nG3a8n06Wieeh0MwY= @@ -799,21 +988,18 @@ github.com/pascaldekloe/goe v0.1.0/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144T 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 v1.9.5 h1:4yBQzkHv+7BHq2PQUZF3Mx0IYxG7LsP222s7Agd3ve8= -github.com/pelletier/go-toml v1.9.5/go.mod h1:u1nR/EPcESfeI/szUZKdtJ0xRNbUoANCkoOuaOx1Y+c= -github.com/pelletier/go-toml/v2 v2.0.5 h1:ipoSadvV8oGUjnUbMub59IDPPwfxF694nG/jwbMiyQg= -github.com/pelletier/go-toml/v2 v2.0.5/go.mod h1:OMHamSCAODeSsVrwwvcJOaoN0LIUIaFVNZzmWyNfXas= +github.com/pelletier/go-toml/v2 v2.0.8 h1:0ctb6s9mE31h0/lhu+J6OPmVeDxJn+kYnJc2jZR9tGQ= +github.com/pelletier/go-toml/v2 v2.0.8/go.mod h1:vuYfssBdrU2XDZ9bYydBu6t+6a6PYNcZljzZR9VXg+4= 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 h1:q2e307iGHPdTGp0hoxKjt1H5pDo6utceo3dQVK3I5XQ= 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/philhofer/fwd v1.1.1/go.mod h1:gk3iGcWd9+svBvR0sR+KPcfE+RNWozjowpeBVG3ZVNU= 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= -github.com/pingcap/errors v0.11.4/go.mod h1:Oi8TUi2kEtXXLMJk9l1cGmz20kV3TaQ0usTwv5KuLY8= github.com/pkg/diff v0.0.0-20210226163009-20ebb0f2a09e/go.mod h1:pJLUxLENpZxwdsKMEsNbx1VGcRFpLqf3715MtcvvzbA= github.com/pkg/errors v0.8.0/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= @@ -831,8 +1017,6 @@ 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.11.0/go.mod h1:Z6t4BnS23TR94PD6BsDNk8yVqroYurpAkEiz0P2BEV0= -github.com/prometheus/client_golang v1.12.1/go.mod h1:3Z9XVyYiZYEO+YQWt3RD2R3jrbd179Rt297l4aS6nDY= 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_model v0.0.0-20180712105110-5c3871d89910/go.mod h1:MbSGuTsp3dbXC40dX6PRTWyKYBIrTGTE9sqQNg2J8bo= @@ -851,62 +1035,48 @@ github.com/prometheus/common v0.7.0/go.mod h1:DjGbpBbp5NYNiECxcL/VnbXCCaQpKd3tt2 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.26.0/go.mod h1:M7rCNAaPfAosfx8veZJCuw84e35h3Cfd9VFqTh1DIvc= -github.com/prometheus/common v0.32.1/go.mod h1:vu+V0TpY+O6vW9J44gczi3Ap/oXXR10b+M/gUGO4Hls= -github.com/prometheus/common v0.37.0 h1:ccBbHCgIiT9uSoFY0vX8H3zsNR5eLt17/RQLUvn8pXE= -github.com/prometheus/common v0.37.0/go.mod h1:phzohg0JFMnBEFGxTDbfu3QyL5GI8gTQJFhYO5B3mfA= +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.6.0/go.mod h1:cz+aTbrPOrUb4q7XlbU9ygM+/jj0fzG6c1xBZuNvfVA= -github.com/prometheus/procfs v0.7.3/go.mod h1:cz+aTbrPOrUb4q7XlbU9ygM+/jj0fzG6c1xBZuNvfVA= -github.com/prometheus/procfs v0.8.0 h1:ODq8ZFEaYeCaZOJlZZdJA2AbQR98dSHSM1KW/You5mo= -github.com/prometheus/procfs v0.8.0/go.mod h1:z7EfXMXOkbkqb9IINtpCn86r/to3BnA0uaxHdg830/4= +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/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= -github.com/regen-network/cosmos-proto v0.3.1 h1:rV7iM4SSFAagvy8RiyhiACbWEGotmqzywPxOvwMdxcg= -github.com/regen-network/cosmos-proto v0.3.1/go.mod h1:jO0sVX6a1B36nmE8C9xBFXpNwWejXC7QqCOnH3O0+YM= -github.com/regen-network/gocuke v0.6.2 h1:pHviZ0kKAq2U2hN2q3smKNxct6hS0mGByFMHGnWA97M= -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.6.1/go.mod h1:xXDCJY+GAPziupqXw64V24skbSoqbTEfhy4qGm1nDQc= -github.com/rogpeppe/go-internal v1.8.1/go.mod h1:JeRgkft04UBgHMgCIwADu4Pn6Mtm5d4nPKWu0nJ5d+o= -github.com/rogpeppe/go-internal v1.9.0 h1:73kH8U+JUqXU8lRuOHeVHaa/SZPifC7BkcraZVejAe8= 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/rs/cors v1.7.0/go.mod h1:gFx+x8UowdsKA9AchylcLynDq+nNFfI8FkUZdN/jGCU= -github.com/rs/cors v1.8.2 h1:KCooALfAYGs415Cwu5ABvv9n9509fSiG5SQJn/AQo4U= -github.com/rs/cors v1.8.2/go.mod h1:XyqrcTp5zjWr1wsJ8PIRZssZ8b/WMcMf71DJnit4EMU= -github.com/rs/xid v1.3.0/go.mod h1:trrq9SKmegXys3aeAKXMUTdJsYXVwGY3RLcfgqegfbg= -github.com/rs/zerolog v1.27.0 h1:1T7qCieN22GVc8S4Q2yuexzBb1EqjbgjSH9RohbMjKs= -github.com/rs/zerolog v1.27.0/go.mod h1:7frBqO0oezxmnO7GF86FY++uy8I0Tk/If5ni1G9Qc0U= +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.30.0 h1:SymVODrcRsaRaSInD9yQtKbtWqwsfoPcRff/oRXLj4c= +github.com/rs/zerolog v1.30.0/go.mod h1:/tk+P47gFdPXq4QYjvCmT5/Gsug2nagsFWBWhAiSi1w= 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= -github.com/ryanuber/columnize v2.1.0+incompatible/go.mod h1:sm1tb6uqfes/u+d4ooFouqFdy9/2g9QGwK3SQygK0Ts= github.com/samuel/go-zookeeper v0.0.0-20190923202752-2cc03de413da/go.mod h1:gi+0XIa01GRL2eRQVjQkKGqKF3SF9vZR/HnPullcV2E= 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/schollz/closestmatch v2.1.0+incompatible/go.mod h1:RtP1ddjLong6gTkbtmuhtR2uUrrJOpYzYRvbcPAid+g= -github.com/sclevine/agouti v3.0.0+incompatible/go.mod h1:b4WX9W9L1sfQKXeJf1mUTLZKJ48R1S7H23Ji7oFO5Bw= 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/sergi/go-diff v1.1.0/go.mod h1:STckp+ISIX8hZLjrqAeVduY0gWCT9IjLuqbuNXdaHfM= 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= @@ -922,15 +1092,15 @@ github.com/spaolacci/murmur3 v0.0.0-20180118202830-f09979ecbc72/go.mod h1:JwIasO github.com/spaolacci/murmur3 v1.1.0 h1:7c1g84S4BPRrfL5Xrdp6fOJ206sU9y293DDHaoy0bLI= 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.9.2 h1:j49Hj62F0n+DaZ1dDCvhABaPNSGNkt32oRFxI33IEMw= -github.com/spf13/afero v1.9.2/go.mod h1:iUV7ddyEEZPO5gA3zD4fJt6iStLlL+Lg4m2cihcDf8Y= +github.com/spf13/afero v1.9.5 h1:stMpOSZFs//0Lv29HduCmli3GUfpFoF3Y1Q/aXj/wVM= +github.com/spf13/afero v1.9.5/go.mod h1:UBogFpq8E9Hx+xc5CNTTEpTnuHVmXDwZcZcE1eb/UhQ= github.com/spf13/cast v1.3.0/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE= -github.com/spf13/cast v1.5.0 h1:rj3WzYc11XZaIZMPKmwP96zkFEnnAmV8s6XbB2aY32w= -github.com/spf13/cast v1.5.0/go.mod h1:SpXXQ5YoyJw6s3/6cMTQuxvgRl3PCJiyaX9p6b155UU= +github.com/spf13/cast v1.5.1 h1:R+kOtfhWQE6TVQzY+4D7wJLBgkdVasCEFxSUBYBYIlA= +github.com/spf13/cast v1.5.1/go.mod h1:b9PdjNptOpzXr7Rq1q9gJML/2cdGQAo69NKzQ10KN48= 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.6.1 h1:o94oiPyS4KD1mPy2fmcYYHHfCxLqYjJOhGsCHFZtEzA= -github.com/spf13/cobra v1.6.1/go.mod h1:IOw/AERYS7UzyrGinqmz6HLUo219MORXGxhbaJUqzrY= +github.com/spf13/cobra v1.7.0 h1:hyqWnYt1ZQShIddO5kBpj3vu05/++x6tJ6dg8EC572I= +github.com/spf13/cobra v1.7.0/go.mod h1:uLxZILRyS/50WlhOIKD7W6V5bgeIt+4sICxh6uRMrb0= github.com/spf13/jwalterweatherman v1.0.0/go.mod h1:cQK4TGJAtQXfYWX+Ddv3mKDzgVb68N+wFjFa4jdeBTo= github.com/spf13/jwalterweatherman v1.1.0 h1:ue6voC5bR5F8YxI5S67j9i582FU4Qvo2bmqnqMYADFk= github.com/spf13/jwalterweatherman v1.1.0/go.mod h1:aNWZUN0dPAAO/Ljvb5BEdw96iTZ0EXowPYD95IqWIGo= @@ -939,11 +1109,9 @@ github.com/spf13/pflag v1.0.3/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnIn 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.14.0 h1:Rg7d3Lo706X9tHsJMUjdiwMpHB7W8WnSVOssIY+JElU= -github.com/spf13/viper v1.14.0/go.mod h1:WT//axPky3FdvXHzGw33dNdXXXfFQqmEalje+egj8As= +github.com/spf13/viper v1.16.0 h1:rGGH0XDZhdUOryiDWjmIvUSWpbNqisK8Wk0Vyefw8hc= +github.com/spf13/viper v1.16.0/go.mod h1:yg78JgCJcbrQOvV9YLXgkLaZqUidkY9K+Dd1FofRzQg= github.com/status-im/keycard-go v0.0.0-20190316090335-8537d3370df4/go.mod h1:RZLeN1LMWmRsyYjvAu+I6Dm9QmlDaIIt+Y+4Kd7Tp+Q= -github.com/strangelove-ventures/packet-forward-middleware/v4 v4.0.6 h1:aY64yjKZyDyzlIbDOkGBPvVpR0ArzIjunpCRKqoIm7o= -github.com/strangelove-ventures/packet-forward-middleware/v4 v4.0.6/go.mod h1:4zAtg449/JISRmf+sbmqolqSLP+QJBh+EtWkWtt/AKE= 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= @@ -961,75 +1129,65 @@ github.com/stretchr/testify v1.6.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/ 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.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU= -github.com/stretchr/testify v1.8.1 h1:w7B6lhMri9wdJUVmEZPGGhZzrYTPvgJArz7wNPgYKsk= github.com/stretchr/testify v1.8.1/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4= -github.com/subosito/gotenv v1.4.1 h1:jyEFiXpy21Wm81FBN71l9VoMMV8H8jG+qIK3GCpY6Qs= -github.com/subosito/gotenv v1.4.1/go.mod h1:ayKnFf/c6rvx/2iiLrJUk1e6plDbT3edrFNGqEflhK0= +github.com/stretchr/testify v1.8.2/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4= +github.com/stretchr/testify v1.8.3/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo= +github.com/stretchr/testify v1.8.4 h1:CcVxjf3Q8PM0mHUKJCdn+eZZtm5yQwehR5yeSVQQcUk= +github.com/stretchr/testify v1.8.4/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo= +github.com/subosito/gotenv v1.4.2 h1:X1TuBLAMDFbaTAChgCBLu3DU3UPyELpnF2jjJ2cz/S8= +github.com/subosito/gotenv v1.4.2/go.mod h1:ayKnFf/c6rvx/2iiLrJUk1e6plDbT3edrFNGqEflhK0= github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 h1:epCh84lMvA70Z7CTTCmYQn2CKbY8j86K7/FAIr141uY= github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7/go.mod h1:q4W45IWZaF22tdD+VEXcAWRA037jwmWEB5VWYORlTpc= -github.com/tecbot/gorocksdb v0.0.0-20191217155057-f0fad39f321c h1:g+WoO5jjkqGAzHWCjJB1zZfXPIAaDpzXIEJ0eS6B5Ok= -github.com/tecbot/gorocksdb v0.0.0-20191217155057-f0fad39f321c/go.mod h1:ahpPrc7HpcfEWDQRZEmnXMzHY03mLDYMCxeDzy46i+8= 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/tendermint/tm-db v0.6.7 h1:fE00Cbl0jayAoqlExN6oyQJ7fR/ZtoVOmvPJ//+shu8= -github.com/tendermint/tm-db v0.6.7/go.mod h1:byQDzFkZV1syXr/ReXS808NxA2xvyuuVgXOJ/088L6I= -github.com/tidwall/btree v1.5.0 h1:iV0yVY/frd7r6qGBXfEYs7DH0gTDgrKTrDjS7xt/IyQ= -github.com/tidwall/btree v1.5.0/go.mod h1:LGm8L/DZjPLmeWGjv5kFrY8dL4uVhMmzmmLYmsObdKE= +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/tinylib/msgp v1.1.5/go.mod h1:eQsjooMTnV42mHu917E26IogZ2930nFyBQdofk10Udg= 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/tmc/grpc-websocket-proxy v0.0.0-20170815181823-89b8d40f7ca8/go.mod h1:ncp9v5uamzpCO7NfCPTXjqaC+bZgJeR0sMTm6dMHP7U= -github.com/ttacon/chalk v0.0.0-20160626202418-22c06c80ed31/go.mod h1:onvgF043R+lC5RZ8IT9rBXDaEDnpnw/Cl+HFiw+v/7Q= github.com/tv42/httpunix v0.0.0-20150427012821-b75d8614f926/go.mod h1:9ESjWnEqriFuLhtthL60Sar/7RFoluCcXsuvEwTV5KM= +github.com/twitchyliquid64/golang-asm v0.15.1 h1:SU5vSMR7hnwNxj24w34ZyCi/FmDZTkS4MhqMhdFk5YI= +github.com/twitchyliquid64/golang-asm v0.15.1/go.mod h1:a1lVb/DtPvCB8fslRZhAngC2+aY1QWCk3Cedj/Gdt08= 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.4/go.mod h1:uQMGLiO92mf5W77hV/PUCpI3pbzQx3CRekS0kk+RGrc= -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.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/urfave/negroni v1.0.0/go.mod h1:Meg73S6kFm/4PpbYdq35yYWoCZ9mS/YSx+lKnmiohz4= github.com/valyala/bytebufferpool v1.0.0/go.mod h1:6bBcMArwyJ5K/AmCkWv1jt77kVWyCJ6HpOuEn7z0Csc= -github.com/valyala/fasthttp v1.6.0/go.mod h1:FstJa9V+Pj9vQ7OJie2qMHdwemEDaDiSdBnvPM1Su9w= 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/valyala/tcplisten v0.0.0-20161114210144-ceec8f93295a/go.mod h1:v3UYOV9WzVtRmSR+PDvWpU/qWl4Wa5LApYYX4ZtKbio= 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/xeipuuv/gojsonpointer v0.0.0-20180127040702-4e3ac2762d5f/go.mod h1:N2zxlSyiKSe5eX1tZViRH5QA0qijqEDrYZiPEAiq3wU= -github.com/xeipuuv/gojsonreference v0.0.0-20180127040603-bd5ef7bd5415/go.mod h1:GwrjFmJcFw6At/Gs6z4yjiIwzuJ1/+UwLxMQDVQXShQ= -github.com/xeipuuv/gojsonschema v1.2.0/go.mod h1:anYRn/JVcOK2ZgGU+IjEV4nwlhoK5sQluxsYJ78Id3Y= 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/yalp/jsonpath v0.0.0-20180802001716-5cc68e5049a0/go.mod h1:/LWChgwKmvncFJFHJ7Gvn9wZArjbV5/FppcK2fKk/tI= github.com/ybbus/jsonrpc v2.1.2+incompatible/go.mod h1:XJrh1eMSzdIYFbM08flv0wp5G35eRniyeGut1z+LSiE= -github.com/yudai/gojsondiff v1.0.0/go.mod h1:AY32+k2cwILAkW1fbgxQ5mUmMiZFgLIV+FBNExI05xg= -github.com/yudai/golcs v0.0.0-20170316035057-ecda9a501e82/go.mod h1:lgjkn3NuSvDfVJdfcVVdX+jpBxNmX4rDAzaS45IcYoM= -github.com/yudai/pp v2.0.1+incompatible/go.mod h1:PuxR/8QJ7cyCkFp/aUDS+JY727OFEZkTdatxwunjIkc= 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= github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.3.5/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k= +github.com/yuin/goldmark v1.4.13/go.mod h1:6yULJ656Px+3vBD8DxQVa3kxgyrAnzto9xy5taEt/CY= github.com/zondax/hid v0.9.1 h1:gQe66rtmyZ8VeGFcOpbuH3r7erYtNEAezCAYu8LdkJo= github.com/zondax/hid v0.9.1/go.mod h1:l5wttcP0jwtdLjqjMMWFVEE7d1zO0jvSPA9OPZxWpEM= github.com/zondax/ledger-go v0.14.1 h1:Pip65OOl4iJ84WTpA4BKChvOufMhhbxED3BaihoZN4c= github.com/zondax/ledger-go v0.14.1/go.mod h1:fZ3Dqg6qcdXWSOJFKMG8GCTnD7slO/RL2feOQv8K320= go.etcd.io/bbolt v1.3.3/go.mod h1:IbVyRI1SCnLcuJnV2u8VeU0CEYM7e686BmAb1XKL+uU= -go.etcd.io/bbolt v1.3.6 h1:/ecaJf0sk1l4l6V4awd65v2C3ILy7MSj+s/x1ADCIMU= -go.etcd.io/bbolt v1.3.6/go.mod h1:qXsaaIqmgQH0T+OPdb99Bf+PKfBBQVAdyD6TY9G8XM4= +go.etcd.io/bbolt v1.3.7 h1:j+zJOnnEjF/kyHlDDgGnVL/AIqIJPq8UoB2GSNfkUfQ= +go.etcd.io/bbolt v1.3.7/go.mod h1:N9Mkw9X8x5fupy0IKsmuqVtoGDyxsaDlbk4Rd05IAQw= go.etcd.io/etcd v0.0.0-20191023171146-3cf2f69b5738/go.mod h1:dnLIgRNXwCJa5e+c6mIZCrds/GIG4ncV9HhK5PX7jPg= go.opencensus.io v0.20.1/go.mod h1:6WKK9ahsWS3RSO+PY9ZHZUfv2irvY6gN279GOPZjmmk= go.opencensus.io v0.20.2/go.mod h1:6WKK9ahsWS3RSO+PY9ZHZUfv2irvY6gN279GOPZjmmk= @@ -1039,6 +1197,10 @@ go.opencensus.io v0.22.2/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw= go.opencensus.io v0.22.3/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw= go.opencensus.io v0.22.4/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw= 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/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= @@ -1048,6 +1210,9 @@ go.uber.org/tools v0.0.0-20190618225709-2cfd321de3ee/go.mod h1:vJERXedbb3MVM5f9E 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/arch v0.0.0-20210923205945-b76863e36670/go.mod h1:5om86z9Hs0C8fWVUuoMHwpExlXzs5Tkyp9hOrfG7pp8= +golang.org/x/arch v0.3.0 h1:02VY4/ZcO/gBOH6PUaoiptASxtXU10jazRCP865E97k= +golang.org/x/arch v0.3.0/go.mod h1:5om86z9Hs0C8fWVUuoMHwpExlXzs5Tkyp9hOrfG7pp8= golang.org/x/crypto v0.0.0-20170930174604-9419663f5a44/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= 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= @@ -1060,7 +1225,6 @@ golang.org/x/crypto v0.0.0-20190701094942-4def268fd1a4/go.mod h1:yigFU9vqHzYiE8U 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-20191227163750-53104e6ec876/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= @@ -1071,9 +1235,12 @@ golang.org/x/crypto v0.0.0-20210322153248-0c34fe9e7dc2/go.mod h1:T9bdIzuCu7OtxOm golang.org/x/crypto v0.0.0-20210421170649-83a5a9bb288b/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.0.0-20211108221036-ceb1ce70b4fa/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= -golang.org/x/crypto v0.5.0 h1:U/0M97KRkSFvyD/3FSmdP5W5swImpNgle/EHFhOsQPE= -golang.org/x/crypto v0.5.0/go.mod h1:NK/OQwhpMQP3MwtdjgLlYHnH9ebylxKWv3e0fK+mkQU= +golang.org/x/crypto v0.0.0-20220314234659-1baeb1ce4c0b/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= +golang.org/x/crypto v0.0.0-20220722155217-630584e8d5aa/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= +golang.org/x/crypto v0.7.0/go.mod h1:pYwdfH91IfpZVANVyUOhSIPZaFoJGxTFbZhFTx+dXZU= +golang.org/x/crypto v0.9.0/go.mod h1:yrmDGqONDYtNj3tH8X9dzUun2m2lzPa9ngI6/RUPGR0= +golang.org/x/crypto v0.11.0 h1:6Ewdq3tDic1mg5xRO4milcWCfMVQhI4NkqWWvqejpuA= +golang.org/x/crypto v0.11.0/go.mod h1:xgJhtzW8F9jGdVFWZESrid1U1bjeNy4zgy5cRr/CIio= golang.org/x/exp v0.0.0-20180321215751-8460e604b9de/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20180807140117-3d87b88a115f/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= @@ -1088,12 +1255,12 @@ golang.org/x/exp v0.0.0-20200119233911-0405dc783f0a/go.mod h1:2RIsYlXP63K8oxa1u0 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-20200513190911-00229845015e/go.mod h1:4M0jN8W1tt0AVLNr8HDosyJCDCDuyL9N9+3m7wDWgKw= -golang.org/x/exp v0.0.0-20221019170559-20944726eadf h1:nFVjjKDgNY37+ZSYCJmtYf7tOlfQswHqplG2eosjOMg= -golang.org/x/exp v0.0.0-20221019170559-20944726eadf/go.mod h1:cyybsKvd6eL0RnXn6p/Grxp8F5bW7iYuBgsNCOHpMYE= +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/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= golang.org/x/lint v0.0.0-20190313153728-d0100b6bd8b3/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc= @@ -1116,9 +1283,12 @@ 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.7.0 h1:LapD9S96VoQRhi/GrNTqeBJFrUjs5UHCAtTlgwA5oZA= +golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4/go.mod h1:jJ57K6gSWd91VN4djpZkiMVwK6gcyfeH4XE8wZrZaV4= +golang.org/x/mod v0.8.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= +golang.org/x/mod v0.11.0 h1:bUO06HqtnRcc/7l71XBe4WcqTZ+3AH1J59zWDDwLKgU= golang.org/x/net v0.0.0-20180719180050-a680a1efc54d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= 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= golang.org/x/net v0.0.0-20181023162649-9b4f9f5ad519/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20181114220301-adae6a3d119a/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= @@ -1128,7 +1298,6 @@ golang.org/x/net v0.0.0-20190108225652-1e06a53dbb7e/go.mod h1:mL1N/T3taQHkDXs73r golang.org/x/net v0.0.0-20190125091013-d26f9f9a57f3/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20190213061140-3a22650c66bd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20190311183353-d8887717615a/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= -golang.org/x/net v0.0.0-20190327091125-710a502c58a2/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190501004415-9ce7a6920f09/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190503192946-f4e77d36d62c/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= @@ -1138,7 +1307,6 @@ golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLL golang.org/x/net v0.0.0-20190628185345-da137c7871d7/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20190724013045-ca1201d0de80/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20190813141303-74dc4d7220e7/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= -golang.org/x/net v0.0.0-20190827160401-ba9fcec4b297/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20191209160850-c0dbc17a3553/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20200114155413-6afb5195e5aa/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20200202094626-16171245cfb2/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= @@ -1159,21 +1327,36 @@ golang.org/x/net v0.0.0-20200822124328-c89045814202/go.mod h1:/O7V0waA8r7cgGh81R 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-20201224014010-6772e930b67b/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-20210525063256-abc453219eb5/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= +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-20211008194852-3b03d305991f/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= golang.org/x/net v0.0.0-20211015210444-4f30a5c0130f/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= +golang.org/x/net v0.0.0-20211112202133-69e39bad7dc2/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.7.0 h1:rJrUqqhjsgNp7KqAIc25s9pZnjU7TUcSY7HcVZjdn1g= -golang.org/x/net v0.7.0/go.mod h1:2Tu9+aMcznHK/AK1HMvgo6xiTLG5rD5rZLDS+rp2Bjs= +golang.org/x/net v0.0.0-20220325170049-de3da57026de/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= +golang.org/x/net v0.0.0-20220412020605-290c469a71a5/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= +golang.org/x/net v0.0.0-20220425223048-2871e0cb64e4/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= +golang.org/x/net v0.0.0-20220607020251-c690dde0001d/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= +golang.org/x/net v0.0.0-20220617184016-355a448f1bc9/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= +golang.org/x/net v0.0.0-20220624214902-1bab6f366d9e/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= +golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= +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.6.0/go.mod h1:2Tu9+aMcznHK/AK1HMvgo6xiTLG5rD5rZLDS+rp2Bjs= +golang.org/x/net v0.8.0/go.mod h1:QVkue5JL9kW//ek3r6jTKnTFis1tRmNAW2P1shuFdJc= +golang.org/x/net v0.10.0/go.mod h1:0qNGK6F8kojg2nk9dLZ2mShWaEBan6FAoqfSigmmuDg= +golang.org/x/net v0.12.0 h1:cfawfvKITfUsFCeJIHJrbSxpeu/E81khclypR0GVT50= +golang.org/x/net v0.12.0/go.mod h1:zEVYFnQC7m/vmpQFELhcD1EWkZlX69l4oqgmer6hfKA= 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= @@ -1183,8 +1366,24 @@ golang.org/x/oauth2 v0.0.0-20200902213428-5d25da1a8d43/go.mod h1:KelEdhl1UZF7XfJ golang.org/x/oauth2 v0.0.0-20201109201403-9fd604954f58/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= golang.org/x/oauth2 v0.0.0-20201208152858-08078c50e5b5/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= golang.org/x/oauth2 v0.0.0-20210218202405-ba52d332ba99/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= +golang.org/x/oauth2 v0.0.0-20210220000619-9bb904979d93/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= +golang.org/x/oauth2 v0.0.0-20210313182246-cd4f82c27b84/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= golang.org/x/oauth2 v0.0.0-20210514164344-f6687ab2804c/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= +golang.org/x/oauth2 v0.0.0-20210628180205-a41e5a781914/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= +golang.org/x/oauth2 v0.0.0-20210805134026-6f1e6394065a/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= +golang.org/x/oauth2 v0.0.0-20210819190943-2bc19b11175f/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= +golang.org/x/oauth2 v0.0.0-20211104180415-d3ed0bb246c8/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= golang.org/x/oauth2 v0.0.0-20220223155221-ee480838109b/go.mod h1:DAh4E804XQdzx2j+YRIaUnCqCV2RuMz24cGBJ5QYIrc= +golang.org/x/oauth2 v0.0.0-20220309155454-6242fa91716a/go.mod h1:DAh4E804XQdzx2j+YRIaUnCqCV2RuMz24cGBJ5QYIrc= +golang.org/x/oauth2 v0.0.0-20220411215720-9780585627b5/go.mod h1:DAh4E804XQdzx2j+YRIaUnCqCV2RuMz24cGBJ5QYIrc= +golang.org/x/oauth2 v0.0.0-20220608161450-d0670ef3b1eb/go.mod h1:jaDAt6Dkxork7LmZnYtzbRWj0W47D86a3TGe0YHBvmE= +golang.org/x/oauth2 v0.0.0-20220622183110-fd043fe589d2/go.mod h1:jaDAt6Dkxork7LmZnYtzbRWj0W47D86a3TGe0YHBvmE= +golang.org/x/oauth2 v0.0.0-20220822191816-0ebed06d0094/go.mod h1:h4gKUeWbJ4rQPri7E0u6Gs4e9Ri2zaLxzw5DI5XGrYg= +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.8.0 h1:6dkIjl3j3LtZ/O3sTgZTMsLKSftL/B8Zgq4huOIIUu8= +golang.org/x/oauth2 v0.8.0/go.mod h1:yr7u4HXZRm1R1kBWqr/xKNqewf0plRYoB7sla+BCIXE= 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= @@ -1196,8 +1395,13 @@ golang.org/x/sync v0.0.0-20200625203802-6e8e738ad208/go.mod h1:RxMgew5VJxzue5/jJ golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20201207232520-09787c993a3a/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20210220032951-036812b2e83c/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.1.0 h1:wsuoTGHzEhffawBOhz5CYhcrV4IdKZbEyZjBMuTp12o= +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.1.0/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.2.0 h1:PUR+T4wwASmuSTYdKjYHI5TD22Wy5ogLU5qZCOLxBrI= 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= golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20181026203630-95b1ffbd15a5/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= @@ -1250,43 +1454,74 @@ golang.org/x/sys v0.0.0-20200803210538-64077c9b5642/go.mod h1:h1NjWce9XRLGQEsW7w 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-20200923182605-d9f96fdee20d/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-20210225134936-a50acf3fe073/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-20210403161142-5e06dd20ab57/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-20210423185535-09eb48e85fd7/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-20210603081109-ebe580a85c40/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20210514084401-e8d321eab015/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20210603125802-9665404d3644/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20210616094352-59db8d763f22/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= 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-20210909193231-528a39cd75f3/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-20210927094055-39ccf1dd6fa6/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20211007075335-d3039528d8ac/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-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= -golang.org/x/sys v0.0.0-20220114195835-da31bd327af9/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220128215802-99c3d69c2c27/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220209214540-3681064d5158/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220227234510-4e6760a101f9/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220310020820-b874c991c1a5/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220315194320-039c03cc5b86/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220328115105-d36c6a25d886/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220412211240-33da011f77ad/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220502124256-b6088ccd6cba/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220503163025-988cb79eb6c6/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220610221304-9f5ed59c137d/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220615213510-4f61da869c0c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220624220833-87e55d714810/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220704084225-05e143d24a9e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220728004956-3c1f35247d10/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220908164124-27713097b956/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.5.0 h1:MUK/U/4lj1t1oPg0HfuXDN/Z1wv31ZJ/YcPiGccS4DU= +golang.org/x/sys v0.0.0-20221010170243-090e33056c14/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.1.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.5.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.8.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.11.0 h1:eG7RXZHdqOJ1i+0lgLgCpSXAp6M3LYlAo6osgSi0xOM= +golang.org/x/sys v0.11.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/term v0.0.0-20201117132131-f5c789dd3221/go.mod h1:Nr5EML6q2oocZ2LXRh80K7BxOlk5/8JxuGnuhpl+muw= 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.5.0 h1:n2a8QNdAb0sZNpU9R1ALUXBbY+w51fCQDN+7EdxNBsY= +golang.org/x/term v0.1.0/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= golang.org/x/term v0.5.0/go.mod h1:jMB1sMXY+tzblOD4FWmEbocvup2/aLOaQEp7JmGp78k= +golang.org/x/term v0.6.0/go.mod h1:m6U89DPEgQRMq3DNkDClhWw02AUbt2daBVO4cn4Hv9U= +golang.org/x/term v0.8.0/go.mod h1:xPskH00ivmX89bAKVGSKKtLOWNx2+17Eiy94tnKShWo= +golang.org/x/term v0.10.0 h1:3R7pNqamzBraeqj/Tj8qt1aQ2HpmlC+Cx/qL/7hn4/c= +golang.org/x/term v0.10.0/go.mod h1:lpqdcUyK/oCiQxvxVrppt5ggO2KCZ5QblwqPnfZ6d5o= 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= @@ -1296,23 +1531,30 @@ golang.org/x/text v0.3.4/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.5/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ= -golang.org/x/text v0.7.0 h1:4BRB4x83lYWy72KwLD/qYDuTu7q9PjSagHvijDw7cLo= +golang.org/x/text v0.3.8/go.mod h1:E6s5w1FMmriuDzIBO73fBruAKo1PCIq6d2Q6DHfQ8WQ= +golang.org/x/text v0.4.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= golang.org/x/text v0.7.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= +golang.org/x/text v0.8.0/go.mod h1:e1OnstbJyHTd6l/uOt8jFFHp6TRDWZR/bV3emEE/zU8= +golang.org/x/text v0.9.0/go.mod h1:e1OnstbJyHTd6l/uOt8jFFHp6TRDWZR/bV3emEE/zU8= +golang.org/x/text v0.12.0 h1:k+n5B8goJNdU7hSvEtMUz3d1Q6D/XW4COJSJR6fN0mc= +golang.org/x/text v0.12.0/go.mod h1:TvPlkZtksWOMsz7fbANvkp4WM8x/WCo/om8BMLbz+aE= golang.org/x/time v0.0.0-20180412165947-fbb02b2291d2/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= 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/tools v0.0.0-20180221164845-07fd8470d635/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= 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-20181221001348-537d06c36207/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= +golang.org/x/tools v0.0.0-20181030221726-6c7e314b6563/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-20190327201419-c70d86f8b7cf/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= golang.org/x/tools v0.0.0-20190506145303-2d16b83fe98c/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= @@ -1354,7 +1596,6 @@ golang.org/x/tools v0.0.0-20200729194436-6467de6f59a7/go.mod h1:njjCfa9FT2d7l9Bc golang.org/x/tools v0.0.0-20200804011535-6c149bb5ef0d/go.mod h1:njjCfa9FT2d7l9Bc6FUM5FLjQPp3cFF28FI3qnDFljA= golang.org/x/tools v0.0.0-20200825202427-b303f430e36d/go.mod h1:njjCfa9FT2d7l9Bc6FUM5FLjQPp3cFF28FI3qnDFljA= golang.org/x/tools v0.0.0-20200904185747-39188db58858/go.mod h1:Cj7w3i3Rnn0Xh82ur9kSqwfTHTeVxaDqrfMjpcNT6bE= -golang.org/x/tools v0.0.0-20201022035929-9cf592e881e9/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.0.0-20201110124207-079ba7bd75cd/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.0.0-20201201161351-ac6f37ff4c2a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.0.0-20201208233053-a543418bbed2/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= @@ -1362,19 +1603,26 @@ golang.org/x/tools v0.0.0-20210105154028-b0ab187a4818/go.mod h1:emZCQorbCU4vsT4f golang.org/x/tools v0.0.0-20210106214847-113979e3529a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.0.0-20210108195828-e2f9c7f1fc8e/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.1.0/go.mod h1:xkSsbof2nBLbhDlRMhhhyNLN/zl3eTqcnHD5viDpcZ0= +golang.org/x/tools v0.1.1/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= +golang.org/x/tools v0.1.2/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= 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.4.0 h1:7mTAgkunk3fr4GAloyyCasadO6h9zSsQZbwvcaIciV4= +golang.org/x/tools v0.1.12/go.mod h1:hNGJHUnrk76NpqgfD5Aqm5Crs+Hm0VOH/i9J2+nxYbc= +golang.org/x/tools v0.6.0 h1:BOw41kyTf3PuCW1pVQf8+Cyg8pMlkYB1oo9iJ6D/lKM= +golang.org/x/tools v0.6.0/go.mod h1:Xwgl3UAJ/d3gWutnCtw505GrjyAbvKui8lOU390QaIU= 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= golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= +golang.org/x/xerrors v0.0.0-20220411194840-2f41105eb62f/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= +golang.org/x/xerrors v0.0.0-20220517211312-f3a8303e98df/go.mod h1:K8+ghG5WaK9qNqU5K3HdILfMLy1f3aNYFI/wnl100a8= +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/gonum v0.8.2 h1:CCXrcPKiGGotvnN6jfUsKk4rRqm7q09/YbKb5xCEvtM= -gonum.org/v1/gonum v0.8.2/go.mod h1:oe/vMfY3deqTw+1EZJhuvEW2iwGF1bW9wwu7XCu0+v0= 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= @@ -1398,14 +1646,46 @@ google.golang.org/api v0.30.0/go.mod h1:QGmEvQ87FHZNiUVJkT14jQNYJ4ZJjdRF23ZXz513 google.golang.org/api v0.35.0/go.mod h1:/XrVsuzM0rZmrsbjJutiuftIzeuTQcEeaYcSk/mQ1dg= google.golang.org/api v0.36.0/go.mod h1:+z5ficQTmoYpPn8LCUNVpK5I7hwkpjbcgqA7I34qYtE= google.golang.org/api v0.40.0/go.mod h1:fYKFpnQN0DsDSKRVRcQSDQNtqWPfM9i+zNPxepjRCQ8= +google.golang.org/api v0.41.0/go.mod h1:RkxM5lITDfTzmyKFPt+wGrCJbVfniCr2ool8kTBzRTU= +google.golang.org/api v0.43.0/go.mod h1:nQsDGjRXMo4lvh5hP0TKqF244gqhGcr/YSIykhUk/94= +google.golang.org/api v0.47.0/go.mod h1:Wbvgpq1HddcWVtzsVLyfLp8lDg6AA241LmgIL59tHXo= +google.golang.org/api v0.48.0/go.mod h1:71Pr1vy+TAZRPkPs/xlCf5SsU8WjuAWv1Pfjbtukyy4= +google.golang.org/api v0.50.0/go.mod h1:4bNT5pAuq5ji4SRZm+5QIkjny9JAyVD/3gaSihNefaw= +google.golang.org/api v0.51.0/go.mod h1:t4HdrdoNgyN5cbEfm7Lum0lcLDLiise1F8qDKX00sOU= +google.golang.org/api v0.54.0/go.mod h1:7C4bFFOvVDGXjfDTAsgGwDgAxRDeQ4X8NvUedIt6z3k= +google.golang.org/api v0.55.0/go.mod h1:38yMfeP1kfjsl8isn0tliTjIb1rJXcQi4UXlbqivdVE= +google.golang.org/api v0.56.0/go.mod h1:38yMfeP1kfjsl8isn0tliTjIb1rJXcQi4UXlbqivdVE= +google.golang.org/api v0.57.0/go.mod h1:dVPlbZyBo2/OjBpmvNdpn2GRm6rPy75jyU7bmhdrMgI= +google.golang.org/api v0.61.0/go.mod h1:xQRti5UdCmoCEqFxcz93fTl338AVqDgyaDRuOZ3hg9I= +google.golang.org/api v0.63.0/go.mod h1:gs4ij2ffTRXwuzzgJl/56BdwJaA194ijkfn++9tDuPo= +google.golang.org/api v0.67.0/go.mod h1:ShHKP8E60yPsKNw/w8w+VYaj9H6buA5UqDp8dhbQZ6g= +google.golang.org/api v0.70.0/go.mod h1:Bs4ZM2HGifEvXwd50TtW70ovgJffJYw2oRCOFU/SkfA= +google.golang.org/api v0.71.0/go.mod h1:4PyU6e6JogV1f9eA4voyrTY2batOLdgZ5qZ5HOCc4j8= +google.golang.org/api v0.74.0/go.mod h1:ZpfMZOVRMywNyvJFeqL9HRWBgAuRfSjJFpe9QtRRyDs= +google.golang.org/api v0.75.0/go.mod h1:pU9QmyHLnzlpar1Mjt4IbapUCy8J+6HD6GeELN69ljA= +google.golang.org/api v0.77.0/go.mod h1:pU9QmyHLnzlpar1Mjt4IbapUCy8J+6HD6GeELN69ljA= +google.golang.org/api v0.78.0/go.mod h1:1Sg78yoMLOhlQTeF+ARBoytAcH1NNyyl390YMy6rKmw= +google.golang.org/api v0.80.0/go.mod h1:xY3nI94gbvBrE0J6NHXhxOmW97HG7Khjkku6AFB3Hyg= +google.golang.org/api v0.84.0/go.mod h1:NTsGnUFJMYROtiquksZHBWtHfeMC7iYthki7Eq3pa8o= +google.golang.org/api v0.85.0/go.mod h1:AqZf8Ep9uZ2pyTvgL+x0D3Zt0eoT9b5E8fmzfu6FO2g= +google.golang.org/api v0.90.0/go.mod h1:+Sem1dnrKlrXMR/X0bPnMWyluQe4RsNoYfmNLhOIkzw= +google.golang.org/api v0.93.0/go.mod h1:+Sem1dnrKlrXMR/X0bPnMWyluQe4RsNoYfmNLhOIkzw= +google.golang.org/api v0.95.0/go.mod h1:eADj+UBuxkh5zlrSntJghuNeg8HwQ1w5lTKkuqaETEI= +google.golang.org/api v0.96.0/go.mod h1:w7wJQLTM+wvQpNf5JyEcBoxK0RH7EDrh/L4qfsuJ13s= +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.126.0 h1:q4GJq+cAdMAC7XP7njvQ4tvohGLiSlytuL4BQxbIZ+o= +google.golang.org/api v0.126.0/go.mod h1:mBwVAtz+87bEN6CbA1GtZPDOqY2R5ONPqJeIlvyo4Aw= +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= google.golang.org/appengine v1.5.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= google.golang.org/appengine v1.6.1/go.mod h1:i06prIuMbXzDqacNJfV5OdTW448YApPu5ww/cMBSeb0= google.golang.org/appengine v1.6.5/go.mod h1:8WjMMxjGQR8xUklV/ARdw2HLXBOI7O7uCIDZVag1xfc= google.golang.org/appengine v1.6.6/go.mod h1:8WjMMxjGQR8xUklV/ARdw2HLXBOI7O7uCIDZVag1xfc= +google.golang.org/appengine v1.6.7 h1:FZR1q0exgwxzPzp/aF+VccGrSfxfPpkBqjIIEq3ru6c= google.golang.org/appengine v1.6.7/go.mod h1:8WjMMxjGQR8xUklV/ARdw2HLXBOI7O7uCIDZVag1xfc= -google.golang.org/genproto v0.0.0-20180518175338-11a468237815/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc= google.golang.org/genproto v0.0.0-20180817151627-c66870c02cf8/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc= google.golang.org/genproto v0.0.0-20180831171423-11092d34479b/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc= google.golang.org/genproto v0.0.0-20190307195333-5fe7a883aa19/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE= @@ -1430,7 +1710,6 @@ google.golang.org/genproto v0.0.0-20200224152610-e50cd9704f63/go.mod h1:55QSHmfG google.golang.org/genproto v0.0.0-20200228133532-8c2c7df3a383/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= google.golang.org/genproto v0.0.0-20200305110556-506484158171/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= google.golang.org/genproto v0.0.0-20200312145019-da6875a35672/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= -google.golang.org/genproto v0.0.0-20200324203455-a04cca1dde73/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= google.golang.org/genproto v0.0.0-20200331122359-1ee6d9798940/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= google.golang.org/genproto v0.0.0-20200423170343-7949de9c1215/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= google.golang.org/genproto v0.0.0-20200430143042-b979b6f78d84/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= @@ -1449,12 +1728,124 @@ google.golang.org/genproto v0.0.0-20201210142538-e3217bee35cc/go.mod h1:FWY/as6D google.golang.org/genproto v0.0.0-20201214200347-8c77b98c765d/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20210108203827-ffc7fda8c3d7/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20210126160654-44e461bb6506/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= +google.golang.org/genproto v0.0.0-20210222152913-aa3ee6e6a81c/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20210226172003-ab064af71705/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= +google.golang.org/genproto v0.0.0-20210303154014-9728d6b83eeb/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= +google.golang.org/genproto v0.0.0-20210310155132-4ce2db91004e/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= +google.golang.org/genproto v0.0.0-20210319143718-93e7006c17a6/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= +google.golang.org/genproto v0.0.0-20210329143202-679c6ae281ee/go.mod h1:9lPAdzaEmUacj36I+k7YKbEc5CXzPIeORRgDAUOu28A= +google.golang.org/genproto v0.0.0-20210402141018-6c239bbf2bb1/go.mod h1:9lPAdzaEmUacj36I+k7YKbEc5CXzPIeORRgDAUOu28A= +google.golang.org/genproto v0.0.0-20210513213006-bf773b8c8384/go.mod h1:P3QM42oQyzQSnHPnZ/vqoCdDmzH28fzWByN9asMeM8A= +google.golang.org/genproto v0.0.0-20210602131652-f16073e35f0c/go.mod h1:UODoCrxHCcBojKKwX1terBiRUaqAsFqJiF615XL43r0= +google.golang.org/genproto v0.0.0-20210604141403-392c879c8b08/go.mod h1:UODoCrxHCcBojKKwX1terBiRUaqAsFqJiF615XL43r0= +google.golang.org/genproto v0.0.0-20210608205507-b6d2f5bf0d7d/go.mod h1:UODoCrxHCcBojKKwX1terBiRUaqAsFqJiF615XL43r0= google.golang.org/genproto v0.0.0-20210624195500-8bfb893ecb84/go.mod h1:SzzZ/N+nwJDaO1kznhnlzqS8ocJICar6hYhVyhi++24= -google.golang.org/genproto v0.0.0-20230125152338-dcaf20b6aeaa h1:qQPhfbPO23fwm/9lQr91L1u62Zo6cm+zI+slZT+uf+o= -google.golang.org/genproto v0.0.0-20230125152338-dcaf20b6aeaa/go.mod h1:RGgjbofJ8xD9Sq1VVhDM1Vok1vRONV+rg+CjzG4SZKM= -google.golang.org/grpc v1.33.2 h1:EQyQC3sa8M+p6Ulc8yy9SWSS2GVwyRc83gAbG8lrl4o= +google.golang.org/genproto v0.0.0-20210713002101-d411969a0d9a/go.mod h1:AxrInvYm1dci+enl5hChSFPOmmUF1+uAa/UsgNRWd7k= +google.golang.org/genproto v0.0.0-20210716133855-ce7ef5c701ea/go.mod h1:AxrInvYm1dci+enl5hChSFPOmmUF1+uAa/UsgNRWd7k= +google.golang.org/genproto v0.0.0-20210728212813-7823e685a01f/go.mod h1:ob2IJxKrgPT52GcgX759i1sleT07tiKowYBGbczaW48= +google.golang.org/genproto v0.0.0-20210805201207-89edb61ffb67/go.mod h1:ob2IJxKrgPT52GcgX759i1sleT07tiKowYBGbczaW48= +google.golang.org/genproto v0.0.0-20210813162853-db860fec028c/go.mod h1:cFeNkxwySK631ADgubI+/XFU/xp8FD5KIVV4rj8UC5w= +google.golang.org/genproto v0.0.0-20210821163610-241b8fcbd6c8/go.mod h1:eFjDcFEctNawg4eG61bRv87N7iHBWyVhJu7u1kqDUXY= +google.golang.org/genproto v0.0.0-20210828152312-66f60bf46e71/go.mod h1:eFjDcFEctNawg4eG61bRv87N7iHBWyVhJu7u1kqDUXY= +google.golang.org/genproto v0.0.0-20210831024726-fe130286e0e2/go.mod h1:eFjDcFEctNawg4eG61bRv87N7iHBWyVhJu7u1kqDUXY= +google.golang.org/genproto v0.0.0-20210903162649-d08c68adba83/go.mod h1:eFjDcFEctNawg4eG61bRv87N7iHBWyVhJu7u1kqDUXY= +google.golang.org/genproto v0.0.0-20210909211513-a8c4777a87af/go.mod h1:eFjDcFEctNawg4eG61bRv87N7iHBWyVhJu7u1kqDUXY= +google.golang.org/genproto v0.0.0-20210924002016-3dee208752a0/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= +google.golang.org/genproto v0.0.0-20211118181313-81c1377c94b1/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= +google.golang.org/genproto v0.0.0-20211206160659-862468c7d6e0/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= +google.golang.org/genproto v0.0.0-20211208223120-3a66f561d7aa/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= +google.golang.org/genproto v0.0.0-20211221195035-429b39de9b1c/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= +google.golang.org/genproto v0.0.0-20220126215142-9970aeb2e350/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= +google.golang.org/genproto v0.0.0-20220207164111-0872dc986b00/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= +google.golang.org/genproto v0.0.0-20220218161850-94dd64e39d7c/go.mod h1:kGP+zUP2Ddo0ayMi4YuN7C3WZyJvGLZRh8Z5wnAqvEI= +google.golang.org/genproto v0.0.0-20220222213610-43724f9ea8cf/go.mod h1:kGP+zUP2Ddo0ayMi4YuN7C3WZyJvGLZRh8Z5wnAqvEI= +google.golang.org/genproto v0.0.0-20220304144024-325a89244dc8/go.mod h1:kGP+zUP2Ddo0ayMi4YuN7C3WZyJvGLZRh8Z5wnAqvEI= +google.golang.org/genproto v0.0.0-20220310185008-1973136f34c6/go.mod h1:kGP+zUP2Ddo0ayMi4YuN7C3WZyJvGLZRh8Z5wnAqvEI= +google.golang.org/genproto v0.0.0-20220314164441-57ef72a4c106/go.mod h1:hAL49I2IFola2sVEjAn7MEwsja0xp51I0tlGAf9hz4E= +google.golang.org/genproto v0.0.0-20220324131243-acbaeb5b85eb/go.mod h1:hAL49I2IFola2sVEjAn7MEwsja0xp51I0tlGAf9hz4E= +google.golang.org/genproto v0.0.0-20220407144326-9054f6ed7bac/go.mod h1:8w6bsBMX6yCPbAVTeqQHvzxW0EIFigd5lZyahWgyfDo= +google.golang.org/genproto v0.0.0-20220413183235-5e96e2839df9/go.mod h1:8w6bsBMX6yCPbAVTeqQHvzxW0EIFigd5lZyahWgyfDo= +google.golang.org/genproto v0.0.0-20220414192740-2d67ff6cf2b4/go.mod h1:8w6bsBMX6yCPbAVTeqQHvzxW0EIFigd5lZyahWgyfDo= +google.golang.org/genproto v0.0.0-20220421151946-72621c1f0bd3/go.mod h1:8w6bsBMX6yCPbAVTeqQHvzxW0EIFigd5lZyahWgyfDo= +google.golang.org/genproto v0.0.0-20220429170224-98d788798c3e/go.mod h1:8w6bsBMX6yCPbAVTeqQHvzxW0EIFigd5lZyahWgyfDo= +google.golang.org/genproto v0.0.0-20220502173005-c8bf987b8c21/go.mod h1:RAyBrSAP7Fh3Nc84ghnVLDPuV51xc9agzmm4Ph6i0Q4= +google.golang.org/genproto v0.0.0-20220505152158-f39f71e6c8f3/go.mod h1:RAyBrSAP7Fh3Nc84ghnVLDPuV51xc9agzmm4Ph6i0Q4= +google.golang.org/genproto v0.0.0-20220518221133-4f43b3371335/go.mod h1:RAyBrSAP7Fh3Nc84ghnVLDPuV51xc9agzmm4Ph6i0Q4= +google.golang.org/genproto v0.0.0-20220523171625-347a074981d8/go.mod h1:RAyBrSAP7Fh3Nc84ghnVLDPuV51xc9agzmm4Ph6i0Q4= +google.golang.org/genproto v0.0.0-20220608133413-ed9918b62aac/go.mod h1:KEWEmljWE5zPzLBa/oHl6DaEt9LmfH6WtH1OHIvleBA= +google.golang.org/genproto v0.0.0-20220616135557-88e70c0c3a90/go.mod h1:KEWEmljWE5zPzLBa/oHl6DaEt9LmfH6WtH1OHIvleBA= +google.golang.org/genproto v0.0.0-20220617124728-180714bec0ad/go.mod h1:KEWEmljWE5zPzLBa/oHl6DaEt9LmfH6WtH1OHIvleBA= +google.golang.org/genproto v0.0.0-20220624142145-8cd45d7dbd1f/go.mod h1:KEWEmljWE5zPzLBa/oHl6DaEt9LmfH6WtH1OHIvleBA= +google.golang.org/genproto v0.0.0-20220628213854-d9e0b6570c03/go.mod h1:KEWEmljWE5zPzLBa/oHl6DaEt9LmfH6WtH1OHIvleBA= +google.golang.org/genproto v0.0.0-20220722212130-b98a9ff5e252/go.mod h1:GkXuJDJ6aQ7lnJcRF+SJVgFdQhypqgl3LB1C9vabdRE= +google.golang.org/genproto v0.0.0-20220801145646-83ce21fca29f/go.mod h1:iHe1svFLAZg9VWz891+QbRMwUv9O/1Ww+/mngYeThbc= +google.golang.org/genproto v0.0.0-20220815135757-37a418bb8959/go.mod h1:dbqgFATTzChvnt+ujMdZwITVAJHFtfyN1qUhDqEiIlk= +google.golang.org/genproto v0.0.0-20220817144833-d7fd3f11b9b1/go.mod h1:dbqgFATTzChvnt+ujMdZwITVAJHFtfyN1qUhDqEiIlk= +google.golang.org/genproto v0.0.0-20220822174746-9e6da59bd2fc/go.mod h1:dbqgFATTzChvnt+ujMdZwITVAJHFtfyN1qUhDqEiIlk= +google.golang.org/genproto v0.0.0-20220829144015-23454907ede3/go.mod h1:dbqgFATTzChvnt+ujMdZwITVAJHFtfyN1qUhDqEiIlk= +google.golang.org/genproto v0.0.0-20220829175752-36a9c930ecbf/go.mod h1:dbqgFATTzChvnt+ujMdZwITVAJHFtfyN1qUhDqEiIlk= +google.golang.org/genproto v0.0.0-20220913154956-18f8339a66a5/go.mod h1:0Nb8Qy+Sk5eDzHnzlStwW3itdNaWoZA5XeSG+R3JHSo= +google.golang.org/genproto v0.0.0-20220914142337-ca0e39ece12f/go.mod h1:0Nb8Qy+Sk5eDzHnzlStwW3itdNaWoZA5XeSG+R3JHSo= +google.golang.org/genproto v0.0.0-20220915135415-7fd63a7952de/go.mod h1:0Nb8Qy+Sk5eDzHnzlStwW3itdNaWoZA5XeSG+R3JHSo= +google.golang.org/genproto v0.0.0-20220916172020-2692e8806bfa/go.mod h1:0Nb8Qy+Sk5eDzHnzlStwW3itdNaWoZA5XeSG+R3JHSo= +google.golang.org/genproto v0.0.0-20220919141832-68c03719ef51/go.mod h1:0Nb8Qy+Sk5eDzHnzlStwW3itdNaWoZA5XeSG+R3JHSo= +google.golang.org/genproto v0.0.0-20220920201722-2b89144ce006/go.mod h1:ht8XFiar2npT/g4vkk7O0WYS1sHOHbdujxbEp7CJWbw= +google.golang.org/genproto v0.0.0-20220926165614-551eb538f295/go.mod h1:woMGP53BroOrRY3xTxlbr8Y3eB/nzAvvFM83q7kG2OI= +google.golang.org/genproto v0.0.0-20220926220553-6981cbe3cfce/go.mod h1:woMGP53BroOrRY3xTxlbr8Y3eB/nzAvvFM83q7kG2OI= +google.golang.org/genproto v0.0.0-20221010155953-15ba04fc1c0e/go.mod h1:3526vdqwhZAwq4wsRUaVG555sVgsNmIjRtO7t/JH29U= +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-20230706204954-ccb25ca9f130 h1:Au6te5hbKUV8pIYWHqOUZ1pva5qK/rwbIhoXEUB9Lu8= +google.golang.org/genproto v0.0.0-20230706204954-ccb25ca9f130/go.mod h1:O9kGHb51iE/nOGvQaDUuadVYqovW56s5emA88lQnj6Y= +google.golang.org/genproto/googleapis/api v0.0.0-20230629202037-9506855d4529 h1:s5YSX+ZH5b5vS9rnpGymvIyMpLRJizowqDlOuyjXnTk= +google.golang.org/genproto/googleapis/api v0.0.0-20230629202037-9506855d4529/go.mod h1:vHYtlOoi6TsQ3Uk2yxR7NI5z8uoV+3pZtR4jmHIkRig= +google.golang.org/genproto/googleapis/rpc v0.0.0-20230711160842-782d3b101e98 h1:bVf09lpb+OJbByTj913DRJioFFAjf/ZGxEz7MajTp2U= +google.golang.org/genproto/googleapis/rpc v0.0.0-20230711160842-782d3b101e98/go.mod h1:TUfxEVdsvPg18p6AslUXFoLdpED4oBnGwyqk3dV1XzM= +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= +google.golang.org/grpc v1.20.1/go.mod h1:10oTOabMzJvdu6/UiuZezV6QK5dSlG84ov/aaiqXj38= +google.golang.org/grpc v1.21.0/go.mod h1:oYelfM1adQP15Ek0mdvEgi9Df8B9CZIaU1084ijfRaM= +google.golang.org/grpc v1.21.1/go.mod h1:oYelfM1adQP15Ek0mdvEgi9Df8B9CZIaU1084ijfRaM= +google.golang.org/grpc v1.22.1/go.mod h1:Y5yQAOtifL1yxbo5wqy6BxZv8vAUGQwXBOALyacEbxg= +google.golang.org/grpc v1.23.0/go.mod h1:Y5yQAOtifL1yxbo5wqy6BxZv8vAUGQwXBOALyacEbxg= +google.golang.org/grpc v1.23.1/go.mod h1:Y5yQAOtifL1yxbo5wqy6BxZv8vAUGQwXBOALyacEbxg= +google.golang.org/grpc v1.25.1/go.mod h1:c3i+UQWmh7LiEpx4sFZnkU36qjEYZ0imhYfXVyQciAY= +google.golang.org/grpc v1.26.0/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk= +google.golang.org/grpc v1.27.0/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk= +google.golang.org/grpc v1.27.1/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk= +google.golang.org/grpc v1.28.0/go.mod h1:rpkK4SK4GF4Ach/+MFLZUBavHOvF2JJB5uozKKal+60= +google.golang.org/grpc v1.29.1/go.mod h1:itym6AZVZYACWQqET3MqgPpjcuV5QH3BxFS3IjizoKk= +google.golang.org/grpc v1.30.0/go.mod h1:N36X2cJ7JwdamYAgDz+s+rVMFjt3numwzf/HckM8pak= +google.golang.org/grpc v1.31.0/go.mod h1:N36X2cJ7JwdamYAgDz+s+rVMFjt3numwzf/HckM8pak= +google.golang.org/grpc v1.31.1/go.mod h1:N36X2cJ7JwdamYAgDz+s+rVMFjt3numwzf/HckM8pak= +google.golang.org/grpc v1.32.0/go.mod h1:N36X2cJ7JwdamYAgDz+s+rVMFjt3numwzf/HckM8pak= +google.golang.org/grpc v1.33.1/go.mod h1:fr5YgcSWrqhRRxogOsw7RzIpsmvOZ6IcH4kBYTpR3n0= google.golang.org/grpc v1.33.2/go.mod h1:JMHMWHQWaTccqQQlmk3MJZS+GWXOdAesneDmEnv2fbc= +google.golang.org/grpc v1.34.0/go.mod h1:WotjhfgOW/POjDeRt8vscBtXq+2VjORFy659qA51WJ8= +google.golang.org/grpc v1.35.0/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU= +google.golang.org/grpc v1.36.0/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU= +google.golang.org/grpc v1.36.1/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU= +google.golang.org/grpc v1.37.0/go.mod h1:NREThFqKR1f3iQ6oBuvc5LadQuXVGo9rkm5ZGrQdJfM= +google.golang.org/grpc v1.37.1/go.mod h1:NREThFqKR1f3iQ6oBuvc5LadQuXVGo9rkm5ZGrQdJfM= +google.golang.org/grpc v1.38.0/go.mod h1:NREThFqKR1f3iQ6oBuvc5LadQuXVGo9rkm5ZGrQdJfM= +google.golang.org/grpc v1.39.0/go.mod h1:PImNr+rS9TWYb2O4/emRugxiyHZ5JyHW5F+RPnDzfrE= +google.golang.org/grpc v1.39.1/go.mod h1:PImNr+rS9TWYb2O4/emRugxiyHZ5JyHW5F+RPnDzfrE= +google.golang.org/grpc v1.40.0/go.mod h1:ogyxbiOoUXAkP+4+xa6PZSE9DZgIHtSpzjDTB9KAK34= +google.golang.org/grpc v1.40.1/go.mod h1:ogyxbiOoUXAkP+4+xa6PZSE9DZgIHtSpzjDTB9KAK34= +google.golang.org/grpc v1.44.0/go.mod h1:k+4IHHFw41K8+bbowsex27ge2rCb65oeWqe4jJ590SU= +google.golang.org/grpc v1.45.0/go.mod h1:lN7owxKUQEqMfSyQikvvk5tf/6zMPsrK+ONuO11+0rQ= +google.golang.org/grpc v1.46.0/go.mod h1:vN9eftEi1UMyUsIF80+uQXhHjbXYbm0uXoFCACuMGWk= +google.golang.org/grpc v1.46.2/go.mod h1:vN9eftEi1UMyUsIF80+uQXhHjbXYbm0uXoFCACuMGWk= +google.golang.org/grpc v1.47.0/go.mod h1:vN9eftEi1UMyUsIF80+uQXhHjbXYbm0uXoFCACuMGWk= +google.golang.org/grpc v1.48.0/go.mod h1:vN9eftEi1UMyUsIF80+uQXhHjbXYbm0uXoFCACuMGWk= +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.56.2 h1:fVRFRnXvU+x6C4IlHZewvJOVHoOv1TUuQyoRsYnB4bI= +google.golang.org/grpc v1.56.2/go.mod h1:I9bI3vqKfayGqPUAwGdOSu7kt6oIJLixfffKrpXqQ9s= +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= google.golang.org/protobuf v0.0.0-20200228230310-ab0ca4ff8a60/go.mod h1:cfTl7dwQJ+fmap5saPgwCLgHXTUD7jkjRqWcaiX5VyM= @@ -1467,26 +1858,26 @@ google.golang.org/protobuf v1.24.0/go.mod h1:r/3tXBNzIEhYS9I1OUVjXDlt8tc493IdKGj google.golang.org/protobuf v1.25.0/go.mod h1:9JNX74DMeImyA3h4bdi1ymwjUzf21/xIlbajtzgsN7c= google.golang.org/protobuf v1.26.0-rc.1/go.mod h1:jlhhOSvTdKEhbULTjvd4ARK9grFBp09yW+WbY/TyQbw= google.golang.org/protobuf v1.26.0/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc= -google.golang.org/protobuf v1.28.2-0.20220831092852-f930b1dc76e8 h1:KR8+MyP7/qOlV+8Af01LtjL04bu7on42eVsxT4EyBQk= -google.golang.org/protobuf v1.28.2-0.20220831092852-f930b1dc76e8/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= +google.golang.org/protobuf v1.27.1/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc= +google.golang.org/protobuf v1.28.0/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= +google.golang.org/protobuf v1.28.1/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= +google.golang.org/protobuf v1.30.0/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= +google.golang.org/protobuf v1.31.0 h1:g0LDEJHgrBl9N9r17Ru3sqWhkIx2NB67okBHPwC7hs8= +google.golang.org/protobuf v1.31.0/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLkstjWtayDeSgw= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= -gopkg.in/check.v1 v1.0.0-20200227125254-8fa46927fb4f/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20200902074654-038fdea0a05b/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q= gopkg.in/cheggaaa/pb.v1 v1.0.25/go.mod h1:V/YB90LKu/1FcN3WVnfiiE5oMCibMjukxqG/qStrOgw= +gopkg.in/cheggaaa/pb.v1 v1.0.27/go.mod h1:V/YB90LKu/1FcN3WVnfiiE5oMCibMjukxqG/qStrOgw= gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI= gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys= gopkg.in/gcfg.v1 v1.2.3/go.mod h1:yesOnuUOFQAhST5vPY4nbZsb/huCgGGXlipJsBn0b3o= -gopkg.in/go-playground/assert.v1 v1.2.1/go.mod h1:9RXL0bg/zibRAgZUYszZSwO/z8Y/a8bDuhia5mkpMnE= -gopkg.in/go-playground/validator.v8 v8.18.2/go.mod h1:RX2a/7Ha8BgOhfk7j780h4/u/RRjR0eouCJSH80/M2Y= -gopkg.in/ini.v1 v1.51.1/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= 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/mgo.v2 v2.0.0-20180705113604-9856a29383ce/go.mod h1:yeKp02qBN3iKW1OzL3MGk2IdtZzaj7SFntXj72NppTA= 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= @@ -1504,14 +1895,14 @@ gopkg.in/yaml.v2 v2.2.8/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.3.0/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY= gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ= -gopkg.in/yaml.v3 v3.0.0-20191120175047-4206685974f2/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= 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.4.0 h1:ZazjZUfuVeZGLAmlKKuyv3IKP5orXcwtOwDQH6YVr6o= +gotest.tools/v3 v3.5.0 h1:Ljk6PdHdOhAb5aDMWXjDLMMhph+BpztA4v1QdqEW2eY= +honnef.co/go/tools v0.0.0-20180728063816-88497007e858/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.0-20190106161140-3f1c8253044a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.0-20190418001031-e561f6794a2a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= @@ -1522,11 +1913,14 @@ honnef.co/go/tools v0.0.1-2020.1.4/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9 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 v0.5.3 h1:163N50IHFqr1phZens4FQOdPgfJscR7a562mjQqeo4M= +pgregory.net/rapid v0.5.5 h1:jkgx1TjbQPD/feRoK+S/mXw9e1uj6WilpHrXJowi6oA= +pgregory.net/rapid v0.5.5/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.3.0 h1:a2VclLzOGrwOHDiV8EfBGhvjHvP46CtW5j6POvhYGGo= +sigs.k8s.io/yaml v1.3.0/go.mod h1:GeOyir5tyXNByN85N/dRIT9es5UQNerPYEKK56eTBm8= sourcegraph.com/sourcegraph/appdash v0.0.0-20190731080439-ebfcffb1b5c0/go.mod h1:hI742Nqp5OhwiqlzhgfbWU4mW4yO10fP+LoT9WOswdU= diff --git a/proto/omniflix/alloc/v1beta1/genesis.proto b/proto/OmniFlix/alloc/v1beta1/genesis.proto similarity index 56% rename from proto/omniflix/alloc/v1beta1/genesis.proto rename to proto/OmniFlix/alloc/v1beta1/genesis.proto index bdd821cb..c6693da6 100644 --- a/proto/omniflix/alloc/v1beta1/genesis.proto +++ b/proto/OmniFlix/alloc/v1beta1/genesis.proto @@ -1,10 +1,10 @@ syntax = "proto3"; -package omniflix.alloc.v1beta1; +package OmniFlix.alloc.v1beta1; import "gogoproto/gogo.proto"; -import "omniflix/alloc/v1beta1/params.proto"; +import "OmniFlix/alloc/v1beta1/params.proto"; -option go_package = "github.com/OmniFlix/omniflixhub/x/alloc/types"; +option go_package = "github.com/OmniFlix/omniflixhub/v2/x/alloc/types"; // GenesisState defines the alloc module's genesis state. message GenesisState { diff --git a/proto/omniflix/alloc/v1beta1/params.proto b/proto/OmniFlix/alloc/v1beta1/params.proto similarity index 95% rename from proto/omniflix/alloc/v1beta1/params.proto rename to proto/OmniFlix/alloc/v1beta1/params.proto index 4ce3dfec..e3fb686c 100644 --- a/proto/omniflix/alloc/v1beta1/params.proto +++ b/proto/OmniFlix/alloc/v1beta1/params.proto @@ -1,8 +1,8 @@ syntax = "proto3"; -package omniflix.alloc.v1beta1; +package OmniFlix.alloc.v1beta1; -option go_package = "github.com/OmniFlix/omniflixhub/x/alloc/types"; +option go_package = "github.com/OmniFlix/omniflixhub/v2/x/alloc/types"; import "gogoproto/gogo.proto"; diff --git a/proto/omniflix/alloc/v1beta1/query.proto b/proto/OmniFlix/alloc/v1beta1/query.proto similarity index 80% rename from proto/omniflix/alloc/v1beta1/query.proto rename to proto/OmniFlix/alloc/v1beta1/query.proto index 41137f66..587c4804 100644 --- a/proto/omniflix/alloc/v1beta1/query.proto +++ b/proto/OmniFlix/alloc/v1beta1/query.proto @@ -1,11 +1,11 @@ syntax = "proto3"; -package omniflix.alloc.v1beta1; +package OmniFlix.alloc.v1beta1; import "gogoproto/gogo.proto"; import "google/api/annotations.proto"; -import "omniflix/alloc/v1beta1/params.proto"; +import "OmniFlix/alloc/v1beta1/params.proto"; -option go_package = "github.com/OmniFlix/omniflixhub/x/alloc/types"; +option go_package = "github.com/OmniFlix/omniflixhub/v2/x/alloc/types"; // QueryParamsRequest is the request type for the Query/Params RPC method. message QueryParamsRequest {} diff --git a/proto/OmniFlix/alloc/v1beta1/tx.proto b/proto/OmniFlix/alloc/v1beta1/tx.proto new file mode 100644 index 00000000..7b34e79c --- /dev/null +++ b/proto/OmniFlix/alloc/v1beta1/tx.proto @@ -0,0 +1,38 @@ +syntax = "proto3"; +package OmniFlix.alloc.v1beta1; + +option go_package = "github.com/OmniFlix/omniflixhub/v2/x/alloc/types"; + +import "cosmos/msg/v1/msg.proto"; +import "OmniFlix/alloc/v1beta1/params.proto"; +import "gogoproto/gogo.proto"; +import "cosmos_proto/cosmos.proto"; + +service Msg { + // UpdateParams defines a governance operation for updating the x/alloc module + // parameters. The authority is hard-coded to the x/gov module account. + // + // Since: cosmos-sdk 0.47 + rpc UpdateParams(MsgUpdateParams) returns (MsgUpdateParamsResponse); +} + +// MsgUpdateParams is the Msg/UpdateParams request type. +// +// Since: cosmos-sdk 0.47 +message MsgUpdateParams { + option (cosmos.msg.v1.signer) = "authority"; + + // authority is the address of the governance account. + string authority = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + + // params defines the x/alloc parameters to update. + // + // NOTE: All parameters must be supplied. + Params params = 2 [(gogoproto.nullable) = false]; +} + +// MsgUpdateParamsResponse defines the response structure for executing a +// MsgUpdateParams message. +// +// Since: cosmos-sdk 0.47 +message MsgUpdateParamsResponse {} \ No newline at end of file diff --git a/proto/omniflix/itc/v1/genesis.proto b/proto/OmniFlix/itc/v1/genesis.proto similarity index 73% rename from proto/omniflix/itc/v1/genesis.proto rename to proto/OmniFlix/itc/v1/genesis.proto index 93a06e8e..9c112db3 100644 --- a/proto/omniflix/itc/v1/genesis.proto +++ b/proto/OmniFlix/itc/v1/genesis.proto @@ -2,10 +2,10 @@ syntax = "proto3"; package OmniFlix.itc.v1; import "gogoproto/gogo.proto"; -import "omniflix/itc/v1/params.proto"; -import "omniflix/itc/v1/itc.proto"; +import "OmniFlix/itc/v1/params.proto"; +import "OmniFlix/itc/v1/itc.proto"; -option go_package = "github.com/OmniFlix/omniflixhub/x/itc/types"; +option go_package = "github.com/OmniFlix/omniflixhub/v2/x/itc/types"; // GenesisState defines the itc module's genesis state. message GenesisState { diff --git a/proto/omniflix/itc/v1/itc.proto b/proto/OmniFlix/itc/v1/itc.proto similarity index 97% rename from proto/omniflix/itc/v1/itc.proto rename to proto/OmniFlix/itc/v1/itc.proto index bcf2338e..2d244807 100644 --- a/proto/omniflix/itc/v1/itc.proto +++ b/proto/OmniFlix/itc/v1/itc.proto @@ -6,7 +6,7 @@ import "gogoproto/gogo.proto"; import "google/protobuf/timestamp.proto"; import "google/protobuf/duration.proto"; -option go_package = "github.com/OmniFlix/omniflixhub/x/itc/types"; +option go_package = "github.com/OmniFlix/omniflixhub/v2/x/itc/types"; option (gogoproto.goproto_getters_all) = false; option (gogoproto.goproto_enum_prefix_all) = false; diff --git a/proto/omniflix/itc/v1/params.proto b/proto/OmniFlix/itc/v1/params.proto similarity index 88% rename from proto/omniflix/itc/v1/params.proto rename to proto/OmniFlix/itc/v1/params.proto index 435d2b6a..a4551613 100644 --- a/proto/omniflix/itc/v1/params.proto +++ b/proto/OmniFlix/itc/v1/params.proto @@ -2,7 +2,7 @@ syntax = "proto3"; package OmniFlix.itc.v1; -option go_package = "github.com/OmniFlix/omniflixhub/x/itc/types"; +option go_package = "github.com/OmniFlix/omniflixhub/v2/x/itc/types"; option (gogoproto.goproto_getters_all) = false; diff --git a/proto/omniflix/itc/v1/query.proto b/proto/OmniFlix/itc/v1/query.proto similarity index 94% rename from proto/omniflix/itc/v1/query.proto rename to proto/OmniFlix/itc/v1/query.proto index ea971cce..139c3e70 100644 --- a/proto/omniflix/itc/v1/query.proto +++ b/proto/OmniFlix/itc/v1/query.proto @@ -4,10 +4,10 @@ package OmniFlix.itc.v1; import "cosmos/base/query/v1beta1/pagination.proto"; import "gogoproto/gogo.proto"; import "google/api/annotations.proto"; -import "omniflix/itc/v1/params.proto"; -import "omniflix/itc/v1/itc.proto"; +import "OmniFlix/itc/v1/params.proto"; +import "OmniFlix/itc/v1/itc.proto"; -option go_package = "github.com/OmniFlix/omniflixhub/x/itc/types"; +option go_package = "github.com/OmniFlix/omniflixhub/v2/x/itc/types"; option (gogoproto.goproto_getters_all) = false; // Query defines the gRPC querier service. diff --git a/proto/omniflix/itc/v1/tx.proto b/proto/OmniFlix/itc/v1/tx.proto similarity index 68% rename from proto/omniflix/itc/v1/tx.proto rename to proto/OmniFlix/itc/v1/tx.proto index ef518acb..e921cf02 100644 --- a/proto/omniflix/itc/v1/tx.proto +++ b/proto/OmniFlix/itc/v1/tx.proto @@ -1,13 +1,16 @@ syntax = "proto3"; package OmniFlix.itc.v1; +import "cosmos/msg/v1/msg.proto"; import "cosmos/base/v1beta1/coin.proto"; import "gogoproto/gogo.proto"; +import "cosmos_proto/cosmos.proto"; import "google/protobuf/timestamp.proto"; import "google/protobuf/duration.proto"; -import "omniflix/itc/v1/itc.proto"; +import "OmniFlix/itc/v1/itc.proto"; +import "OmniFlix/itc/v1/params.proto"; -option go_package = "github.com/OmniFlix/omniflixhub/x/itc/types"; +option go_package = "github.com/OmniFlix/omniflixhub/v2/x/itc/types"; option (gogoproto.goproto_getters_all) = false; service Msg { @@ -18,6 +21,12 @@ service Msg { rpc Claim(MsgClaim) returns (MsgClaimResponse); rpc DepositCampaign(MsgDepositCampaign) returns (MsgDepositCampaignResponse); + + // UpdateParams defines a governance operation for updating the x/itc module + // parameters. The authority is hard-coded to the x/gov module account. + // + // Since: cosmos-sdk 0.47 + rpc UpdateParams(MsgUpdateParams) returns (MsgUpdateParamsResponse); } message MsgCreateCampaign { @@ -81,4 +90,25 @@ message MsgDepositCampaign { string depositor = 3; } -message MsgDepositCampaignResponse {} \ No newline at end of file +message MsgDepositCampaignResponse {} + +// MsgUpdateParams is the Msg/UpdateParams request type. +// +// Since: cosmos-sdk 0.47 +message MsgUpdateParams { + option (cosmos.msg.v1.signer) = "authority"; + + // authority is the address of the governance account. + string authority = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + + // params defines the x/itc parameters to update. + // + // NOTE: All parameters must be supplied. + Params params = 2 [(gogoproto.nullable) = false]; +} + +// MsgUpdateParamsResponse defines the response structure for executing a +// MsgUpdateParams message. +// +// Since: cosmos-sdk 0.47 +message MsgUpdateParamsResponse {} \ No newline at end of file diff --git a/proto/omniflix/marketplace/v1beta1/auction.proto b/proto/OmniFlix/marketplace/v1beta1/auction.proto similarity index 94% rename from proto/omniflix/marketplace/v1beta1/auction.proto rename to proto/OmniFlix/marketplace/v1beta1/auction.proto index eeb79df8..ae69382a 100644 --- a/proto/omniflix/marketplace/v1beta1/auction.proto +++ b/proto/OmniFlix/marketplace/v1beta1/auction.proto @@ -4,9 +4,9 @@ package OmniFlix.marketplace.v1beta1; import "cosmos/base/v1beta1/coin.proto"; import "gogoproto/gogo.proto"; import "google/protobuf/timestamp.proto"; -import "omniflix/marketplace/v1beta1/listing.proto"; +import "OmniFlix/marketplace/v1beta1/listing.proto"; -option go_package = "github.com/OmniFlix/omniflixhub/x/marketplace/types"; +option go_package = "github.com/OmniFlix/omniflixhub/v2/x/marketplace/types"; option (gogoproto.goproto_getters_all) = false; option (gogoproto.goproto_enum_prefix_all) = false; diff --git a/proto/omniflix/marketplace/v1beta1/events.proto b/proto/OmniFlix/marketplace/v1beta1/events.proto similarity index 94% rename from proto/omniflix/marketplace/v1beta1/events.proto rename to proto/OmniFlix/marketplace/v1beta1/events.proto index 55bd7eec..0381d6d5 100644 --- a/proto/omniflix/marketplace/v1beta1/events.proto +++ b/proto/OmniFlix/marketplace/v1beta1/events.proto @@ -1,7 +1,7 @@ syntax = "proto3"; package OmniFlix.marketplace.v1beta1; -option go_package = "github.com/OmniFlix/omniflixhub/x/marketplace/types"; +option go_package = "github.com/OmniFlix/omniflixhub/v2/x/marketplace/types"; // EventListONFT is emitted on NFT Listing on market message EventListNFT { diff --git a/proto/omniflix/marketplace/v1beta1/genesis.proto b/proto/OmniFlix/marketplace/v1beta1/genesis.proto similarity index 71% rename from proto/omniflix/marketplace/v1beta1/genesis.proto rename to proto/OmniFlix/marketplace/v1beta1/genesis.proto index 97169bbf..2dcf0646 100644 --- a/proto/omniflix/marketplace/v1beta1/genesis.proto +++ b/proto/OmniFlix/marketplace/v1beta1/genesis.proto @@ -2,11 +2,11 @@ syntax = "proto3"; package OmniFlix.marketplace.v1beta1; import "gogoproto/gogo.proto"; -import "omniflix/marketplace/v1beta1/listing.proto"; -import "omniflix/marketplace/v1beta1/auction.proto"; -import "omniflix/marketplace/v1beta1/params.proto"; +import "OmniFlix/marketplace/v1beta1/listing.proto"; +import "OmniFlix/marketplace/v1beta1/auction.proto"; +import "OmniFlix/marketplace/v1beta1/params.proto"; -option go_package = "github.com/OmniFlix/omniflixhub/x/marketplace/types"; +option go_package = "github.com/OmniFlix/omniflixhub/v2/x/marketplace/types"; message GenesisState { // NFTs that are listed in marketplace diff --git a/proto/omniflix/marketplace/v1beta1/listing.proto b/proto/OmniFlix/marketplace/v1beta1/listing.proto similarity index 93% rename from proto/omniflix/marketplace/v1beta1/listing.proto rename to proto/OmniFlix/marketplace/v1beta1/listing.proto index d9d9ada8..648db657 100644 --- a/proto/omniflix/marketplace/v1beta1/listing.proto +++ b/proto/OmniFlix/marketplace/v1beta1/listing.proto @@ -4,7 +4,7 @@ package OmniFlix.marketplace.v1beta1; import "cosmos/base/v1beta1/coin.proto"; import "gogoproto/gogo.proto"; -option go_package = "github.com/OmniFlix/omniflixhub/x/marketplace/types"; +option go_package = "github.com/OmniFlix/omniflixhub/v2/x/marketplace/types"; option (gogoproto.goproto_getters_all) = false; diff --git a/proto/omniflix/marketplace/v1beta1/params.proto b/proto/OmniFlix/marketplace/v1beta1/params.proto similarity index 94% rename from proto/omniflix/marketplace/v1beta1/params.proto rename to proto/OmniFlix/marketplace/v1beta1/params.proto index 1dad65a1..d9bfabe3 100644 --- a/proto/omniflix/marketplace/v1beta1/params.proto +++ b/proto/OmniFlix/marketplace/v1beta1/params.proto @@ -4,7 +4,7 @@ package OmniFlix.marketplace.v1beta1; import "gogoproto/gogo.proto"; import "google/protobuf/duration.proto"; -option go_package = "github.com/OmniFlix/omniflixhub/x/marketplace/types"; +option go_package = "github.com/OmniFlix/omniflixhub/v2/x/marketplace/types"; option (gogoproto.goproto_getters_all) = false; diff --git a/proto/omniflix/marketplace/v1beta1/query.proto b/proto/OmniFlix/marketplace/v1beta1/query.proto similarity index 95% rename from proto/omniflix/marketplace/v1beta1/query.proto rename to proto/OmniFlix/marketplace/v1beta1/query.proto index 7d45c347..4d6dc069 100644 --- a/proto/omniflix/marketplace/v1beta1/query.proto +++ b/proto/OmniFlix/marketplace/v1beta1/query.proto @@ -3,12 +3,12 @@ package OmniFlix.marketplace.v1beta1; import "cosmos/base/query/v1beta1/pagination.proto"; import "google/api/annotations.proto"; -import "omniflix/marketplace/v1beta1/listing.proto"; -import "omniflix/marketplace/v1beta1/params.proto"; -import "omniflix/marketplace/v1beta1/auction.proto"; +import "OmniFlix/marketplace/v1beta1/listing.proto"; +import "OmniFlix/marketplace/v1beta1/params.proto"; +import "OmniFlix/marketplace/v1beta1/auction.proto"; import "gogoproto/gogo.proto"; -option go_package = "github.com/OmniFlix/omniflixhub/x/marketplace/types"; +option go_package = "github.com/OmniFlix/omniflixhub/v2/x/marketplace/types"; service Query { // Params queries params of the marketplace module. diff --git a/proto/omniflix/marketplace/v1beta1/tx.proto b/proto/OmniFlix/marketplace/v1beta1/tx.proto similarity index 75% rename from proto/omniflix/marketplace/v1beta1/tx.proto rename to proto/OmniFlix/marketplace/v1beta1/tx.proto index fb18a8c1..2053a52b 100644 --- a/proto/omniflix/marketplace/v1beta1/tx.proto +++ b/proto/OmniFlix/marketplace/v1beta1/tx.proto @@ -1,14 +1,17 @@ syntax = "proto3"; package OmniFlix.marketplace.v1beta1; +import "cosmos/msg/v1/msg.proto"; import "cosmos/base/v1beta1/coin.proto"; -import "omniflix/marketplace/v1beta1/listing.proto"; -import "omniflix/marketplace/v1beta1/auction.proto"; +import "cosmos_proto/cosmos.proto"; +import "OmniFlix/marketplace/v1beta1/listing.proto"; +import "OmniFlix/marketplace/v1beta1/auction.proto"; +import "OmniFlix/marketplace/v1beta1/params.proto"; import "gogoproto/gogo.proto"; import "google/protobuf/duration.proto"; import "google/protobuf/timestamp.proto"; -option go_package = "github.com/OmniFlix/omniflixhub/x/marketplace/types"; +option go_package = "github.com/OmniFlix/omniflixhub/v2/x/marketplace/types"; option (gogoproto.goproto_getters_all) = false; service Msg { @@ -27,6 +30,12 @@ service Msg { rpc PlaceBid(MsgPlaceBid) returns (MsgPlaceBidResponse); + // UpdateParams defines a governance operation for updating the x/marketplace module + // parameters. The authority is hard-coded to the x/marketplace module account. + // + // Since: cosmos-sdk 0.47 + rpc UpdateParams(MsgUpdateParams) returns (MsgUpdateParamsResponse); + } @@ -124,4 +133,25 @@ message MsgPlaceBid { string bidder = 3; } -message MsgPlaceBidResponse {} \ No newline at end of file +message MsgPlaceBidResponse {} + +// MsgUpdateParams is the Msg/UpdateParams request type. +// +// Since: cosmos-sdk 0.47 +message MsgUpdateParams { + option (cosmos.msg.v1.signer) = "authority"; + + // authority is the address of the governance account. + string authority = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + + // params defines the x/marketplace parameters to update. + // + // NOTE: All parameters must be supplied. + Params params = 2 [(gogoproto.nullable) = false]; +} + +// MsgUpdateParamsResponse defines the response structure for executing a +// MsgUpdateParams message. +// +// Since: cosmos-sdk 0.47 +message MsgUpdateParamsResponse {} \ No newline at end of file diff --git a/proto/buf.gen.gogo.yaml b/proto/buf.gen.gogo.yaml new file mode 100644 index 00000000..855ea251 --- /dev/null +++ b/proto/buf.gen.gogo.yaml @@ -0,0 +1,8 @@ +version: v1 +plugins: + - name: gocosmos + out: .. + opt: plugins=grpc,Mgoogle/protobuf/any.proto=github.com/cosmos/cosmos-sdk/codec/types + - name: grpc-gateway + out: .. + opt: logtostderr=true,allow_colon_final_segments=true \ No newline at end of file diff --git a/proto/buf.lock b/proto/buf.lock new file mode 100644 index 00000000..9d25b179 --- /dev/null +++ b/proto/buf.lock @@ -0,0 +1,23 @@ +# Generated by buf. DO NOT EDIT. +version: v1 +deps: + - remote: buf.build + owner: cosmos + repository: cosmos-proto + commit: 1935555c206d4afb9e94615dfd0fad31 + - remote: buf.build + owner: cosmos + repository: cosmos-sdk + commit: 954f7b05f38440fc8250134b15adec47 + - remote: buf.build + owner: cosmos + repository: gogo-proto + commit: 34d970b699f84aa382f3c29773a60836 + - remote: buf.build + owner: cosmos + repository: ics23 + commit: 55085f7c710a45f58fa09947208eb70b + - remote: buf.build + owner: googleapis + repository: googleapis + commit: 8d7204855ec14631a499bd7393ce1970 \ No newline at end of file diff --git a/proto/buf.yaml b/proto/buf.yaml new file mode 100644 index 00000000..320fa078 --- /dev/null +++ b/proto/buf.yaml @@ -0,0 +1,24 @@ +version: v1 +name: buf.build/OmniFlix/omniflixhub +deps: + - buf.build/cosmos/gogo-proto:a14993478f40695898ed8a86931094b6656e8a5d + - buf.build/cosmos/cosmos-sdk:v0.47.0 + - buf.build/cosmos/cosmos-proto:1935555c206d4afb9e94615dfd0fad31 + - buf.build/googleapis/googleapis:8d7204855ec14631a499bd7393ce1970 + - buf.build/cosmos/ics23:b1abd8678aab07165efd453c96796a179eb3131f +breaking: + use: + - FILE +lint: + use: + - DEFAULT + - COMMENTS + - FILE_LOWER_SNAKE_CASE + except: + - UNARY_RPC + - COMMENT_FIELD + - SERVICE_SUFFIX + - PACKAGE_VERSION_SUFFIX + - RPC_REQUEST_STANDARD_NAME + ignore: + - tendermint \ No newline at end of file diff --git a/proto/omniflix/alloc/v1beta1/tx.proto b/proto/omniflix/alloc/v1beta1/tx.proto deleted file mode 100644 index e3f17ff6..00000000 --- a/proto/omniflix/alloc/v1beta1/tx.proto +++ /dev/null @@ -1,12 +0,0 @@ -syntax = "proto3"; -package omniflix.alloc.v1beta1; - - - - -option go_package = "github.com/OmniFlix/omniflixhub/x/alloc/types"; - -// Msg defines the alloc Msg service. -service Msg { - -} \ No newline at end of file diff --git a/scripts/protoc_swagger_openapi_gen.sh b/scripts/protoc_swagger_openapi_gen.sh index 8e9fa595..23f44541 100644 --- a/scripts/protoc_swagger_openapi_gen.sh +++ b/scripts/protoc_swagger_openapi_gen.sh @@ -12,7 +12,7 @@ mkdir -p ./tmp-swagger-gen # Get the paths used repos from go/pkg/mod cosmos_sdk_dir=$(go list -f '{{ .Dir }}' -m github.com/cosmos/cosmos-sdk) -ibc_go=$(go list -f '{{ .Dir }}' -m github.com/cosmos/ibc-go/v4) +ibc_go=$(go list -f '{{ .Dir }}' -m github.com/cosmos/ibc-go/v7) onft=$(go list -f '{{ .Dir }}' -m github.com/OmniFlix/onft) marketplace=$(go list -f '{{ .Dir }}' -m github.com/OmniFlix/marketplace) streampay=$(go list -f '{{ .Dir }}' -m github.com/OmniFlix/streampay) diff --git a/scripts/protocgen.sh b/scripts/protocgen.sh index bd8af96b..061c01b1 100644 --- a/scripts/protocgen.sh +++ b/scripts/protocgen.sh @@ -2,30 +2,9 @@ set -eo pipefail -# get protoc executions -#go get github.com/regen-network/cosmos-proto/protoc-gen-gocosmos 2>/dev/null -# get cosmos sdk from github - -# Get the path of the cosmos-sdk repo from go/pkg/mod - # cosmos_sdk_dir=$(go list -f '{{ .Dir }}' -m github.com/cosmos/cosmos-sdk) -# echo $cosmos_sdk_dir; -proto_dirs=$(find ./proto -path -prune -o -name '*.proto' -print0 | xargs -0 -n1 dirname | sort | uniq) -for dir in $proto_dirs; do - protoc \ - -I "proto" \ - -I "third_party/proto" \ - --gocosmos_out=plugins=interfacetype+grpc,\ -Mgoogle/protobuf/any.proto=github.com/cosmos/cosmos-sdk/codec/types:. \ - $(find "${dir}" -maxdepth 1 -name '*.proto') - - # command to generate gRPC gateway (*.pb.gw.go in respective modules) files - protoc \ - -I "proto" \ - -I "third_party/proto" \ - --grpc-gateway_out=logtostderr=true:. \ - $(find "${dir}" -maxdepth 1 -name '*.proto') -done +echo "Generating gogo proto code" +(cd proto; buf generate --template buf.gen.gogo.yaml) # move proto files to the right places -cp -r github.com/OmniFlix/omniflixhub/* ./ +cp -r github.com/OmniFlix/omniflixhub/v2/* ./ rm -rf github.com diff --git a/testutil/network/network.go b/testutil/network/network.go deleted file mode 100644 index e99fa59b..00000000 --- a/testutil/network/network.go +++ /dev/null @@ -1,79 +0,0 @@ -package network - -import ( - "fmt" - "testing" - "time" - - "github.com/cosmos/cosmos-sdk/baseapp" - "github.com/cosmos/cosmos-sdk/crypto/hd" - "github.com/cosmos/cosmos-sdk/crypto/keyring" - servertypes "github.com/cosmos/cosmos-sdk/server/types" - "github.com/cosmos/cosmos-sdk/simapp" - storetypes "github.com/cosmos/cosmos-sdk/store/types" - "github.com/cosmos/cosmos-sdk/testutil/network" - sdk "github.com/cosmos/cosmos-sdk/types" - authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" - tmrand "github.com/tendermint/tendermint/libs/rand" - tmdb "github.com/tendermint/tm-db" - - "github.com/OmniFlix/omniflixhub/app" -) - -type ( - Network = network.Network - Config = network.Config -) - -// New creates instance with fully configured cosmos network. -// Accepts optional config, that will be used in place of the DefaultConfig() if provided. -func New(t *testing.T, configs ...network.Config) *network.Network { - t.Helper() - if len(configs) > 1 { - panic("at most one config should be provided") - } - var cfg network.Config - if len(configs) == 0 { - cfg = DefaultConfig() - } else { - cfg = configs[0] - } - net := network.New(t, cfg) - t.Cleanup(net.Cleanup) - return net -} - -// DefaultConfig will initialize config for the network with custom application, -// genesis and single validator. All other parameters are inherited from cosmos-sdk/testutil/network.DefaultConfig -func DefaultConfig() network.Config { - encoding := app.MakeEncodingConfig() - return network.Config{ - Codec: encoding.Marshaler, - TxConfig: encoding.TxConfig, - LegacyAmino: encoding.Amino, - InterfaceRegistry: encoding.InterfaceRegistry, - AccountRetriever: authtypes.AccountRetriever{}, - AppConstructor: func(val network.Validator) servertypes.Application { - return app.NewOmniFlixApp( - val.Ctx.Logger, tmdb.NewMemDB(), nil, true, map[int64]bool{}, val.Ctx.Config.RootDir, 0, - encoding, - simapp.EmptyAppOptions{}, - baseapp.SetPruning(storetypes.NewPruningOptionsFromString(val.AppConfig.Pruning)), - baseapp.SetMinGasPrices(val.AppConfig.MinGasPrices), - ) - }, - GenesisState: app.ModuleBasics.DefaultGenesis(encoding.Marshaler), - TimeoutCommit: 2 * time.Second, - ChainID: "chain-" + tmrand.NewRand().Str(6), - NumValidators: 1, - BondDenom: sdk.DefaultBondDenom, - MinGasPrices: fmt.Sprintf("0.000006%s", sdk.DefaultBondDenom), - AccountTokens: sdk.TokensFromConsensusPower(1000, sdk.NewInt(1)), - StakingTokens: sdk.TokensFromConsensusPower(500, sdk.NewInt(1)), - BondedTokens: sdk.TokensFromConsensusPower(100, sdk.NewInt(1)), - PruningStrategy: storetypes.PruningOptionNothing, - CleanupDir: true, - SigningAlgo: string(hd.Secp256k1Type), - KeyringOptions: []keyring.Option{}, - } -} diff --git a/testutil/simapp/simapp.go b/testutil/simapp/simapp.go deleted file mode 100644 index ca3733fa..00000000 --- a/testutil/simapp/simapp.go +++ /dev/null @@ -1,53 +0,0 @@ -package simapp - -import ( - "encoding/json" - "time" - - "github.com/cosmos/cosmos-sdk/simapp" - abci "github.com/tendermint/tendermint/abci/types" - "github.com/tendermint/tendermint/libs/log" - tmproto "github.com/tendermint/tendermint/proto/tendermint/types" - tmtypes "github.com/tendermint/tendermint/types" - tmdb "github.com/tendermint/tm-db" - - "github.com/OmniFlix/omniflixhub/app" -) - -// New creates application instance with in-memory database and disabled logging. -func New(dir string) *app.OmniFlixApp { - db := tmdb.NewMemDB() - logger := log.NewNopLogger() - - encoding := app.MakeEncodingConfig() - - a := app.NewOmniFlixApp(logger, db, nil, true, map[int64]bool{}, dir, 0, encoding, - simapp.EmptyAppOptions{}) - stateBytes, err := json.MarshalIndent(app.ModuleBasics.DefaultGenesis(encoding.Marshaler), "", " ") - if err != nil { - panic(err) - } - // InitChain updates deliverState which is required when app.NewContext is called - a.InitChain(abci.RequestInitChain{ - ConsensusParams: defaultConsensusParams, - AppStateBytes: stateBytes, - }) - return a -} - -var defaultConsensusParams = &abci.ConsensusParams{ - Block: &abci.BlockParams{ - MaxBytes: 200000, - MaxGas: 2000000, - }, - Evidence: &tmproto.EvidenceParams{ - MaxAgeNumBlocks: 302400, - MaxAgeDuration: 504 * time.Hour, // 3 weeks is the max duration - MaxBytes: 10000, - }, - Validator: &tmproto.ValidatorParams{ - PubKeyTypes: []string{ - tmtypes.ABCIPubKeyTypeEd25519, - }, - }, -} diff --git a/third_party/proto/confio/proofs.proto b/third_party/proto/confio/proofs.proto deleted file mode 100644 index da43503e..00000000 --- a/third_party/proto/confio/proofs.proto +++ /dev/null @@ -1,234 +0,0 @@ -syntax = "proto3"; - -package ics23; -option go_package = "github.com/confio/ics23/go"; - -enum HashOp { - // NO_HASH is the default if no data passed. Note this is an illegal argument some places. - NO_HASH = 0; - SHA256 = 1; - SHA512 = 2; - KECCAK = 3; - RIPEMD160 = 4; - BITCOIN = 5; // ripemd160(sha256(x)) -} - -/** -LengthOp defines how to process the key and value of the LeafOp -to include length information. After encoding the length with the given -algorithm, the length will be prepended to the key and value bytes. -(Each one with it's own encoded length) -*/ -enum LengthOp { - // NO_PREFIX don't include any length info - NO_PREFIX = 0; - // VAR_PROTO uses protobuf (and go-amino) varint encoding of the length - VAR_PROTO = 1; - // VAR_RLP uses rlp int encoding of the length - VAR_RLP = 2; - // FIXED32_BIG uses big-endian encoding of the length as a 32 bit integer - FIXED32_BIG = 3; - // FIXED32_LITTLE uses little-endian encoding of the length as a 32 bit integer - FIXED32_LITTLE = 4; - // FIXED64_BIG uses big-endian encoding of the length as a 64 bit integer - FIXED64_BIG = 5; - // FIXED64_LITTLE uses little-endian encoding of the length as a 64 bit integer - FIXED64_LITTLE = 6; - // REQUIRE_32_BYTES is like NONE, but will fail if the input is not exactly 32 bytes (sha256 output) - REQUIRE_32_BYTES = 7; - // REQUIRE_64_BYTES is like NONE, but will fail if the input is not exactly 64 bytes (sha512 output) - REQUIRE_64_BYTES = 8; -} - -/** -ExistenceProof takes a key and a value and a set of steps to perform on it. -The result of peforming all these steps will provide a "root hash", which can -be compared to the value in a header. - -Since it is computationally infeasible to produce a hash collission for any of the used -cryptographic hash functions, if someone can provide a series of operations to transform -a given key and value into a root hash that matches some trusted root, these key and values -must be in the referenced merkle tree. - -The only possible issue is maliablity in LeafOp, such as providing extra prefix data, -which should be controlled by a spec. Eg. with lengthOp as NONE, - prefix = FOO, key = BAR, value = CHOICE -and - prefix = F, key = OOBAR, value = CHOICE -would produce the same value. - -With LengthOp this is tricker but not impossible. Which is why the "leafPrefixEqual" field -in the ProofSpec is valuable to prevent this mutability. And why all trees should -length-prefix the data before hashing it. -*/ -message ExistenceProof { - bytes key = 1; - bytes value = 2; - LeafOp leaf = 3; - repeated InnerOp path = 4; -} - -/* -NonExistenceProof takes a proof of two neighbors, one left of the desired key, -one right of the desired key. If both proofs are valid AND they are neighbors, -then there is no valid proof for the given key. -*/ -message NonExistenceProof { - bytes key = 1; // TODO: remove this as unnecessary??? we prove a range - ExistenceProof left = 2; - ExistenceProof right = 3; -} - -/* -CommitmentProof is either an ExistenceProof or a NonExistenceProof, or a Batch of such messages -*/ -message CommitmentProof { - oneof proof { - ExistenceProof exist = 1; - NonExistenceProof nonexist = 2; - BatchProof batch = 3; - CompressedBatchProof compressed = 4; - } -} - -/** -LeafOp represents the raw key-value data we wish to prove, and -must be flexible to represent the internal transformation from -the original key-value pairs into the basis hash, for many existing -merkle trees. - -key and value are passed in. So that the signature of this operation is: - leafOp(key, value) -> output - -To process this, first prehash the keys and values if needed (ANY means no hash in this case): - hkey = prehashKey(key) - hvalue = prehashValue(value) - -Then combine the bytes, and hash it - output = hash(prefix || length(hkey) || hkey || length(hvalue) || hvalue) -*/ -message LeafOp { - HashOp hash = 1; - HashOp prehash_key = 2; - HashOp prehash_value = 3; - LengthOp length = 4; - // prefix is a fixed bytes that may optionally be included at the beginning to differentiate - // a leaf node from an inner node. - bytes prefix = 5; -} - -/** -InnerOp represents a merkle-proof step that is not a leaf. -It represents concatenating two children and hashing them to provide the next result. - -The result of the previous step is passed in, so the signature of this op is: - innerOp(child) -> output - -The result of applying InnerOp should be: - output = op.hash(op.prefix || child || op.suffix) - - where the || operator is concatenation of binary data, -and child is the result of hashing all the tree below this step. - -Any special data, like prepending child with the length, or prepending the entire operation with -some value to differentiate from leaf nodes, should be included in prefix and suffix. -If either of prefix or suffix is empty, we just treat it as an empty string -*/ -message InnerOp { - HashOp hash = 1; - bytes prefix = 2; - bytes suffix = 3; -} - - -/** -ProofSpec defines what the expected parameters are for a given proof type. -This can be stored in the client and used to validate any incoming proofs. - - verify(ProofSpec, Proof) -> Proof | Error - -As demonstrated in tests, if we don't fix the algorithm used to calculate the -LeafHash for a given tree, there are many possible key-value pairs that can -generate a given hash (by interpretting the preimage differently). -We need this for proper security, requires client knows a priori what -tree format server uses. But not in code, rather a configuration object. -*/ -message ProofSpec { - // any field in the ExistenceProof must be the same as in this spec. - // except Prefix, which is just the first bytes of prefix (spec can be longer) - LeafOp leaf_spec = 1; - InnerSpec inner_spec = 2; - // max_depth (if > 0) is the maximum number of InnerOps allowed (mainly for fixed-depth tries) - int32 max_depth = 3; - // min_depth (if > 0) is the minimum number of InnerOps allowed (mainly for fixed-depth tries) - int32 min_depth = 4; -} - -/* -InnerSpec contains all store-specific structure info to determine if two proofs from a -given store are neighbors. - -This enables: - - isLeftMost(spec: InnerSpec, op: InnerOp) - isRightMost(spec: InnerSpec, op: InnerOp) - isLeftNeighbor(spec: InnerSpec, left: InnerOp, right: InnerOp) -*/ -message InnerSpec { - // Child order is the ordering of the children node, must count from 0 - // iavl tree is [0, 1] (left then right) - // merk is [0, 2, 1] (left, right, here) - repeated int32 child_order = 1; - int32 child_size = 2; - int32 min_prefix_length = 3; - int32 max_prefix_length = 4; - // empty child is the prehash image that is used when one child is nil (eg. 20 bytes of 0) - bytes empty_child = 5; - // hash is the algorithm that must be used for each InnerOp - HashOp hash = 6; -} - -/* -BatchProof is a group of multiple proof types than can be compressed -*/ -message BatchProof { - repeated BatchEntry entries = 1; -} - -// Use BatchEntry not CommitmentProof, to avoid recursion -message BatchEntry { - oneof proof { - ExistenceProof exist = 1; - NonExistenceProof nonexist = 2; - } -} - - -/****** all items here are compressed forms *******/ - -message CompressedBatchProof { - repeated CompressedBatchEntry entries = 1; - repeated InnerOp lookup_inners = 2; -} - -// Use BatchEntry not CommitmentProof, to avoid recursion -message CompressedBatchEntry { - oneof proof { - CompressedExistenceProof exist = 1; - CompressedNonExistenceProof nonexist = 2; - } -} - -message CompressedExistenceProof { - bytes key = 1; - bytes value = 2; - LeafOp leaf = 3; - // these are indexes into the lookup_inners table in CompressedBatchProof - repeated int32 path = 4; -} - -message CompressedNonExistenceProof { - bytes key = 1; // TODO: remove this as unnecessary??? we prove a range - CompressedExistenceProof left = 2; - CompressedExistenceProof right = 3; -} diff --git a/third_party/proto/cosmos/base/query/v1beta1/pagination.proto b/third_party/proto/cosmos/base/query/v1beta1/pagination.proto deleted file mode 100644 index b46c0516..00000000 --- a/third_party/proto/cosmos/base/query/v1beta1/pagination.proto +++ /dev/null @@ -1,49 +0,0 @@ -syntax = "proto3"; -package cosmos.base.query.v1beta1; - -option go_package = "github.com/cosmos/cosmos-sdk/types/query"; - -// PageRequest is to be embedded in gRPC request messages for efficient -// pagination. Ex: -// -// message SomeRequest { -// Foo some_parameter = 1; -// PageRequest page = 2; -// } -message PageRequest { - // key is a value returned in PageResponse.next_key to begin - // querying the next page most efficiently. Only one of offset or key - // should be set. - bytes key = 1; - - // offset is a numeric offset that can be used when key is unavailable. - // It is less efficient than using key. Only one of offset or key should - // be set. - uint64 offset = 2; - - // limit is the total number of results to be returned in the result page. - // If left empty it will default to a value to be set by each app. - uint64 limit = 3; - - // count_total is set to true to indicate that the result set should include - // a count of the total number of items available for pagination in UIs. count_total - // is only respected when offset is used. It is ignored when key is set. - bool count_total = 4; -} - -// PageResponse is to be embedded in gRPC response messages where the corresponding -// request message has used PageRequest -// -// message SomeResponse { -// repeated Bar results = 1; -// PageResponse page = 2; -// } -message PageResponse { - // next_key is the key to be passed to PageRequest.key to - // query the next page most efficiently - bytes next_key = 1; - - // total is total number of results available if PageRequest.count_total - // was set, its value is undefined otherwise - uint64 total = 2; -} diff --git a/third_party/proto/cosmos/base/v1beta1/coin.proto b/third_party/proto/cosmos/base/v1beta1/coin.proto deleted file mode 100644 index fab75284..00000000 --- a/third_party/proto/cosmos/base/v1beta1/coin.proto +++ /dev/null @@ -1,40 +0,0 @@ -syntax = "proto3"; -package cosmos.base.v1beta1; - -import "gogoproto/gogo.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/types"; -option (gogoproto.goproto_stringer_all) = false; -option (gogoproto.stringer_all) = false; - -// Coin defines a token with a denomination and an amount. -// -// NOTE: The amount field is an Int which implements the custom method -// signatures required by gogoproto. -message Coin { - option (gogoproto.equal) = true; - - string denom = 1; - string amount = 2 [(gogoproto.customtype) = "Int", (gogoproto.nullable) = false]; -} - -// DecCoin defines a token with a denomination and a decimal amount. -// -// NOTE: The amount field is an Dec which implements the custom method -// signatures required by gogoproto. -message DecCoin { - option (gogoproto.equal) = true; - - string denom = 1; - string amount = 2 [(gogoproto.customtype) = "Dec", (gogoproto.nullable) = false]; -} - -// IntProto defines a Protobuf wrapper around an Int object. -message IntProto { - string int = 1 [(gogoproto.customtype) = "Int", (gogoproto.nullable) = false]; -} - -// DecProto defines a Protobuf wrapper around a Dec object. -message DecProto { - string dec = 1 [(gogoproto.customtype) = "Dec", (gogoproto.nullable) = false]; -} diff --git a/third_party/proto/cosmos_proto/coin.proto b/third_party/proto/cosmos_proto/coin.proto deleted file mode 100644 index fab75284..00000000 --- a/third_party/proto/cosmos_proto/coin.proto +++ /dev/null @@ -1,40 +0,0 @@ -syntax = "proto3"; -package cosmos.base.v1beta1; - -import "gogoproto/gogo.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/types"; -option (gogoproto.goproto_stringer_all) = false; -option (gogoproto.stringer_all) = false; - -// Coin defines a token with a denomination and an amount. -// -// NOTE: The amount field is an Int which implements the custom method -// signatures required by gogoproto. -message Coin { - option (gogoproto.equal) = true; - - string denom = 1; - string amount = 2 [(gogoproto.customtype) = "Int", (gogoproto.nullable) = false]; -} - -// DecCoin defines a token with a denomination and a decimal amount. -// -// NOTE: The amount field is an Dec which implements the custom method -// signatures required by gogoproto. -message DecCoin { - option (gogoproto.equal) = true; - - string denom = 1; - string amount = 2 [(gogoproto.customtype) = "Dec", (gogoproto.nullable) = false]; -} - -// IntProto defines a Protobuf wrapper around an Int object. -message IntProto { - string int = 1 [(gogoproto.customtype) = "Int", (gogoproto.nullable) = false]; -} - -// DecProto defines a Protobuf wrapper around a Dec object. -message DecProto { - string dec = 1 [(gogoproto.customtype) = "Dec", (gogoproto.nullable) = false]; -} diff --git a/third_party/proto/cosmos_proto/cosmos.proto b/third_party/proto/cosmos_proto/cosmos.proto deleted file mode 100644 index 167b1707..00000000 --- a/third_party/proto/cosmos_proto/cosmos.proto +++ /dev/null @@ -1,16 +0,0 @@ -syntax = "proto3"; -package cosmos_proto; - -import "google/protobuf/descriptor.proto"; - -option go_package = "github.com/regen-network/cosmos-proto"; - -extend google.protobuf.MessageOptions { - string interface_type = 93001; - - string implements_interface = 93002; -} - -extend google.protobuf.FieldOptions { - string accepts_interface = 93001; -} diff --git a/third_party/proto/cosmos_proto/pagination.proto b/third_party/proto/cosmos_proto/pagination.proto deleted file mode 100644 index cd3a1f27..00000000 --- a/third_party/proto/cosmos_proto/pagination.proto +++ /dev/null @@ -1,49 +0,0 @@ -syntax = "proto3"; -package cosmos.query; - -option go_package = "github.com/cosmos/cosmos-sdk/types/query"; - -// PageRequest is to be embedded in gRPC request messages for efficient -// pagination. Ex: -// -// message SomeRequest { -// Foo some_parameter = 1; -// PageRequest page = 2; -// } -message PageRequest { - // key is a value returned in PageResponse.next_key to begin - // querying the next page most efficiently. Only one of offset or key - // should be set. - bytes key = 1; - - // offset is a numeric offset that can be used when key is unavailable. - // It is less efficient than using key. Only one of offset or key should - // be set. - uint64 offset = 2; - - // limit is the total number of results to be returned in the result page. - // If left empty it will default to a value to be set by each app. - uint64 limit = 3; - - // count_total is set to true to indicate that the result set should include - // a count of the total number of items available for pagination in UIs. count_total - // is only respected when offset is used. It is ignored when key is set. - bool count_total = 4; -} - -// PageResponse is to be embedded in gRPC response messages where the corresponding -// request message has used PageRequest -// -// message SomeResponse { -// repeated Bar results = 1; -// PageResponse page = 2; -// } -message PageResponse { - // next_key is the key to be passed to PageRequest.key to - // query the next page most efficiently - bytes next_key = 1; - - // total is total number of results available if PageRequest.count_total - // was set, its value is undefined otherwise - uint64 total = 2; -} diff --git a/third_party/proto/gogoproto/gogo.proto b/third_party/proto/gogoproto/gogo.proto deleted file mode 100644 index 49e78f99..00000000 --- a/third_party/proto/gogoproto/gogo.proto +++ /dev/null @@ -1,145 +0,0 @@ -// Protocol Buffers for Go with Gadgets -// -// Copyright (c) 2013, The GoGo Authors. All rights reserved. -// http://github.com/gogo/protobuf -// -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions are -// met: -// -// * Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// * Redistributions in binary form must reproduce the above -// copyright notice, this list of conditions and the following disclaimer -// in the documentation and/or other materials provided with the -// distribution. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -syntax = "proto2"; -package gogoproto; - -import "google/protobuf/descriptor.proto"; - -option java_package = "com.google.protobuf"; -option java_outer_classname = "GoGoProtos"; -option go_package = "github.com/gogo/protobuf/gogoproto"; - -extend google.protobuf.EnumOptions { - optional bool goproto_enum_prefix = 62001; - optional bool goproto_enum_stringer = 62021; - optional bool enum_stringer = 62022; - optional string enum_customname = 62023; - optional bool enumdecl = 62024; -} - -extend google.protobuf.EnumValueOptions { - optional string enumvalue_customname = 66001; -} - -extend google.protobuf.FileOptions { - optional bool goproto_getters_all = 63001; - optional bool goproto_enum_prefix_all = 63002; - optional bool goproto_stringer_all = 63003; - optional bool verbose_equal_all = 63004; - optional bool face_all = 63005; - optional bool gostring_all = 63006; - optional bool populate_all = 63007; - optional bool stringer_all = 63008; - optional bool onlyone_all = 63009; - - optional bool equal_all = 63013; - optional bool description_all = 63014; - optional bool testgen_all = 63015; - optional bool benchgen_all = 63016; - optional bool marshaler_all = 63017; - optional bool unmarshaler_all = 63018; - optional bool stable_marshaler_all = 63019; - - optional bool sizer_all = 63020; - - optional bool goproto_enum_stringer_all = 63021; - optional bool enum_stringer_all = 63022; - - optional bool unsafe_marshaler_all = 63023; - optional bool unsafe_unmarshaler_all = 63024; - - optional bool goproto_extensions_map_all = 63025; - optional bool goproto_unrecognized_all = 63026; - optional bool gogoproto_import = 63027; - optional bool protosizer_all = 63028; - optional bool compare_all = 63029; - optional bool typedecl_all = 63030; - optional bool enumdecl_all = 63031; - - optional bool goproto_registration = 63032; - optional bool messagename_all = 63033; - - optional bool goproto_sizecache_all = 63034; - optional bool goproto_unkeyed_all = 63035; -} - -extend google.protobuf.MessageOptions { - optional bool goproto_getters = 64001; - optional bool goproto_stringer = 64003; - optional bool verbose_equal = 64004; - optional bool face = 64005; - optional bool gostring = 64006; - optional bool populate = 64007; - optional bool stringer = 67008; - optional bool onlyone = 64009; - - optional bool equal = 64013; - optional bool description = 64014; - optional bool testgen = 64015; - optional bool benchgen = 64016; - optional bool marshaler = 64017; - optional bool unmarshaler = 64018; - optional bool stable_marshaler = 64019; - - optional bool sizer = 64020; - - optional bool unsafe_marshaler = 64023; - optional bool unsafe_unmarshaler = 64024; - - optional bool goproto_extensions_map = 64025; - optional bool goproto_unrecognized = 64026; - - optional bool protosizer = 64028; - optional bool compare = 64029; - - optional bool typedecl = 64030; - - optional bool messagename = 64033; - - optional bool goproto_sizecache = 64034; - optional bool goproto_unkeyed = 64035; -} - -extend google.protobuf.FieldOptions { - optional bool nullable = 65001; - optional bool embed = 65002; - optional string customtype = 65003; - optional string customname = 65004; - optional string jsontag = 65005; - optional string moretags = 65006; - optional string casttype = 65007; - optional string castkey = 65008; - optional string castvalue = 65009; - - optional bool stdtime = 65010; - optional bool stdduration = 65011; - optional bool wktpointer = 65012; - - optional string castrepeated = 65013; -} diff --git a/third_party/proto/google/api/annotations.proto b/third_party/proto/google/api/annotations.proto deleted file mode 100644 index 85c361b4..00000000 --- a/third_party/proto/google/api/annotations.proto +++ /dev/null @@ -1,31 +0,0 @@ -// Copyright (c) 2015, Google Inc. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -syntax = "proto3"; - -package google.api; - -import "google/api/http.proto"; -import "google/protobuf/descriptor.proto"; - -option go_package = "google.golang.org/genproto/googleapis/api/annotations;annotations"; -option java_multiple_files = true; -option java_outer_classname = "AnnotationsProto"; -option java_package = "com.google.api"; -option objc_class_prefix = "GAPI"; - -extend google.protobuf.MethodOptions { - // See `HttpRule`. - HttpRule http = 72295728; -} diff --git a/third_party/proto/google/api/http.proto b/third_party/proto/google/api/http.proto deleted file mode 100644 index 2bd3a19b..00000000 --- a/third_party/proto/google/api/http.proto +++ /dev/null @@ -1,318 +0,0 @@ -// Copyright 2018 Google LLC -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -syntax = "proto3"; - -package google.api; - -option cc_enable_arenas = true; -option go_package = "google.golang.org/genproto/googleapis/api/annotations;annotations"; -option java_multiple_files = true; -option java_outer_classname = "HttpProto"; -option java_package = "com.google.api"; -option objc_class_prefix = "GAPI"; - - -// Defines the HTTP configuration for an API service. It contains a list of -// [HttpRule][google.api.HttpRule], each specifying the mapping of an RPC method -// to one or more HTTP REST API methods. -message Http { - // A list of HTTP configuration rules that apply to individual API methods. - // - // **NOTE:** All service configuration rules follow "last one wins" order. - repeated HttpRule rules = 1; - - // When set to true, URL path parmeters will be fully URI-decoded except in - // cases of single segment matches in reserved expansion, where "%2F" will be - // left encoded. - // - // The default behavior is to not decode RFC 6570 reserved characters in multi - // segment matches. - bool fully_decode_reserved_expansion = 2; -} - -// `HttpRule` defines the mapping of an RPC method to one or more HTTP -// REST API methods. The mapping specifies how different portions of the RPC -// request message are mapped to URL path, URL query parameters, and -// HTTP request body. The mapping is typically specified as an -// `google.api.http` annotation on the RPC method, -// see "google/api/annotations.proto" for details. -// -// The mapping consists of a field specifying the path template and -// method kind. The path template can refer to fields in the request -// message, as in the example below which describes a REST GET -// operation on a resource collection of messages: -// -// -// service Messaging { -// rpc GetMessage(GetMessageRequest) returns (Message) { -// option (google.api.http).get = "/v1/messages/{message_id}/{sub.subfield}"; -// } -// } -// message GetMessageRequest { -// message SubMessage { -// string subfield = 1; -// } -// string message_id = 1; // mapped to the URL -// SubMessage sub = 2; // `sub.subfield` is url-mapped -// } -// message Message { -// string text = 1; // content of the resource -// } -// -// The same http annotation can alternatively be expressed inside the -// `GRPC API Configuration` YAML file. -// -// http: -// rules: -// - selector: .Messaging.GetMessage -// get: /v1/messages/{message_id}/{sub.subfield} -// -// This definition enables an automatic, bidrectional mapping of HTTP -// JSON to RPC. Example: -// -// HTTP | RPC -// -----|----- -// `GET /v1/messages/123456/foo` | `GetMessage(message_id: "123456" sub: SubMessage(subfield: "foo"))` -// -// In general, not only fields but also field paths can be referenced -// from a path pattern. Fields mapped to the path pattern cannot be -// repeated and must have a primitive (non-message) type. -// -// Any fields in the request message which are not bound by the path -// pattern automatically become (optional) HTTP query -// parameters. Assume the following definition of the request message: -// -// -// service Messaging { -// rpc GetMessage(GetMessageRequest) returns (Message) { -// option (google.api.http).get = "/v1/messages/{message_id}"; -// } -// } -// message GetMessageRequest { -// message SubMessage { -// string subfield = 1; -// } -// string message_id = 1; // mapped to the URL -// int64 revision = 2; // becomes a parameter -// SubMessage sub = 3; // `sub.subfield` becomes a parameter -// } -// -// -// This enables a HTTP JSON to RPC mapping as below: -// -// HTTP | RPC -// -----|----- -// `GET /v1/messages/123456?revision=2&sub.subfield=foo` | `GetMessage(message_id: "123456" revision: 2 sub: SubMessage(subfield: "foo"))` -// -// Note that fields which are mapped to HTTP parameters must have a -// primitive type or a repeated primitive type. Message types are not -// allowed. In the case of a repeated type, the parameter can be -// repeated in the URL, as in `...?param=A¶m=B`. -// -// For HTTP method kinds which allow a request body, the `body` field -// specifies the mapping. Consider a REST update method on the -// message resource collection: -// -// -// service Messaging { -// rpc UpdateMessage(UpdateMessageRequest) returns (Message) { -// option (google.api.http) = { -// put: "/v1/messages/{message_id}" -// body: "message" -// }; -// } -// } -// message UpdateMessageRequest { -// string message_id = 1; // mapped to the URL -// Message message = 2; // mapped to the body -// } -// -// -// The following HTTP JSON to RPC mapping is enabled, where the -// representation of the JSON in the request body is determined by -// protos JSON encoding: -// -// HTTP | RPC -// -----|----- -// `PUT /v1/messages/123456 { "text": "Hi!" }` | `UpdateMessage(message_id: "123456" message { text: "Hi!" })` -// -// The special name `*` can be used in the body mapping to define that -// every field not bound by the path template should be mapped to the -// request body. This enables the following alternative definition of -// the update method: -// -// service Messaging { -// rpc UpdateMessage(Message) returns (Message) { -// option (google.api.http) = { -// put: "/v1/messages/{message_id}" -// body: "*" -// }; -// } -// } -// message Message { -// string message_id = 1; -// string text = 2; -// } -// -// -// The following HTTP JSON to RPC mapping is enabled: -// -// HTTP | RPC -// -----|----- -// `PUT /v1/messages/123456 { "text": "Hi!" }` | `UpdateMessage(message_id: "123456" text: "Hi!")` -// -// Note that when using `*` in the body mapping, it is not possible to -// have HTTP parameters, as all fields not bound by the path end in -// the body. This makes this option more rarely used in practice of -// defining REST APIs. The common usage of `*` is in custom methods -// which don't use the URL at all for transferring data. -// -// It is possible to define multiple HTTP methods for one RPC by using -// the `additional_bindings` option. Example: -// -// service Messaging { -// rpc GetMessage(GetMessageRequest) returns (Message) { -// option (google.api.http) = { -// get: "/v1/messages/{message_id}" -// additional_bindings { -// get: "/v1/users/{user_id}/messages/{message_id}" -// } -// }; -// } -// } -// message GetMessageRequest { -// string message_id = 1; -// string user_id = 2; -// } -// -// -// This enables the following two alternative HTTP JSON to RPC -// mappings: -// -// HTTP | RPC -// -----|----- -// `GET /v1/messages/123456` | `GetMessage(message_id: "123456")` -// `GET /v1/users/me/messages/123456` | `GetMessage(user_id: "me" message_id: "123456")` -// -// # Rules for HTTP mapping -// -// The rules for mapping HTTP path, query parameters, and body fields -// to the request message are as follows: -// -// 1. The `body` field specifies either `*` or a field path, or is -// omitted. If omitted, it indicates there is no HTTP request body. -// 2. Leaf fields (recursive expansion of nested messages in the -// request) can be classified into three types: -// (a) Matched in the URL template. -// (b) Covered by body (if body is `*`, everything except (a) fields; -// else everything under the body field) -// (c) All other fields. -// 3. URL query parameters found in the HTTP request are mapped to (c) fields. -// 4. Any body sent with an HTTP request can contain only (b) fields. -// -// The syntax of the path template is as follows: -// -// Template = "/" Segments [ Verb ] ; -// Segments = Segment { "/" Segment } ; -// Segment = "*" | "**" | LITERAL | Variable ; -// Variable = "{" FieldPath [ "=" Segments ] "}" ; -// FieldPath = IDENT { "." IDENT } ; -// Verb = ":" LITERAL ; -// -// The syntax `*` matches a single path segment. The syntax `**` matches zero -// or more path segments, which must be the last part of the path except the -// `Verb`. The syntax `LITERAL` matches literal text in the path. -// -// The syntax `Variable` matches part of the URL path as specified by its -// template. A variable template must not contain other variables. If a variable -// matches a single path segment, its template may be omitted, e.g. `{var}` -// is equivalent to `{var=*}`. -// -// If a variable contains exactly one path segment, such as `"{var}"` or -// `"{var=*}"`, when such a variable is expanded into a URL path, all characters -// except `[-_.~0-9a-zA-Z]` are percent-encoded. Such variables show up in the -// Discovery Document as `{var}`. -// -// If a variable contains one or more path segments, such as `"{var=foo/*}"` -// or `"{var=**}"`, when such a variable is expanded into a URL path, all -// characters except `[-_.~/0-9a-zA-Z]` are percent-encoded. Such variables -// show up in the Discovery Document as `{+var}`. -// -// NOTE: While the single segment variable matches the semantics of -// [RFC 6570](https://tools.ietf.org/html/rfc6570) Section 3.2.2 -// Simple String Expansion, the multi segment variable **does not** match -// RFC 6570 Reserved Expansion. The reason is that the Reserved Expansion -// does not expand special characters like `?` and `#`, which would lead -// to invalid URLs. -// -// NOTE: the field paths in variables and in the `body` must not refer to -// repeated fields or map fields. -message HttpRule { - // Selects methods to which this rule applies. - // - // Refer to [selector][google.api.DocumentationRule.selector] for syntax details. - string selector = 1; - - // Determines the URL pattern is matched by this rules. This pattern can be - // used with any of the {get|put|post|delete|patch} methods. A custom method - // can be defined using the 'custom' field. - oneof pattern { - // Used for listing and getting information about resources. - string get = 2; - - // Used for updating a resource. - string put = 3; - - // Used for creating a resource. - string post = 4; - - // Used for deleting a resource. - string delete = 5; - - // Used for updating a resource. - string patch = 6; - - // The custom pattern is used for specifying an HTTP method that is not - // included in the `pattern` field, such as HEAD, or "*" to leave the - // HTTP method unspecified for this rule. The wild-card rule is useful - // for services that provide content to Web (HTML) clients. - CustomHttpPattern custom = 8; - } - - // The name of the request field whose value is mapped to the HTTP body, or - // `*` for mapping all fields not captured by the path pattern to the HTTP - // body. NOTE: the referred field must not be a repeated field and must be - // present at the top-level of request message type. - string body = 7; - - // Optional. The name of the response field whose value is mapped to the HTTP - // body of response. Other response fields are ignored. When - // not set, the response message will be used as HTTP body of response. - string response_body = 12; - - // Additional HTTP bindings for the selector. Nested bindings must - // not contain an `additional_bindings` field themselves (that is, - // the nesting may only be one level deep). - repeated HttpRule additional_bindings = 11; -} - -// A custom pattern is used for defining custom HTTP verb. -message CustomHttpPattern { - // The name of this custom HTTP verb. - string kind = 1; - - // The path matched by this custom verb. - string path = 2; -} diff --git a/third_party/proto/google/api/httpbody.proto b/third_party/proto/google/api/httpbody.proto deleted file mode 100644 index 4428515c..00000000 --- a/third_party/proto/google/api/httpbody.proto +++ /dev/null @@ -1,78 +0,0 @@ -// Copyright 2018 Google LLC. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// - -syntax = "proto3"; - -package google.api; - -import "google/protobuf/any.proto"; - -option cc_enable_arenas = true; -option go_package = "google.golang.org/genproto/googleapis/api/httpbody;httpbody"; -option java_multiple_files = true; -option java_outer_classname = "HttpBodyProto"; -option java_package = "com.google.api"; -option objc_class_prefix = "GAPI"; - -// Message that represents an arbitrary HTTP body. It should only be used for -// payload formats that can't be represented as JSON, such as raw binary or -// an HTML page. -// -// -// This message can be used both in streaming and non-streaming API methods in -// the request as well as the response. -// -// It can be used as a top-level request field, which is convenient if one -// wants to extract parameters from either the URL or HTTP template into the -// request fields and also want access to the raw HTTP body. -// -// Example: -// -// message GetResourceRequest { -// // A unique request id. -// string request_id = 1; -// -// // The raw HTTP body is bound to this field. -// google.api.HttpBody http_body = 2; -// } -// -// service ResourceService { -// rpc GetResource(GetResourceRequest) returns (google.api.HttpBody); -// rpc UpdateResource(google.api.HttpBody) returns -// (google.protobuf.Empty); -// } -// -// Example with streaming methods: -// -// service CaldavService { -// rpc GetCalendar(stream google.api.HttpBody) -// returns (stream google.api.HttpBody); -// rpc UpdateCalendar(stream google.api.HttpBody) -// returns (stream google.api.HttpBody); -// } -// -// Use of this type only changes how the request and response bodies are -// handled, all other features will continue to work unchanged. -message HttpBody { - // The HTTP Content-Type header value specifying the content type of the body. - string content_type = 1; - - // The HTTP request/response body as raw binary. - bytes data = 2; - - // Application specific response metadata. Must be set in the first response - // for streaming APIs. - repeated google.protobuf.Any extensions = 3; -} \ No newline at end of file diff --git a/third_party/proto/google/protobuf/any.proto b/third_party/proto/google/protobuf/any.proto deleted file mode 100644 index 1431810e..00000000 --- a/third_party/proto/google/protobuf/any.proto +++ /dev/null @@ -1,161 +0,0 @@ -// Protocol Buffers - Google's data interchange format -// Copyright 2008 Google Inc. All rights reserved. -// https://developers.google.com/protocol-buffers/ -// -// Redistribution and use in source and binary forms, with or without -// modification, are permitted provided that the following conditions are -// met: -// -// * Redistributions of source code must retain the above copyright -// notice, this list of conditions and the following disclaimer. -// * Redistributions in binary form must reproduce the above -// copyright notice, this list of conditions and the following disclaimer -// in the documentation and/or other materials provided with the -// distribution. -// * Neither the name of Google Inc. nor the names of its -// contributors may be used to endorse or promote products derived from -// this software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -syntax = "proto3"; - -package google.protobuf; - -import "gogoproto/gogo.proto"; - -option csharp_namespace = "Google.Protobuf.WellKnownTypes"; -option go_package = "types"; -option java_package = "com.google.protobuf"; -option java_outer_classname = "AnyProto"; -option java_multiple_files = true; -option objc_class_prefix = "GPB"; - -// `Any` contains an arbitrary serialized protocol buffer message along with a -// URL that describes the type of the serialized message. -// -// Protobuf library provides support to pack/unpack Any values in the form -// of utility functions or additional generated methods of the Any type. -// -// Example 1: Pack and unpack a message in C++. -// -// Foo foo = ...; -// Any any; -// any.PackFrom(foo); -// ... -// if (any.UnpackTo(&foo)) { -// ... -// } -// -// Example 2: Pack and unpack a message in Java. -// -// Foo foo = ...; -// Any any = Any.pack(foo); -// ... -// if (any.is(Foo.class)) { -// foo = any.unpack(Foo.class); -// } -// -// Example 3: Pack and unpack a message in Python. -// -// foo = Foo(...) -// any = Any() -// any.Pack(foo) -// ... -// if any.Is(Foo.DESCRIPTOR): -// any.Unpack(foo) -// ... -// -// Example 4: Pack and unpack a message in Go -// -// foo := &pb.Foo{...} -// any, err := ptypes.MarshalAny(foo) -// ... -// foo := &pb.Foo{} -// if err := ptypes.UnmarshalAny(any, foo); err != nil { -// ... -// } -// -// The pack methods provided by protobuf library will by default use -// 'type.googleapis.com/full.type.name' as the type URL and the unpack -// methods only use the fully qualified type name after the last '/' -// in the type URL, for example "foo.bar.com/x/y.z" will yield type -// name "y.z". -// -// -// JSON -// ==== -// The JSON representation of an `Any` value uses the regular -// representation of the deserialized, embedded message, with an -// additional field `@type` which contains the type URL. Example: -// -// package google.profile; -// message Person { -// string first_name = 1; -// string last_name = 2; -// } -// -// { -// "@type": "type.googleapis.com/google.profile.Person", -// "firstName": , -// "lastName": -// } -// -// If the embedded message type is well-known and has a custom JSON -// representation, that representation will be embedded adding a field -// `value` which holds the custom JSON in addition to the `@type` -// field. Example (for message [google.protobuf.Duration][]): -// -// { -// "@type": "type.googleapis.com/google.protobuf.Duration", -// "value": "1.212s" -// } -// -message Any { - // A URL/resource name that uniquely identifies the type of the serialized - // protocol buffer message. This string must contain at least - // one "/" character. The last segment of the URL's path must represent - // the fully qualified name of the type (as in - // `path/google.protobuf.Duration`). The name should be in a canonical form - // (e.g., leading "." is not accepted). - // - // In practice, teams usually precompile into the binary all types that they - // expect it to use in the context of Any. However, for URLs which use the - // scheme `http`, `https`, or no scheme, one can optionally set up a type - // server that maps type URLs to message definitions as follows: - // - // * If no scheme is provided, `https` is assumed. - // * An HTTP GET on the URL must yield a [google.protobuf.Type][] - // value in binary format, or produce an error. - // * Applications are allowed to cache lookup results based on the - // URL, or have them precompiled into a binary to avoid any - // lookup. Therefore, binary compatibility needs to be preserved - // on changes to types. (Use versioned type names to manage - // breaking changes.) - // - // Note: this functionality is not currently available in the official - // protobuf release, and it is not used for type URLs beginning with - // type.googleapis.com. - // - // Schemes other than `http`, `https` (or the empty scheme) might be - // used with implementation specific semantics. - // - string type_url = 1; - - // Must be a valid serialized protocol buffer of the above specified type. - bytes value = 2; - - option (gogoproto.typedecl) = false; -} - -option (gogoproto.goproto_registration) = false; diff --git a/third_party/proto/tendermint/abci/types.proto b/third_party/proto/tendermint/abci/types.proto deleted file mode 100644 index 2cbcabb2..00000000 --- a/third_party/proto/tendermint/abci/types.proto +++ /dev/null @@ -1,407 +0,0 @@ -syntax = "proto3"; -package tendermint.abci; - -option go_package = "github.com/tendermint/tendermint/abci/types"; - -// For more information on gogo.proto, see: -// https://github.com/gogo/protobuf/blob/master/extensions.md -import "tendermint/crypto/proof.proto"; -import "tendermint/types/types.proto"; -import "tendermint/crypto/keys.proto"; -import "tendermint/types/params.proto"; -import "google/protobuf/timestamp.proto"; -import "gogoproto/gogo.proto"; - -// This file is copied from http://github.com/tendermint/abci -// NOTE: When using custom types, mind the warnings. -// https://github.com/gogo/protobuf/blob/master/custom_types.md#warnings-and-issues - -//---------------------------------------- -// Request types - -message Request { - oneof value { - RequestEcho echo = 1; - RequestFlush flush = 2; - RequestInfo info = 3; - RequestSetOption set_option = 4; - RequestInitChain init_chain = 5; - RequestQuery query = 6; - RequestBeginBlock begin_block = 7; - RequestCheckTx check_tx = 8; - RequestDeliverTx deliver_tx = 9; - RequestEndBlock end_block = 10; - RequestCommit commit = 11; - RequestListSnapshots list_snapshots = 12; - RequestOfferSnapshot offer_snapshot = 13; - RequestLoadSnapshotChunk load_snapshot_chunk = 14; - RequestApplySnapshotChunk apply_snapshot_chunk = 15; - } -} - -message RequestEcho { - string message = 1; -} - -message RequestFlush {} - -message RequestInfo { - string version = 1; - uint64 block_version = 2; - uint64 p2p_version = 3; -} - -// nondeterministic -message RequestSetOption { - string key = 1; - string value = 2; -} - -message RequestInitChain { - google.protobuf.Timestamp time = 1 - [(gogoproto.nullable) = false, (gogoproto.stdtime) = true]; - string chain_id = 2; - ConsensusParams consensus_params = 3; - repeated ValidatorUpdate validators = 4 [(gogoproto.nullable) = false]; - bytes app_state_bytes = 5; - int64 initial_height = 6; -} - -message RequestQuery { - bytes data = 1; - string path = 2; - int64 height = 3; - bool prove = 4; -} - -message RequestBeginBlock { - bytes hash = 1; - tendermint.types.Header header = 2 [(gogoproto.nullable) = false]; - LastCommitInfo last_commit_info = 3 [(gogoproto.nullable) = false]; - repeated Evidence byzantine_validators = 4 [(gogoproto.nullable) = false]; -} - -enum CheckTxType { - NEW = 0 [(gogoproto.enumvalue_customname) = "New"]; - RECHECK = 1 [(gogoproto.enumvalue_customname) = "Recheck"]; -} - -message RequestCheckTx { - bytes tx = 1; - CheckTxType type = 2; -} - -message RequestDeliverTx { - bytes tx = 1; -} - -message RequestEndBlock { - int64 height = 1; -} - -message RequestCommit {} - -// lists available snapshots -message RequestListSnapshots { -} - -// offers a snapshot to the application -message RequestOfferSnapshot { - Snapshot snapshot = 1; // snapshot offered by peers - bytes app_hash = 2; // light client-verified app hash for snapshot height -} - -// loads a snapshot chunk -message RequestLoadSnapshotChunk { - uint64 height = 1; - uint32 format = 2; - uint32 chunk = 3; -} - -// Applies a snapshot chunk -message RequestApplySnapshotChunk { - uint32 index = 1; - bytes chunk = 2; - string sender = 3; -} - -//---------------------------------------- -// Response types - -message Response { - oneof value { - ResponseException exception = 1; - ResponseEcho echo = 2; - ResponseFlush flush = 3; - ResponseInfo info = 4; - ResponseSetOption set_option = 5; - ResponseInitChain init_chain = 6; - ResponseQuery query = 7; - ResponseBeginBlock begin_block = 8; - ResponseCheckTx check_tx = 9; - ResponseDeliverTx deliver_tx = 10; - ResponseEndBlock end_block = 11; - ResponseCommit commit = 12; - ResponseListSnapshots list_snapshots = 13; - ResponseOfferSnapshot offer_snapshot = 14; - ResponseLoadSnapshotChunk load_snapshot_chunk = 15; - ResponseApplySnapshotChunk apply_snapshot_chunk = 16; - } -} - -// nondeterministic -message ResponseException { - string error = 1; -} - -message ResponseEcho { - string message = 1; -} - -message ResponseFlush {} - -message ResponseInfo { - string data = 1; - - string version = 2; - uint64 app_version = 3; - - int64 last_block_height = 4; - bytes last_block_app_hash = 5; -} - -// nondeterministic -message ResponseSetOption { - uint32 code = 1; - // bytes data = 2; - string log = 3; - string info = 4; -} - -message ResponseInitChain { - ConsensusParams consensus_params = 1; - repeated ValidatorUpdate validators = 2 [(gogoproto.nullable) = false]; - bytes app_hash = 3; -} - -message ResponseQuery { - uint32 code = 1; - // bytes data = 2; // use "value" instead. - string log = 3; // nondeterministic - string info = 4; // nondeterministic - int64 index = 5; - bytes key = 6; - bytes value = 7; - tendermint.crypto.ProofOps proof_ops = 8; - int64 height = 9; - string codespace = 10; -} - -message ResponseBeginBlock { - repeated Event events = 1 - [(gogoproto.nullable) = false, (gogoproto.jsontag) = "events,omitempty"]; -} - -message ResponseCheckTx { - uint32 code = 1; - bytes data = 2; - string log = 3; // nondeterministic - string info = 4; // nondeterministic - int64 gas_wanted = 5 [json_name = "gas_wanted"]; - int64 gas_used = 6 [json_name = "gas_used"]; - repeated Event events = 7 - [(gogoproto.nullable) = false, (gogoproto.jsontag) = "events,omitempty"]; - string codespace = 8; -} - -message ResponseDeliverTx { - uint32 code = 1; - bytes data = 2; - string log = 3; // nondeterministic - string info = 4; // nondeterministic - int64 gas_wanted = 5 [json_name = "gas_wanted"]; - int64 gas_used = 6 [json_name = "gas_used"]; - repeated Event events = 7 - [(gogoproto.nullable) = false, (gogoproto.jsontag) = "events,omitempty"]; - string codespace = 8; -} - -message ResponseEndBlock { - repeated ValidatorUpdate validator_updates = 1 - [(gogoproto.nullable) = false]; - ConsensusParams consensus_param_updates = 2; - repeated Event events = 3 - [(gogoproto.nullable) = false, (gogoproto.jsontag) = "events,omitempty"]; -} - -message ResponseCommit { - // reserve 1 - bytes data = 2; - int64 retain_height = 3; -} - -message ResponseListSnapshots { - repeated Snapshot snapshots = 1; -} - -message ResponseOfferSnapshot { - Result result = 1; - - enum Result { - UNKNOWN = 0; // Unknown result, abort all snapshot restoration - ACCEPT = 1; // Snapshot accepted, apply chunks - ABORT = 2; // Abort all snapshot restoration - REJECT = 3; // Reject this specific snapshot, try others - REJECT_FORMAT = 4; // Reject all snapshots of this format, try others - REJECT_SENDER = 5; // Reject all snapshots from the sender(s), try others - } -} - -message ResponseLoadSnapshotChunk { - bytes chunk = 1; -} - -message ResponseApplySnapshotChunk { - Result result = 1; - repeated uint32 refetch_chunks = 2; // Chunks to refetch and reapply - repeated string reject_senders = 3; // Chunk senders to reject and ban - - enum Result { - UNKNOWN = 0; // Unknown result, abort all snapshot restoration - ACCEPT = 1; // Chunk successfully accepted - ABORT = 2; // Abort all snapshot restoration - RETRY = 3; // Retry chunk (combine with refetch and reject) - RETRY_SNAPSHOT = 4; // Retry snapshot (combine with refetch and reject) - REJECT_SNAPSHOT = 5; // Reject this snapshot, try others - } -} - -//---------------------------------------- -// Misc. - -// ConsensusParams contains all consensus-relevant parameters -// that can be adjusted by the abci app -message ConsensusParams { - BlockParams block = 1; - tendermint.types.EvidenceParams evidence = 2; - tendermint.types.ValidatorParams validator = 3; - tendermint.types.VersionParams version = 4; -} - -// BlockParams contains limits on the block size. -message BlockParams { - // Note: must be greater than 0 - int64 max_bytes = 1; - // Note: must be greater or equal to -1 - int64 max_gas = 2; -} - -message LastCommitInfo { - int32 round = 1; - repeated VoteInfo votes = 2 [(gogoproto.nullable) = false]; -} - -// Event allows application developers to attach additional information to -// ResponseBeginBlock, ResponseEndBlock, ResponseCheckTx and ResponseDeliverTx. -// Later, transactions may be queried using these events. -message Event { - string type = 1; - repeated EventAttribute attributes = 2 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "attributes,omitempty" - ]; -} - -// EventAttribute is a single key-value pair, associated with an event. -message EventAttribute { - bytes key = 1; - bytes value = 2; - bool index = 3; // nondeterministic -} - -// TxResult contains results of executing the transaction. -// -// One usage is indexing transaction results. -message TxResult { - int64 height = 1; - uint32 index = 2; - bytes tx = 3; - ResponseDeliverTx result = 4 [(gogoproto.nullable) = false]; -} - -//---------------------------------------- -// Blockchain Types - -// Validator -message Validator { - bytes address = 1; // The first 20 bytes of SHA256(public key) - // PubKey pub_key = 2 [(gogoproto.nullable)=false]; - int64 power = 3; // The voting power -} - -// ValidatorUpdate -message ValidatorUpdate { - tendermint.crypto.PublicKey pub_key = 1 [(gogoproto.nullable) = false]; - int64 power = 2; -} - -// VoteInfo -message VoteInfo { - Validator validator = 1 [(gogoproto.nullable) = false]; - bool signed_last_block = 2; -} - -enum EvidenceType { - UNKNOWN = 0; - DUPLICATE_VOTE = 1; - LIGHT_CLIENT_ATTACK = 2; -} - -message Evidence { - EvidenceType type = 1; - // The offending validator - Validator validator = 2 [(gogoproto.nullable) = false]; - // The height when the offense occurred - int64 height = 3; - // The corresponding time where the offense occurred - google.protobuf.Timestamp time = 4 [ - (gogoproto.nullable) = false, - (gogoproto.stdtime) = true - ]; - // Total voting power of the validator set in case the ABCI application does - // not store historical validators. - // https://github.com/tendermint/tendermint/issues/4581 - int64 total_voting_power = 5; -} - -//---------------------------------------- -// State Sync Types - -message Snapshot { - uint64 height = 1; // The height at which the snapshot was taken - uint32 format = 2; // The application-specific snapshot format - uint32 chunks = 3; // Number of chunks in the snapshot - bytes hash = 4; // Arbitrary snapshot hash, equal only if identical - bytes metadata = 5; // Arbitrary application metadata -} - -//---------------------------------------- -// Service Definition - -service ABCIApplication { - rpc Echo(RequestEcho) returns (ResponseEcho); - rpc Flush(RequestFlush) returns (ResponseFlush); - rpc Info(RequestInfo) returns (ResponseInfo); - rpc SetOption(RequestSetOption) returns (ResponseSetOption); - rpc DeliverTx(RequestDeliverTx) returns (ResponseDeliverTx); - rpc CheckTx(RequestCheckTx) returns (ResponseCheckTx); - rpc Query(RequestQuery) returns (ResponseQuery); - rpc Commit(RequestCommit) returns (ResponseCommit); - rpc InitChain(RequestInitChain) returns (ResponseInitChain); - rpc BeginBlock(RequestBeginBlock) returns (ResponseBeginBlock); - rpc EndBlock(RequestEndBlock) returns (ResponseEndBlock); - rpc ListSnapshots(RequestListSnapshots) returns (ResponseListSnapshots); - rpc OfferSnapshot(RequestOfferSnapshot) returns (ResponseOfferSnapshot); - rpc LoadSnapshotChunk(RequestLoadSnapshotChunk) returns (ResponseLoadSnapshotChunk); - rpc ApplySnapshotChunk(RequestApplySnapshotChunk) returns (ResponseApplySnapshotChunk); -} diff --git a/third_party/proto/tendermint/crypto/keys.proto b/third_party/proto/tendermint/crypto/keys.proto deleted file mode 100644 index 16fd7adf..00000000 --- a/third_party/proto/tendermint/crypto/keys.proto +++ /dev/null @@ -1,17 +0,0 @@ -syntax = "proto3"; -package tendermint.crypto; - -option go_package = "github.com/tendermint/tendermint/proto/tendermint/crypto"; - -import "gogoproto/gogo.proto"; - -// PublicKey defines the keys available for use with Tendermint Validators -message PublicKey { - option (gogoproto.compare) = true; - option (gogoproto.equal) = true; - - oneof sum { - bytes ed25519 = 1; - bytes secp256k1 = 2; - } -} diff --git a/third_party/proto/tendermint/crypto/proof.proto b/third_party/proto/tendermint/crypto/proof.proto deleted file mode 100644 index 975df768..00000000 --- a/third_party/proto/tendermint/crypto/proof.proto +++ /dev/null @@ -1,41 +0,0 @@ -syntax = "proto3"; -package tendermint.crypto; - -option go_package = "github.com/tendermint/tendermint/proto/tendermint/crypto"; - -import "gogoproto/gogo.proto"; - -message Proof { - int64 total = 1; - int64 index = 2; - bytes leaf_hash = 3; - repeated bytes aunts = 4; -} - -message ValueOp { - // Encoded in ProofOp.Key. - bytes key = 1; - - // To encode in ProofOp.Data - Proof proof = 2; -} - -message DominoOp { - string key = 1; - string input = 2; - string output = 3; -} - -// ProofOp defines an operation used for calculating Merkle root -// The data could be arbitrary format, providing nessecary data -// for example neighbouring node hash -message ProofOp { - string type = 1; - bytes key = 2; - bytes data = 3; -} - -// ProofOps is Merkle proof defined by the list of ProofOps -message ProofOps { - repeated ProofOp ops = 1 [(gogoproto.nullable) = false]; -} diff --git a/third_party/proto/tendermint/libs/bits/types.proto b/third_party/proto/tendermint/libs/bits/types.proto deleted file mode 100644 index 3111d113..00000000 --- a/third_party/proto/tendermint/libs/bits/types.proto +++ /dev/null @@ -1,9 +0,0 @@ -syntax = "proto3"; -package tendermint.libs.bits; - -option go_package = "github.com/tendermint/tendermint/proto/tendermint/libs/bits"; - -message BitArray { - int64 bits = 1; - repeated uint64 elems = 2; -} diff --git a/third_party/proto/tendermint/p2p/types.proto b/third_party/proto/tendermint/p2p/types.proto deleted file mode 100644 index 0d42ea40..00000000 --- a/third_party/proto/tendermint/p2p/types.proto +++ /dev/null @@ -1,34 +0,0 @@ -syntax = "proto3"; -package tendermint.p2p; - -option go_package = "github.com/tendermint/tendermint/proto/tendermint/p2p"; - -import "gogoproto/gogo.proto"; - -message NetAddress { - string id = 1 [(gogoproto.customname) = "ID"]; - string ip = 2 [(gogoproto.customname) = "IP"]; - uint32 port = 3; -} - -message ProtocolVersion { - uint64 p2p = 1 [(gogoproto.customname) = "P2P"]; - uint64 block = 2; - uint64 app = 3; -} - -message DefaultNodeInfo { - ProtocolVersion protocol_version = 1 [(gogoproto.nullable) = false]; - string default_node_id = 2 [(gogoproto.customname) = "DefaultNodeID"]; - string listen_addr = 3; - string network = 4; - string version = 5; - bytes channels = 6; - string moniker = 7; - DefaultNodeInfoOther other = 8 [(gogoproto.nullable) = false]; -} - -message DefaultNodeInfoOther { - string tx_index = 1; - string rpc_address = 2 [(gogoproto.customname) = "RPCAddress"]; -} diff --git a/third_party/proto/tendermint/types/block.proto b/third_party/proto/tendermint/types/block.proto deleted file mode 100644 index 84e9bb15..00000000 --- a/third_party/proto/tendermint/types/block.proto +++ /dev/null @@ -1,15 +0,0 @@ -syntax = "proto3"; -package tendermint.types; - -option go_package = "github.com/tendermint/tendermint/proto/tendermint/types"; - -import "gogoproto/gogo.proto"; -import "tendermint/types/types.proto"; -import "tendermint/types/evidence.proto"; - -message Block { - Header header = 1 [(gogoproto.nullable) = false]; - Data data = 2 [(gogoproto.nullable) = false]; - tendermint.types.EvidenceList evidence = 3 [(gogoproto.nullable) = false]; - Commit last_commit = 4; -} diff --git a/third_party/proto/tendermint/types/evidence.proto b/third_party/proto/tendermint/types/evidence.proto deleted file mode 100644 index 3b234571..00000000 --- a/third_party/proto/tendermint/types/evidence.proto +++ /dev/null @@ -1,38 +0,0 @@ -syntax = "proto3"; -package tendermint.types; - -option go_package = "github.com/tendermint/tendermint/proto/tendermint/types"; - -import "gogoproto/gogo.proto"; -import "google/protobuf/timestamp.proto"; -import "tendermint/types/types.proto"; -import "tendermint/types/validator.proto"; - -message Evidence { - oneof sum { - DuplicateVoteEvidence duplicate_vote_evidence = 1; - LightClientAttackEvidence light_client_attack_evidence = 2; - } -} - -// DuplicateVoteEvidence contains evidence of a validator signed two conflicting votes. -message DuplicateVoteEvidence { - tendermint.types.Vote vote_a = 1; - tendermint.types.Vote vote_b = 2; - int64 total_voting_power = 3; - int64 validator_power = 4; - google.protobuf.Timestamp timestamp = 5 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true]; -} - -// LightClientAttackEvidence contains evidence of a set of validators attempting to mislead a light client. -message LightClientAttackEvidence { - tendermint.types.LightBlock conflicting_block = 1; - int64 common_height = 2; - repeated tendermint.types.Validator byzantine_validators = 3; - int64 total_voting_power = 4; - google.protobuf.Timestamp timestamp = 5 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true]; -} - -message EvidenceList { - repeated Evidence evidence = 1 [(gogoproto.nullable) = false]; -} diff --git a/third_party/proto/tendermint/types/params.proto b/third_party/proto/tendermint/types/params.proto deleted file mode 100644 index 0de7d846..00000000 --- a/third_party/proto/tendermint/types/params.proto +++ /dev/null @@ -1,80 +0,0 @@ -syntax = "proto3"; -package tendermint.types; - -option go_package = "github.com/tendermint/tendermint/proto/tendermint/types"; - -import "gogoproto/gogo.proto"; -import "google/protobuf/duration.proto"; - -option (gogoproto.equal_all) = true; - -// ConsensusParams contains consensus critical parameters that determine the -// validity of blocks. -message ConsensusParams { - BlockParams block = 1 [(gogoproto.nullable) = false]; - EvidenceParams evidence = 2 [(gogoproto.nullable) = false]; - ValidatorParams validator = 3 [(gogoproto.nullable) = false]; - VersionParams version = 4 [(gogoproto.nullable) = false]; -} - -// BlockParams contains limits on the block size. -message BlockParams { - // Max block size, in bytes. - // Note: must be greater than 0 - int64 max_bytes = 1; - // Max gas per block. - // Note: must be greater or equal to -1 - int64 max_gas = 2; - // Minimum time increment between consecutive blocks (in milliseconds) If the - // block header timestamp is ahead of the system clock, decrease this value. - // - // Not exposed to the application. - int64 time_iota_ms = 3; -} - -// EvidenceParams determine how we handle evidence of malfeasance. -message EvidenceParams { - // Max age of evidence, in blocks. - // - // The basic formula for calculating this is: MaxAgeDuration / {average block - // time}. - int64 max_age_num_blocks = 1; - - // Max age of evidence, in time. - // - // It should correspond with an app's "unbonding period" or other similar - // mechanism for handling [Nothing-At-Stake - // attacks](https://github.com/ethereum/wiki/wiki/Proof-of-Stake-FAQ#what-is-the-nothing-at-stake-problem-and-how-can-it-be-fixed). - google.protobuf.Duration max_age_duration = 2 - [(gogoproto.nullable) = false, (gogoproto.stdduration) = true]; - - // This sets the maximum size of total evidence in bytes that can be committed in a single block. - // and should fall comfortably under the max block bytes. - // Default is 1048576 or 1MB - int64 max_bytes = 3; -} - -// ValidatorParams restrict the public key types validators can use. -// NOTE: uses ABCI pubkey naming, not Amino names. -message ValidatorParams { - option (gogoproto.populate) = true; - option (gogoproto.equal) = true; - - repeated string pub_key_types = 1; -} - -// VersionParams contains the ABCI application version. -message VersionParams { - option (gogoproto.populate) = true; - option (gogoproto.equal) = true; - - uint64 app_version = 1; -} - -// HashedParams is a subset of ConsensusParams. -// -// It is hashed into the Header.ConsensusHash. -message HashedParams { - int64 block_max_bytes = 1; - int64 block_max_gas = 2; -} diff --git a/third_party/proto/tendermint/types/types.proto b/third_party/proto/tendermint/types/types.proto deleted file mode 100644 index 7f7ea74c..00000000 --- a/third_party/proto/tendermint/types/types.proto +++ /dev/null @@ -1,157 +0,0 @@ -syntax = "proto3"; -package tendermint.types; - -option go_package = "github.com/tendermint/tendermint/proto/tendermint/types"; - -import "gogoproto/gogo.proto"; -import "google/protobuf/timestamp.proto"; -import "tendermint/crypto/proof.proto"; -import "tendermint/version/types.proto"; -import "tendermint/types/validator.proto"; - -// BlockIdFlag indicates which BlcokID the signature is for -enum BlockIDFlag { - option (gogoproto.goproto_enum_stringer) = true; - option (gogoproto.goproto_enum_prefix) = false; - - BLOCK_ID_FLAG_UNKNOWN = 0 [(gogoproto.enumvalue_customname) = "BlockIDFlagUnknown"]; - BLOCK_ID_FLAG_ABSENT = 1 [(gogoproto.enumvalue_customname) = "BlockIDFlagAbsent"]; - BLOCK_ID_FLAG_COMMIT = 2 [(gogoproto.enumvalue_customname) = "BlockIDFlagCommit"]; - BLOCK_ID_FLAG_NIL = 3 [(gogoproto.enumvalue_customname) = "BlockIDFlagNil"]; -} - -// SignedMsgType is a type of signed message in the consensus. -enum SignedMsgType { - option (gogoproto.goproto_enum_stringer) = true; - option (gogoproto.goproto_enum_prefix) = false; - - SIGNED_MSG_TYPE_UNKNOWN = 0 [(gogoproto.enumvalue_customname) = "UnknownType"]; - // Votes - SIGNED_MSG_TYPE_PREVOTE = 1 [(gogoproto.enumvalue_customname) = "PrevoteType"]; - SIGNED_MSG_TYPE_PRECOMMIT = 2 [(gogoproto.enumvalue_customname) = "PrecommitType"]; - - // Proposals - SIGNED_MSG_TYPE_PROPOSAL = 32 [(gogoproto.enumvalue_customname) = "ProposalType"]; -} - -// PartsetHeader -message PartSetHeader { - uint32 total = 1; - bytes hash = 2; -} - -message Part { - uint32 index = 1; - bytes bytes = 2; - tendermint.crypto.Proof proof = 3 [(gogoproto.nullable) = false]; -} - -// BlockID -message BlockID { - bytes hash = 1; - PartSetHeader part_set_header = 2 [(gogoproto.nullable) = false]; -} - -// -------------------------------- - -// Header defines the structure of a Tendermint block header. -message Header { - // basic block info - tendermint.version.Consensus version = 1 [(gogoproto.nullable) = false]; - string chain_id = 2 [(gogoproto.customname) = "ChainID"]; - int64 height = 3; - google.protobuf.Timestamp time = 4 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true]; - - // prev block info - BlockID last_block_id = 5 [(gogoproto.nullable) = false]; - - // hashes of block data - bytes last_commit_hash = 6; // commit from validators from the last block - bytes data_hash = 7; // transactions - - // hashes from the app output from the prev block - bytes validators_hash = 8; // validators for the current block - bytes next_validators_hash = 9; // validators for the next block - bytes consensus_hash = 10; // consensus params for current block - bytes app_hash = 11; // state after txs from the previous block - bytes last_results_hash = 12; // root hash of all results from the txs from the previous block - - // consensus info - bytes evidence_hash = 13; // evidence included in the block - bytes proposer_address = 14; // original proposer of the block -} - -// Data contains the set of transactions included in the block -message Data { - // Txs that will be applied by state @ block.Height+1. - // NOTE: not all txs here are valid. We're just agreeing on the order first. - // This means that block.AppHash does not include these txs. - repeated bytes txs = 1; -} - -// Vote represents a prevote, precommit, or commit vote from validators for -// consensus. -message Vote { - SignedMsgType type = 1; - int64 height = 2; - int32 round = 3; - BlockID block_id = 4 - [(gogoproto.nullable) = false, (gogoproto.customname) = "BlockID"]; // zero if vote is nil. - google.protobuf.Timestamp timestamp = 5 - [(gogoproto.nullable) = false, (gogoproto.stdtime) = true]; - bytes validator_address = 6; - int32 validator_index = 7; - bytes signature = 8; -} - -// Commit contains the evidence that a block was committed by a set of validators. -message Commit { - int64 height = 1; - int32 round = 2; - BlockID block_id = 3 [(gogoproto.nullable) = false, (gogoproto.customname) = "BlockID"]; - repeated CommitSig signatures = 4 [(gogoproto.nullable) = false]; -} - -// CommitSig is a part of the Vote included in a Commit. -message CommitSig { - BlockIDFlag block_id_flag = 1; - bytes validator_address = 2; - google.protobuf.Timestamp timestamp = 3 - [(gogoproto.nullable) = false, (gogoproto.stdtime) = true]; - bytes signature = 4; -} - -message Proposal { - SignedMsgType type = 1; - int64 height = 2; - int32 round = 3; - int32 pol_round = 4; - BlockID block_id = 5 [(gogoproto.customname) = "BlockID", (gogoproto.nullable) = false]; - google.protobuf.Timestamp timestamp = 6 - [(gogoproto.nullable) = false, (gogoproto.stdtime) = true]; - bytes signature = 7; -} - -message SignedHeader { - Header header = 1; - Commit commit = 2; -} - -message LightBlock { - SignedHeader signed_header = 1; - tendermint.types.ValidatorSet validator_set = 2; -} - -message BlockMeta { - BlockID block_id = 1 [(gogoproto.customname) = "BlockID", (gogoproto.nullable) = false]; - int64 block_size = 2; - Header header = 3 [(gogoproto.nullable) = false]; - int64 num_txs = 4; -} - -// TxProof represents a Merkle proof of the presence of a transaction in the Merkle tree. -message TxProof { - bytes root_hash = 1; - bytes data = 2; - tendermint.crypto.Proof proof = 3; -} diff --git a/third_party/proto/tendermint/types/validator.proto b/third_party/proto/tendermint/types/validator.proto deleted file mode 100644 index 49860b96..00000000 --- a/third_party/proto/tendermint/types/validator.proto +++ /dev/null @@ -1,25 +0,0 @@ -syntax = "proto3"; -package tendermint.types; - -option go_package = "github.com/tendermint/tendermint/proto/tendermint/types"; - -import "gogoproto/gogo.proto"; -import "tendermint/crypto/keys.proto"; - -message ValidatorSet { - repeated Validator validators = 1; - Validator proposer = 2; - int64 total_voting_power = 3; -} - -message Validator { - bytes address = 1; - tendermint.crypto.PublicKey pub_key = 2 [(gogoproto.nullable) = false]; - int64 voting_power = 3; - int64 proposer_priority = 4; -} - -message SimpleValidator { - tendermint.crypto.PublicKey pub_key = 1; - int64 voting_power = 2; -} diff --git a/third_party/proto/tendermint/version/types.proto b/third_party/proto/tendermint/version/types.proto deleted file mode 100644 index 6061868b..00000000 --- a/third_party/proto/tendermint/version/types.proto +++ /dev/null @@ -1,24 +0,0 @@ -syntax = "proto3"; -package tendermint.version; - -option go_package = "github.com/tendermint/tendermint/proto/tendermint/version"; - -import "gogoproto/gogo.proto"; - -// App includes the protocol and software version for the application. -// This information is included in ResponseInfo. The App.Protocol can be -// updated in ResponseEndBlock. -message App { - uint64 protocol = 1; - string software = 2; -} - -// Consensus captures the consensus rules for processing a block in the blockchain, -// including all blockchain data structures and the rules of the application's -// state transition machine. -message Consensus { - option (gogoproto.equal) = true; - - uint64 block = 1; - uint64 app = 2; -} diff --git a/x/alloc/abci.go b/x/alloc/abci.go index 60edc050..0eea839d 100644 --- a/x/alloc/abci.go +++ b/x/alloc/abci.go @@ -4,8 +4,8 @@ import ( "fmt" "time" - "github.com/OmniFlix/omniflixhub/x/alloc/keeper" - "github.com/OmniFlix/omniflixhub/x/alloc/types" + "github.com/OmniFlix/omniflixhub/v2/x/alloc/keeper" + "github.com/OmniFlix/omniflixhub/v2/x/alloc/types" "github.com/cosmos/cosmos-sdk/telemetry" sdk "github.com/cosmos/cosmos-sdk/types" ) diff --git a/x/alloc/client/cli/query.go b/x/alloc/client/cli/query.go index f3aa872c..efc13132 100644 --- a/x/alloc/client/cli/query.go +++ b/x/alloc/client/cli/query.go @@ -5,7 +5,7 @@ import ( "github.com/cosmos/cosmos-sdk/client/flags" - "github.com/OmniFlix/omniflixhub/x/alloc/types" + "github.com/OmniFlix/omniflixhub/v2/x/alloc/types" "github.com/cosmos/cosmos-sdk/client" "github.com/spf13/cobra" ) diff --git a/x/alloc/client/cli/tx.go b/x/alloc/client/cli/tx.go index 918822ad..519150c8 100644 --- a/x/alloc/client/cli/tx.go +++ b/x/alloc/client/cli/tx.go @@ -6,7 +6,7 @@ import ( "github.com/spf13/cobra" - "github.com/OmniFlix/omniflixhub/x/alloc/types" + "github.com/OmniFlix/omniflixhub/v2/x/alloc/types" "github.com/cosmos/cosmos-sdk/client" ) diff --git a/x/alloc/exported/exported.go b/x/alloc/exported/exported.go new file mode 100644 index 00000000..000114e6 --- /dev/null +++ b/x/alloc/exported/exported.go @@ -0,0 +1,18 @@ +package exported + +import ( + sdk "github.com/cosmos/cosmos-sdk/types" + paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" +) + +type ( + ParamSet = paramtypes.ParamSet + + // Subspace defines an interface that implements the legacy x/params Subspace + // type. + // + // NOTE: This is used solely for migration of x/params managed parameters. + Subspace interface { + GetParamSet(ctx sdk.Context, ps ParamSet) + } +) diff --git a/x/alloc/genesis.go b/x/alloc/genesis.go index 1c913d12..c5bff577 100644 --- a/x/alloc/genesis.go +++ b/x/alloc/genesis.go @@ -1,15 +1,18 @@ package alloc import ( - "github.com/OmniFlix/omniflixhub/x/alloc/keeper" - "github.com/OmniFlix/omniflixhub/x/alloc/types" + "github.com/OmniFlix/omniflixhub/v2/x/alloc/keeper" + "github.com/OmniFlix/omniflixhub/v2/x/alloc/types" sdk "github.com/cosmos/cosmos-sdk/types" ) // InitGenesis initializes the capability module's state from a provided genesis // state. func InitGenesis(ctx sdk.Context, k keeper.Keeper, genState types.GenesisState) { - k.SetParams(ctx, genState.Params) + err := k.SetParams(ctx, genState.Params) + if err != nil { + panic(err) + } } // ExportGenesis returns the capability module's exported genesis. diff --git a/x/alloc/handler.go b/x/alloc/handler.go deleted file mode 100644 index c017af16..00000000 --- a/x/alloc/handler.go +++ /dev/null @@ -1,23 +0,0 @@ -package alloc - -import ( - "fmt" - - "github.com/OmniFlix/omniflixhub/x/alloc/keeper" - "github.com/OmniFlix/omniflixhub/x/alloc/types" - sdk "github.com/cosmos/cosmos-sdk/types" - sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" -) - -// NewHandler ... -func NewHandler(k keeper.Keeper) sdk.Handler { - _ = keeper.NewMsgServerImpl(k) - - return func(ctx sdk.Context, msg sdk.Msg) (*sdk.Result, error) { - switch msg := msg.(type) { //nolint:gocritic - default: - errMsg := fmt.Sprintf("unrecognized %s message type: %T", types.ModuleName, msg) - return nil, sdkerrors.Wrap(sdkerrors.ErrUnknownRequest, errMsg) - } - } -} diff --git a/x/alloc/keeper/grpc_query.go b/x/alloc/keeper/grpc_query.go index e3b9e091..0df9c71c 100644 --- a/x/alloc/keeper/grpc_query.go +++ b/x/alloc/keeper/grpc_query.go @@ -3,7 +3,7 @@ package keeper import ( "context" - "github.com/OmniFlix/omniflixhub/x/alloc/types" + "github.com/OmniFlix/omniflixhub/v2/x/alloc/types" sdk "github.com/cosmos/cosmos-sdk/types" ) diff --git a/x/alloc/keeper/keeper.go b/x/alloc/keeper/keeper.go index 01ef32cb..a27b46a5 100644 --- a/x/alloc/keeper/keeper.go +++ b/x/alloc/keeper/keeper.go @@ -1,46 +1,47 @@ package keeper import ( + "errors" "fmt" - "github.com/tendermint/tendermint/libs/log" - - "github.com/OmniFlix/omniflixhub/x/alloc/types" + "github.com/OmniFlix/omniflixhub/v2/x/alloc/types" + "github.com/cometbft/cometbft/libs/log" "github.com/cosmos/cosmos-sdk/codec" + storetypes "github.com/cosmos/cosmos-sdk/store/types" sdk "github.com/cosmos/cosmos-sdk/types" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" - paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" ) type ( Keeper struct { cdc codec.BinaryCodec - storeKey sdk.StoreKey - memKey sdk.StoreKey + storeKey storetypes.StoreKey + memKey storetypes.StoreKey accountKeeper types.AccountKeeper bankKeeper types.BankKeeper stakingKeeper types.StakingKeeper distrKeeper types.DistrKeeper - paramstore paramtypes.Subspace + // the address capable of executing a MsgUpdateParams message. Typically, this + // should be the x/gov module account. + authority string } ) func NewKeeper( cdc codec.BinaryCodec, storeKey, - memKey sdk.StoreKey, + memKey storetypes.StoreKey, accountKeeper types.AccountKeeper, bankKeeper types.BankKeeper, stakingKeeper types.StakingKeeper, distrKeeper types.DistrKeeper, - ps paramtypes.Subspace, + authority string, ) *Keeper { - // set KeyTable if it has not already been set - if !ps.HasKeyTable() { - ps = ps.WithKeyTable(types.ParamKeyTable()) + if addr := accountKeeper.GetModuleAddress(types.ModuleName); addr == nil { + panic(fmt.Sprintf("the x/%s module account has not been set", types.ModuleName)) } return &Keeper{ @@ -52,10 +53,15 @@ func NewKeeper( bankKeeper: bankKeeper, stakingKeeper: stakingKeeper, distrKeeper: distrKeeper, - paramstore: ps, + authority: authority, } } +// GetAuthority returns the x/alloc module's authority. +func (k Keeper) GetAuthority() string { + return k.authority +} + func (k Keeper) Logger(ctx sdk.Context) log.Logger { return ctx.Logger().With("module", fmt.Sprintf("x/%s", types.ModuleName)) } @@ -69,13 +75,14 @@ func (k Keeper) GetModuleAccountAddress() sdk.AccAddress { func (k Keeper) DistributeMintedCoins(ctx sdk.Context) error { blockRewardsAddr := k.accountKeeper.GetModuleAccount(ctx, authtypes.FeeCollectorName).GetAddress() blockRewards := k.bankKeeper.GetBalance(ctx, blockRewardsAddr, k.stakingKeeper.BondDenom(ctx)) - blockRewardsAmountDec := blockRewards.Amount.ToDec() params := k.GetParams(ctx) proportions := params.DistributionProportions - nftIncentiveAmount := blockRewardsAmountDec.Mul(proportions.NftIncentives).TruncateInt() - nftIncentiveCoin := sdk.NewCoin(k.stakingKeeper.BondDenom(ctx), nftIncentiveAmount) + nftIncentiveCoin, err := getProportionAmount(blockRewards, proportions.NftIncentives) + if err != nil { + return err + } k.Logger(ctx).Debug( "distributing minted coins to nft incentives receivers", @@ -90,8 +97,10 @@ func (k Keeper) DistributeMintedCoins(ctx sdk.Context) error { return err } - nodeHostsIncentiveAmount := blockRewardsAmountDec.Mul(proportions.NodeHostsIncentives).TruncateInt() - nodeHostsIncentiveCoin := sdk.NewCoin(k.stakingKeeper.BondDenom(ctx), nodeHostsIncentiveAmount) + nodeHostsIncentiveCoin, err := getProportionAmount(blockRewards, proportions.NodeHostsIncentives) + if err != nil { + return err + } k.Logger(ctx).Debug( "distributing minted coins to node host incentives receivers", @@ -106,8 +115,10 @@ func (k Keeper) DistributeMintedCoins(ctx sdk.Context) error { return err } - devRewardAmount := blockRewardsAmountDec.Mul(proportions.DeveloperRewards).TruncateInt() - devRewardCoin := sdk.NewCoin(k.stakingKeeper.BondDenom(ctx), devRewardAmount) + devRewardCoin, err := getProportionAmount(blockRewards, proportions.DeveloperRewards) + if err != nil { + return err + } k.Logger(ctx).Debug( "distributing minted coins to developer rewards receivers", @@ -124,8 +135,10 @@ func (k Keeper) DistributeMintedCoins(ctx sdk.Context) error { } // calculate staking rewards - stakingRewardAmount := blockRewardsAmountDec.Mul(proportions.StakingRewards).TruncateInt() - stakingRewardCoin := sdk.NewCoin(k.stakingKeeper.BondDenom(ctx), stakingRewardAmount) + stakingRewardCoin, err := getProportionAmount(blockRewards, proportions.StakingRewards) + if err != nil { + return err + } // subtract from original provision to ensure no coins left over after the allocations communityPoolCoin := blockRewards. @@ -144,12 +157,14 @@ func (k Keeper) DistributeMintedCoins(ctx sdk.Context) error { func (k Keeper) distributeCoinToWeightedAddresses( ctx sdk.Context, weightedAddresses []types.WeightedAddress, - totalAmount sdk.Coin, + totalCoin sdk.Coin, fromAddress sdk.AccAddress, ) error { - totalAmountDec := totalAmount.Amount.ToDec() for _, w := range weightedAddresses { - amount := sdk.NewCoin(k.stakingKeeper.BondDenom(ctx), totalAmountDec.Mul(w.Weight).TruncateInt()) + amount, err := getProportionAmount(totalCoin, w.Weight) + if err != nil { + return err + } if w.Address == "" { err := k.distrKeeper.FundCommunityPool(ctx, sdk.NewCoins(amount), fromAddress) if err != nil { @@ -170,3 +185,10 @@ func (k Keeper) distributeCoinToWeightedAddresses( } return nil } + +func getProportionAmount(totalCoin sdk.Coin, ratio sdk.Dec) (sdk.Coin, error) { + if ratio.GT(sdk.OneDec()) { + return sdk.Coin{}, errors.New("ratio cannot be greater than 1") + } + return sdk.NewCoin(totalCoin.Denom, sdk.NewDecFromInt(totalCoin.Amount).Mul(ratio).TruncateInt()), nil +} diff --git a/x/alloc/keeper/keeper_test.go b/x/alloc/keeper/keeper_test.go index fce5f96f..c8f30ff3 100644 --- a/x/alloc/keeper/keeper_test.go +++ b/x/alloc/keeper/keeper_test.go @@ -4,48 +4,97 @@ import ( "testing" "time" - "github.com/OmniFlix/omniflixhub/app" - "github.com/OmniFlix/omniflixhub/testutil/simapp" - "github.com/OmniFlix/omniflixhub/x/alloc/types" + tmproto "github.com/cometbft/cometbft/proto/tendermint/types" + + "github.com/OmniFlix/omniflixhub/v2/app/apptesting" + "github.com/OmniFlix/omniflixhub/v2/x/alloc/types" sdk "github.com/cosmos/cosmos-sdk/types" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" bankkeeper "github.com/cosmos/cosmos-sdk/x/bank/keeper" - minttypes "github.com/cosmos/cosmos-sdk/x/mint/types" "github.com/stretchr/testify/suite" - tmproto "github.com/tendermint/tendermint/proto/tendermint/types" + + "github.com/OmniFlix/omniflixhub/v2/app" ) type KeeperTestSuite struct { + apptesting.KeeperTestHelper suite.Suite ctx sdk.Context + app *app.OmniFlixApp } func (suite *KeeperTestSuite) SetupTest() { - suite.app = simapp.New(suite.T().TempDir()) - suite.ctx = suite.app.BaseApp.NewContext( - false, - tmproto.Header{Height: 1, ChainID: "omniflixhub-1", Time: time.Now().UTC()}, - ) - suite.app.AllocKeeper.SetParams(suite.ctx, types.DefaultParams()) + suite.app = app.Setup(suite.T()) + suite.ctx = suite.app.BaseApp.NewContext(false, tmproto.Header{ + ChainID: app.SimAppChainID, + Height: 5, + Time: time.Now().UTC(), + }) } func TestKeeperTestSuite(t *testing.T) { suite.Run(t, new(KeeperTestSuite)) } -func FundAccount(bankKeeper bankkeeper.Keeper, ctx sdk.Context, addr sdk.AccAddress, amounts sdk.Coins) error { - if err := bankKeeper.MintCoins(ctx, minttypes.ModuleName, amounts); err != nil { +func FundModuleAccount(bankKeeper bankkeeper.Keeper, ctx sdk.Context, recipientMod string, amounts sdk.Coins) error { + if err := bankKeeper.MintCoins(ctx, types.ModuleName, amounts); err != nil { return err } - return bankKeeper.SendCoinsFromModuleToAccount(ctx, minttypes.ModuleName, addr, amounts) + return bankKeeper.SendCoinsFromModuleToModule(ctx, types.ModuleName, recipientMod, amounts) } -func FundModuleAccount(bankKeeper bankkeeper.Keeper, ctx sdk.Context, recipientMod string, amounts sdk.Coins) error { - if err := bankKeeper.MintCoins(ctx, minttypes.ModuleName, amounts); err != nil { - return err +func (suite *KeeperTestSuite) TestParams() { + testCases := []struct { + name string + input types.Params + expectErr bool + }{ + { + name: "set invalid params", + input: types.Params{ + DistributionProportions: types.DistributionProportions{ + StakingRewards: sdk.NewDecWithPrec(-1, 2), + NftIncentives: sdk.NewDecWithPrec(100, 2), + NodeHostsIncentives: sdk.NewDecWithPrec(5, 2), + DeveloperRewards: sdk.NewDecWithPrec(0, 2), + CommunityPool: sdk.NewDecWithPrec(5, 2), + }, + }, + expectErr: true, + }, + { + name: "set full valid params", + input: types.Params{ + DistributionProportions: types.DistributionProportions{ + StakingRewards: sdk.NewDecWithPrec(60, 2), // 60% + NftIncentives: sdk.NewDecWithPrec(15, 2), // 15% + NodeHostsIncentives: sdk.NewDecWithPrec(5, 2), // 5% + DeveloperRewards: sdk.NewDecWithPrec(15, 2), // 15% + CommunityPool: sdk.NewDecWithPrec(5, 2), // 5% + }, + }, + expectErr: false, + }, + } + + for _, tc := range testCases { + tc := tc + + suite.Run(tc.name, func() { + expected := suite.app.AllocKeeper.GetParams(suite.ctx) + err := suite.app.AllocKeeper.SetParams(suite.ctx, tc.input) + if tc.expectErr { + suite.Require().Error(err) + } else { + expected = tc.input + suite.Require().NoError(err) + } + + p := suite.app.AllocKeeper.GetParams(suite.ctx) + suite.Require().Equal(expected, p) + }) } - return bankKeeper.SendCoinsFromModuleToModule(ctx, minttypes.ModuleName, recipientMod, amounts) } func (suite *KeeperTestSuite) TestDistribution() { @@ -80,8 +129,8 @@ func (suite *KeeperTestSuite) TestDistribution() { Weight: sdk.NewDec(1), }, } - suite.app.AllocKeeper.SetParams(suite.ctx, params) - + err := suite.app.AllocKeeper.SetParams(suite.ctx, params) + suite.Require().NoError(err) feePool := suite.app.DistrKeeper.GetFeePool(suite.ctx) feeCollector := suite.app.AccountKeeper.GetModuleAddress(authtypes.FeeCollectorName) suite.Equal( @@ -97,7 +146,6 @@ func (suite *KeeperTestSuite) TestDistribution() { suite.Require().NotNil(feeCollectorAccount) suite.Require().NoError(FundModuleAccount(suite.app.BankKeeper, suite.ctx, feeCollectorAccount.GetName(), mintCoins)) - feeCollector = suite.app.AccountKeeper.GetModuleAddress(authtypes.FeeCollectorName) suite.Equal( mintCoin.Amount.String(), @@ -117,11 +165,11 @@ func (suite *KeeperTestSuite) TestDistribution() { // remaining going to next module should be 100% - 40% = 60% suite.Equal( - mintCoin.Amount.ToDec().Mul(sdk.NewDecWithPrec(100, 2).Sub(modulePortion)).RoundInt().String(), + sdk.NewDecFromInt(mintCoin.Amount).Mul(sdk.NewDecWithPrec(100, 2).Sub(modulePortion)).RoundInt().String(), suite.app.BankKeeper.GetAllBalances(suite.ctx, feeCollector).AmountOf(denom).String()) suite.Equal( - mintCoin.Amount.ToDec().Mul(params.DistributionProportions.DeveloperRewards).TruncateInt(), + sdk.NewDecFromInt(mintCoin.Amount).Mul(params.DistributionProportions.DeveloperRewards).TruncateInt(), suite.app.BankKeeper.GetBalance(suite.ctx, devRewardsReceiver, denom).Amount) // since the NFT incentives are not setup yet, funds go into the community pool @@ -129,6 +177,6 @@ func (suite *KeeperTestSuite) TestDistribution() { communityPoolPortion := params.DistributionProportions.CommunityPool // 5% suite.Equal( - mintCoin.Amount.ToDec().Mul(communityPoolPortion), + sdk.NewDecFromInt(mintCoin.Amount).Mul(communityPoolPortion), feePool.CommunityPool.AmountOf(denom)) } diff --git a/x/alloc/keeper/migrator.go b/x/alloc/keeper/migrator.go new file mode 100644 index 00000000..13393213 --- /dev/null +++ b/x/alloc/keeper/migrator.go @@ -0,0 +1,28 @@ +package keeper + +import ( + "github.com/OmniFlix/omniflixhub/v2/x/alloc/exported" + v3 "github.com/OmniFlix/omniflixhub/v2/x/alloc/migrations/v3" + sdk "github.com/cosmos/cosmos-sdk/types" +) + +// Migrator is a struct for handling in-place state migrations. +type Migrator struct { + keeper Keeper + legacySubspace exported.Subspace +} + +func NewMigrator(k Keeper, ss exported.Subspace) Migrator { + return Migrator{ + keeper: k, + legacySubspace: ss, + } +} + +// Migrate2to3 migrates the x/alloc module state from the consensus version 2 to +// version 3. Specifically, it takes the parameters that are currently stored +// and managed by the x/params modules and stores them directly into the x/alloc +// module state. +func (m Migrator) Migrate2to3(ctx sdk.Context) error { + return v3.Migrate(ctx, ctx.KVStore(m.keeper.storeKey), m.legacySubspace, m.keeper.cdc) +} diff --git a/x/alloc/keeper/msg_server.go b/x/alloc/keeper/msg_server.go index 4aefa090..076f5cee 100644 --- a/x/alloc/keeper/msg_server.go +++ b/x/alloc/keeper/msg_server.go @@ -1,7 +1,12 @@ package keeper import ( - "github.com/OmniFlix/omniflixhub/x/alloc/types" + "context" + + errorsmod "cosmossdk.io/errors" + "github.com/OmniFlix/omniflixhub/v2/x/alloc/types" + sdk "github.com/cosmos/cosmos-sdk/types" + govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" ) type msgServer struct { @@ -15,3 +20,16 @@ func NewMsgServerImpl(keeper Keeper) types.MsgServer { } var _ types.MsgServer = msgServer{} + +func (m msgServer) UpdateParams(goCtx context.Context, req *types.MsgUpdateParams) (*types.MsgUpdateParamsResponse, error) { + if m.authority != req.Authority { + return nil, errorsmod.Wrapf(govtypes.ErrInvalidSigner, "invalid authority; expected %s, got %s", m.authority, req.Authority) + } + + ctx := sdk.UnwrapSDKContext(goCtx) + if err := m.SetParams(ctx, req.Params); err != nil { + return nil, err + } + + return &types.MsgUpdateParamsResponse{}, nil +} diff --git a/x/alloc/keeper/params.go b/x/alloc/keeper/params.go index 04792dad..0d5edbb0 100644 --- a/x/alloc/keeper/params.go +++ b/x/alloc/keeper/params.go @@ -1,17 +1,31 @@ package keeper import ( - "github.com/OmniFlix/omniflixhub/x/alloc/types" + "github.com/OmniFlix/omniflixhub/v2/x/alloc/types" sdk "github.com/cosmos/cosmos-sdk/types" ) // GetParams returns the total set of alloc parameters. func (k Keeper) GetParams(ctx sdk.Context) (params types.Params) { - k.paramstore.GetParamSet(ctx, ¶ms) + store := ctx.KVStore(k.storeKey) + bz := store.Get(types.ParamsKey) + if bz == nil { + return params + } + + k.cdc.MustUnmarshal(bz, ¶ms) return params } // SetParams sets the total set of alloc parameters. -func (k Keeper) SetParams(ctx sdk.Context, params types.Params) { - k.paramstore.SetParamSet(ctx, ¶ms) +func (k Keeper) SetParams(ctx sdk.Context, params types.Params) error { + if err := params.Validate(); err != nil { + return err + } + + store := ctx.KVStore(k.storeKey) + bz := k.cdc.MustMarshal(¶ms) + store.Set(types.ParamsKey, bz) + + return nil } diff --git a/x/alloc/migrations/v3/migrate.go b/x/alloc/migrations/v3/migrate.go new file mode 100644 index 00000000..d1ea933b --- /dev/null +++ b/x/alloc/migrations/v3/migrate.go @@ -0,0 +1,37 @@ +package v3 + +import ( + "github.com/OmniFlix/omniflixhub/v2/x/alloc/exported" + "github.com/OmniFlix/omniflixhub/v2/x/alloc/types" + "github.com/cosmos/cosmos-sdk/codec" + sdk "github.com/cosmos/cosmos-sdk/types" +) + +const ( + ModuleName = "alloc" +) + +var ParamsKey = []byte{0x00} + +// Migrate migrates the x/alloc module state from the consensus version 2 to +// version 3. Specifically, it takes the parameters that are currently stored +// and managed by the x/params modules and stores them directly into the x/alloc +// module state. +func Migrate( + ctx sdk.Context, + store sdk.KVStore, + legacySubspace exported.Subspace, + cdc codec.BinaryCodec, +) error { + var currParams types.Params + legacySubspace.GetParamSet(ctx, &currParams) + + if err := currParams.Validate(); err != nil { + return err + } + + bz := cdc.MustMarshal(&currParams) + store.Set(ParamsKey, bz) + + return nil +} diff --git a/x/alloc/migrations/v3/migrator_test.go b/x/alloc/migrations/v3/migrator_test.go new file mode 100644 index 00000000..fc04951b --- /dev/null +++ b/x/alloc/migrations/v3/migrator_test.go @@ -0,0 +1,45 @@ +package v3_test + +import ( + "testing" + + "github.com/stretchr/testify/require" + + "github.com/OmniFlix/omniflixhub/v2/x/alloc" + "github.com/OmniFlix/omniflixhub/v2/x/alloc/exported" + v3 "github.com/OmniFlix/omniflixhub/v2/x/alloc/migrations/v3" + "github.com/OmniFlix/omniflixhub/v2/x/alloc/types" + "github.com/cosmos/cosmos-sdk/testutil" + sdk "github.com/cosmos/cosmos-sdk/types" + moduletestutil "github.com/cosmos/cosmos-sdk/types/module/testutil" +) + +type mockSubspace struct { + ps types.Params +} + +func newMockSubspace(ps types.Params) mockSubspace { + return mockSubspace{ps: ps} +} + +func (ms mockSubspace) GetParamSet(ctx sdk.Context, ps exported.ParamSet) { + *ps.(*types.Params) = ms.ps +} + +func TestMigrate(t *testing.T) { + encCfg := moduletestutil.MakeTestEncodingConfig(alloc.AppModuleBasic{}) + cdc := encCfg.Codec + + storeKey := sdk.NewKVStoreKey(v3.ModuleName) + tKey := sdk.NewTransientStoreKey("transient_test") + ctx := testutil.DefaultContext(storeKey, tKey) + store := ctx.KVStore(storeKey) + + legacySubspace := newMockSubspace(types.DefaultParams()) + require.NoError(t, v3.Migrate(ctx, store, legacySubspace, cdc)) + + var res types.Params + bz := store.Get(v3.ParamsKey) + require.NoError(t, cdc.Unmarshal(bz, &res)) + require.Equal(t, legacySubspace.ps, res) +} diff --git a/x/alloc/module.go b/x/alloc/module.go index a1a4c723..b60aa2ff 100644 --- a/x/alloc/module.go +++ b/x/alloc/module.go @@ -5,15 +5,17 @@ import ( "encoding/json" "fmt" + "github.com/OmniFlix/omniflixhub/v2/x/alloc/exported" + "github.com/gorilla/mux" "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/spf13/cobra" - abci "github.com/tendermint/tendermint/abci/types" + abci "github.com/cometbft/cometbft/abci/types" - "github.com/OmniFlix/omniflixhub/x/alloc/client/cli" - "github.com/OmniFlix/omniflixhub/x/alloc/keeper" - "github.com/OmniFlix/omniflixhub/x/alloc/types" + "github.com/OmniFlix/omniflixhub/v2/x/alloc/client/cli" + "github.com/OmniFlix/omniflixhub/v2/x/alloc/keeper" + "github.com/OmniFlix/omniflixhub/v2/x/alloc/types" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/codec" cdctypes "github.com/cosmos/cosmos-sdk/codec/types" @@ -30,6 +32,9 @@ var ( // AppModuleBasic // ---------------------------------------------------------------------------- +// ConsensusVersion defines the current x/alloc module consensus version. +const ConsensusVersion = 3 + // AppModuleBasic implements the AppModuleBasic interface for the alloc module. type AppModuleBasic struct { cdc codec.BinaryCodec @@ -45,11 +50,11 @@ func (AppModuleBasic) Name() string { } func (AppModuleBasic) RegisterCodec(cdc *codec.LegacyAmino) { - types.RegisterCodec(cdc) + types.RegisterLegacyAminoCodec(cdc) } func (AppModuleBasic) RegisterLegacyAminoCodec(cdc *codec.LegacyAmino) { - types.RegisterCodec(cdc) + types.RegisterLegacyAminoCodec(cdc) } // RegisterInterfaces registers the module's interface types @@ -101,13 +106,15 @@ func (AppModuleBasic) GetQueryCmd() *cobra.Command { type AppModule struct { AppModuleBasic - keeper keeper.Keeper + keeper keeper.Keeper + legacySubspace exported.Subspace } -func NewAppModule(cdc codec.Codec, keeper keeper.Keeper) AppModule { +func NewAppModule(cdc codec.Codec, keeper keeper.Keeper, ss exported.Subspace) AppModule { return AppModule{ AppModuleBasic: NewAppModuleBasic(cdc), keeper: keeper, + legacySubspace: ss, } } @@ -116,23 +123,20 @@ func (am AppModule) Name() string { return am.AppModuleBasic.Name() } -// Route returns the alloc module's message routing key. -func (am AppModule) Route() sdk.Route { - return sdk.NewRoute(types.RouterKey, NewHandler(am.keeper)) -} - // QuerierRoute returns the alloc module's query routing key. func (AppModule) QuerierRoute() string { return types.QuerierRoute } -// LegacyQuerierHandler returns the alloc module's Querier. -func (am AppModule) LegacyQuerierHandler(legacyQuerierCdc *codec.LegacyAmino) sdk.Querier { - return nil -} - // RegisterServices registers a GRPC query service to respond to the // module-specific GRPC queries. func (am AppModule) RegisterServices(cfg module.Configurator) { types.RegisterQueryServer(cfg.QueryServer(), am.keeper) + types.RegisterMsgServer(cfg.MsgServer(), keeper.NewMsgServerImpl(am.keeper)) + + m := keeper.NewMigrator(am.keeper, am.legacySubspace) + + if err := cfg.RegisterMigration(types.ModuleName, 2, m.Migrate2to3); err != nil { + panic(fmt.Sprintf("failed to migrate x/%s from version 2 to 3: %v", types.ModuleName, err)) + } } // RegisterInvariants registers the alloc module's invariants. @@ -157,7 +161,7 @@ func (am AppModule) ExportGenesis(ctx sdk.Context, cdc codec.JSONCodec) json.Raw } // ConsensusVersion implements ConsensusVersion. -func (AppModule) ConsensusVersion() uint64 { return 2 } +func (AppModule) ConsensusVersion() uint64 { return ConsensusVersion } // BeginBlock executes all ABCI BeginBlock logic respective to the alloc module. func (am AppModule) BeginBlock(ctx sdk.Context, _ abci.RequestBeginBlock) { diff --git a/x/alloc/types/codec.go b/x/alloc/types/codec.go index 0191d6d4..61c38b59 100644 --- a/x/alloc/types/codec.go +++ b/x/alloc/types/codec.go @@ -2,20 +2,41 @@ package types import ( "github.com/cosmos/cosmos-sdk/codec" - cdctypes "github.com/cosmos/cosmos-sdk/codec/types" + "github.com/cosmos/cosmos-sdk/codec/legacy" + "github.com/cosmos/cosmos-sdk/codec/types" + cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/msgservice" + authzcodec "github.com/cosmos/cosmos-sdk/x/authz/codec" ) -func RegisterCodec(cdc *codec.LegacyAmino) { +var ( + amino = codec.NewLegacyAmino() + ModuleCdc = codec.NewAminoCodec(amino) +) + +func init() { + RegisterLegacyAminoCodec(amino) + cryptocodec.RegisterCrypto(amino) + sdk.RegisterLegacyAminoCodec(amino) + + // Register all Amino interfaces and concrete types on the authz Amino codec + // so that this can later be used to properly serialize MsgGrant and MsgExec + // instances. + RegisterLegacyAminoCodec(authzcodec.Amino) } -func RegisterInterfaces(registry cdctypes.InterfaceRegistry) { - registry.RegisterImplementations((*sdk.Msg)(nil)) +// RegisterLegacyAminoCodec registers concrete types on the LegacyAmino codec +func RegisterLegacyAminoCodec(cdc *codec.LegacyAmino) { + cdc.RegisterConcrete(Params{}, "OmniFlix/alloc/Params", nil) + legacy.RegisterAminoMsg(cdc, &MsgUpdateParams{}, "OmniFlix/alloc/MsgUpdateParams") +} - msgservice.RegisterMsgServiceDesc(registry, &_Msg_serviceDesc) +func RegisterInterfaces(registry types.InterfaceRegistry) { + registry.RegisterImplementations( + (*sdk.Msg)(nil), + &MsgUpdateParams{}, + ) msgservice.RegisterMsgServiceDesc(registry, &_Msg_serviceDesc) } - -var ModuleCdc = codec.NewProtoCodec(cdctypes.NewInterfaceRegistry()) diff --git a/x/alloc/types/genesis.pb.go b/x/alloc/types/genesis.pb.go index f308db68..841df6b0 100644 --- a/x/alloc/types/genesis.pb.go +++ b/x/alloc/types/genesis.pb.go @@ -1,12 +1,12 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: omniflix/alloc/v1beta1/genesis.proto +// source: OmniFlix/alloc/v1beta1/genesis.proto package types import ( fmt "fmt" - _ "github.com/gogo/protobuf/gogoproto" - proto "github.com/gogo/protobuf/proto" + _ "github.com/cosmos/gogoproto/gogoproto" + proto "github.com/cosmos/gogoproto/proto" io "io" math "math" math_bits "math/bits" @@ -32,7 +32,7 @@ func (m *GenesisState) Reset() { *m = GenesisState{} } func (m *GenesisState) String() string { return proto.CompactTextString(m) } func (*GenesisState) ProtoMessage() {} func (*GenesisState) Descriptor() ([]byte, []int) { - return fileDescriptor_8ab28b35850f79a1, []int{0} + return fileDescriptor_3f1e0cf2f304cb56, []int{0} } func (m *GenesisState) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -69,28 +69,29 @@ func (m *GenesisState) GetParams() Params { } func init() { - proto.RegisterType((*GenesisState)(nil), "omniflix.alloc.v1beta1.GenesisState") + proto.RegisterType((*GenesisState)(nil), "OmniFlix.alloc.v1beta1.GenesisState") } func init() { - proto.RegisterFile("omniflix/alloc/v1beta1/genesis.proto", fileDescriptor_8ab28b35850f79a1) + proto.RegisterFile("OmniFlix/alloc/v1beta1/genesis.proto", fileDescriptor_3f1e0cf2f304cb56) } -var fileDescriptor_8ab28b35850f79a1 = []byte{ - // 205 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0xc9, 0xcf, 0xcd, 0xcb, - 0x4c, 0xcb, 0xc9, 0xac, 0xd0, 0x4f, 0xcc, 0xc9, 0xc9, 0x4f, 0xd6, 0x2f, 0x33, 0x4c, 0x4a, 0x2d, +var fileDescriptor_3f1e0cf2f304cb56 = []byte{ + // 209 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0xf1, 0xcf, 0xcd, 0xcb, + 0x74, 0xcb, 0xc9, 0xac, 0xd0, 0x4f, 0xcc, 0xc9, 0xc9, 0x4f, 0xd6, 0x2f, 0x33, 0x4c, 0x4a, 0x2d, 0x49, 0x34, 0xd4, 0x4f, 0x4f, 0xcd, 0x4b, 0x2d, 0xce, 0x2c, 0xd6, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x83, 0xa9, 0xd2, 0x03, 0xab, 0xd2, 0x83, 0xaa, 0x92, 0x12, 0x49, 0xcf, 0x4f, 0xcf, 0x07, 0x2b, 0xd1, 0x07, 0xb1, 0x20, 0xaa, 0xa5, 0x94, 0x71, 0x98, 0x59, 0x90, 0x58, 0x94, 0x98, 0x0b, 0x35, 0x52, 0xc9, 0x87, 0x8b, 0xc7, 0x1d, 0x62, 0x47, 0x70, 0x49, 0x62, 0x49, 0xaa, 0x90, 0x0d, 0x17, 0x1b, 0x44, 0x5e, 0x82, 0x51, 0x81, 0x51, 0x83, 0xdb, 0x48, 0x4e, 0x0f, 0xbb, 0x9d, - 0x7a, 0x01, 0x60, 0x55, 0x4e, 0x2c, 0x27, 0xee, 0xc9, 0x33, 0x04, 0x41, 0xf5, 0x38, 0xb9, 0x9f, + 0x7a, 0x01, 0x60, 0x55, 0x4e, 0x2c, 0x27, 0xee, 0xc9, 0x33, 0x04, 0x41, 0xf5, 0x38, 0x79, 0x9d, 0x78, 0x24, 0xc7, 0x78, 0xe1, 0x91, 0x1c, 0xe3, 0x83, 0x47, 0x72, 0x8c, 0x13, 0x1e, 0xcb, 0x31, - 0x5c, 0x78, 0x2c, 0xc7, 0x70, 0xe3, 0xb1, 0x1c, 0x43, 0x94, 0x6e, 0x7a, 0x66, 0x49, 0x46, 0x69, - 0x92, 0x5e, 0x72, 0x7e, 0xae, 0xbe, 0x7f, 0x6e, 0x5e, 0xa6, 0x1b, 0xc8, 0x5d, 0x30, 0xa3, 0x33, - 0x4a, 0x93, 0xf4, 0x61, 0xae, 0x2c, 0xa9, 0x2c, 0x48, 0x2d, 0x4e, 0x62, 0x03, 0xbb, 0xce, 0x18, - 0x10, 0x00, 0x00, 0xff, 0xff, 0xb1, 0x5a, 0x14, 0xe3, 0x18, 0x01, 0x00, 0x00, + 0x5c, 0x78, 0x2c, 0xc7, 0x70, 0xe3, 0xb1, 0x1c, 0x43, 0x94, 0x41, 0x7a, 0x66, 0x49, 0x46, 0x69, + 0x92, 0x5e, 0x72, 0x7e, 0xae, 0x3e, 0xdc, 0x5d, 0xf9, 0xb9, 0x79, 0x99, 0x69, 0x39, 0x99, 0x15, + 0x19, 0xa5, 0x49, 0xfa, 0x65, 0x46, 0xfa, 0x30, 0x87, 0x96, 0x54, 0x16, 0xa4, 0x16, 0x27, 0xb1, + 0x81, 0x1d, 0x68, 0x0c, 0x08, 0x00, 0x00, 0xff, 0xff, 0x3c, 0xb8, 0x87, 0x92, 0x1b, 0x01, 0x00, + 0x00, } func (m *GenesisState) Marshal() (dAtA []byte, err error) { diff --git a/x/alloc/types/genesis_test.go b/x/alloc/types/genesis_test.go index ed06f487..ea91c6da 100644 --- a/x/alloc/types/genesis_test.go +++ b/x/alloc/types/genesis_test.go @@ -3,7 +3,7 @@ package types_test import ( "testing" - "github.com/OmniFlix/omniflixhub/x/alloc/types" + "github.com/OmniFlix/omniflixhub/v2/x/alloc/types" "github.com/stretchr/testify/require" ) diff --git a/x/alloc/types/keys.go b/x/alloc/types/keys.go index d25c98f9..53493188 100644 --- a/x/alloc/types/keys.go +++ b/x/alloc/types/keys.go @@ -1,5 +1,7 @@ package types +var ParamsKey = []byte{0x00} + const ( // ModuleName defines the module name ModuleName = "alloc" diff --git a/x/alloc/types/msgs.go b/x/alloc/types/msgs.go new file mode 100644 index 00000000..e0ce8a24 --- /dev/null +++ b/x/alloc/types/msgs.go @@ -0,0 +1,29 @@ +package types + +import ( + "cosmossdk.io/errors" + + sdk "github.com/cosmos/cosmos-sdk/types" +) + +var _ sdk.Msg = &MsgUpdateParams{} + +// GetSignBytes implements the LegacyMsg interface. +func (m MsgUpdateParams) GetSignBytes() []byte { + return sdk.MustSortJSON(ModuleCdc.MustMarshalJSON(&m)) +} + +// GetSigners returns the expected signers for a MsgUpdateParams message. +func (m *MsgUpdateParams) GetSigners() []sdk.AccAddress { + addr, _ := sdk.AccAddressFromBech32(m.Authority) + return []sdk.AccAddress{addr} +} + +// ValidateBasic does a sanity check on the provided data. +func (m *MsgUpdateParams) ValidateBasic() error { + if _, err := sdk.AccAddressFromBech32(m.Authority); err != nil { + return errors.Wrap(err, "invalid authority address") + } + + return m.Params.Validate() +} diff --git a/x/alloc/types/params.go b/x/alloc/types/params.go index 5b4cf68a..d442b86a 100644 --- a/x/alloc/types/params.go +++ b/x/alloc/types/params.go @@ -1,26 +1,9 @@ package types import ( - "errors" - "fmt" - sdk "github.com/cosmos/cosmos-sdk/types" - paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" -) - -// Parameter store keys -var ( - KeyDistributionProportions = []byte("DistributionProportions") - KeyDeveloperRewardsReceiver = []byte("DeveloperRewardsReceiver") - KeyNftIncentivesReceiver = []byte("NftIncentivesReceiver") - KeyNodeHostIncentivesReceiver = []byte("NodeHostIncentivesReceiver") ) -// ParamKeyTable ParamTable for module. -func ParamKeyTable() paramtypes.KeyTable { - return paramtypes.NewKeyTable().RegisterParamSet(&Params{}) -} - func NewParams( distrProportions DistributionProportions, weightedDevRewardsReceivers []WeightedAddress, @@ -45,9 +28,9 @@ func DefaultParams() Params { DeveloperRewards: sdk.NewDecWithPrec(15, 2), // 15% CommunityPool: sdk.NewDecWithPrec(5, 2), // 5% }, - WeightedDeveloperRewardsReceivers: []WeightedAddress{}, - WeightedNftIncentivesReceivers: []WeightedAddress{}, - WeightedNodeHostsIncentivesReceivers: []WeightedAddress{}, + WeightedDeveloperRewardsReceivers: []WeightedAddress(nil), + WeightedNftIncentivesReceivers: []WeightedAddress(nil), + WeightedNodeHostsIncentivesReceivers: []WeightedAddress(nil), } } @@ -59,96 +42,3 @@ func (p Params) Validate() error { err := validateWeightedAddresses(p.WeightedDeveloperRewardsReceivers) return err } - -// ParamSetPairs Implements params.ParamSet -func (p *Params) ParamSetPairs() paramtypes.ParamSetPairs { - return paramtypes.ParamSetPairs{ - paramtypes.NewParamSetPair(KeyDistributionProportions, &p.DistributionProportions, validateDistributionProportions), - paramtypes.NewParamSetPair( - KeyDeveloperRewardsReceiver, - &p.WeightedDeveloperRewardsReceivers, - validateWeightedAddresses, - ), - paramtypes.NewParamSetPair( - KeyNftIncentivesReceiver, - &p.WeightedNftIncentivesReceivers, - validateWeightedAddresses, - ), - paramtypes.NewParamSetPair( - KeyNodeHostIncentivesReceiver, - &p.WeightedNodeHostsIncentivesReceivers, - validateWeightedAddresses, - ), - } -} - -func validateDistributionProportions(i interface{}) error { - v, ok := i.(DistributionProportions) - if !ok { - return fmt.Errorf("invalid parameter type: %T", i) - } - - if v.StakingRewards.IsNegative() { - return errors.New("staking rewards distribution ratio should not be negative") - } - - if v.NftIncentives.IsNegative() { - return errors.New("NFT incentives distribution ratio should not be negative") - } - - if v.NodeHostsIncentives.IsNegative() { - return errors.New("node hosts incentives distribution ratio should not be negative") - } - - if v.DeveloperRewards.IsNegative() { - return errors.New("developer rewards distribution ratio should not be negative") - } - - if v.CommunityPool.IsNegative() { - return errors.New("community pool distribution ratio should not be negative") - } - - totalProportions := v.StakingRewards.Add(v.NftIncentives).Add(v.NodeHostsIncentives).Add(v.DeveloperRewards).Add(v.CommunityPool) - - if !totalProportions.Equal(sdk.NewDec(1)) { - return errors.New("total distributions ratio should be equal to 100%") - } - - return nil -} - -func validateWeightedAddresses(i interface{}) error { - v, ok := i.([]WeightedAddress) - if !ok { - return fmt.Errorf("invalid parameter type: %T", i) - } - - // fund community pool when rewards address is empty - if len(v) == 0 { - return nil - } - - weightSum := sdk.NewDec(0) - for i, w := range v { - // we allow address to be "" to go to community pool - if w.Address != "" { - _, err := sdk.AccAddressFromBech32(w.Address) - if err != nil { - return fmt.Errorf("invalid address at %dth", i) - } - } - if !w.Weight.IsPositive() { - return fmt.Errorf("non-positive weight at %dth", i) - } - if w.Weight.GT(sdk.NewDec(1)) { - return fmt.Errorf("more than 1 weight at %dth", i) - } - weightSum = weightSum.Add(w.Weight) - } - - if !weightSum.Equal(sdk.NewDec(1)) { - return fmt.Errorf("invalid weight sum: %s", weightSum.String()) - } - - return nil -} diff --git a/x/alloc/types/params.pb.go b/x/alloc/types/params.pb.go index e4cf6a3d..d44efc85 100644 --- a/x/alloc/types/params.pb.go +++ b/x/alloc/types/params.pb.go @@ -1,13 +1,13 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: omniflix/alloc/v1beta1/params.proto +// source: OmniFlix/alloc/v1beta1/params.proto package types import ( fmt "fmt" github_com_cosmos_cosmos_sdk_types "github.com/cosmos/cosmos-sdk/types" - _ "github.com/gogo/protobuf/gogoproto" - proto "github.com/gogo/protobuf/proto" + _ "github.com/cosmos/gogoproto/gogoproto" + proto "github.com/cosmos/gogoproto/proto" io "io" math "math" math_bits "math/bits" @@ -33,7 +33,7 @@ func (m *WeightedAddress) Reset() { *m = WeightedAddress{} } func (m *WeightedAddress) String() string { return proto.CompactTextString(m) } func (*WeightedAddress) ProtoMessage() {} func (*WeightedAddress) Descriptor() ([]byte, []int) { - return fileDescriptor_e15b25018432ff35, []int{0} + return fileDescriptor_daf6c8a7183c717a, []int{0} } func (m *WeightedAddress) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -81,7 +81,7 @@ func (m *DistributionProportions) Reset() { *m = DistributionProportions func (m *DistributionProportions) String() string { return proto.CompactTextString(m) } func (*DistributionProportions) ProtoMessage() {} func (*DistributionProportions) Descriptor() ([]byte, []int) { - return fileDescriptor_e15b25018432ff35, []int{1} + return fileDescriptor_daf6c8a7183c717a, []int{1} } func (m *DistributionProportions) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -125,7 +125,7 @@ func (m *Params) Reset() { *m = Params{} } func (m *Params) String() string { return proto.CompactTextString(m) } func (*Params) ProtoMessage() {} func (*Params) Descriptor() ([]byte, []int) { - return fileDescriptor_e15b25018432ff35, []int{2} + return fileDescriptor_daf6c8a7183c717a, []int{2} } func (m *Params) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -183,55 +183,56 @@ func (m *Params) GetWeightedNodeHostsIncentivesReceivers() []WeightedAddress { } func init() { - proto.RegisterType((*WeightedAddress)(nil), "omniflix.alloc.v1beta1.WeightedAddress") - proto.RegisterType((*DistributionProportions)(nil), "omniflix.alloc.v1beta1.DistributionProportions") - proto.RegisterType((*Params)(nil), "omniflix.alloc.v1beta1.Params") + proto.RegisterType((*WeightedAddress)(nil), "OmniFlix.alloc.v1beta1.WeightedAddress") + proto.RegisterType((*DistributionProportions)(nil), "OmniFlix.alloc.v1beta1.DistributionProportions") + proto.RegisterType((*Params)(nil), "OmniFlix.alloc.v1beta1.Params") } func init() { - proto.RegisterFile("omniflix/alloc/v1beta1/params.proto", fileDescriptor_e15b25018432ff35) + proto.RegisterFile("OmniFlix/alloc/v1beta1/params.proto", fileDescriptor_daf6c8a7183c717a) } -var fileDescriptor_e15b25018432ff35 = []byte{ - // 605 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x55, 0x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0x44, 0x8c, 0x74, 0x8f, 0x52, 0xbb, - 0xb2, 0xf5, 0x7f, 0xdb, 0x5e, 0x64, 0x83, 0xa8, 0x94, 0x0c, 0x5a, 0xfe, 0xf3, 0x97, 0x2d, 0x50, - 0x6c, 0x05, 0x35, 0x92, 0x3d, 0x50, 0xb1, 0x52, 0xb1, 0xd3, 0xbd, 0x79, 0xee, 0x82, 0x90, 0x6d, - 0x1f, 0x69, 0xea, 0xfa, 0x8e, 0xa9, 0x1b, 0xe2, 0x5a, 0x2f, 0xf8, 0xae, 0xd1, 0xbe, 0xb5, 0x21, - 0xcd, 0x3f, 0x24, 0xf0, 0x68, 0x18, 0x95, 0x50, 0x5f, 0x59, 0x8f, 0xce, 0xb0, 0x89, 0xc9, 0x00, - 0x33, 0x3f, 0x71, 0xf9, 0xda, 0xf6, 0xd1, 0x93, 0x4d, 0xf2, 0x4b, 0x45, 0xae, 0x1f, 0xfb, 0xb2, - 0xb3, 0x71, 0xf5, 0x69, 0xba, 0x60, 0x57, 0x4b, 0x40, 0xf4, 0x20, 0x86, 0x35, 0x96, 0xde, 0x09, - 0x8a, 0x31, 0xf2, 0x77, 0x09, 0x24, 0x28, 0x7d, 0x31, 0xc6, 0x29, 0xb3, 0xf9, 0x6c, 0x66, 0x9f, - 0x47, 0x66, 0x6b, 0x4b, 0x66, 0x37, 0xf1, 0x43, 0xa4, 0xc4, 0x98, 0x66, 0xba, 0x38, 0x73, 0x9b, - 0x3f, 0x25, 0x50, 0x9b, 0xd3, 0xac, 0x4b, 0x7d, 0xca, 0x6d, 0x21, 0x9b, 0xdb, 0x17, 0x91, 0x5b, - 0x6d, 0xd9, 0xed, 0xd5, 0x32, 0x10, 0x25, 0x2f, 0xba, 0xb9, 0x5a, 0xb7, 0xc4, 0x7a, 0xfd, 0xe4, - 0x62, 0xa2, 0x48, 0x97, 0x13, 0x45, 0xfa, 0x33, 0x51, 0xa4, 0xaf, 0x53, 0x25, 0x77, 0x39, 0x55, - 0x72, 0xbf, 0xa6, 0x4a, 0xee, 0xc3, 0x41, 0x2a, 0xf8, 0xef, 0x1d, 0x97, 0xbc, 0xf1, 0xaf, 0x83, - 0xd8, 0x74, 0xaf, 0xdf, 0xd6, 0xe2, 0xcb, 0x21, 0xe8, 0x40, 0xbb, 0x18, 0xfc, 0xcd, 0x1f, 0xff, - 0x0b, 0x00, 0x00, 0xff, 0xff, 0x04, 0xd1, 0xae, 0xc7, 0x3b, 0x06, 0x00, 0x00, +var fileDescriptor_daf6c8a7183c717a = []byte{ + // 610 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x55, 0xbf, 0x6f, 0xd3, 0x4e, + 0x1c, 0x8d, 0xbf, 0x4d, 0xf3, 0x15, 0x57, 0x25, 0x05, 0x43, 0xdb, 0x08, 0x21, 0x07, 0x0e, 0x04, + 0x91, 0x00, 0xbb, 0x4d, 0x07, 0x24, 0x16, 0x44, 0x14, 0x41, 0xe9, 0x10, 0xa2, 0x5b, 0x2a, 0xb1, + 0x58, 0x8e, 0x7d, 0x49, 0x4e, 0xb5, 0x7d, 0xe6, 0xee, 0x92, 0x34, 0x2b, 0x33, 0x03, 0x23, 0x7f, + 0x00, 0x2b, 0x3b, 0x7f, 0x42, 0xc7, 0x8e, 0x88, 0x21, 0x42, 0xc9, 0xc6, 0x98, 0xbf, 0x00, 0xf9, + 0x67, 0x9c, 0x5f, 0x95, 0x2c, 0xa6, 0x9c, 0x3f, 0x79, 0x7a, 0xef, 0xe5, 0xe3, 0xf7, 0x72, 0xe0, + 0xe1, 0x7b, 0xc7, 0x25, 0x6f, 0x6c, 0x72, 0xa1, 0x19, 0xb6, 0x4d, 0x4d, 0x6d, 0x70, 0xd4, 0xc6, + 0xc2, 0x38, 0xd2, 0x3c, 0x83, 0x19, 0x0e, 0x57, 0x3d, 0x46, 0x05, 0x95, 0xf7, 0x63, 0x90, 0x1a, + 0x80, 0xd4, 0x08, 0x74, 0xf7, 0x4e, 0x97, 0x76, 0x69, 0x00, 0xd1, 0xfc, 0x53, 0x88, 0x86, 0x5f, + 0x25, 0xb0, 0x7b, 0x86, 0x49, 0xb7, 0x27, 0xb0, 0xf5, 0xda, 0xb2, 0x18, 0xe6, 0x5c, 0x7e, 0x06, + 0xfe, 0x37, 0xc2, 0x63, 0x59, 0xba, 0x2f, 0x55, 0x6f, 0xd4, 0xe5, 0xd9, 0xb8, 0x52, 0x1a, 0x19, + 0x8e, 0xfd, 0x12, 0x46, 0x5f, 0x40, 0x14, 0x43, 0xe4, 0x33, 0x50, 0x18, 0x06, 0x04, 0xe5, 0xff, + 0x02, 0xf0, 0xab, 0xcb, 0x71, 0x25, 0xf7, 0x6b, 0x5c, 0x79, 0xdc, 0x25, 0xa2, 0xd7, 0x6f, 0xab, + 0x26, 0x75, 0x34, 0x93, 0x72, 0x87, 0xf2, 0xe8, 0xe3, 0x39, 0xb7, 0xce, 0x35, 0x31, 0xf2, 0x30, + 0x57, 0x1b, 0xd8, 0x9c, 0x8d, 0x2b, 0xc5, 0x90, 0x3a, 0x64, 0x81, 0x28, 0xa2, 0x83, 0x7f, 0xf2, + 0xe0, 0xa0, 0x41, 0xb8, 0x60, 0xa4, 0xdd, 0x17, 0x84, 0xba, 0x2d, 0x46, 0x3d, 0xca, 0xfc, 0x13, + 0x97, 0x3f, 0x82, 0x5d, 0x2e, 0x8c, 0x73, 0xe2, 0x76, 0x75, 0x86, 0x87, 0x06, 0xb3, 0x62, 0xab, + 0x27, 0x99, 0xd5, 0xf7, 0x43, 0xf5, 0x25, 0x3a, 0x88, 0x4a, 0xd1, 0x04, 0x85, 0x03, 0xd9, 0x05, + 0x25, 0xb7, 0x23, 0x74, 0xe2, 0x9a, 0xd8, 0x15, 0x64, 0x80, 0x79, 0xf4, 0x7b, 0xdf, 0x66, 0x56, + 0xdc, 0x0b, 0x15, 0x17, 0xd9, 0x20, 0x2a, 0xba, 0x1d, 0xf1, 0x2e, 0x79, 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87, 0x91, 0xd9, 0xea, 0x92, 0xd9, 0x4d, 0xfc, 0x10, 0x29, 0x31, 0xa6, 0x99, 0x2e, + 0xce, 0xdc, 0xe6, 0x0f, 0x09, 0x54, 0xe7, 0x34, 0xeb, 0x52, 0x9f, 0x72, 0x9b, 0xcf, 0xe6, 0xf6, + 0x45, 0xe4, 0x56, 0x5b, 0x76, 0x7b, 0xbd, 0x0c, 0x44, 0xc9, 0x8b, 0x6e, 0xae, 0xd6, 0x2d, 0xb1, + 0x5e, 0x3f, 0xbd, 0x9c, 0x28, 0xd2, 0xd5, 0x44, 0x91, 0x7e, 0x4f, 0x14, 0xe9, 0xcb, 0x54, 0xc9, + 0x5d, 0x4d, 0x95, 0xdc, 0xcf, 0xa9, 0x92, 0xfb, 0x70, 0x98, 0x0a, 0x7e, 0x72, 0x1d, 0x50, 0xc7, + 0x25, 0x1d, 0x9b, 0x5c, 0xf4, 0xfa, 0x6d, 0x6d, 0x50, 0xd3, 0xe2, 0xfb, 0x21, 0xa8, 0x41, 0xbb, + 0x10, 0xfc, 0xd3, 0x1f, 0xff, 0x0d, 0x00, 0x00, 0xff, 0xff, 0x6a, 0xa0, 0xe6, 0xa9, 0x3e, 0x06, + 0x00, 0x00, } func (m *WeightedAddress) Marshal() (dAtA []byte, err error) { diff --git a/x/alloc/types/params_legacy.go b/x/alloc/types/params_legacy.go new file mode 100644 index 00000000..758bad26 --- /dev/null +++ b/x/alloc/types/params_legacy.go @@ -0,0 +1,115 @@ +package types + +import ( + "errors" + "fmt" + + sdk "github.com/cosmos/cosmos-sdk/types" + paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" +) + +// Parameter store keys +var ( + KeyDistributionProportions = []byte("DistributionProportions") + KeyDeveloperRewardsReceiver = []byte("DeveloperRewardsReceiver") + KeyNftIncentivesReceiver = []byte("NftIncentivesReceiver") + KeyNodeHostIncentivesReceiver = []byte("NodeHostIncentivesReceiver") +) + +// ParamKeyTable ParamTable for module. +func ParamKeyTable() paramtypes.KeyTable { + return paramtypes.NewKeyTable().RegisterParamSet(&Params{}) +} + +// ParamSetPairs Implements params.ParamSet +func (p *Params) ParamSetPairs() paramtypes.ParamSetPairs { + return paramtypes.ParamSetPairs{ + paramtypes.NewParamSetPair(KeyDistributionProportions, &p.DistributionProportions, validateDistributionProportions), + paramtypes.NewParamSetPair( + KeyDeveloperRewardsReceiver, + &p.WeightedDeveloperRewardsReceivers, + validateWeightedAddresses, + ), + paramtypes.NewParamSetPair( + KeyNftIncentivesReceiver, + &p.WeightedNftIncentivesReceivers, + validateWeightedAddresses, + ), + paramtypes.NewParamSetPair( + KeyNodeHostIncentivesReceiver, + &p.WeightedNodeHostsIncentivesReceivers, + validateWeightedAddresses, + ), + } +} + +func validateDistributionProportions(i interface{}) error { + v, ok := i.(DistributionProportions) + if !ok { + return fmt.Errorf("invalid parameter type: %T", i) + } + + if v.StakingRewards.IsNegative() { + return errors.New("staking rewards distribution ratio should not be negative") + } + + if v.NftIncentives.IsNegative() { + return errors.New("NFT incentives distribution ratio should not be negative") + } + + if v.NodeHostsIncentives.IsNegative() { + return errors.New("node hosts incentives distribution ratio should not be negative") + } + + if v.DeveloperRewards.IsNegative() { + return errors.New("developer rewards distribution ratio should not be negative") + } + + if v.CommunityPool.IsNegative() { + return errors.New("community pool distribution ratio should not be negative") + } + + totalProportions := v.StakingRewards.Add(v.NftIncentives).Add(v.NodeHostsIncentives).Add(v.DeveloperRewards).Add(v.CommunityPool) + + if !totalProportions.Equal(sdk.NewDec(1)) { + return errors.New("total distributions ratio should be equal to 100%") + } + + return nil +} + +func validateWeightedAddresses(i interface{}) error { + v, ok := i.([]WeightedAddress) + if !ok { + return fmt.Errorf("invalid parameter type: %T", i) + } + + // fund community pool when rewards address is empty + if len(v) == 0 { + return nil + } + + weightSum := sdk.NewDec(0) + for i, w := range v { + // we allow address to be "" to go to community pool + if w.Address != "" { + _, err := sdk.AccAddressFromBech32(w.Address) + if err != nil { + return fmt.Errorf("invalid address at %dth", i) + } + } + if !w.Weight.IsPositive() { + return fmt.Errorf("non-positive weight at %dth", i) + } + if w.Weight.GT(sdk.NewDec(1)) { + return fmt.Errorf("more than 1 weight at %dth", i) + } + weightSum = weightSum.Add(w.Weight) + } + + if !weightSum.Equal(sdk.NewDec(1)) { + return fmt.Errorf("invalid weight sum: %s", weightSum.String()) + } + + return nil +} diff --git a/x/alloc/types/query.pb.go b/x/alloc/types/query.pb.go index 0957f0b6..6863d8cd 100644 --- a/x/alloc/types/query.pb.go +++ b/x/alloc/types/query.pb.go @@ -1,14 +1,14 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: omniflix/alloc/v1beta1/query.proto +// source: OmniFlix/alloc/v1beta1/query.proto package types import ( context "context" fmt "fmt" - _ "github.com/gogo/protobuf/gogoproto" - grpc1 "github.com/gogo/protobuf/grpc" - proto "github.com/gogo/protobuf/proto" + _ "github.com/cosmos/gogoproto/gogoproto" + grpc1 "github.com/cosmos/gogoproto/grpc" + proto "github.com/cosmos/gogoproto/proto" _ "google.golang.org/genproto/googleapis/api/annotations" grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" @@ -37,7 +37,7 @@ func (m *QueryParamsRequest) Reset() { *m = QueryParamsRequest{} } func (m *QueryParamsRequest) String() string { return proto.CompactTextString(m) } func (*QueryParamsRequest) ProtoMessage() {} func (*QueryParamsRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_0e80840c0c61e377, []int{0} + return fileDescriptor_80cfb0155efe5b8a, []int{0} } func (m *QueryParamsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -76,7 +76,7 @@ func (m *QueryParamsResponse) Reset() { *m = QueryParamsResponse{} } func (m *QueryParamsResponse) String() string { return proto.CompactTextString(m) } func (*QueryParamsResponse) ProtoMessage() {} func (*QueryParamsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_0e80840c0c61e377, []int{1} + return fileDescriptor_80cfb0155efe5b8a, []int{1} } func (m *QueryParamsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -113,18 +113,18 @@ func (m *QueryParamsResponse) GetParams() Params { } func init() { - proto.RegisterType((*QueryParamsRequest)(nil), "omniflix.alloc.v1beta1.QueryParamsRequest") - proto.RegisterType((*QueryParamsResponse)(nil), "omniflix.alloc.v1beta1.QueryParamsResponse") + proto.RegisterType((*QueryParamsRequest)(nil), "OmniFlix.alloc.v1beta1.QueryParamsRequest") + proto.RegisterType((*QueryParamsResponse)(nil), "OmniFlix.alloc.v1beta1.QueryParamsResponse") } func init() { - proto.RegisterFile("omniflix/alloc/v1beta1/query.proto", fileDescriptor_0e80840c0c61e377) + proto.RegisterFile("OmniFlix/alloc/v1beta1/query.proto", fileDescriptor_80cfb0155efe5b8a) } -var fileDescriptor_0e80840c0c61e377 = []byte{ - // 286 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0xca, 0xcf, 0xcd, 0xcb, - 0x4c, 0xcb, 0xc9, 0xac, 0xd0, 0x4f, 0xcc, 0xc9, 0xc9, 0x4f, 0xd6, 0x2f, 0x33, 0x4c, 0x4a, 0x2d, +var fileDescriptor_80cfb0155efe5b8a = []byte{ + // 289 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0xf2, 0xcf, 0xcd, 0xcb, + 0x74, 0xcb, 0xc9, 0xac, 0xd0, 0x4f, 0xcc, 0xc9, 0xc9, 0x4f, 0xd6, 0x2f, 0x33, 0x4c, 0x4a, 0x2d, 0x49, 0x34, 0xd4, 0x2f, 0x2c, 0x4d, 0x2d, 0xaa, 0xd4, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x83, 0xa9, 0xd1, 0x03, 0xab, 0xd1, 0x83, 0xaa, 0x91, 0x12, 0x49, 0xcf, 0x4f, 0xcf, 0x07, 0x2b, 0xd1, 0x07, 0xb1, 0x20, 0xaa, 0xa5, 0x64, 0xd2, 0xf3, 0xf3, 0xd3, 0x73, 0x52, 0xf5, 0x13, 0x0b, @@ -135,12 +135,13 @@ var fileDescriptor_0e80840c0c61e377 = []byte{ 0xd4, 0xe0, 0x36, 0x92, 0xd3, 0xc3, 0xee, 0x5c, 0x3d, 0x88, 0x3e, 0x27, 0x96, 0x13, 0xf7, 0xe4, 0x19, 0x82, 0xa0, 0x7a, 0x8c, 0x26, 0x33, 0x72, 0xb1, 0x82, 0x4d, 0x15, 0xea, 0x64, 0xe4, 0x62, 0x83, 0x28, 0x11, 0xd2, 0xc2, 0x65, 0x04, 0xa6, 0xab, 0xa4, 0xb4, 0x89, 0x52, 0x0b, 0x71, 0xab, - 0x92, 0x5a, 0xd3, 0xe5, 0x27, 0x93, 0x99, 0x14, 0x84, 0xe4, 0xf4, 0xf1, 0x06, 0x83, 0x93, 0xfb, - 0x89, 0x47, 0x72, 0x8c, 0x17, 0x1e, 0xc9, 0x31, 0x3e, 0x78, 0x24, 0xc7, 0x38, 0xe1, 0xb1, 0x1c, - 0xc3, 0x85, 0xc7, 0x72, 0x0c, 0x37, 0x1e, 0xcb, 0x31, 0x44, 0xe9, 0xa6, 0x67, 0x96, 0x64, 0x94, - 0x26, 0xe9, 0x25, 0xe7, 0xe7, 0xea, 0xfb, 0xe7, 0xe6, 0x65, 0xba, 0x81, 0xcc, 0x80, 0x19, 0x96, - 0x51, 0x9a, 0xa4, 0x0f, 0x33, 0xb1, 0xa4, 0xb2, 0x20, 0xb5, 0x38, 0x89, 0x0d, 0x1c, 0xa0, 0xc6, - 0x80, 0x00, 0x00, 0x00, 0xff, 0xff, 0x71, 0x99, 0x7b, 0x69, 0xe7, 0x01, 0x00, 0x00, + 0x92, 0x5a, 0xd3, 0xe5, 0x27, 0x93, 0x99, 0x14, 0x84, 0xe4, 0xf4, 0xf3, 0x73, 0xf3, 0x32, 0xd3, + 0x70, 0x05, 0x83, 0x93, 0xd7, 0x89, 0x47, 0x72, 0x8c, 0x17, 0x1e, 0xc9, 0x31, 0x3e, 0x78, 0x24, + 0xc7, 0x38, 0xe1, 0xb1, 0x1c, 0xc3, 0x85, 0xc7, 0x72, 0x0c, 0x37, 0x1e, 0xcb, 0x31, 0x44, 0x19, + 0xa4, 0x67, 0x96, 0x64, 0x94, 0x26, 0xe9, 0x25, 0xe7, 0xe7, 0xea, 0xc3, 0x83, 0x12, 0x66, 0x58, + 0x46, 0x69, 0x92, 0x7e, 0x99, 0x91, 0x3e, 0xcc, 0xd0, 0x92, 0xca, 0x82, 0xd4, 0xe2, 0x24, 0x36, + 0x70, 0x98, 0x1a, 0x03, 0x02, 0x00, 0x00, 0xff, 0xff, 0xf5, 0xb4, 0xb1, 0x84, 0xea, 0x01, 0x00, + 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -168,7 +169,7 @@ func NewQueryClient(cc grpc1.ClientConn) QueryClient { func (c *queryClient) Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) { out := new(QueryParamsResponse) - err := c.cc.Invoke(ctx, "/omniflix.alloc.v1beta1.Query/Params", in, out, opts...) + err := c.cc.Invoke(ctx, "/OmniFlix.alloc.v1beta1.Query/Params", in, out, opts...) if err != nil { return nil, err } @@ -202,7 +203,7 @@ func _Query_Params_Handler(srv interface{}, ctx context.Context, dec func(interf } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: "/omniflix.alloc.v1beta1.Query/Params", + FullMethod: "/OmniFlix.alloc.v1beta1.Query/Params", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Params(ctx, req.(*QueryParamsRequest)) @@ -211,7 +212,7 @@ func _Query_Params_Handler(srv interface{}, ctx context.Context, dec func(interf } var _Query_serviceDesc = grpc.ServiceDesc{ - ServiceName: "omniflix.alloc.v1beta1.Query", + ServiceName: "OmniFlix.alloc.v1beta1.Query", HandlerType: (*QueryServer)(nil), Methods: []grpc.MethodDesc{ { @@ -220,7 +221,7 @@ var _Query_serviceDesc = grpc.ServiceDesc{ }, }, Streams: []grpc.StreamDesc{}, - Metadata: "omniflix/alloc/v1beta1/query.proto", + Metadata: "OmniFlix/alloc/v1beta1/query.proto", } func (m *QueryParamsRequest) Marshal() (dAtA []byte, err error) { diff --git a/x/alloc/types/query.pb.gw.go b/x/alloc/types/query.pb.gw.go index 29c862ae..fff33f8e 100644 --- a/x/alloc/types/query.pb.gw.go +++ b/x/alloc/types/query.pb.gw.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-grpc-gateway. DO NOT EDIT. -// source: omniflix/alloc/v1beta1/query.proto +// source: OmniFlix/alloc/v1beta1/query.proto /* Package types is a reverse proxy. @@ -145,7 +145,7 @@ func RegisterQueryHandlerClient(ctx context.Context, mux *runtime.ServeMux, clie } var ( - pattern_Query_Params_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"omniflix", "alloc", "v1beta1", "params"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_Params_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"omniflix", "alloc", "v1beta1", "params"}, "", runtime.AssumeColonVerbOpt(false))) ) var ( diff --git a/x/alloc/types/tx.pb.go b/x/alloc/types/tx.pb.go index 88369c78..a04ee8b0 100644 --- a/x/alloc/types/tx.pb.go +++ b/x/alloc/types/tx.pb.go @@ -1,15 +1,22 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: omniflix/alloc/v1beta1/tx.proto +// source: OmniFlix/alloc/v1beta1/tx.proto package types import ( context "context" fmt "fmt" - grpc1 "github.com/gogo/protobuf/grpc" - proto "github.com/gogo/protobuf/proto" + _ "github.com/cosmos/cosmos-proto" + _ "github.com/cosmos/cosmos-sdk/types/msgservice" + _ "github.com/cosmos/gogoproto/gogoproto" + grpc1 "github.com/cosmos/gogoproto/grpc" + proto "github.com/cosmos/gogoproto/proto" grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" + io "io" math "math" + math_bits "math/bits" ) // Reference imports to suppress errors if they are not otherwise used. @@ -23,19 +30,135 @@ var _ = math.Inf // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package -func init() { proto.RegisterFile("omniflix/alloc/v1beta1/tx.proto", fileDescriptor_83cb2d7efbfd690f) } +// MsgUpdateParams is the Msg/UpdateParams request type. +// +// Since: cosmos-sdk 0.47 +type MsgUpdateParams struct { + // authority is the address of the governance account. + Authority string `protobuf:"bytes,1,opt,name=authority,proto3" json:"authority,omitempty"` + // params defines the x/alloc parameters to update. + // + // NOTE: All parameters must be supplied. + Params Params `protobuf:"bytes,2,opt,name=params,proto3" json:"params"` +} + +func (m *MsgUpdateParams) Reset() { *m = MsgUpdateParams{} } +func (m *MsgUpdateParams) String() string { return proto.CompactTextString(m) } +func (*MsgUpdateParams) ProtoMessage() {} +func (*MsgUpdateParams) Descriptor() ([]byte, []int) { + return fileDescriptor_f92938753a42b42e, []int{0} +} +func (m *MsgUpdateParams) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *MsgUpdateParams) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_MsgUpdateParams.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 *MsgUpdateParams) XXX_Merge(src proto.Message) { + xxx_messageInfo_MsgUpdateParams.Merge(m, src) +} +func (m *MsgUpdateParams) XXX_Size() int { + return m.Size() +} +func (m *MsgUpdateParams) XXX_DiscardUnknown() { + xxx_messageInfo_MsgUpdateParams.DiscardUnknown(m) +} + +var xxx_messageInfo_MsgUpdateParams proto.InternalMessageInfo + +func (m *MsgUpdateParams) GetAuthority() string { + if m != nil { + return m.Authority + } + return "" +} -var fileDescriptor_83cb2d7efbfd690f = []byte{ - // 140 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0xcf, 0xcf, 0xcd, 0xcb, - 0x4c, 0xcb, 0xc9, 0xac, 0xd0, 0x4f, 0xcc, 0xc9, 0xc9, 0x4f, 0xd6, 0x2f, 0x33, 0x4c, 0x4a, 0x2d, +func (m *MsgUpdateParams) GetParams() Params { + if m != nil { + return m.Params + } + return Params{} +} + +// MsgUpdateParamsResponse defines the response structure for executing a +// MsgUpdateParams message. +// +// Since: cosmos-sdk 0.47 +type MsgUpdateParamsResponse struct { +} + +func (m *MsgUpdateParamsResponse) Reset() { *m = MsgUpdateParamsResponse{} } +func (m *MsgUpdateParamsResponse) String() string { return proto.CompactTextString(m) } +func (*MsgUpdateParamsResponse) ProtoMessage() {} +func (*MsgUpdateParamsResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_f92938753a42b42e, []int{1} +} +func (m *MsgUpdateParamsResponse) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *MsgUpdateParamsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_MsgUpdateParamsResponse.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 *MsgUpdateParamsResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_MsgUpdateParamsResponse.Merge(m, src) +} +func (m *MsgUpdateParamsResponse) XXX_Size() int { + return m.Size() +} +func (m *MsgUpdateParamsResponse) XXX_DiscardUnknown() { + xxx_messageInfo_MsgUpdateParamsResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_MsgUpdateParamsResponse proto.InternalMessageInfo + +func init() { + proto.RegisterType((*MsgUpdateParams)(nil), "OmniFlix.alloc.v1beta1.MsgUpdateParams") + proto.RegisterType((*MsgUpdateParamsResponse)(nil), "OmniFlix.alloc.v1beta1.MsgUpdateParamsResponse") +} + +func init() { proto.RegisterFile("OmniFlix/alloc/v1beta1/tx.proto", fileDescriptor_f92938753a42b42e) } + +var fileDescriptor_f92938753a42b42e = []byte{ + // 329 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0xf7, 0xcf, 0xcd, 0xcb, + 0x74, 0xcb, 0xc9, 0xac, 0xd0, 0x4f, 0xcc, 0xc9, 0xc9, 0x4f, 0xd6, 0x2f, 0x33, 0x4c, 0x4a, 0x2d, 0x49, 0x34, 0xd4, 0x2f, 0xa9, 0xd0, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x83, 0x29, 0xd0, - 0x03, 0x2b, 0xd0, 0x83, 0x2a, 0x30, 0x62, 0xe5, 0x62, 0xf6, 0x2d, 0x4e, 0x77, 0x72, 0x3f, 0xf1, - 0x48, 0x8e, 0xf1, 0xc2, 0x23, 0x39, 0xc6, 0x07, 0x8f, 0xe4, 0x18, 0x27, 0x3c, 0x96, 0x63, 0xb8, - 0xf0, 0x58, 0x8e, 0xe1, 0xc6, 0x63, 0x39, 0x86, 0x28, 0xdd, 0xf4, 0xcc, 0x92, 0x8c, 0xd2, 0x24, - 0xbd, 0xe4, 0xfc, 0x5c, 0x7d, 0xff, 0xdc, 0xbc, 0x4c, 0x37, 0x90, 0x25, 0x30, 0xc3, 0x32, 0x4a, - 0x93, 0xf4, 0x61, 0x56, 0x96, 0x54, 0x16, 0xa4, 0x16, 0x27, 0xb1, 0x81, 0xad, 0x33, 0x06, 0x04, - 0x00, 0x00, 0xff, 0xff, 0xd9, 0x29, 0x10, 0x3c, 0x91, 0x00, 0x00, 0x00, + 0x03, 0x2b, 0xd0, 0x83, 0x2a, 0x90, 0x12, 0x4f, 0xce, 0x2f, 0xce, 0xcd, 0x2f, 0xd6, 0xcf, 0x2d, + 0x4e, 0xd7, 0x2f, 0x33, 0x04, 0x51, 0x10, 0x0d, 0x52, 0xca, 0x38, 0x4c, 0x2c, 0x48, 0x2c, 0x4a, + 0xcc, 0x2d, 0x86, 0x2a, 0x12, 0x49, 0xcf, 0x4f, 0xcf, 0x07, 0x33, 0xf5, 0x41, 0x2c, 0xa8, 0xa8, + 0x24, 0xc4, 0xcc, 0x78, 0x88, 0x04, 0x84, 0x03, 0x91, 0x52, 0x9a, 0xce, 0xc8, 0xc5, 0xef, 0x5b, + 0x9c, 0x1e, 0x5a, 0x90, 0x92, 0x58, 0x92, 0x1a, 0x00, 0x36, 0x4a, 0xc8, 0x8c, 0x8b, 0x33, 0xb1, + 0xb4, 0x24, 0x23, 0xbf, 0x28, 0xb3, 0xa4, 0x52, 0x82, 0x51, 0x81, 0x51, 0x83, 0xd3, 0x49, 0xe2, + 0xd2, 0x16, 0x5d, 0x11, 0xa8, 0x46, 0xc7, 0x94, 0x94, 0xa2, 0xd4, 0xe2, 0xe2, 0xe0, 0x92, 0xa2, + 0xcc, 0xbc, 0xf4, 0x20, 0x84, 0x52, 0x21, 0x1b, 0x2e, 0x36, 0x88, 0x63, 0x24, 0x98, 0x14, 0x18, + 0x35, 0xb8, 0x8d, 0xe4, 0xf4, 0xb0, 0xfb, 0x51, 0x0f, 0x62, 0x8f, 0x13, 0xcb, 0x89, 0x7b, 0xf2, + 0x0c, 0x41, 0x50, 0x3d, 0x56, 0x7c, 0x4d, 0xcf, 0x37, 0x68, 0x21, 0x4c, 0x53, 0x92, 0xe4, 0x12, + 0x47, 0x73, 0x58, 0x50, 0x6a, 0x71, 0x41, 0x7e, 0x5e, 0x71, 0xaa, 0x51, 0x3e, 0x17, 0xb3, 0x6f, + 0x71, 0xba, 0x50, 0x06, 0x17, 0x0f, 0x8a, 0xbb, 0xd5, 0x71, 0xd9, 0x87, 0x66, 0x8e, 0x94, 0x3e, + 0x91, 0x0a, 0x61, 0x16, 0x3a, 0x79, 0x9d, 0x78, 0x24, 0xc7, 0x78, 0xe1, 0x91, 0x1c, 0xe3, 0x83, + 0x47, 0x72, 0x8c, 0x13, 0x1e, 0xcb, 0x31, 0x5c, 0x78, 0x2c, 0xc7, 0x70, 0xe3, 0xb1, 0x1c, 0x43, + 0x94, 0x41, 0x7a, 0x66, 0x49, 0x46, 0x69, 0x92, 0x5e, 0x72, 0x7e, 0xae, 0x3e, 0x3c, 0x82, 0xf2, + 0x73, 0xf3, 0x32, 0xd3, 0x72, 0x32, 0x2b, 0x32, 0x4a, 0x93, 0xf4, 0xcb, 0x8c, 0xf4, 0x61, 0x31, + 0x56, 0x52, 0x59, 0x90, 0x5a, 0x9c, 0xc4, 0x06, 0x0e, 0x78, 0x63, 0x40, 0x00, 0x00, 0x00, 0xff, + 0xff, 0x36, 0x6e, 0xf5, 0x3a, 0x22, 0x02, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -50,6 +173,11 @@ 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 { + // UpdateParams defines a governance operation for updating the x/alloc module + // parameters. The authority is hard-coded to the x/gov module account. + // + // Since: cosmos-sdk 0.47 + UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) } type msgClient struct { @@ -60,22 +188,417 @@ func NewMsgClient(cc grpc1.ClientConn) MsgClient { return &msgClient{cc} } +func (c *msgClient) UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) { + out := new(MsgUpdateParamsResponse) + err := c.cc.Invoke(ctx, "/OmniFlix.alloc.v1beta1.Msg/UpdateParams", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + // MsgServer is the server API for Msg service. type MsgServer interface { + // UpdateParams defines a governance operation for updating the x/alloc module + // parameters. The authority is hard-coded to the x/gov module account. + // + // Since: cosmos-sdk 0.47 + UpdateParams(context.Context, *MsgUpdateParams) (*MsgUpdateParamsResponse, error) } // UnimplementedMsgServer can be embedded to have forward compatible implementations. type UnimplementedMsgServer struct { } +func (*UnimplementedMsgServer) UpdateParams(ctx context.Context, req *MsgUpdateParams) (*MsgUpdateParamsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method UpdateParams not implemented") +} + func RegisterMsgServer(s grpc1.Server, srv MsgServer) { s.RegisterService(&_Msg_serviceDesc, srv) } +func _Msg_UpdateParams_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgUpdateParams) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).UpdateParams(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/OmniFlix.alloc.v1beta1.Msg/UpdateParams", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).UpdateParams(ctx, req.(*MsgUpdateParams)) + } + return interceptor(ctx, in, info, handler) +} + var _Msg_serviceDesc = grpc.ServiceDesc{ - ServiceName: "omniflix.alloc.v1beta1.Msg", + ServiceName: "OmniFlix.alloc.v1beta1.Msg", HandlerType: (*MsgServer)(nil), - Methods: []grpc.MethodDesc{}, - Streams: []grpc.StreamDesc{}, - Metadata: "omniflix/alloc/v1beta1/tx.proto", + Methods: []grpc.MethodDesc{ + { + MethodName: "UpdateParams", + Handler: _Msg_UpdateParams_Handler, + }, + }, + Streams: []grpc.StreamDesc{}, + Metadata: "OmniFlix/alloc/v1beta1/tx.proto", +} + +func (m *MsgUpdateParams) 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 *MsgUpdateParams) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *MsgUpdateParams) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + { + size, err := m.Params.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintTx(dAtA, i, uint64(size)) + } + 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 *MsgUpdateParamsResponse) 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 *MsgUpdateParamsResponse) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *MsgUpdateParamsResponse) 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 + for v >= 1<<7 { + dAtA[offset] = uint8(v&0x7f | 0x80) + v >>= 7 + offset++ + } + dAtA[offset] = uint8(v) + return base +} +func (m *MsgUpdateParams) 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 = m.Params.Size() + n += 1 + l + sovTx(uint64(l)) + return n +} + +func (m *MsgUpdateParamsResponse) 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 +} +func sozTx(x uint64) (n int) { + return sovTx(uint64((x << 1) ^ uint64((int64(x) >> 63)))) +} +func (m *MsgUpdateParams) 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: MsgUpdateParams: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: MsgUpdateParams: 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 Params", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Params.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 *MsgUpdateParamsResponse) 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: MsgUpdateParamsResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: MsgUpdateParamsResponse: 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 skipTx(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, ErrIntOverflowTx + } + 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, ErrIntOverflowTx + } + 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, ErrIntOverflowTx + } + 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, ErrInvalidLengthTx + } + iNdEx += length + case 3: + depth++ + case 4: + if depth == 0 { + return 0, ErrUnexpectedEndOfGroupTx + } + depth-- + case 5: + iNdEx += 4 + default: + return 0, fmt.Errorf("proto: illegal wireType %d", wireType) + } + if iNdEx < 0 { + return 0, ErrInvalidLengthTx + } + if depth == 0 { + return iNdEx, nil + } + } + return 0, io.ErrUnexpectedEOF +} + +var ( + ErrInvalidLengthTx = fmt.Errorf("proto: negative length found during unmarshaling") + ErrIntOverflowTx = fmt.Errorf("proto: integer overflow") + ErrUnexpectedEndOfGroupTx = fmt.Errorf("proto: unexpected end of group") +) diff --git a/x/itc/abci.go b/x/itc/abci.go index dd8d2e78..47b4e673 100644 --- a/x/itc/abci.go +++ b/x/itc/abci.go @@ -1,9 +1,9 @@ package itc import ( - "github.com/OmniFlix/omniflixhub/x/itc/keeper" + "github.com/OmniFlix/omniflixhub/v2/x/itc/keeper" + abcitypes "github.com/cometbft/cometbft/abci/types" sdk "github.com/cosmos/cosmos-sdk/types" - abcitypes "github.com/tendermint/tendermint/abci/types" ) func EndBlock(ctx sdk.Context, k keeper.Keeper) []abcitypes.ValidatorUpdate { diff --git a/x/itc/client/cli/flags.go b/x/itc/client/cli/flags.go index 8d9e3361..d9283a63 100644 --- a/x/itc/client/cli/flags.go +++ b/x/itc/client/cli/flags.go @@ -4,7 +4,6 @@ import ( flag "github.com/spf13/pflag" ) -// nolint:all const ( FlagNftDenomId = "nft-denom-id" FlagNftId = "nft-id" diff --git a/x/itc/client/cli/query.go b/x/itc/client/cli/query.go index 30141120..36cdc887 100644 --- a/x/itc/client/cli/query.go +++ b/x/itc/client/cli/query.go @@ -11,7 +11,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/version" - "github.com/OmniFlix/omniflixhub/x/itc/types" + "github.com/OmniFlix/omniflixhub/v2/x/itc/types" "github.com/spf13/cobra" ) diff --git a/x/itc/client/cli/tx.go b/x/itc/client/cli/tx.go index de82c8ac..84af184d 100644 --- a/x/itc/client/cli/tx.go +++ b/x/itc/client/cli/tx.go @@ -4,7 +4,7 @@ import ( "fmt" "strconv" - "github.com/OmniFlix/omniflixhub/x/itc/types" + "github.com/OmniFlix/omniflixhub/v2/x/itc/types" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cosmos/cosmos-sdk/client/tx" diff --git a/x/itc/client/cli/utils.go b/x/itc/client/cli/utils.go index 3fb0353b..72a92eac 100644 --- a/x/itc/client/cli/utils.go +++ b/x/itc/client/cli/utils.go @@ -7,7 +7,7 @@ import ( "strings" "time" - "github.com/OmniFlix/omniflixhub/x/itc/types" + "github.com/OmniFlix/omniflixhub/v2/x/itc/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/spf13/pflag" ) diff --git a/x/itc/exported/itc.go b/x/itc/exported/itc.go index 0d5d9280..0aed4a7e 100644 --- a/x/itc/exported/itc.go +++ b/x/itc/exported/itc.go @@ -3,6 +3,8 @@ package exported import ( "time" + paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" + sdk "github.com/cosmos/cosmos-sdk/types" ) @@ -31,3 +33,15 @@ type ClaimI interface { GetNftId() string GetInteractionType() string } + +type ( + ParamSet = paramtypes.ParamSet + + // Subspace defines an interface that implements the legacy x/params Subspace + // type. + // + // NOTE: This is used solely for migration of x/params managed parameters. + Subspace interface { + GetParamSet(ctx sdk.Context, ps ParamSet) + } +) diff --git a/x/itc/genesis.go b/x/itc/genesis.go index 91950c10..7c27ac3d 100644 --- a/x/itc/genesis.go +++ b/x/itc/genesis.go @@ -3,8 +3,8 @@ package itc import ( "fmt" - "github.com/OmniFlix/omniflixhub/x/itc/keeper" - "github.com/OmniFlix/omniflixhub/x/itc/types" + "github.com/OmniFlix/omniflixhub/v2/x/itc/keeper" + "github.com/OmniFlix/omniflixhub/v2/x/itc/types" sdk "github.com/cosmos/cosmos-sdk/types" ) @@ -18,7 +18,10 @@ func InitGenesis(ctx sdk.Context, k keeper.Keeper, genState types.GenesisState) k.SetCampaignWithCreator(ctx, c.GetCreator(), c.GetId()) } k.SetNextCampaignNumber(ctx, genState.NextCampaignNumber) - k.SetParams(ctx, genState.Params) + err := k.SetParams(ctx, genState.Params) + if err != nil { + panic(err) + } for _, cc := range genState.Claims { k.SetClaim(ctx, cc) diff --git a/x/itc/handler.go b/x/itc/handler.go deleted file mode 100644 index b971158c..00000000 --- a/x/itc/handler.go +++ /dev/null @@ -1,39 +0,0 @@ -package itc - -import ( - "fmt" - - "github.com/OmniFlix/omniflixhub/x/itc/keeper" - "github.com/OmniFlix/omniflixhub/x/itc/types" - - sdk "github.com/cosmos/cosmos-sdk/types" - sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" -) - -// NewHandler ... -func NewHandler(k keeper.Keeper) sdk.Handler { - msgServer := keeper.NewMsgServerImpl(k) - - return func(ctx sdk.Context, msg sdk.Msg) (*sdk.Result, error) { - ctx = ctx.WithEventManager(sdk.NewEventManager()) - - switch msg := msg.(type) { - case *types.MsgCreateCampaign: - res, err := msgServer.CreateCampaign(sdk.WrapSDKContext(ctx), msg) - return sdk.WrapServiceResult(ctx, res, err) - case *types.MsgCancelCampaign: - res, err := msgServer.CancelCampaign(sdk.WrapSDKContext(ctx), msg) - return sdk.WrapServiceResult(ctx, res, err) - case *types.MsgDepositCampaign: - res, err := msgServer.DepositCampaign(sdk.WrapSDKContext(ctx), msg) - return sdk.WrapServiceResult(ctx, res, err) - case *types.MsgClaim: - res, err := msgServer.Claim(sdk.WrapSDKContext(ctx), msg) - return sdk.WrapServiceResult(ctx, res, err) - - default: - errMsg := fmt.Sprintf("unrecognized %s message type: %T", types.ModuleName, msg) - return nil, sdkerrors.Wrap(sdkerrors.ErrUnknownRequest, errMsg) - } - } -} diff --git a/x/itc/keeper/campaign.go b/x/itc/keeper/campaign.go index 048582bc..6b6b4a8b 100644 --- a/x/itc/keeper/campaign.go +++ b/x/itc/keeper/campaign.go @@ -4,7 +4,9 @@ import ( "crypto/sha256" "fmt" - "github.com/OmniFlix/omniflixhub/x/itc/types" + errorsmod "cosmossdk.io/errors" + + "github.com/OmniFlix/omniflixhub/v2/x/itc/types" nfttypes "github.com/OmniFlix/onft/types" streampaytypes "github.com/OmniFlix/streampay/v2/x/streampay/types" sdk "github.com/cosmos/cosmos-sdk/types" @@ -41,7 +43,7 @@ func (k Keeper) CreateCampaign( } // Authorize if mintCollection.Creator != campaign.Creator { - return sdkerrors.Wrapf( + return errorsmod.Wrapf( sdkerrors.ErrUnauthorized, "nft mint denom id %s isn't owned by campaign creator %s", mintCollection.Id, @@ -70,10 +72,10 @@ func (k Keeper) CreateCampaign( func (k Keeper) CancelCampaign(ctx sdk.Context, campaignId uint64, creator sdk.AccAddress) error { campaign, found := k.GetCampaign(ctx, campaignId) if !found { - return sdkerrors.Wrapf(types.ErrCampaignDoesNotExists, "campaign %d not exists", campaignId) + return errorsmod.Wrapf(types.ErrCampaignDoesNotExists, "campaign %d not exists", campaignId) } if creator.String() != campaign.Creator { - return sdkerrors.Wrapf(sdkerrors.ErrUnauthorized, "unauthorized address %s", creator.String()) + return errorsmod.Wrapf(sdkerrors.ErrUnauthorized, "unauthorized address %s", creator.String()) } // return funds @@ -116,11 +118,11 @@ func (k Keeper) Claim(ctx sdk.Context, campaign types.Campaign, claimer sdk.AccA } // check if claim exists with given nft if k.HasClaim(ctx, campaign.GetId(), nft.GetID()) { - return sdkerrors.Wrapf(types.ErrClaimExists, + return errorsmod.Wrapf(types.ErrClaimExists, "claim exists with given nft %s", nft.GetID()) } if (campaign.MaxAllowedClaims - campaign.ClaimCount) <= 0 { - return sdkerrors.Wrapf(types.ErrClaimNotAllowed, + return errorsmod.Wrapf(types.ErrClaimNotAllowed, "max allowed claims reached for this campaign (campaign: %d, maxAllowedClaims: %d).", campaign.GetId(), campaign.GetMaxAllowedClaims(), @@ -129,14 +131,14 @@ func (k Keeper) Claim(ctx sdk.Context, campaign types.Campaign, claimer sdk.AccA if campaign.ClaimType == types.CLAIM_TYPE_FT || campaign.ClaimType == types.CLAIM_TYPE_FT_AND_NFT { if campaign.AvailableTokens.IsLT(campaign.TokensPerClaim) { - return sdkerrors.Wrapf(sdkerrors.ErrInsufficientFunds, + return errorsmod.Wrapf(sdkerrors.ErrInsufficientFunds, "insufficient available tokens, available tokens %s", campaign.AvailableTokens.String(), ) } } if !claimer.Equals(nft.GetOwner()) { - return sdkerrors.Wrapf(sdkerrors.ErrUnauthorized, + return errorsmod.Wrapf(sdkerrors.ErrUnauthorized, "nft %s isn't owned by address %s", claim.NftId, claimer.String()) } @@ -210,7 +212,7 @@ func (k Keeper) Claim(ctx sdk.Context, campaign types.Campaign, claimer sdk.AccA campaign.GetCreator(), claimer, ); err != nil { - return sdkerrors.Wrapf(types.ErrClaimingNFT, + return errorsmod.Wrapf(types.ErrClaimingNFT, "unable to mint nft denomId %s", campaign.NftMintDetails.DenomId) } } @@ -230,10 +232,10 @@ func (k Keeper) Claim(ctx sdk.Context, campaign types.Campaign, claimer sdk.AccA func (k Keeper) DepositCampaign(ctx sdk.Context, campaignId uint64, depositor sdk.AccAddress, amount sdk.Coin) error { campaign, found := k.GetCampaign(ctx, campaignId) if !found { - return sdkerrors.Wrapf(types.ErrCampaignDoesNotExists, "campaign id %d not exists", campaignId) + return errorsmod.Wrapf(types.ErrCampaignDoesNotExists, "campaign id %d not exists", campaignId) } if depositor.String() != campaign.Creator { - return sdkerrors.Wrapf(types.ErrDepositNotAllowed, "deposit not allowed from address %s"+ + return errorsmod.Wrapf(types.ErrDepositNotAllowed, "deposit not allowed from address %s"+ "only creator of the campaign is allowed to deposit", depositor.String()) } // Transfer tokens from depositor to module account diff --git a/x/itc/keeper/events.go b/x/itc/keeper/events.go index 06ddf8fd..e38d0166 100644 --- a/x/itc/keeper/events.go +++ b/x/itc/keeper/events.go @@ -4,7 +4,7 @@ import ( "fmt" "time" - "github.com/OmniFlix/omniflixhub/x/itc/types" + "github.com/OmniFlix/omniflixhub/v2/x/itc/types" sdk "github.com/cosmos/cosmos-sdk/types" ) diff --git a/x/itc/keeper/grpc_query.go b/x/itc/keeper/grpc_query.go index 9f6efe63..ab39b86d 100644 --- a/x/itc/keeper/grpc_query.go +++ b/x/itc/keeper/grpc_query.go @@ -9,7 +9,7 @@ import ( "google.golang.org/grpc/codes" "google.golang.org/grpc/status" - "github.com/OmniFlix/omniflixhub/x/itc/types" + "github.com/OmniFlix/omniflixhub/v2/x/itc/types" sdk "github.com/cosmos/cosmos-sdk/types" ) @@ -18,8 +18,7 @@ var _ types.QueryServer = Keeper{} // Params returns params of the itc module. func (k Keeper) Params(c context.Context, _ *types.QueryParamsRequest) (*types.QueryParamsResponse, error) { ctx := sdk.UnwrapSDKContext(c) - var params types.Params - k.paramSpace.GetParamSet(ctx, ¶ms) + params := k.GetParams(ctx) return &types.QueryParamsResponse{Params: params}, nil } diff --git a/x/itc/keeper/itc.go b/x/itc/keeper/itc.go index 3b0b0fc9..eabfec0e 100644 --- a/x/itc/keeper/itc.go +++ b/x/itc/keeper/itc.go @@ -3,10 +3,10 @@ package keeper import ( "fmt" - "github.com/OmniFlix/omniflixhub/x/itc/types" + "github.com/OmniFlix/omniflixhub/v2/x/itc/types" "github.com/cosmos/cosmos-sdk/store/prefix" sdk "github.com/cosmos/cosmos-sdk/types" - gogotypes "github.com/gogo/protobuf/types" + gogotypes "github.com/cosmos/gogoproto/types" ) // GetNextCampaignNumber get the next campaign number diff --git a/x/itc/keeper/keeper.go b/x/itc/keeper/keeper.go index d90aa423..98daac6f 100644 --- a/x/itc/keeper/keeper.go +++ b/x/itc/keeper/keeper.go @@ -3,48 +3,47 @@ package keeper import ( "fmt" - "github.com/tendermint/tendermint/libs/log" + storetypes "github.com/cosmos/cosmos-sdk/store/types" - "github.com/OmniFlix/omniflixhub/x/itc/types" + "github.com/cometbft/cometbft/libs/log" + + "github.com/OmniFlix/omniflixhub/v2/x/itc/types" "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" - paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" ) type ( Keeper struct { cdc codec.Codec - storeKey sdk.StoreKey + storeKey storetypes.StoreKey accountKeeper types.AccountKeeper bankKeeper types.BankKeeper nftKeeper types.NftKeeper streampayKeeper types.StreamPayKeeper distributionKeeper types.DistributionKeeper - paramSpace paramtypes.Subspace + + // the address capable of executing a MsgUpdateParams message. Typically, this + // should be the x/gov module account. + authority string } ) func NewKeeper( cdc codec.Codec, - storeKey sdk.StoreKey, + storeKey storetypes.StoreKey, accountKeeper types.AccountKeeper, bankKeeper types.BankKeeper, nftKeeper types.NftKeeper, streampayKeeper types.StreamPayKeeper, distributionKeeper types.DistributionKeeper, - ps paramtypes.Subspace, + authority string, ) Keeper { // ensure itc module account is set if addr := accountKeeper.GetModuleAddress(types.ModuleName); addr == nil { panic(fmt.Sprintf("%s module account has not been set", types.ModuleName)) } - // set KeyTable if it has not already been set - if !ps.HasKeyTable() { - ps = ps.WithKeyTable(types.ParamKeyTable()) - } - return Keeper{ cdc: cdc, storeKey: storeKey, @@ -53,10 +52,15 @@ func NewKeeper( nftKeeper: nftKeeper, streampayKeeper: streampayKeeper, distributionKeeper: distributionKeeper, - paramSpace: ps, + authority: authority, } } +// GetAuthority returns the x/itc module's authority. +func (k Keeper) GetAuthority() string { + return k.authority +} + func (k Keeper) Logger(ctx sdk.Context) log.Logger { return ctx.Logger().With("module", fmt.Sprintf("x/%s", types.ModuleName)) } diff --git a/x/itc/keeper/keeper_test.go b/x/itc/keeper/keeper_test.go index 12a73bf3..4bbd0435 100644 --- a/x/itc/keeper/keeper_test.go +++ b/x/itc/keeper/keeper_test.go @@ -8,9 +8,9 @@ import ( onftkeeper "github.com/OmniFlix/onft/keeper" onfttypes "github.com/OmniFlix/onft/types" - "github.com/OmniFlix/omniflixhub/app/apptesting" - "github.com/OmniFlix/omniflixhub/x/itc/keeper" - "github.com/OmniFlix/omniflixhub/x/itc/types" + "github.com/OmniFlix/omniflixhub/v2/app/apptesting" + "github.com/OmniFlix/omniflixhub/v2/x/itc/keeper" + "github.com/OmniFlix/omniflixhub/v2/x/itc/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/stretchr/testify/suite" ) @@ -316,3 +316,54 @@ func (suite *KeeperTestSuite) TestHasCampaign() { suite.Require().False(keeper.HasCampaign(sdkCtx, 1)) suite.Require().False(keeper.HasCampaign(sdkCtx, 2)) } + +func (suite *KeeperTestSuite) TestParams() { + testCases := []struct { + name string + input types.Params + expectErr bool + }{ + { + name: "set invalid max campaign duration", + input: types.Params{ + MaxCampaignDuration: -1, + CreationFee: types.DefaultCampaignCreationFee, + }, + expectErr: true, + }, + { + name: "set invalid creation fee", + input: types.Params{ + MaxCampaignDuration: types.DefaultMaxCampaignDuration, + CreationFee: sdk.Coin{}, + }, + expectErr: true, + }, + { + name: "set full valid params", + input: types.Params{ + CreationFee: types.DefaultCampaignCreationFee, + MaxCampaignDuration: types.DefaultMaxCampaignDuration, + }, + expectErr: false, + }, + } + + for _, tc := range testCases { + tc := tc + + suite.Run(tc.name, func() { + expected := suite.App.ItcKeeper.GetParams(suite.Ctx) + err := suite.App.ItcKeeper.SetParams(suite.Ctx, tc.input) + if tc.expectErr { + suite.Require().Error(err) + } else { + expected = tc.input + suite.Require().NoError(err) + } + + p := suite.App.ItcKeeper.GetParams(suite.Ctx) + suite.Require().Equal(expected, p) + }) + } +} diff --git a/x/itc/keeper/migrator.go b/x/itc/keeper/migrator.go new file mode 100644 index 00000000..e0122db5 --- /dev/null +++ b/x/itc/keeper/migrator.go @@ -0,0 +1,28 @@ +package keeper + +import ( + "github.com/OmniFlix/omniflixhub/v2/x/itc/exported" + v2 "github.com/OmniFlix/omniflixhub/v2/x/itc/migrations/v2" + sdk "github.com/cosmos/cosmos-sdk/types" +) + +// Migrator is a struct for handling in-place state migrations. +type Migrator struct { + keeper Keeper + legacySubspace exported.Subspace +} + +func NewMigrator(k Keeper, ss exported.Subspace) Migrator { + return Migrator{ + keeper: k, + legacySubspace: ss, + } +} + +// Migrate1to2 migrates the x/itc module state from the consensus version 1 to +// version 2. Specifically, it takes the parameters that are currently stored +// and managed by the x/params modules and stores them directly into the x/itc +// module state. +func (m Migrator) Migrate1to2(ctx sdk.Context) error { + return v2.Migrate(ctx, ctx.KVStore(m.keeper.storeKey), m.legacySubspace, m.keeper.cdc) +} diff --git a/x/itc/keeper/msg_server.go b/x/itc/keeper/msg_server.go index ae45727b..2ca0885e 100644 --- a/x/itc/keeper/msg_server.go +++ b/x/itc/keeper/msg_server.go @@ -3,9 +3,12 @@ package keeper import ( "context" - "github.com/OmniFlix/omniflixhub/x/itc/types" + govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" + + errorsmod "cosmossdk.io/errors" + + "github.com/OmniFlix/omniflixhub/v2/x/itc/types" sdk "github.com/cosmos/cosmos-sdk/types" - sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" ) type msgServer struct { @@ -32,43 +35,43 @@ func (m msgServer) CreateCampaign(goCtx context.Context, return nil, err } if msg.Deposit.Denom != msg.TokensPerClaim.Denom { - return nil, sdkerrors.Wrapf(types.ErrInvalidTokens, "mismatched token denoms") + return nil, errorsmod.Wrapf(types.ErrInvalidTokens, "mismatched token denoms") } // StartTime must be after current time if msg.StartTime.Before(ctx.BlockTime()) { - return nil, sdkerrors.Wrapf(types.ErrInvalidDuration, "start time must be in future") + return nil, errorsmod.Wrapf(types.ErrInvalidDuration, "start time must be in future") } endTime := msg.StartTime.Add(msg.Duration) if endTime.Before(msg.StartTime) || endTime.Equal(msg.StartTime) { - return nil, sdkerrors.Wrapf(types.ErrInvalidDuration, "duration must be positive or nil") + return nil, errorsmod.Wrapf(types.ErrInvalidDuration, "duration must be positive or nil") } if msg.Duration > m.Keeper.GetMaxCampaignDuration(ctx) { - return nil, sdkerrors.Wrapf(types.ErrInvalidDuration, + return nil, errorsmod.Wrapf(types.ErrInvalidDuration, "duration must be less than max campaign duration (%d)", m.Keeper.GetMaxCampaignDuration(ctx)) } campaignCreationFee := m.Keeper.GetCampaignCreationFee(ctx) if !msg.CreationFee.Equal(campaignCreationFee) { if msg.CreationFee.Denom != campaignCreationFee.Denom { - return nil, sdkerrors.Wrapf(types.ErrInvalidFeeDenom, "invalid creation fee denom %s", + return nil, errorsmod.Wrapf(types.ErrInvalidFeeDenom, "invalid creation fee denom %s", msg.CreationFee.Denom) } if msg.CreationFee.Amount.LT(campaignCreationFee.Amount) { - return nil, sdkerrors.Wrapf(types.ErrNotEnoughFeeAmount, + return nil, errorsmod.Wrapf(types.ErrNotEnoughFeeAmount, "%s fee is not enough, to create %s fee is required", msg.CreationFee.String(), campaignCreationFee.String()) } - return nil, sdkerrors.Wrapf(types.ErrInvalidCreationFee, + return nil, errorsmod.Wrapf(types.ErrInvalidCreationFee, "given fee (%s) not matched with campaign creation fee. %s required to create itc campaign", msg.CreationFee.String(), campaignCreationFee.String()) } if (msg.ClaimType == types.CLAIM_TYPE_FT || msg.ClaimType == types.CLAIM_TYPE_FT_AND_NFT) && msg.Distribution == nil { - return nil, sdkerrors.Wrapf( + return nil, errorsmod.Wrapf( types.ErrInvalidNFTMintDetails, "distribution config is required for ft claim type", ) } if (msg.ClaimType == types.CLAIM_TYPE_NFT || msg.ClaimType == types.CLAIM_TYPE_FT_AND_NFT) && msg.NftMintDetails == nil { - return nil, sdkerrors.Wrapf( + return nil, errorsmod.Wrapf( types.ErrInvalidNFTMintDetails, "nft mint details are required for nft claim type", ) @@ -132,14 +135,14 @@ func (m msgServer) Claim(goCtx context.Context, msg *types.MsgClaim) (*types.Msg campaign, found := m.Keeper.GetCampaign(ctx, msg.CampaignId) if !found { - return nil, sdkerrors.Wrapf(types.ErrCampaignDoesNotExists, "campaign id %d not exists", msg.CampaignId) + return nil, errorsmod.Wrapf(types.ErrCampaignDoesNotExists, "campaign id %d not exists", msg.CampaignId) } if campaign.StartTime.Unix() > ctx.BlockTime().Unix() { - return nil, sdkerrors.Wrapf(types.ErrInactiveCampaign, + return nil, errorsmod.Wrapf(types.ErrInactiveCampaign, "cannot claim on inactive campaign %d, ", campaign.Id) } if msg.Interaction != campaign.Interaction { - return nil, sdkerrors.Wrapf(types.ErrInteractionMismatch, + return nil, errorsmod.Wrapf(types.ErrInteractionMismatch, "required interaction %s, got %s. ", campaign.Interaction, msg.Interaction) } @@ -163,13 +166,13 @@ func (m msgServer) DepositCampaign(goCtx context.Context, } campaign, found := m.Keeper.GetCampaign(ctx, msg.CampaignId) if !found { - return nil, sdkerrors.Wrapf(types.ErrCampaignDoesNotExists, "campaign id %d not exists", msg.CampaignId) + return nil, errorsmod.Wrapf(types.ErrCampaignDoesNotExists, "campaign id %d not exists", msg.CampaignId) } if campaign.ClaimType == types.CLAIM_TYPE_NFT { - return nil, sdkerrors.Wrapf(types.ErrDepositNotAllowed, "deposit not allowed for this type of campaign") + return nil, errorsmod.Wrapf(types.ErrDepositNotAllowed, "deposit not allowed for this type of campaign") } if msg.Amount.Denom != campaign.TotalTokens.Denom { - return nil, sdkerrors.Wrapf(types.ErrTokenDenomMismatch, + return nil, errorsmod.Wrapf(types.ErrTokenDenomMismatch, "token denom mismatch, required %s, got %s", campaign.TotalTokens.Denom, msg.Amount.Denom) } if err := m.Keeper.DepositCampaign(ctx, msg.CampaignId, depositor, msg.Amount); err != nil { @@ -178,3 +181,16 @@ func (m msgServer) DepositCampaign(goCtx context.Context, return &types.MsgDepositCampaignResponse{}, nil } + +func (m msgServer) UpdateParams(goCtx context.Context, req *types.MsgUpdateParams) (*types.MsgUpdateParamsResponse, error) { + if m.authority != req.Authority { + return nil, errorsmod.Wrapf(govtypes.ErrInvalidSigner, "invalid authority; expected %s, got %s", m.authority, req.Authority) + } + + ctx := sdk.UnwrapSDKContext(goCtx) + if err := m.SetParams(ctx, req.Params); err != nil { + return nil, err + } + + return &types.MsgUpdateParamsResponse{}, nil +} diff --git a/x/itc/keeper/msg_server_test.go b/x/itc/keeper/msg_server_test.go index fd844838..04619786 100644 --- a/x/itc/keeper/msg_server_test.go +++ b/x/itc/keeper/msg_server_test.go @@ -7,7 +7,7 @@ import ( onfttypes "github.com/OmniFlix/onft/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" - "github.com/OmniFlix/omniflixhub/x/itc/types" + "github.com/OmniFlix/omniflixhub/v2/x/itc/types" sdk "github.com/cosmos/cosmos-sdk/types" ) @@ -508,3 +508,64 @@ func (suite *KeeperTestSuite) TestDepositCampaign() { }) } } + +func (suite *KeeperTestSuite) TestUpdateParams() { + testCases := []struct { + name string + request *types.MsgUpdateParams + expectErr bool + }{ + { + name: "set invalid authority", + request: &types.MsgUpdateParams{ + Authority: "foo", + }, + expectErr: true, + }, + { + name: "set invalid creation fee param", + request: &types.MsgUpdateParams{ + Authority: suite.App.ItcKeeper.GetAuthority(), + Params: types.Params{ + MaxCampaignDuration: types.DefaultMaxCampaignDuration, + CreationFee: sdk.NewCoin("foo", sdk.NewInt(0)), + }, + }, + expectErr: true, + }, + { + name: "set invalid max duration param", + request: &types.MsgUpdateParams{ + Authority: suite.App.ItcKeeper.GetAuthority(), + Params: types.Params{ + MaxCampaignDuration: -1, + CreationFee: types.DefaultCampaignCreationFee, + }, + }, + expectErr: true, + }, + { + name: "set full valid params", + request: &types.MsgUpdateParams{ + Authority: suite.App.ItcKeeper.GetAuthority(), + Params: types.Params{ + MaxCampaignDuration: types.DefaultMaxCampaignDuration, + CreationFee: types.DefaultCampaignCreationFee, + }, + }, + expectErr: false, + }, + } + + for _, tc := range testCases { + tc := tc + suite.Run(tc.name, func() { + _, err := suite.msgServer.UpdateParams(suite.Ctx, tc.request) + if tc.expectErr { + suite.Require().Error(err) + } else { + suite.Require().NoError(err) + } + }) + } +} diff --git a/x/itc/keeper/params.go b/x/itc/keeper/params.go index 719e66e6..cff99f3b 100644 --- a/x/itc/keeper/params.go +++ b/x/itc/keeper/params.go @@ -3,29 +3,41 @@ package keeper import ( "time" - "github.com/OmniFlix/omniflixhub/x/itc/types" + "github.com/OmniFlix/omniflixhub/v2/x/itc/types" sdk "github.com/cosmos/cosmos-sdk/types" ) // GetParams gets the parameters for the itc module. func (k Keeper) GetParams(ctx sdk.Context) (params types.Params) { - k.paramSpace.GetParamSet(ctx, ¶ms) + store := ctx.KVStore(k.storeKey) + bz := store.Get(types.ParamsKey) + if bz == nil { + return params + } + k.cdc.MustUnmarshal(bz, ¶ms) return params } // SetParams sets the parameters for the itc module. -func (k Keeper) SetParams(ctx sdk.Context, params types.Params) { - k.paramSpace.SetParamSet(ctx, ¶ms) +func (k Keeper) SetParams(ctx sdk.Context, params types.Params) error { + if err := params.ValidateBasic(); err != nil { + return err + } + + store := ctx.KVStore(k.storeKey) + bz := k.cdc.MustMarshal(¶ms) + store.Set(types.ParamsKey, bz) + return nil } // GetMaxCampaignDuration returns the maximum duration allowed to create a campaign. func (k Keeper) GetMaxCampaignDuration(ctx sdk.Context) (duration time.Duration) { - k.paramSpace.Get(ctx, types.ParamStoreKeyMaxCampaignDuration, &duration) - return duration + params := k.GetParams(ctx) + return params.MaxCampaignDuration } // GetCampaignCreationFee returns the creation fee required to create a campaign. func (k Keeper) GetCampaignCreationFee(ctx sdk.Context) (creationFee sdk.Coin) { - k.paramSpace.Get(ctx, types.ParamStoreKeyCampaignCreationFee, &creationFee) - return creationFee + params := k.GetParams(ctx) + return params.CreationFee } diff --git a/x/itc/migrations/v2/migrate.go b/x/itc/migrations/v2/migrate.go new file mode 100644 index 00000000..07d7b081 --- /dev/null +++ b/x/itc/migrations/v2/migrate.go @@ -0,0 +1,37 @@ +package v2 + +import ( + "github.com/OmniFlix/omniflixhub/v2/x/itc/exported" + "github.com/OmniFlix/omniflixhub/v2/x/itc/types" + "github.com/cosmos/cosmos-sdk/codec" + sdk "github.com/cosmos/cosmos-sdk/types" +) + +const ( + ModuleName = "itc" +) + +var ParamsKey = []byte{0x12} + +// Migrate migrates the x/itc module state from the consensus version 1 to +// version 2. Specifically, it takes the parameters that are currently stored +// and managed by the x/params modules and stores them directly into the x/itc +// module state. +func Migrate( + ctx sdk.Context, + store sdk.KVStore, + legacySubspace exported.Subspace, + cdc codec.BinaryCodec, +) error { + var currParams types.Params + legacySubspace.GetParamSet(ctx, &currParams) + + if err := currParams.ValidateBasic(); err != nil { + return err + } + + bz := cdc.MustMarshal(&currParams) + store.Set(ParamsKey, bz) + + return nil +} diff --git a/x/itc/migrations/v2/migrator_test.go b/x/itc/migrations/v2/migrator_test.go new file mode 100644 index 00000000..9c029178 --- /dev/null +++ b/x/itc/migrations/v2/migrator_test.go @@ -0,0 +1,45 @@ +package v2_test + +import ( + "testing" + + "github.com/stretchr/testify/require" + + "github.com/OmniFlix/omniflixhub/v2/x/itc" + "github.com/OmniFlix/omniflixhub/v2/x/itc/exported" + v2 "github.com/OmniFlix/omniflixhub/v2/x/itc/migrations/v2" + "github.com/OmniFlix/omniflixhub/v2/x/itc/types" + "github.com/cosmos/cosmos-sdk/testutil" + sdk "github.com/cosmos/cosmos-sdk/types" + moduletestutil "github.com/cosmos/cosmos-sdk/types/module/testutil" +) + +type mockSubspace struct { + ps types.Params +} + +func newMockSubspace(ps types.Params) mockSubspace { + return mockSubspace{ps: ps} +} + +func (ms mockSubspace) GetParamSet(ctx sdk.Context, ps exported.ParamSet) { + *ps.(*types.Params) = ms.ps +} + +func TestMigrate(t *testing.T) { + encCfg := moduletestutil.MakeTestEncodingConfig(itc.AppModuleBasic{}) + cdc := encCfg.Codec + + storeKey := sdk.NewKVStoreKey(v2.ModuleName) + tKey := sdk.NewTransientStoreKey("transient_test") + ctx := testutil.DefaultContext(storeKey, tKey) + store := ctx.KVStore(storeKey) + + legacySubspace := newMockSubspace(types.DefaultParams()) + require.NoError(t, v2.Migrate(ctx, store, legacySubspace, cdc)) + + var res types.Params + bz := store.Get(v2.ParamsKey) + require.NoError(t, cdc.Unmarshal(bz, &res)) + require.Equal(t, legacySubspace.ps, res) +} diff --git a/x/itc/module.go b/x/itc/module.go index 8cca8c67..4d24c9d6 100644 --- a/x/itc/module.go +++ b/x/itc/module.go @@ -5,17 +5,19 @@ import ( "encoding/json" "fmt" - "github.com/OmniFlix/omniflixhub/x/itc/client/cli" + "github.com/OmniFlix/omniflixhub/v2/x/itc/exported" + + "github.com/OmniFlix/omniflixhub/v2/x/itc/client/cli" "github.com/cosmos/cosmos-sdk/types/module" "github.com/spf13/cobra" "github.com/gorilla/mux" "github.com/grpc-ecosystem/grpc-gateway/runtime" - abci "github.com/tendermint/tendermint/abci/types" + abci "github.com/cometbft/cometbft/abci/types" - "github.com/OmniFlix/omniflixhub/x/itc/keeper" - "github.com/OmniFlix/omniflixhub/x/itc/types" + "github.com/OmniFlix/omniflixhub/v2/x/itc/keeper" + "github.com/OmniFlix/omniflixhub/v2/x/itc/types" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/codec" cdctypes "github.com/cosmos/cosmos-sdk/codec/types" @@ -31,6 +33,9 @@ var ( // AppModuleBasic // ---------------------------------------------------------------------------- +// ConsensusVersion defines the current x/itc module consensus version. +const ConsensusVersion = 2 + // AppModuleBasic implements the AppModuleBasic interface for the itc module. type AppModuleBasic struct { cdc codec.BinaryCodec @@ -96,13 +101,15 @@ func (AppModuleBasic) GetQueryCmd() *cobra.Command { type AppModule struct { AppModuleBasic - keeper keeper.Keeper + keeper keeper.Keeper + legacySubspace exported.Subspace } -func NewAppModule(cdc codec.Codec, keeper keeper.Keeper) AppModule { +func NewAppModule(cdc codec.Codec, keeper keeper.Keeper, ss exported.Subspace) AppModule { return AppModule{ AppModuleBasic: NewAppModuleBasic(cdc), keeper: keeper, + legacySubspace: ss, } } @@ -111,24 +118,19 @@ func (am AppModule) Name() string { return am.AppModuleBasic.Name() } -// Route returns the itc module's message routing key. -func (am AppModule) Route() sdk.Route { - return sdk.NewRoute(types.RouterKey, NewHandler(am.keeper)) -} - // QuerierRoute returns the itc module's query routing key. func (AppModule) QuerierRoute() string { return types.QuerierRoute } -// LegacyQuerierHandler returns the itc module's Querier. -func (am AppModule) LegacyQuerierHandler(_ *codec.LegacyAmino) sdk.Querier { - return nil -} - // RegisterServices registers a GRPC query service to respond to the // module-specific GRPC queries. func (am AppModule) RegisterServices(cfg module.Configurator) { types.RegisterMsgServer(cfg.MsgServer(), keeper.NewMsgServerImpl(am.keeper)) types.RegisterQueryServer(cfg.QueryServer(), am.keeper) + m := keeper.NewMigrator(am.keeper, am.legacySubspace) + + if err := cfg.RegisterMigration(types.ModuleName, 1, m.Migrate1to2); err != nil { + panic(fmt.Sprintf("failed to migrate x/%s from version 1 to 2: %v", types.ModuleName, err)) + } } // RegisterInvariants registers the itc module's invariants. @@ -153,7 +155,7 @@ func (am AppModule) ExportGenesis(ctx sdk.Context, cdc codec.JSONCodec) json.Raw } // ConsensusVersion implements ConsensusVersion. -func (AppModule) ConsensusVersion() uint64 { return 1 } +func (AppModule) ConsensusVersion() uint64 { return ConsensusVersion } // BeginBlock executes all ABCI BeginBlock logic respective to the itc module. func (am AppModule) BeginBlock(_ sdk.Context, _ abci.RequestBeginBlock) {} diff --git a/x/itc/types/campaign.go b/x/itc/types/campaign.go index 46852cd0..70e5e31a 100644 --- a/x/itc/types/campaign.go +++ b/x/itc/types/campaign.go @@ -4,9 +4,9 @@ import "C" import ( "time" - "github.com/OmniFlix/omniflixhub/x/itc/exported" + "github.com/OmniFlix/omniflixhub/v2/x/itc/exported" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/gogo/protobuf/proto" + "github.com/cosmos/gogoproto/proto" ) var ( diff --git a/x/itc/types/claim.go b/x/itc/types/claim.go index 58b45fbe..cc4a4f7c 100644 --- a/x/itc/types/claim.go +++ b/x/itc/types/claim.go @@ -1,9 +1,9 @@ package types import ( - "github.com/OmniFlix/omniflixhub/x/itc/exported" + "github.com/OmniFlix/omniflixhub/v2/x/itc/exported" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/gogo/protobuf/proto" + "github.com/cosmos/gogoproto/proto" ) var ( diff --git a/x/itc/types/codec.go b/x/itc/types/codec.go index bec217ac..2d134d2c 100644 --- a/x/itc/types/codec.go +++ b/x/itc/types/codec.go @@ -1,11 +1,13 @@ package types import ( - "github.com/OmniFlix/omniflixhub/x/itc/exported" + "github.com/OmniFlix/omniflixhub/v2/x/itc/exported" "github.com/cosmos/cosmos-sdk/codec" "github.com/cosmos/cosmos-sdk/codec/types" cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/cosmos/cosmos-sdk/types/msgservice" + authzcodec "github.com/cosmos/cosmos-sdk/x/authz/codec" ) func RegisterLegacyAminoCodec(cdc *codec.LegacyAmino) { @@ -13,11 +15,13 @@ func RegisterLegacyAminoCodec(cdc *codec.LegacyAmino) { cdc.RegisterConcrete(&MsgCancelCampaign{}, "OmniFlix/itc/MsgCancelCampaign", nil) cdc.RegisterConcrete(&MsgClaim{}, "OmniFlix/itc/MsgClaim", nil) cdc.RegisterConcrete(&MsgDepositCampaign{}, "OmniFlix/itc/MsgDepositCampaign", nil) + cdc.RegisterConcrete(&MsgUpdateParams{}, "OmniFlix/itc/MsgUpdateParams", nil) cdc.RegisterInterface((*exported.CampaignI)(nil), nil) cdc.RegisterConcrete(&Campaign{}, "OmniFlix/itc/Campaign", nil) cdc.RegisterInterface((*exported.ClaimI)(nil), nil) cdc.RegisterConcrete(&Claim{}, "OmniFlix/itc/Claim", nil) + cdc.RegisterConcrete(&Params{}, "OmniFlix/itc/Params", nil) } func RegisterInterfaces(registry types.InterfaceRegistry) { @@ -26,6 +30,7 @@ func RegisterInterfaces(registry types.InterfaceRegistry) { &MsgCancelCampaign{}, &MsgClaim{}, &MsgDepositCampaign{}, + &MsgUpdateParams{}, ) registry.RegisterImplementations((*exported.CampaignI)(nil), @@ -34,6 +39,7 @@ func RegisterInterfaces(registry types.InterfaceRegistry) { registry.RegisterImplementations((*exported.ClaimI)(nil), &Claim{}, ) + msgservice.RegisterMsgServiceDesc(registry, &_Msg_serviceDesc) } var ( @@ -45,5 +51,11 @@ var ( func init() { RegisterLegacyAminoCodec(amino) cryptocodec.RegisterCrypto(amino) + + // Register all Amino interfaces and concrete types on the authz Amino codec + // so that this can later be used to properly serialize MsgGrant and MsgExec + // instances. + RegisterLegacyAminoCodec(authzcodec.Amino) + amino.Seal() } diff --git a/x/itc/types/codec_test.go b/x/itc/types/codec_test.go index 4559da8a..d861352f 100644 --- a/x/itc/types/codec_test.go +++ b/x/itc/types/codec_test.go @@ -23,11 +23,12 @@ func (suite *CodecTestSuite) TestRegisterInterfaces() { RegisterInterfaces(registry) impls := registry.ListImplementations(sdk.MsgInterfaceProtoName) - suite.Require().Equal(4, len(impls)) + suite.Require().Equal(5, len(impls)) suite.Require().ElementsMatch([]string{ "/OmniFlix.itc.v1.MsgCreateCampaign", "/OmniFlix.itc.v1.MsgCancelCampaign", "/OmniFlix.itc.v1.MsgDepositCampaign", "/OmniFlix.itc.v1.MsgClaim", + "/OmniFlix.itc.v1.MsgUpdateParams", }, impls) } diff --git a/x/itc/types/errors.go b/x/itc/types/errors.go index 52616864..6fcbfe3f 100644 --- a/x/itc/types/errors.go +++ b/x/itc/types/errors.go @@ -1,29 +1,29 @@ package types import ( - sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" + errorsmod "cosmossdk.io/errors" ) // itc module errors var ( - ErrInvalidTokens = sdkerrors.Register(ModuleName, 2, "invalid tokens") - ErrInvalidDuration = sdkerrors.Register(ModuleName, 3, "invalid duration") - ErrInvalidTimestamp = sdkerrors.Register(ModuleName, 4, "invalid time") - ErrNonPositiveNumber = sdkerrors.Register(ModuleName, 5, "non positive number") - ErrCampaignDoesNotExists = sdkerrors.Register(ModuleName, 6, "campaign does not exists") - ErrInactiveCampaign = sdkerrors.Register(ModuleName, 7, "campaign is not active") - ErrInvalidNFTMintDetails = sdkerrors.Register(ModuleName, 8, "invalid nft mint details") - ErrInValidMaxAllowedClaims = sdkerrors.Register(ModuleName, 9, "invalid max allowed claims") - ErrInvalidClaimType = sdkerrors.Register(ModuleName, 10, "invalid claim type") - ErrInteractionMismatch = sdkerrors.Register(ModuleName, 11, "interaction mismatch") - ErrClaimExists = sdkerrors.Register(ModuleName, 12, "claim exists") - ErrClaimNotAllowed = sdkerrors.Register(ModuleName, 13, "claim not allowed") - ErrTokenDenomMismatch = sdkerrors.Register(ModuleName, 14, "invalid token denom") - ErrClaimingNFT = sdkerrors.Register(ModuleName, 15, "claim nft failed") - ErrDepositNotAllowed = sdkerrors.Register(ModuleName, 16, "deposit not allowed") - ErrInvalidCreationFee = sdkerrors.Register(ModuleName, 17, "invalid fee") - ErrInvalidFeeDenom = sdkerrors.Register(ModuleName, 18, "invalid fee denom") - ErrNotEnoughFeeAmount = sdkerrors.Register(ModuleName, 19, "not enough fee") - ErrInvalidDistribution = sdkerrors.Register(ModuleName, 20, "invalid distribution") - ErrInvalidNftDenomId = sdkerrors.Register(ModuleName, 21, "invalid nft denom id") + ErrInvalidTokens = errorsmod.Register(ModuleName, 2, "invalid tokens") + ErrInvalidDuration = errorsmod.Register(ModuleName, 3, "invalid duration") + ErrInvalidTimestamp = errorsmod.Register(ModuleName, 4, "invalid time") + ErrNonPositiveNumber = errorsmod.Register(ModuleName, 5, "non positive number") + ErrCampaignDoesNotExists = errorsmod.Register(ModuleName, 6, "campaign does not exists") + ErrInactiveCampaign = errorsmod.Register(ModuleName, 7, "campaign is not active") + ErrInvalidNFTMintDetails = errorsmod.Register(ModuleName, 8, "invalid nft mint details") + ErrInValidMaxAllowedClaims = errorsmod.Register(ModuleName, 9, "invalid max allowed claims") + ErrInvalidClaimType = errorsmod.Register(ModuleName, 10, "invalid claim type") + ErrInteractionMismatch = errorsmod.Register(ModuleName, 11, "interaction mismatch") + ErrClaimExists = errorsmod.Register(ModuleName, 12, "claim exists") + ErrClaimNotAllowed = errorsmod.Register(ModuleName, 13, "claim not allowed") + ErrTokenDenomMismatch = errorsmod.Register(ModuleName, 14, "invalid token denom") + ErrClaimingNFT = errorsmod.Register(ModuleName, 15, "claim nft failed") + ErrDepositNotAllowed = errorsmod.Register(ModuleName, 16, "deposit not allowed") + ErrInvalidCreationFee = errorsmod.Register(ModuleName, 17, "invalid fee") + ErrInvalidFeeDenom = errorsmod.Register(ModuleName, 18, "invalid fee denom") + ErrNotEnoughFeeAmount = errorsmod.Register(ModuleName, 19, "not enough fee") + ErrInvalidDistribution = errorsmod.Register(ModuleName, 20, "invalid distribution") + ErrInvalidNftDenomId = errorsmod.Register(ModuleName, 21, "invalid nft denom id") ) diff --git a/x/itc/types/expected_keepers.go b/x/itc/types/expected_keepers.go index 89d9dc30..58c48873 100644 --- a/x/itc/types/expected_keepers.go +++ b/x/itc/types/expected_keepers.go @@ -28,7 +28,7 @@ type BankKeeper interface { // NftKeeper defines the expected nft keeper type NftKeeper interface { - GetONFT(ctx sdk.Context, denomId, onftId string) (nft nft.ONFT, err error) + GetONFT(ctx sdk.Context, denomId, onftId string) (nft nft.ONFTI, err error) GetDenom(ctx sdk.Context, denomId string) (nfttypes.Denom, error) MintONFT(ctx sdk.Context, denomID, onftID string, diff --git a/x/itc/types/genesis.go b/x/itc/types/genesis.go index 84b11474..0bd87516 100644 --- a/x/itc/types/genesis.go +++ b/x/itc/types/genesis.go @@ -1,6 +1,7 @@ package types import ( + errorsmod "cosmossdk.io/errors" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" ) @@ -20,7 +21,7 @@ func NewGenesisState(campaigns []Campaign, func (m *GenesisState) ValidateGenesis() error { for _, c := range m.Campaigns { if c.GetCreator().Empty() { - return sdkerrors.Wrap(sdkerrors.ErrInvalidAddress, "missing campaign creator address") + return errorsmod.Wrap(sdkerrors.ErrInvalidAddress, "missing campaign creator address") } if err := ValidateCampaign(c); err != nil { return err @@ -35,7 +36,7 @@ func (m *GenesisState) ValidateGenesis() error { return err } if m.NextCampaignNumber <= 0 { - return sdkerrors.Wrap(ErrNonPositiveNumber, "must be a number and greater than 0.") + return errorsmod.Wrap(ErrNonPositiveNumber, "must be a number and greater than 0.") } return nil } diff --git a/x/itc/types/genesis.pb.go b/x/itc/types/genesis.pb.go index 51f794bc..f77f3feb 100644 --- a/x/itc/types/genesis.pb.go +++ b/x/itc/types/genesis.pb.go @@ -1,12 +1,12 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: omniflix/itc/v1/genesis.proto +// source: OmniFlix/itc/v1/genesis.proto package types import ( fmt "fmt" - _ "github.com/gogo/protobuf/gogoproto" - proto "github.com/gogo/protobuf/proto" + _ "github.com/cosmos/gogoproto/gogoproto" + proto "github.com/cosmos/gogoproto/proto" io "io" math "math" math_bits "math/bits" @@ -35,7 +35,7 @@ func (m *GenesisState) Reset() { *m = GenesisState{} } func (m *GenesisState) String() string { return proto.CompactTextString(m) } func (*GenesisState) ProtoMessage() {} func (*GenesisState) Descriptor() ([]byte, []int) { - return fileDescriptor_fdd3eb581c75e979, []int{0} + return fileDescriptor_deb2e38137256903, []int{0} } func (m *GenesisState) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -96,29 +96,29 @@ func init() { proto.RegisterType((*GenesisState)(nil), "OmniFlix.itc.v1.GenesisState") } -func init() { proto.RegisterFile("omniflix/itc/v1/genesis.proto", fileDescriptor_fdd3eb581c75e979) } +func init() { proto.RegisterFile("OmniFlix/itc/v1/genesis.proto", fileDescriptor_deb2e38137256903) } -var fileDescriptor_fdd3eb581c75e979 = []byte{ - // 296 bytes of a gzipped FileDescriptorProto +var fileDescriptor_deb2e38137256903 = []byte{ + // 297 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x64, 0x90, 0xcf, 0x4a, 0xc3, 0x30, - 0x00, 0xc6, 0x1b, 0x37, 0x06, 0x66, 0x82, 0x10, 0x86, 0x76, 0x43, 0xe3, 0xf0, 0x34, 0x10, 0x12, - 0x37, 0xf5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 0xc9, 0x3a, 0x64, 0x34, 0x6c, 0xd3, 0x32, 0xcb, 0xa2, 0xf3, + 0x1f, 0x00, 0x0f, 0xee, 0xab, 0xc6, 0x17, 0xc3, 0x0c, 0x47, 0x37, 0x70, 0xdf, 0x67, 0x32, 0x64, + 0x22, 0x50, 0xb1, 0x0b, 0xc6, 0x9d, 0x49, 0x7f, 0x36, 0x24, 0xad, 0x47, 0x90, 0xdb, 0x5a, 0x31, + 0xef, 0x6e, 0xbe, 0xce, 0x9c, 0xc5, 0xbf, 0x03, 0x5d, 0xc0, 0x81, 0xe2, 0x99, 0x59, 0x36, 0x37, + 0x4b, 0x95, 0x48, 0x8f, 0x47, 0xee, 0xde, 0x18, 0x4c, 0xba, 0x0b, 0x54, 0xb2, 0xc6, 0xfc, 0x68, + 0x09, 0xba, 0x82, 0x3d, 0x7f, 0xcd, 0x84, 0x8c, 0xdd, 0x8e, 0x6d, 0x3b, 0xda, 0x6d, 0x2b, 0x71, + 0x5d, 0x55, 0x6b, 0xd1, 0x35, 0xec, 0x55, 0x5f, 0x74, 0xbb, 0x63, 0x30, 0xe9, 0xcf, 0x8e, 0x77, + 0x5c, 0xcf, 0x16, 0x37, 0xb6, 0x4a, 0x3c, 0x7f, 0xd8, 0xe4, 0x18, 0x6c, 0x73, 0x0c, 0xbe, 0x73, + 0x0c, 0x3e, 0x0a, 0xec, 0x6c, 0x0b, 0xec, 0x7c, 0x16, 0xd8, 0x79, 0x25, 0x81, 0x30, 0xab, 0xc4, + 0x23, 0xbe, 0x96, 0xf4, 0x6f, 0x2e, 0x2d, 0x95, 0x78, 0x5b, 0x8b, 0x6c, 0x95, 0x78, 0x34, 0x9d, + 0xd1, 0x6a, 0x3f, 0xf3, 0x1e, 0xf2, 0xd8, 0xeb, 0xd9, 0xfd, 0x2e, 0x7f, 0x03, 0x00, 0x00, 0xff, + 0xff, 0x02, 0x56, 0x05, 0x57, 0xc0, 0x01, 0x00, 0x00, } func (m *GenesisState) Marshal() (dAtA []byte, err error) { diff --git a/x/itc/types/genesis_test.go b/x/itc/types/genesis_test.go index 6fc32a45..697e2946 100644 --- a/x/itc/types/genesis_test.go +++ b/x/itc/types/genesis_test.go @@ -4,10 +4,10 @@ import ( "testing" "time" - "github.com/OmniFlix/omniflixhub/x/itc/types" + "github.com/OmniFlix/omniflixhub/v2/x/itc/types" + "github.com/cometbft/cometbft/crypto/ed25519" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/stretchr/testify/require" - "github.com/tendermint/tendermint/crypto/ed25519" ) func TestGenesisState_ValidateGenesis(t *testing.T) { diff --git a/x/itc/types/itc.pb.go b/x/itc/types/itc.pb.go index 30dc1694..b2b7eebd 100644 --- a/x/itc/types/itc.pb.go +++ b/x/itc/types/itc.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: omniflix/itc/v1/itc.proto +// source: OmniFlix/itc/v1/itc.proto package types @@ -7,9 +7,9 @@ import ( fmt "fmt" github_com_cosmos_cosmos_sdk_types "github.com/cosmos/cosmos-sdk/types" types "github.com/cosmos/cosmos-sdk/types" - _ "github.com/gogo/protobuf/gogoproto" - proto "github.com/gogo/protobuf/proto" - github_com_gogo_protobuf_types "github.com/gogo/protobuf/types" + _ "github.com/cosmos/gogoproto/gogoproto" + proto "github.com/cosmos/gogoproto/proto" + github_com_gogo_protobuf_types "github.com/cosmos/gogoproto/types" _ "google.golang.org/protobuf/types/known/durationpb" _ "google.golang.org/protobuf/types/known/timestamppb" io "io" @@ -52,7 +52,7 @@ func (x DistributionType) String() string { } func (DistributionType) EnumDescriptor() ([]byte, []int) { - return fileDescriptor_b99fa199354013a9, []int{0} + return fileDescriptor_bab9913014645745, []int{0} } type InteractionType int32 @@ -80,7 +80,7 @@ func (x InteractionType) String() string { } func (InteractionType) EnumDescriptor() ([]byte, []int) { - return fileDescriptor_b99fa199354013a9, []int{1} + return fileDescriptor_bab9913014645745, []int{1} } type CampaignStatus int32 @@ -108,7 +108,7 @@ func (x CampaignStatus) String() string { } func (CampaignStatus) EnumDescriptor() ([]byte, []int) { - return fileDescriptor_b99fa199354013a9, []int{2} + return fileDescriptor_bab9913014645745, []int{2} } type ClaimType int32 @@ -136,7 +136,7 @@ func (x ClaimType) String() string { } func (ClaimType) EnumDescriptor() ([]byte, []int) { - return fileDescriptor_b99fa199354013a9, []int{3} + return fileDescriptor_bab9913014645745, []int{3} } type Campaign struct { @@ -164,7 +164,7 @@ func (m *Campaign) Reset() { *m = Campaign{} } func (m *Campaign) String() string { return proto.CompactTextString(m) } func (*Campaign) ProtoMessage() {} func (*Campaign) Descriptor() ([]byte, []int) { - return fileDescriptor_b99fa199354013a9, []int{0} + return fileDescriptor_bab9913014645745, []int{0} } func (m *Campaign) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -202,7 +202,7 @@ func (m *Distribution) Reset() { *m = Distribution{} } func (m *Distribution) String() string { return proto.CompactTextString(m) } func (*Distribution) ProtoMessage() {} func (*Distribution) Descriptor() ([]byte, []int) { - return fileDescriptor_b99fa199354013a9, []int{1} + return fileDescriptor_bab9913014645745, []int{1} } func (m *Distribution) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -248,7 +248,7 @@ func (m *NFTDetails) Reset() { *m = NFTDetails{} } func (m *NFTDetails) String() string { return proto.CompactTextString(m) } func (*NFTDetails) ProtoMessage() {} func (*NFTDetails) Descriptor() ([]byte, []int) { - return fileDescriptor_b99fa199354013a9, []int{2} + return fileDescriptor_bab9913014645745, []int{2} } func (m *NFTDetails) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -288,7 +288,7 @@ func (m *Claim) Reset() { *m = Claim{} } func (m *Claim) String() string { return proto.CompactTextString(m) } func (*Claim) ProtoMessage() {} func (*Claim) Descriptor() ([]byte, []int) { - return fileDescriptor_b99fa199354013a9, []int{3} + return fileDescriptor_bab9913014645745, []int{3} } func (m *Claim) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -328,85 +328,86 @@ func init() { proto.RegisterType((*Claim)(nil), "OmniFlix.itc.v1.Claim") } -func init() { proto.RegisterFile("omniflix/itc/v1/itc.proto", fileDescriptor_b99fa199354013a9) } - -var fileDescriptor_b99fa199354013a9 = []byte{ - // 1199 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x56, 0xcb, 0x6e, 0xdb, 0x46, - 0x14, 0x15, 0x15, 0x3b, 0x91, 0xae, 0x14, 0x59, 0x99, 0xbc, 0x68, 0xbb, 0x96, 0x54, 0x2e, 0x0a, - 0xc3, 0x45, 0x29, 0x38, 0x6d, 0x51, 0xa4, 0x3b, 0x3d, 0x5b, 0xa2, 0x31, 0x6d, 0x8c, 0xe8, 0xa2, - 0xc9, 0x86, 0x18, 0x91, 0x23, 0x67, 0x60, 0x91, 0x14, 0xc8, 0x91, 0x63, 0xff, 0x45, 0x80, 0x6e, - 0xba, 0xe9, 0xa7, 0x74, 0x9f, 0x65, 0x96, 0x45, 0x17, 0x6a, 0x93, 0xfc, 0x81, 0xd1, 0x0f, 0x28, - 0x66, 0x86, 0xb4, 0x18, 0xb9, 0x68, 0xd0, 0xac, 0x34, 0xf7, 0x75, 0xee, 0x9d, 0xcb, 0xc3, 0x43, - 0xc1, 0x66, 0x14, 0x84, 0x6c, 0x32, 0x65, 0xe7, 0x6d, 0xc6, 0xbd, 0xf6, 0xd9, 0xbe, 0xf8, 0x31, - 0x67, 0x71, 0xc4, 0x23, 0xb4, 0x71, 0x18, 0x84, 0x6c, 0x38, 0x65, 0xe7, 0xa6, 0xf0, 0x9d, 0xed, - 0x6f, 0x35, 0xbc, 0x28, 0x09, 0xa2, 0xa4, 0x3d, 0x26, 0x09, 0x6d, 0x9f, 0xed, 0x8f, 0x29, 0x27, - 0xfb, 0x6d, 0x2f, 0x62, 0xa1, 0x2a, 0xd8, 0xba, 0x77, 0x12, 0x9d, 0x44, 0xf2, 0xd8, 0x16, 0xa7,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- 0xd0, 0x57, 0x83, 0xaf, 0x26, 0x58, 0xb6, 0x80, 0xfe, 0x71, 0x50, 0xd7, 0xd0, 0x16, 0x3c, 0x58, - 0x8d, 0xa6, 0xb1, 0xe2, 0xde, 0x01, 0x94, 0xaf, 0x3e, 0x44, 0xe8, 0x0e, 0xdc, 0xee, 0x3d, 0xe9, - 0x58, 0x07, 0x6a, 0x9c, 0xa1, 0x58, 0x09, 0x82, 0x5a, 0xce, 0x65, 0x0f, 0x1d, 0x35, 0xfb, 0x7b, - 0x69, 0x6e, 0xc7, 0xee, 0xcb, 0x50, 0xb1, 0x7b, 0xf0, 0xea, 0x4d, 0xa3, 0xf0, 0xfa, 0x4d, 0xa3, - 0xf0, 0xea, 0x6d, 0x43, 0x7b, 0xfd, 0xb6, 0xa1, 0xfd, 0xf5, 0xb6, 0xa1, 0xbd, 0x7c, 0xd7, 0x28, - 0xbc, 0x7e, 0xd7, 0x28, 0xfc, 0xfe, 0xae, 0x51, 0x78, 0xf6, 0x79, 0x8e, 0xf0, 0xd9, 0xf3, 0x6c, - 0x67, 0x7f, 0xdd, 0x9e, 0xcf, 0xc7, 0x6d, 0xf5, 0xff, 0x4d, 0x32, 0x7f, 0x7c, 0x53, 0xea, 0xc0, - 0x97, 0xff, 0x04, 0x00, 0x00, 0xff, 0xff, 0x32, 0x36, 0xba, 0x98, 0xdc, 0x09, 0x00, 0x00, +func init() { proto.RegisterFile("OmniFlix/itc/v1/itc.proto", fileDescriptor_bab9913014645745) } + +var fileDescriptor_bab9913014645745 = []byte{ + // 1202 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x56, 0xcd, 0x6e, 0xdb, 0xc6, + 0x16, 0x16, 0x15, 0x3b, 0x91, 0x8e, 0x14, 0x59, 0x99, 0xfc, 0xd1, 0xf6, 0xb5, 0xa4, 0xcb, 0xc5, + 0x85, 0x61, 0xe0, 0x52, 0x70, 0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bc, 0x7d, 0xd7, 0x28, 0xbc, 0x79, + 0xdf, 0xd0, 0xde, 0xbe, 0x6f, 0x68, 0xbf, 0xbf, 0x6f, 0x68, 0xaf, 0x3f, 0x34, 0x0a, 0x6f, 0x3f, + 0x34, 0x0a, 0xbf, 0x7c, 0x68, 0x14, 0x5e, 0x98, 0x39, 0xc2, 0x5f, 0x7f, 0xb1, 0x45, 0x41, 0xc8, + 0x26, 0x53, 0x76, 0xf1, 0x72, 0x3e, 0x6e, 0x2f, 0x9e, 0xb4, 0xd5, 0x27, 0x9c, 0x24, 0xff, 0xf8, + 0xb6, 0x94, 0x82, 0xff, 0xfd, 0x19, 0x00, 0x00, 0xff, 0xff, 0x88, 0x71, 0x04, 0x22, 0xdf, 0x09, + 0x00, 0x00, } func (m *Campaign) Marshal() (dAtA []byte, err error) { diff --git a/x/itc/types/key.go b/x/itc/types/key.go index 8566aef5..b1d06eaf 100644 --- a/x/itc/types/key.go +++ b/x/itc/types/key.go @@ -16,6 +16,8 @@ var ( PrefixCampaignCreator = []byte{0x02} PrefixNextCampaignNumber = []byte{0x03} PrefixClaimByNftId = []byte{0x11} + + ParamsKey = []byte{0x12} ) func KeyCampaignIdPrefix(id uint64) []byte { diff --git a/x/itc/types/msgs.go b/x/itc/types/msgs.go index 476d004d..4d68b73d 100644 --- a/x/itc/types/msgs.go +++ b/x/itc/types/msgs.go @@ -3,6 +3,8 @@ package types import ( "time" + errorsmod "cosmossdk.io/errors" + "github.com/OmniFlix/onft/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" @@ -19,7 +21,13 @@ const ( TypeMsgClaim = "claim" ) -var _ sdk.Msg = &MsgCreateCampaign{} +var ( + _ sdk.Msg = &MsgCreateCampaign{} + _ sdk.Msg = &MsgCancelCampaign{} + _ sdk.Msg = &MsgDepositCampaign{} + _ sdk.Msg = &MsgClaim{} + _ sdk.Msg = &MsgUpdateParams{} +) func NewMsgCreateCampaign(name, description string, interaction InteractionType, claimType ClaimType, @@ -58,7 +66,7 @@ func (msg MsgCreateCampaign) Type() string { return TypeMsgCreateCampaign } func (msg MsgCreateCampaign) ValidateBasic() error { _, err := sdk.AccAddressFromBech32(msg.Creator) if err != nil { - return sdkerrors.Wrapf(sdkerrors.ErrInvalidAddress, "invalid creator address (%s)", err) + return errorsmod.Wrapf(sdkerrors.ErrInvalidAddress, "invalid creator address (%s)", err) } if err := ValidateClaimType(msg.ClaimType); err != nil { return err @@ -67,7 +75,7 @@ func (msg MsgCreateCampaign) ValidateBasic() error { return err } if msg.NftDenomId == "" { - return sdkerrors.Wrapf(ErrInvalidNftDenomId, "nft denom id cannot be empty") + return errorsmod.Wrapf(ErrInvalidNftDenomId, "nft denom id cannot be empty") } if msg.ClaimType != CLAIM_TYPE_NFT { if err := ValidateTokens(msg.Deposit, msg.TokensPerClaim); err != nil { @@ -82,13 +90,13 @@ func (msg MsgCreateCampaign) ValidateBasic() error { return err } if msg.NftMintDetails != nil && msg.NftDenomId == msg.NftMintDetails.DenomId { - return sdkerrors.Wrapf(ErrInvalidNFTMintDetails, + return errorsmod.Wrapf(ErrInvalidNFTMintDetails, "nft denom id and nft mint details denom id cannot be same (%s)", msg.NftDenomId) } } if msg.MaxAllowedClaims == 0 { - return sdkerrors.Wrapf(ErrInValidMaxAllowedClaims, + return errorsmod.Wrapf(ErrInValidMaxAllowedClaims, "max allowed claims must be a positive number (%d)", msg.MaxAllowedClaims) } if err := ValidateTimestamp(msg.StartTime); err != nil { @@ -128,7 +136,7 @@ func (msg MsgCancelCampaign) Type() string { return TypeMsgCancelCampaign } func (msg MsgCancelCampaign) ValidateBasic() error { _, err := sdk.AccAddressFromBech32(msg.Creator) if err != nil { - return sdkerrors.Wrapf(sdkerrors.ErrInvalidAddress, "invalid creator address (%s)", err) + return errorsmod.Wrapf(sdkerrors.ErrInvalidAddress, "invalid creator address (%s)", err) } return nil } @@ -162,10 +170,10 @@ func (msg MsgDepositCampaign) Type() string { return TypeMsgDepositCampaign } func (msg MsgDepositCampaign) ValidateBasic() error { _, err := sdk.AccAddressFromBech32(msg.Depositor) if err != nil { - return sdkerrors.Wrapf(sdkerrors.ErrInvalidAddress, "invalid depositor address (%s)", err) + return errorsmod.Wrapf(sdkerrors.ErrInvalidAddress, "invalid depositor address (%s)", err) } if msg.Amount.IsNil() || (!msg.Amount.IsValid() && msg.Amount.IsZero()) { - return sdkerrors.Wrapf(sdkerrors.ErrInvalidCoins, + return errorsmod.Wrapf(sdkerrors.ErrInvalidCoins, "amount must be valid and positive (%s)", msg.Amount.String()) } return nil @@ -203,10 +211,10 @@ func (msg MsgClaim) Type() string { return TypeMsgClaim } func (msg MsgClaim) ValidateBasic() error { _, err := sdk.AccAddressFromBech32(msg.Claimer) if err != nil { - return sdkerrors.Wrapf(sdkerrors.ErrInvalidAddress, "invalid claimer address (%s)", msg.Claimer) + return errorsmod.Wrapf(sdkerrors.ErrInvalidAddress, "invalid claimer address (%s)", msg.Claimer) } if len(msg.NftId) == 0 { - return sdkerrors.Wrapf(types.ErrInvalidONFTID, "invalid nft id (%s)", msg.NftId) + return errorsmod.Wrapf(types.ErrInvalidONFTID, "invalid nft id (%s)", msg.NftId) } return ValidateInteractionType(msg.Interaction) } @@ -224,3 +232,23 @@ func (msg MsgClaim) GetSigners() []sdk.AccAddress { } return []sdk.AccAddress{from} } + +// GetSignBytes implements the LegacyMsg interface. +func (m MsgUpdateParams) GetSignBytes() []byte { + return sdk.MustSortJSON(ModuleCdc.MustMarshalJSON(&m)) +} + +// GetSigners returns the expected signers for a MsgUpdateParams message. +func (m *MsgUpdateParams) GetSigners() []sdk.AccAddress { + addr, _ := sdk.AccAddressFromBech32(m.Authority) + return []sdk.AccAddress{addr} +} + +// ValidateBasic does a sanity check on the provided data. +func (m *MsgUpdateParams) ValidateBasic() error { + if _, err := sdk.AccAddressFromBech32(m.Authority); err != nil { + return errorsmod.Wrap(err, "invalid authority address") + } + + return m.Params.ValidateBasic() +} diff --git a/x/itc/types/msgs_test.go b/x/itc/types/msgs_test.go index dc5c3290..5d0d5b50 100644 --- a/x/itc/types/msgs_test.go +++ b/x/itc/types/msgs_test.go @@ -4,10 +4,10 @@ import ( "testing" "time" - "github.com/OmniFlix/omniflixhub/x/itc/types" + "github.com/OmniFlix/omniflixhub/v2/x/itc/types" + "github.com/cometbft/cometbft/crypto/ed25519" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/stretchr/testify/require" - "github.com/tendermint/tendermint/crypto/ed25519" ) var ( diff --git a/x/itc/types/params.go b/x/itc/types/params.go index 71105813..773d395b 100644 --- a/x/itc/types/params.go +++ b/x/itc/types/params.go @@ -4,10 +4,9 @@ import ( "fmt" "time" - sdk "github.com/cosmos/cosmos-sdk/types" - sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" + errorsmod "cosmossdk.io/errors" - paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" + sdk "github.com/cosmos/cosmos-sdk/types" ) const ( @@ -16,16 +15,14 @@ const ( var DefaultCampaignCreationFee = sdk.NewInt64Coin("uflix", 10_000_000) -var ( - ParamStoreKeyMaxCampaignDuration = []byte("MaxCampaignDuration") - ParamStoreKeyCampaignCreationFee = []byte("CampaignCreationFee") -) - -var _ paramtypes.ParamSet = (*Params)(nil) - -// ParamKeyTable returns the parameter key table. -func ParamKeyTable() paramtypes.KeyTable { - return paramtypes.NewKeyTable().RegisterParamSet(&Params{}) +func NewParams( + creationFee sdk.Coin, + maxCampaignDuration time.Duration, +) Params { + return Params{ + CreationFee: creationFee, + MaxCampaignDuration: maxCampaignDuration, + } } // DefaultParams returns default itc parameters @@ -36,14 +33,6 @@ func DefaultParams() Params { } } -// ParamSetPairs returns the parameter set pairs. -func (p *Params) ParamSetPairs() paramtypes.ParamSetPairs { - return paramtypes.ParamSetPairs{ - paramtypes.NewParamSetPair(ParamStoreKeyMaxCampaignDuration, &p.MaxCampaignDuration, validateMaxCampaignDuration), - paramtypes.NewParamSetPair(ParamStoreKeyCampaignCreationFee, &p.CreationFee, validateCampaignCreationFee), - } -} - // ValidateBasic performs basic validation on itc parameters. func (p Params) ValidateBasic() error { if err := validateMaxCampaignDuration(p.MaxCampaignDuration); err != nil { @@ -75,7 +64,7 @@ func validateCampaignCreationFee(i interface{}) error { } if !fee.IsValid() || fee.IsZero() { - return sdkerrors.Wrapf(ErrInvalidCreationFee, + return errorsmod.Wrapf(ErrInvalidCreationFee, "invalid fee amount %s, only accepts positive amounts", fee.String()) } return nil diff --git a/x/itc/types/params.pb.go b/x/itc/types/params.pb.go index 8b157529..4d85cbf8 100644 --- a/x/itc/types/params.pb.go +++ b/x/itc/types/params.pb.go @@ -1,14 +1,14 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: omniflix/itc/v1/params.proto +// source: OmniFlix/itc/v1/params.proto package types import ( fmt "fmt" types "github.com/cosmos/cosmos-sdk/types" - _ "github.com/gogo/protobuf/gogoproto" - proto "github.com/gogo/protobuf/proto" - github_com_gogo_protobuf_types "github.com/gogo/protobuf/types" + _ "github.com/cosmos/gogoproto/gogoproto" + proto "github.com/cosmos/gogoproto/proto" + github_com_gogo_protobuf_types "github.com/cosmos/gogoproto/types" _ "google.golang.org/protobuf/types/known/durationpb" io "io" math "math" @@ -37,7 +37,7 @@ func (m *Params) Reset() { *m = Params{} } func (m *Params) String() string { return proto.CompactTextString(m) } func (*Params) ProtoMessage() {} func (*Params) Descriptor() ([]byte, []int) { - return fileDescriptor_a57ac922a662f57a, []int{0} + return fileDescriptor_dca4accf521d18f5, []int{0} } func (m *Params) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -70,31 +70,30 @@ func init() { proto.RegisterType((*Params)(nil), "OmniFlix.itc.v1.Params") } -func init() { proto.RegisterFile("omniflix/itc/v1/params.proto", fileDescriptor_a57ac922a662f57a) } +func init() { proto.RegisterFile("OmniFlix/itc/v1/params.proto", fileDescriptor_dca4accf521d18f5) } -var fileDescriptor_a57ac922a662f57a = []byte{ - // 321 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00,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, 0x14, 0xbb, 0xb1, 0x0b, 0xe3, - 0xd1, 0x66, 0x37, 0x74, 0xbe, 0x77, 0xc3, 0xc1, 0x9a, 0xeb, 0xe8, 0xda, 0xfb, 0x53, 0xc5, 0x7b, - 0xfd, 0x18, 0x92, 0x59, 0x57, 0xf3, 0x62, 0x62, 0xbf, 0x1a, 0x7a, 0xe7, 0xc1, 0xfd, 0x2f, 0x52, - 0x59, 0xe1, 0xf9, 0x42, 0xca, 0xde, 0x3f, 0xeb, 0x57, 0x07, 0x66, 0x87, 0xc0, 0xcc, 0x06, 0x66, - 0x13, 0x54, 0xf1, 0xf8, 0xcc, 0xfa, 0x75, 0x6b, 0xbf, 0xdf, 0x64, 0x6f, 0xd6, 0x6e, 0xc6, 0xa9, - 0x94, 0xe3, 0xdb, 0xcd, 0x17, 0x75, 0x36, 0x7b, 0x4a, 0xb6, 0x7b, 0x4a, 0x3e, 0xf7, 0x94, 0xbc, - 0x94, 0xd4, 0xd9, 0x96, 0xd4, 0x79, 0x2b, 0xa9, 0xf3, 0x78, 0x11, 0x2a, 0xb3, 0xcc, 0x03, 0x26, - 0x50, 0x43, 0x73, 0x6e, 0x68, 0x5a, 0x59, 0xe6, 0x01, 0xd4, 0xd5, 0x98, 0x75, 0x22, 0xb3, 0xa0, - 0x55, 0xe5, 0xbe, 0xfa, 0x09, 0x00, 0x00, 0xff, 0xff, 0x65, 0x2d, 0xb8, 0xcb, 0xb7, 0x01, 0x00, - 0x00, +var fileDescriptor_dca4accf521d18f5 = []byte{ + // 319 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x6c, 0x51, 0xbd, 0x4e, 0xc3, 0x30, + 0x18, 0x8c, 0x19, 0x3a, 0xa4, 0x48, 0x48, 0x2d, 0x48, 0xa5, 0x54, 0x2e, 0xca, 0xd4, 0xc9, 0x56, + 0xca, 0xc6, 0xd8, 0xa2, 0x4e, 0x48, 0xa0, 0x6e, 0xb0, 0x54, 0x8e, 0x71, 0x5d, 0x4b, 0x71, 0xbe, + 0x28, 0x71, 0x42, 0xfa, 0x16, 0x8c, 0x3c, 0x52, 0xc7, 0x8e, 0x0c, 0xa8, 0x40, 0xf3, 0x06, 0x3c, + 0x01, 0x6a, 0xe2, 0x20, 0x06, 0xb6, 0xfb, 0x7e, 0xee, 0x4e, 0xa7, 0x73, 0x07, 0x77, 0x3a, 0x52, + 0xb3, 0x50, 0x15, 0x54, 0x19, 0x4e, 0x73, 0x9f, 0xc6, 0x2c, 0x61, 0x3a, 0x25, 0x71, 0x02, 0x06, + 0x3a, 0x27, 0xcd, 0x95, 0x28, 0xc3, 0x49, 0xee, 0xf7, 0x31, 0x87, 0x54, 0x43, 0x4a, 0x03, 0x96, + 0x0a, 0x9a, 0xfb, 0x81, 0x30, 0xcc, 0xa7, 0x1c, 0x54, 0x54, 0x13, 0xfa, 0xa7, 0x12, 0x24, 0x54, + 0x90, 0x1e, 0x90, 0xdd, 0x62, 0x09, 0x20, 0x43, 0x41, 0xab, 0x29, 0xc8, 0x96, 0xf4, 0x29, 0x4b, + 0x98, 0x51, 0x60, 0x59, 0xde, 0x3b, 0x72, 0x5b, 0xf7, 0x95, 0x6f, 0xe7, 0xd9, 0x3d, 0xd3, 0xac, + 0x58, 0x70, 0xa6, 0x63, 0xa6, 0x64, 0xb4, 0x68, 0x3e, 0x7b, 0xe8, 0x12, 0x8d, 0xda, 0xe3, 0x73, + 0x52, 0x4b, 0x91, 0x46, 0x8a, 0xdc, 0xd8, 0x87, 0xc9, 0x68, 0xb3, 0x1b, 0x3a, 0xdf, 0xbb, 0xe1, + 0x60, 0xcd, 0x74, 0x78, 0xed, 0xfd, 0xab, 0xe2, 0xbd, 0x7e, 0x0c, 0xd1, 0xbc, 0xab, 0x59, 0x31, + 0xb5, 0xa7, 0x86, 0xde, 0x79, 0x70, 0x8f, 0x79, 0x22, 0x2a, 0xbc, 0x58, 0x0a, 0xd1, 0x3b, 0xb2, + 0x7e, 0x75, 0x60, 0x72, 0x08, 0x4c, 0x6c, 0x60, 0x32, 0x05, 0x15, 0x4d, 0x2e, 0xac, 0x5f, 0xb7, + 0xf6, 0xfb, 0x4b, 0xf6, 0xe6, 0xed, 0x66, 0x9c, 0x09, 0x31, 0xb9, 0xdd, 0x7c, 0x61, 0x67, 0xb3, + 0xc7, 0x68, 0xbb, 0xc7, 0xe8, 0x73, 0x8f, 0xd1, 0x4b, 0x89, 0x9d, 0x6d, 0x89, 0x9d, 0xb7, 0x12, + 0x3b, 0x8f, 0x44, 0x2a, 0xb3, 0xca, 0x02, 0xc2, 0x41, 0xd3, 0xdf, 0x32, 0x40, 0x47, 0x6a, 0x19, + 0xaa, 0x62, 0x95, 0x05, 0x34, 0x1f, 0xd3, 0xba, 0x1d, 0xb3, 0x8e, 0x45, 0x1a, 0xb4, 0xaa, 0xe8, + 0x57, 0x3f, 0x01, 0x00, 0x00, 0xff, 0xff, 0x52, 0xb9, 0x69, 0x94, 0xba, 0x01, 0x00, 0x00, } func (m *Params) Marshal() (dAtA []byte, err error) { diff --git a/x/itc/types/params_legacy.go b/x/itc/types/params_legacy.go new file mode 100644 index 00000000..aaee29bb --- /dev/null +++ b/x/itc/types/params_legacy.go @@ -0,0 +1,25 @@ +package types + +import ( + paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" +) + +var ( + ParamStoreKeyMaxCampaignDuration = []byte("MaxCampaignDuration") + ParamStoreKeyCampaignCreationFee = []byte("CampaignCreationFee") +) + +var _ paramtypes.ParamSet = (*Params)(nil) + +// ParamKeyTable returns the parameter key table. +func ParamKeyTable() paramtypes.KeyTable { + return paramtypes.NewKeyTable().RegisterParamSet(&Params{}) +} + +// ParamSetPairs returns the parameter set pairs. +func (p *Params) ParamSetPairs() paramtypes.ParamSetPairs { + return paramtypes.ParamSetPairs{ + paramtypes.NewParamSetPair(ParamStoreKeyMaxCampaignDuration, &p.MaxCampaignDuration, validateMaxCampaignDuration), + paramtypes.NewParamSetPair(ParamStoreKeyCampaignCreationFee, &p.CreationFee, validateCampaignCreationFee), + } +} diff --git a/x/itc/types/query.pb.go b/x/itc/types/query.pb.go index 75a7c08c..32eca7a0 100644 --- a/x/itc/types/query.pb.go +++ b/x/itc/types/query.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: omniflix/itc/v1/query.proto +// source: OmniFlix/itc/v1/query.proto package types @@ -7,9 +7,9 @@ import ( context "context" fmt "fmt" query "github.com/cosmos/cosmos-sdk/types/query" - _ "github.com/gogo/protobuf/gogoproto" - grpc1 "github.com/gogo/protobuf/grpc" - proto "github.com/gogo/protobuf/proto" + _ "github.com/cosmos/gogoproto/gogoproto" + grpc1 "github.com/cosmos/gogoproto/grpc" + proto "github.com/cosmos/gogoproto/proto" _ "google.golang.org/genproto/googleapis/api/annotations" grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" @@ -38,7 +38,7 @@ func (m *QueryParamsRequest) Reset() { *m = QueryParamsRequest{} } func (m *QueryParamsRequest) String() string { return proto.CompactTextString(m) } func (*QueryParamsRequest) ProtoMessage() {} func (*QueryParamsRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_f8ec6107537089f6, []int{0} + return fileDescriptor_ef132d1435694c85, []int{0} } func (m *QueryParamsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -77,7 +77,7 @@ func (m *QueryParamsResponse) Reset() { *m = QueryParamsResponse{} } func (m *QueryParamsResponse) String() string { return proto.CompactTextString(m) } func (*QueryParamsResponse) ProtoMessage() {} func (*QueryParamsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_f8ec6107537089f6, []int{1} + return fileDescriptor_ef132d1435694c85, []int{1} } func (m *QueryParamsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -117,7 +117,7 @@ func (m *QueryCampaignsRequest) Reset() { *m = QueryCampaignsRequest{} } func (m *QueryCampaignsRequest) String() string { return proto.CompactTextString(m) } func (*QueryCampaignsRequest) ProtoMessage() {} func (*QueryCampaignsRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_f8ec6107537089f6, []int{2} + return fileDescriptor_ef132d1435694c85, []int{2} } func (m *QueryCampaignsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -157,7 +157,7 @@ func (m *QueryCampaignsResponse) Reset() { *m = QueryCampaignsResponse{} func (m *QueryCampaignsResponse) String() string { return proto.CompactTextString(m) } func (*QueryCampaignsResponse) ProtoMessage() {} func (*QueryCampaignsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_f8ec6107537089f6, []int{3} + return fileDescriptor_ef132d1435694c85, []int{3} } func (m *QueryCampaignsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -195,7 +195,7 @@ func (m *QueryCampaignRequest) Reset() { *m = QueryCampaignRequest{} } func (m *QueryCampaignRequest) String() string { return proto.CompactTextString(m) } func (*QueryCampaignRequest) ProtoMessage() {} func (*QueryCampaignRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_f8ec6107537089f6, []int{4} + return fileDescriptor_ef132d1435694c85, []int{4} } func (m *QueryCampaignRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -233,7 +233,7 @@ func (m *QueryCampaignResponse) Reset() { *m = QueryCampaignResponse{} } func (m *QueryCampaignResponse) String() string { return proto.CompactTextString(m) } func (*QueryCampaignResponse) ProtoMessage() {} func (*QueryCampaignResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_f8ec6107537089f6, []int{5} + return fileDescriptor_ef132d1435694c85, []int{5} } func (m *QueryCampaignResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -273,7 +273,7 @@ func (m *QueryClaimsRequest) Reset() { *m = QueryClaimsRequest{} } func (m *QueryClaimsRequest) String() string { return proto.CompactTextString(m) } func (*QueryClaimsRequest) ProtoMessage() {} func (*QueryClaimsRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_f8ec6107537089f6, []int{6} + return fileDescriptor_ef132d1435694c85, []int{6} } func (m *QueryClaimsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -311,7 +311,7 @@ func (m *QueryClaimsResponse) Reset() { *m = QueryClaimsResponse{} } func (m *QueryClaimsResponse) String() string { return proto.CompactTextString(m) } func (*QueryClaimsResponse) ProtoMessage() {} func (*QueryClaimsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_f8ec6107537089f6, []int{7} + return fileDescriptor_ef132d1435694c85, []int{7} } func (m *QueryClaimsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -351,51 +351,51 @@ func init() { proto.RegisterType((*QueryClaimsResponse)(nil), "OmniFlix.itc.v1.QueryClaimsResponse") } -func init() { proto.RegisterFile("omniflix/itc/v1/query.proto", fileDescriptor_f8ec6107537089f6) } +func init() { proto.RegisterFile("OmniFlix/itc/v1/query.proto", fileDescriptor_ef132d1435694c85) } -var fileDescriptor_f8ec6107537089f6 = []byte{ - // 648 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x54, 0x4d, 0x6b, 0x13, 0x4f, - 0x1c, 0xce, 0xb4, 0xfd, 0xe7, 0x6f, 0xa7, 0xa0, 0x30, 0xd6, 0x36, 0x8d, 0x65, 0x53, 0x56, 0x6d, - 0x43, 0x85, 0x1d, 0x13, 0x15, 0x41, 0xf1, 0x92, 0x42, 0xa5, 0x20, 0xb4, 0xae, 0x9e, 0xbc, 0xc8, - 0x64, 0xb3, 0x6e, 0x07, 0xb2, 0x3b, 0xdb, 0xdd, 0x49, 0x68, 0x10, 0x41, 0xc4, 0x9b, 0x17, 0x41, +var fileDescriptor_ef132d1435694c85 = []byte{ + // 650 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x54, 0x4f, 0x6b, 0x13, 0x4f, + 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0x67, 0x4d, 0x60, + 0x7b, 0x5e, 0x9a, 0xc2, 0xbf, 0x2d, 0xf0, 0x77, 0x51, 0x75, 0x3a, 0x3e, 0x7e, 0x33, 0x61, 0xcd, + 0xb7, 0x89, 0x0c, 0xd2, 0x21, 0xd3, 0x64, 0x48, 0x39, 0x7b, 0x9a, 0x0c, 0x69, 0x93, 0xcd, 0x90, + 0x41, 0xfa, 0xa9, 0x71, 0xd0, 0xff, 0x6d, 0x14, 0xfa, 0x03, 0x03, 0x9c, 0x0e, 0x0c, 0xf0, 0x6b, + 0x60, 0x80, 0x4f, 0x43, 0xa3, 0x70, 0x3a, 0x34, 0x0a, 0x3f, 0x87, 0x46, 0xe1, 0x85, 0xe5, 0x51, + 0x7e, 0xdc, 0x69, 0x5a, 0x0e, 0xf3, 0xf1, 0xe8, 0x79, 0xd7, 0x9d, 0x8e, 0x3b, 0x4d, 0xdc, 0xad, + 0x63, 0xd9, 0x91, 0xf7, 0x42, 0x37, 0x6e, 0x16, 0xc5, 0x7b, 0x7f, 0xe7, 0x5f, 0x00, 0x00, 0x00, + 0xff, 0xff, 0xd2, 0x56, 0x96, 0xca, 0xb8, 0x06, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -583,7 +583,7 @@ var _Query_serviceDesc = grpc.ServiceDesc{ }, }, Streams: []grpc.StreamDesc{}, - Metadata: "omniflix/itc/v1/query.proto", + Metadata: "OmniFlix/itc/v1/query.proto", } func (m *QueryParamsRequest) Marshal() (dAtA []byte, err error) { diff --git a/x/itc/types/query.pb.gw.go b/x/itc/types/query.pb.gw.go index 10e12a3e..51694e21 100644 --- a/x/itc/types/query.pb.gw.go +++ b/x/itc/types/query.pb.gw.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-grpc-gateway. DO NOT EDIT. -// source: omniflix/itc/v1/query.proto +// source: OmniFlix/itc/v1/query.proto /* Package types is a reverse proxy. @@ -400,13 +400,13 @@ func RegisterQueryHandlerClient(ctx context.Context, mux *runtime.ServeMux, clie } var ( - pattern_Query_Params_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"omniflix", "itc", "v1", "params"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_Params_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"omniflix", "itc", "v1", "params"}, "", runtime.AssumeColonVerbOpt(false))) - pattern_Query_Campaigns_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"omniflix", "itc", "v1", "campaigns"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_Campaigns_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"omniflix", "itc", "v1", "campaigns"}, "", runtime.AssumeColonVerbOpt(false))) - pattern_Query_Campaign_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4}, []string{"omniflix", "itc", "v1", "campaigns", "campaign_id"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_Campaign_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4}, []string{"omniflix", "itc", "v1", "campaigns", "campaign_id"}, "", runtime.AssumeColonVerbOpt(false))) - pattern_Query_Claims_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"omniflix", "itc", "v1", "claims"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_Claims_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"omniflix", "itc", "v1", "claims"}, "", runtime.AssumeColonVerbOpt(false))) ) var ( diff --git a/x/itc/types/tx.pb.go b/x/itc/types/tx.pb.go index 96521acd..91103bef 100644 --- a/x/itc/types/tx.pb.go +++ b/x/itc/types/tx.pb.go @@ -1,16 +1,18 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: omniflix/itc/v1/tx.proto +// source: OmniFlix/itc/v1/tx.proto package types import ( context "context" fmt "fmt" + _ "github.com/cosmos/cosmos-proto" types "github.com/cosmos/cosmos-sdk/types" - _ "github.com/gogo/protobuf/gogoproto" - grpc1 "github.com/gogo/protobuf/grpc" - proto "github.com/gogo/protobuf/proto" - github_com_gogo_protobuf_types "github.com/gogo/protobuf/types" + _ "github.com/cosmos/cosmos-sdk/types/msgservice" + _ "github.com/cosmos/gogoproto/gogoproto" + grpc1 "github.com/cosmos/gogoproto/grpc" + proto "github.com/cosmos/gogoproto/proto" + github_com_gogo_protobuf_types "github.com/cosmos/gogoproto/types" grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" @@ -55,7 +57,7 @@ func (m *MsgCreateCampaign) Reset() { *m = MsgCreateCampaign{} } func (m *MsgCreateCampaign) String() string { return proto.CompactTextString(m) } func (*MsgCreateCampaign) ProtoMessage() {} func (*MsgCreateCampaign) Descriptor() ([]byte, []int) { - return fileDescriptor_175246c809bd38a4, []int{0} + return fileDescriptor_eab55ed2c687566d, []int{0} } func (m *MsgCreateCampaign) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -91,7 +93,7 @@ func (m *MsgCreateCampaignResponse) Reset() { *m = MsgCreateCampaignResp func (m *MsgCreateCampaignResponse) String() string { return proto.CompactTextString(m) } func (*MsgCreateCampaignResponse) ProtoMessage() {} func (*MsgCreateCampaignResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_175246c809bd38a4, []int{1} + return fileDescriptor_eab55ed2c687566d, []int{1} } func (m *MsgCreateCampaignResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -129,7 +131,7 @@ func (m *MsgCancelCampaign) Reset() { *m = MsgCancelCampaign{} } func (m *MsgCancelCampaign) String() string { return proto.CompactTextString(m) } func (*MsgCancelCampaign) ProtoMessage() {} func (*MsgCancelCampaign) Descriptor() ([]byte, []int) { - return fileDescriptor_175246c809bd38a4, []int{2} + return fileDescriptor_eab55ed2c687566d, []int{2} } func (m *MsgCancelCampaign) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -165,7 +167,7 @@ func (m *MsgCancelCampaignResponse) Reset() { *m = MsgCancelCampaignResp func (m *MsgCancelCampaignResponse) String() string { return proto.CompactTextString(m) } func (*MsgCancelCampaignResponse) ProtoMessage() {} func (*MsgCancelCampaignResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_175246c809bd38a4, []int{3} + return fileDescriptor_eab55ed2c687566d, []int{3} } func (m *MsgCancelCampaignResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -205,7 +207,7 @@ func (m *MsgClaim) Reset() { *m = MsgClaim{} } func (m *MsgClaim) String() string { return proto.CompactTextString(m) } func (*MsgClaim) ProtoMessage() {} func (*MsgClaim) Descriptor() ([]byte, []int) { - return fileDescriptor_175246c809bd38a4, []int{4} + return fileDescriptor_eab55ed2c687566d, []int{4} } func (m *MsgClaim) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -241,7 +243,7 @@ func (m *MsgClaimResponse) Reset() { *m = MsgClaimResponse{} } func (m *MsgClaimResponse) String() string { return proto.CompactTextString(m) } func (*MsgClaimResponse) ProtoMessage() {} func (*MsgClaimResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_175246c809bd38a4, []int{5} + return fileDescriptor_eab55ed2c687566d, []int{5} } func (m *MsgClaimResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -280,7 +282,7 @@ func (m *MsgDepositCampaign) Reset() { *m = MsgDepositCampaign{} } func (m *MsgDepositCampaign) String() string { return proto.CompactTextString(m) } func (*MsgDepositCampaign) ProtoMessage() {} func (*MsgDepositCampaign) Descriptor() ([]byte, []int) { - return fileDescriptor_175246c809bd38a4, []int{6} + return fileDescriptor_eab55ed2c687566d, []int{6} } func (m *MsgDepositCampaign) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -316,7 +318,7 @@ func (m *MsgDepositCampaignResponse) Reset() { *m = MsgDepositCampaignRe func (m *MsgDepositCampaignResponse) String() string { return proto.CompactTextString(m) } func (*MsgDepositCampaignResponse) ProtoMessage() {} func (*MsgDepositCampaignResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_175246c809bd38a4, []int{7} + return fileDescriptor_eab55ed2c687566d, []int{7} } func (m *MsgDepositCampaignResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -345,6 +347,91 @@ func (m *MsgDepositCampaignResponse) XXX_DiscardUnknown() { var xxx_messageInfo_MsgDepositCampaignResponse proto.InternalMessageInfo +// MsgUpdateParams is the Msg/UpdateParams request type. +// +// Since: cosmos-sdk 0.47 +type MsgUpdateParams struct { + // authority is the address of the governance account. + Authority string `protobuf:"bytes,1,opt,name=authority,proto3" json:"authority,omitempty"` + // params defines the x/itc parameters to update. + // + // NOTE: All parameters must be supplied. + Params Params `protobuf:"bytes,2,opt,name=params,proto3" json:"params"` +} + +func (m *MsgUpdateParams) Reset() { *m = MsgUpdateParams{} } +func (m *MsgUpdateParams) String() string { return proto.CompactTextString(m) } +func (*MsgUpdateParams) ProtoMessage() {} +func (*MsgUpdateParams) Descriptor() ([]byte, []int) { + return fileDescriptor_eab55ed2c687566d, []int{8} +} +func (m *MsgUpdateParams) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *MsgUpdateParams) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_MsgUpdateParams.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 *MsgUpdateParams) XXX_Merge(src proto.Message) { + xxx_messageInfo_MsgUpdateParams.Merge(m, src) +} +func (m *MsgUpdateParams) XXX_Size() int { + return m.Size() +} +func (m *MsgUpdateParams) XXX_DiscardUnknown() { + xxx_messageInfo_MsgUpdateParams.DiscardUnknown(m) +} + +var xxx_messageInfo_MsgUpdateParams proto.InternalMessageInfo + +// MsgUpdateParamsResponse defines the response structure for executing a +// MsgUpdateParams message. +// +// Since: cosmos-sdk 0.47 +type MsgUpdateParamsResponse struct { +} + +func (m *MsgUpdateParamsResponse) Reset() { *m = MsgUpdateParamsResponse{} } +func (m *MsgUpdateParamsResponse) String() string { return proto.CompactTextString(m) } +func (*MsgUpdateParamsResponse) ProtoMessage() {} +func (*MsgUpdateParamsResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_eab55ed2c687566d, []int{9} +} +func (m *MsgUpdateParamsResponse) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *MsgUpdateParamsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_MsgUpdateParamsResponse.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 *MsgUpdateParamsResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_MsgUpdateParamsResponse.Merge(m, src) +} +func (m *MsgUpdateParamsResponse) XXX_Size() int { + return m.Size() +} +func (m *MsgUpdateParamsResponse) XXX_DiscardUnknown() { + xxx_messageInfo_MsgUpdateParamsResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_MsgUpdateParamsResponse proto.InternalMessageInfo + func init() { proto.RegisterType((*MsgCreateCampaign)(nil), "OmniFlix.itc.v1.MsgCreateCampaign") proto.RegisterType((*MsgCreateCampaignResponse)(nil), "OmniFlix.itc.v1.MsgCreateCampaignResponse") @@ -354,69 +441,79 @@ func init() { proto.RegisterType((*MsgClaimResponse)(nil), "OmniFlix.itc.v1.MsgClaimResponse") proto.RegisterType((*MsgDepositCampaign)(nil), "OmniFlix.itc.v1.MsgDepositCampaign") proto.RegisterType((*MsgDepositCampaignResponse)(nil), "OmniFlix.itc.v1.MsgDepositCampaignResponse") -} - -func init() { proto.RegisterFile("omniflix/itc/v1/tx.proto", fileDescriptor_175246c809bd38a4) } - -var fileDescriptor_175246c809bd38a4 = []byte{ - // 900 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x55, 0x4d, 0x6f, 0xe3, 0x44, - 0x18, 0x8e, 0x77, 0xd3, 0x8f, 0xbc, 0x29, 0xd9, 0xee, 0xc0, 0xee, 0x3a, 0xe9, 0xd6, 0x0e, 0xe6, - 0x52, 0xb1, 0x92, 0xad, 0x96, 0x03, 0x82, 0x0b, 0x5a, 0x37, 0x54, 0x8a, 0x56, 0x5d, 0x56, 0x56, - 0x0f, 0x80, 0x84, 0xc2, 0xc4, 0x9e, 0x78, 0x47, 0xd8, 0x33, 0x96, 0x67, 0x52, 0xd2, 0xff, 0xc0, - 0x61, 0x8f, 0x1c, 0xf9, 0x39, 0x3d, 0x70, 0xd8, 0x23, 0xa7, 0x00, 0xed, 0x3f, 0x88, 0xc4, 0x1d, - 0xcd, 0xd8, 0x4e, 0xf3, 0xd1, 0xa5, 0x7b, 0xe0, 0x36, 0xf3, 0xce, 0xf3, 0x3e, 0xef, 0xf3, 0x7e, - 0xd9, 0x60, 0xf2, 0x94, 0xd1, 0x51, 0x42, 0x27, 0x1e, 0x95, 0xa1, 0x77, 0x7e, 0xe8, 0xc9, 0x89, - 0x9b, 0xe5, 0x5c, 0x72, 0xf4, 0xe0, 0x9b, 0x94, 0xd1, 0x93, 0x84, 0x4e, 0x5c, 0x2a, 0x43, 0xf7, - 0xfc, 0xb0, 0x63, 0x85, 0x5c, 0xa4, 0x5c, 0x78, 0x43, 0x2c, 0x88, 0x77, 0x7e, 0x38, 0x24, 0x12, - 0x1f, 0x7a, 0x21, 0xa7, 0xac, 0x70, 0xe8, 0x7c, 0x14, 0xf3, 0x98, 0xeb, 0xa3, 0xa7, 0x4e, 0xa5, -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00, 0x00, 0xff, 0xff, 0x16, 0x9c, 0x0b, 0x87, - 0x45, 0x08, 0x00, 0x00, + proto.RegisterType((*MsgUpdateParams)(nil), "OmniFlix.itc.v1.MsgUpdateParams") + proto.RegisterType((*MsgUpdateParamsResponse)(nil), "OmniFlix.itc.v1.MsgUpdateParamsResponse") +} + +func init() { proto.RegisterFile("OmniFlix/itc/v1/tx.proto", fileDescriptor_eab55ed2c687566d) } + +var fileDescriptor_eab55ed2c687566d = []byte{ + // 1030 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x56, 0x3f, 0x6f, 0xe4, 0x44, + 0x14, 0x8f, 0xef, 0xf2, 0x6f, 0x67, 0xc3, 0x26, 0x37, 0xdc, 0x5d, 0xbc, 0x9b, 0x64, 0xbd, 0x98, + 0x26, 0x3a, 0x84, 0xad, 0x04, 0x01, 0xe2, 0x1a, 0x14, 0x27, 0x44, 0x8a, 0x8e, 0x1c, 0x91, 0x09, + 0x12, 0x9c, 0x84, 0x96, 0x59, 0x7b, 0xd6, 0x19, 0xb1, 0x9e, 0xb1, 0x3c, 0xb3, 0x21, 0x69, 0xa9, + 0x29, 0x52, 0x52, 0xf2, 0x11, 0x28, 0xf8, 0x10, 0x29, 0x28, 0x0e, 0x2a, 0xaa, 0x05, 0x92, 0x82, + 0x3e, 0x9f, 0x00, 0xcd, 0x1f, 0xef, 0x1f, 0x6f, 0x8e, 0x5c, 0x41, 0x37, 0xf3, 0xde, 0xef, 0xfd, + 0x7e, 0xef, 0xcd, 0xbc, 0x37, 0x36, 0xb0, 0x3f, 0x4b, 0x29, 0xd9, 0xef, 0x91, 0x33, 0x9f, 0x88, + 0xc8, 0x3f, 0xdd, 0xf2, 0xc5, 0x99, 0x97, 0xe5, 0x4c, 0x30, 0xb8, 0x5c, 0x78, 0x3c, 0x22, 0x22, + 0xef, 0x74, 0xab, 0xb1, 0x1a, 0x31, 0x9e, 0x32, 0xee, 0xa7, 0x3c, 0x91, 0xc0, 0x94, 0x27, 0x1a, + 0xd9, 0x68, 0x1a, 0x47, 0x07, 0x71, 0xec, 0x9f, 0x6e, 0x75, 0xb0, 0x40, 0x5b, 0x7e, 0xc4, 0x08, + 0x35, 0xfe, 0x87, 0x09, 0x4b, 0x98, 0x5a, 0xfa, 0x72, 0x65, 0xac, 0x75, 0x1d, 0xd5, 0xd6, 0x0e, + 0xbd, 0x31, 0x2e, 0x27, 0x61, 0x2c, 0xe9, 0x61, 0x5f, 0xed, 0x3a, 0xfd, 0xae, 0x2f, 0x48, 0x8a, + 0xb9, 0x40, 0x69, 0x56, 0x28, 0x96, 0x01, 0x71, 0x3f, 0x47, 0x82, 0xb0, 0x42, 0xb1, 0x5e, 0xae, + 0x4a, 0x96, 0xa0, 0x5d, 0xeb, 0x65, 0x57, 0x86, 0x72, 0x94, 0x1a, 0x65, 0xf7, 0xd7, 0x05, 0xf0, + 0xe0, 0x90, 0x27, 0xbb, 0x39, 0x46, 0x02, 0xef, 0xa2, 0x34, 0x43, 0x24, 0xa1, 0x10, 0x82, 0x59, + 0x8a, 0x52, 0x6c, 0x5b, 0x2d, 0x6b, 0xb3, 0x12, 0xaa, 0x35, 0x6c, 0x81, 0x6a, 0x8c, 0x79, 0x94, + 0x93, 0x4c, 0xea, 0xda, 0xf7, 0x94, 0x6b, 0xdc, 0x04, 0x03, 0x50, 0x25, 0x54, 0xe0, 0x1c, 0x45, + 0x0a, 0x71, 0xbf, 0x65, 0x6d, 0xd6, 0xb6, 0x5b, 0x5e, 0xe9, 0x58, 0xbd, 0x83, 0x11, 0xe6, 0xf8, + 0x3c, 0xc3, 0xe1, 0x78, 0x10, 0x3c, 0x02, 0x20, 0xea, 0x21, 0x92, 0xb6, 0xc5, 0x79, 0x86, 0xed, + 0x59, 0x45, 0xd1, 0x98, 0xa2, 0xd8, 0x95, 0x10, 0x19, 0x1c, 0x3c, 0xba, 0x19, 0x38, 0x0f, 0xce, + 0x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, 0xc1, 0xe3, 0x9b, 0x81, 0x03, 0xc7, 0xcf, 0x56, 0x99, 0xdd, + 0xb0, 0x46, 0xbb, 0xe2, 0x90, 0x50, 0x61, 0x70, 0xf0, 0x4b, 0x00, 0xb8, 0x40, 0xb9, 0x68, 0xcb, + 0x6e, 0xb7, 0x81, 0x22, 0x6e, 0x78, 0xba, 0xd3, 0xbd, 0xa2, 0xd3, 0xbd, 0xe3, 0x62, 0x14, 0x82, + 0x0d, 0x93, 0xaf, 0xb9, 0xef, 0x51, 0xac, 0x7b, 0xf1, 0xa7, 0x63, 0x85, 0x15, 0x65, 0x90, 0x70, + 0xf8, 0x31, 0x58, 0x2c, 0x06, 0xc4, 0xae, 0x9a, 0x63, 0x28, 0xf3, 0xee, 0x19, 0x40, 0xb0, 0x28, + 0x69, 0x7f, 0x94, 0x0c, 0xc3, 0x20, 0xb8, 0x03, 0x96, 0x62, 0xc2, 0x45, 0x4e, 0x3a, 0x7d, 0x45, + 0xb2, 0xa4, 0x48, 0x36, 0xa6, 0xaa, 0xde, 0x1b, 0x03, 0x85, 0x13, 0x21, 0xd0, 0x06, 0x0b, 0x91, + 0x9c, 0x2a, 0x96, 0xdb, 0x6f, 0xa8, 0x59, 0x29, 0xb6, 0xf0, 0x2b, 0xb0, 0xa4, 0x96, 0x84, 0xd1, + 0x76, 0x17, 0x63, 0xbb, 0x76, 0xd7, 0x45, 0xad, 0x99, 0xc2, 0x4d, 0xc3, 0x8e, 0x07, 0xbb, 0x61, + 0xb5, 0xd8, 0xee, 0x63, 0xec, 0xae, 0x81, 0xfa, 0xd4, 0x34, 0x87, 0x98, 0x67, 0x8c, 0x72, 0xec, + 0x3e, 0xd7, 0xa3, 0x8e, 0x68, 0x84, 0x7b, 0xc3, 0x51, 0x77, 0x40, 0x35, 0x32, 0x6b, 0x39, 0x1d, + 0x72, 0xe2, 0x67, 0x43, 0x50, 0x98, 0x0e, 0xe2, 0xf1, 0x3a, 0xee, 0x4d, 0xd4, 0x51, 0x88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, 0x43, 0x9e, 0xc0, 0x6f, 0x40, 0xad, 0xf4, 0xb9, 0x71, 0xa7, 0xb4, 0xa6, + 0x9a, 0xb8, 0xf1, 0xe4, 0x6e, 0x4c, 0xa1, 0xa4, 0x14, 0x26, 0xbb, 0xfc, 0x76, 0x85, 0x09, 0xcc, + 0x2b, 0x14, 0x6e, 0xed, 0x6e, 0xf8, 0x09, 0x98, 0xd3, 0x9d, 0x5d, 0xbf, 0x35, 0x48, 0xba, 0x1a, + 0x6f, 0xbd, 0xd2, 0x35, 0xa4, 0x89, 0xc0, 0x72, 0xb9, 0xd3, 0xde, 0xbe, 0x2d, 0xaa, 0x04, 0x6a, + 0xbc, 0xf3, 0x1a, 0xa0, 0xa1, 0xc8, 0x0b, 0xb0, 0x34, 0xd1, 0x21, 0xad, 0xdb, 0x82, 0xc7, 0x11, + 0x8d, 0xcd, 0xbb, 0x10, 0x05, 0x77, 0xf0, 0xe9, 0xe5, 0xdf, 0xcd, 0x99, 0xcb, 0xab, 0xa6, 0xf5, + 0xf2, 0xaa, 0x69, 0xfd, 0x75, 0xd5, 0xb4, 0x2e, 0xae, 0x9b, 0x33, 0x2f, 0xaf, 0x9b, 0x33, 0x7f, + 0x5c, 0x37, 0x67, 0x5e, 0x78, 0x09, 0x11, 0x27, 0xfd, 0x8e, 0x17, 0xb1, 0xd4, 0x1f, 0xfe, 0x85, + 0xb0, 0x94, 0x92, 0x6e, 0x8f, 0x9c, 0x9d, 0xf4, 0x3b, 0xfe, 0xe9, 0xb6, 0xaf, 0x7f, 0x4b, 0xe4, + 0x57, 0x9b, 0x77, 0xe6, 0xd5, 0xe3, 0xfc, 0xde, 0xbf, 0x01, 0x00, 0x00, 0xff, 0xff, 0xf6, 0x0e, + 0xf2, 0x2b, 0xa4, 0x09, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -435,6 +532,11 @@ type MsgClient interface { CancelCampaign(ctx context.Context, in *MsgCancelCampaign, opts ...grpc.CallOption) (*MsgCancelCampaignResponse, error) Claim(ctx context.Context, in *MsgClaim, opts ...grpc.CallOption) (*MsgClaimResponse, error) DepositCampaign(ctx context.Context, in *MsgDepositCampaign, opts ...grpc.CallOption) (*MsgDepositCampaignResponse, error) + // UpdateParams defines a governance operation for updating the x/itc module + // parameters. The authority is hard-coded to the x/gov module account. + // + // Since: cosmos-sdk 0.47 + UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) } type msgClient struct { @@ -481,12 +583,26 @@ func (c *msgClient) DepositCampaign(ctx context.Context, in *MsgDepositCampaign, return out, nil } +func (c *msgClient) UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) { + out := new(MsgUpdateParamsResponse) + err := c.cc.Invoke(ctx, "/OmniFlix.itc.v1.Msg/UpdateParams", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + // MsgServer is the server API for Msg service. type MsgServer interface { CreateCampaign(context.Context, *MsgCreateCampaign) (*MsgCreateCampaignResponse, error) CancelCampaign(context.Context, *MsgCancelCampaign) (*MsgCancelCampaignResponse, error) Claim(context.Context, *MsgClaim) (*MsgClaimResponse, error) DepositCampaign(context.Context, *MsgDepositCampaign) (*MsgDepositCampaignResponse, error) + // UpdateParams defines a governance operation for updating the x/itc module + // parameters. The authority is hard-coded to the x/gov module account. + // + // Since: cosmos-sdk 0.47 + UpdateParams(context.Context, *MsgUpdateParams) (*MsgUpdateParamsResponse, error) } // UnimplementedMsgServer can be embedded to have forward compatible implementations. @@ -505,6 +621,9 @@ func (*UnimplementedMsgServer) Claim(ctx context.Context, req *MsgClaim) (*MsgCl func (*UnimplementedMsgServer) DepositCampaign(ctx context.Context, req *MsgDepositCampaign) (*MsgDepositCampaignResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method DepositCampaign not implemented") } +func (*UnimplementedMsgServer) UpdateParams(ctx context.Context, req *MsgUpdateParams) (*MsgUpdateParamsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method UpdateParams not implemented") +} func RegisterMsgServer(s grpc1.Server, srv MsgServer) { s.RegisterService(&_Msg_serviceDesc, srv) @@ -582,6 +701,24 @@ func _Msg_DepositCampaign_Handler(srv interface{}, ctx context.Context, dec func return interceptor(ctx, in, info, handler) } +func _Msg_UpdateParams_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgUpdateParams) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).UpdateParams(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/OmniFlix.itc.v1.Msg/UpdateParams", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).UpdateParams(ctx, req.(*MsgUpdateParams)) + } + return interceptor(ctx, in, info, handler) +} + var _Msg_serviceDesc = grpc.ServiceDesc{ ServiceName: "OmniFlix.itc.v1.Msg", HandlerType: (*MsgServer)(nil), @@ -602,9 +739,13 @@ var _Msg_serviceDesc = grpc.ServiceDesc{ MethodName: "DepositCampaign", Handler: _Msg_DepositCampaign_Handler, }, + { + MethodName: "UpdateParams", + Handler: _Msg_UpdateParams_Handler, + }, }, Streams: []grpc.StreamDesc{}, - Metadata: "omniflix/itc/v1/tx.proto", + Metadata: "OmniFlix/itc/v1/tx.proto", } func (m *MsgCreateCampaign) Marshal() (dAtA []byte, err error) { @@ -962,6 +1103,69 @@ func (m *MsgDepositCampaignResponse) MarshalToSizedBuffer(dAtA []byte) (int, err return len(dAtA) - i, nil } +func (m *MsgUpdateParams) 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 *MsgUpdateParams) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *MsgUpdateParams) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + { + size, err := m.Params.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintTx(dAtA, i, uint64(size)) + } + 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 *MsgUpdateParamsResponse) 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 *MsgUpdateParamsResponse) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *MsgUpdateParamsResponse) 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 @@ -1118,6 +1322,30 @@ func (m *MsgDepositCampaignResponse) Size() (n int) { return n } +func (m *MsgUpdateParams) 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 = m.Params.Size() + n += 1 + l + sovTx(uint64(l)) + return n +} + +func (m *MsgUpdateParamsResponse) 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 } @@ -2183,6 +2411,171 @@ func (m *MsgDepositCampaignResponse) Unmarshal(dAtA []byte) error { } return nil } +func (m *MsgUpdateParams) 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: MsgUpdateParams: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: MsgUpdateParams: 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 Params", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Params.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 *MsgUpdateParamsResponse) 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: MsgUpdateParamsResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: MsgUpdateParamsResponse: 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 skipTx(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 diff --git a/x/itc/types/validation.go b/x/itc/types/validation.go index ec4985fc..d90daef3 100644 --- a/x/itc/types/validation.go +++ b/x/itc/types/validation.go @@ -3,6 +3,8 @@ package types import ( "time" + errorsmod "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" ) @@ -10,7 +12,7 @@ import ( // ValidateCampaign checks campaign is valid or not func ValidateCampaign(campaign Campaign) error { if _, err := sdk.AccAddressFromBech32(campaign.Creator); err != nil { - return sdkerrors.Wrapf(sdkerrors.ErrInvalidAddress, "invalid creator address (%s)", err) + return errorsmod.Wrapf(sdkerrors.ErrInvalidAddress, "invalid creator address (%s)", err) } if err := ValidateClaimType(campaign.ClaimType); err != nil { return err @@ -37,7 +39,7 @@ func ValidateCampaign(campaign Campaign) error { } } if campaign.MaxAllowedClaims == 0 { - return sdkerrors.Wrapf(ErrInValidMaxAllowedClaims, + return errorsmod.Wrapf(ErrInValidMaxAllowedClaims, "max allowed claims must be a positive number (%d)", campaign.MaxAllowedClaims) } return nil @@ -46,10 +48,10 @@ func ValidateCampaign(campaign Campaign) error { func ValidateDuration(t interface{}) error { duration, ok := t.(time.Duration) if !ok { - return sdkerrors.Wrapf(ErrInvalidDuration, "invalid value for duration: %T", t) + return errorsmod.Wrapf(ErrInvalidDuration, "invalid value for duration: %T", t) } if duration.Nanoseconds() <= 0 { - return sdkerrors.Wrapf(ErrInvalidDuration, + return errorsmod.Wrapf(ErrInvalidDuration, "invalid duration %s, only accepts positive value", duration.String()) } return nil @@ -58,7 +60,7 @@ func ValidateDuration(t interface{}) error { func ValidateTimestamp(t interface{}) error { _, ok := t.(time.Time) if !ok { - return sdkerrors.Wrapf(ErrInvalidTimestamp, "invalid timestamp: %T", t) + return errorsmod.Wrapf(ErrInvalidTimestamp, "invalid timestamp: %T", t) } return nil } @@ -75,39 +77,39 @@ func ValidateClaimType(claimType ClaimType) error { if claimType == CLAIM_TYPE_FT || claimType == CLAIM_TYPE_NFT || claimType == CLAIM_TYPE_FT_AND_NFT { return nil } - return sdkerrors.Wrapf(ErrInvalidClaimType, "unknown claim type (%s)", claimType) + return errorsmod.Wrapf(ErrInvalidClaimType, "unknown claim type (%s)", claimType) } func ValidateClaim(claim Claim) error { if _, err := sdk.AccAddressFromBech32(claim.Address); err != nil { - return sdkerrors.Wrapf(sdkerrors.ErrInvalidAddress, "invalid claimer address (%s)", err) + return errorsmod.Wrapf(sdkerrors.ErrInvalidAddress, "invalid claimer address (%s)", err) } return nil } func ValidateTokens(tokensA, tokensB sdk.Coin) error { if tokensA.IsNil() || tokensB.IsNil() { - return sdkerrors.Wrapf( + return errorsmod.Wrapf( ErrInvalidTokens, "invalid tokens, only accepts positive amount", ) } if !tokensA.IsValid() { - return sdkerrors.Wrapf( + return errorsmod.Wrapf( ErrInvalidTokens, "invalid tokens %s, only accepts positive amount", tokensA.String(), ) } if !tokensB.IsValid() { - return sdkerrors.Wrapf( + return errorsmod.Wrapf( ErrInvalidTokens, "invalid tokens %s, only accepts positive amount", tokensB.String(), ) } if tokensA.Denom != tokensB.Denom { - return sdkerrors.Wrapf( + return errorsmod.Wrapf( ErrInvalidTokens, "mismatched token denoms (%s, %s)", tokensA.Denom, @@ -119,7 +121,7 @@ func ValidateTokens(tokensA, tokensB sdk.Coin) error { func validateNFTMintDetails(details *NFTDetails) error { if details == nil || len(details.Name) == 0 || len(details.DenomId) == 0 || len(details.MediaUri) == 0 { - return sdkerrors.Wrapf( + return errorsmod.Wrapf( ErrInvalidNFTMintDetails, "invalid nft mint details, details should not be nil and name, media_uri can not be empty.") } @@ -128,10 +130,10 @@ func validateNFTMintDetails(details *NFTDetails) error { func ValidateDistribution(distribution *Distribution) error { if distribution == nil { - return sdkerrors.Wrapf(ErrInvalidDistribution, "distribution can not be nil") + return errorsmod.Wrapf(ErrInvalidDistribution, "distribution can not be nil") } if !(distribution.Type == DISTRIBUTION_TYPE_STREAM || distribution.Type == DISTRIBUTION_TYPE_INSTANT) { - return sdkerrors.Wrapf(ErrInvalidClaimType, "invalid distribution type (%s)", distribution.Type) + return errorsmod.Wrapf(ErrInvalidClaimType, "invalid distribution type (%s)", distribution.Type) } if distribution.Type == DISTRIBUTION_TYPE_STREAM { if err := ValidateDuration(distribution.StreamDuration); err != nil { @@ -144,7 +146,7 @@ func ValidateDistribution(distribution *Distribution) error { func ValidateInteractionType(interaction InteractionType) error { if !(interaction == INTERACTION_TYPE_BURN || interaction == INTERACTION_TYPE_TRANSFER || interaction == INTERACTION_TYPE_HOLD) { - return sdkerrors.Wrapf(ErrInteractionMismatch, "unknown interaction type (%s)", interaction) + return errorsmod.Wrapf(ErrInteractionMismatch, "unknown interaction type (%s)", interaction) } return nil } diff --git a/x/marketplace/abci.go b/x/marketplace/abci.go index 29b9cf26..66852518 100644 --- a/x/marketplace/abci.go +++ b/x/marketplace/abci.go @@ -1,9 +1,9 @@ package marketplace import ( - "github.com/OmniFlix/omniflixhub/x/marketplace/keeper" + "github.com/OmniFlix/omniflixhub/v2/x/marketplace/keeper" + abcitypes "github.com/cometbft/cometbft/abci/types" sdk "github.com/cosmos/cosmos-sdk/types" - abcitypes "github.com/tendermint/tendermint/abci/types" ) func EndBlock(ctx sdk.Context, k keeper.Keeper) []abcitypes.ValidatorUpdate { diff --git a/x/marketplace/client/cli/query.go b/x/marketplace/client/cli/query.go index 50f826ec..8297f2e1 100644 --- a/x/marketplace/client/cli/query.go +++ b/x/marketplace/client/cli/query.go @@ -11,7 +11,7 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/version" - "github.com/OmniFlix/omniflixhub/x/marketplace/types" + "github.com/OmniFlix/omniflixhub/v2/x/marketplace/types" "github.com/spf13/cobra" ) diff --git a/x/marketplace/client/cli/tx.go b/x/marketplace/client/cli/tx.go index 334881f5..40059e00 100644 --- a/x/marketplace/client/cli/tx.go +++ b/x/marketplace/client/cli/tx.go @@ -12,7 +12,7 @@ import ( "github.com/cosmos/cosmos-sdk/version" "github.com/spf13/cobra" - "github.com/OmniFlix/omniflixhub/x/marketplace/types" + "github.com/OmniFlix/omniflixhub/v2/x/marketplace/types" "github.com/cosmos/cosmos-sdk/client" ) diff --git a/x/marketplace/client/rest/query.go b/x/marketplace/client/rest/query.go deleted file mode 100644 index 26f124c5..00000000 --- a/x/marketplace/client/rest/query.go +++ /dev/null @@ -1,174 +0,0 @@ -package rest - -import ( - "context" - "fmt" - "net/http" - "strings" - - "github.com/gorilla/mux" - - "github.com/cosmos/cosmos-sdk/client" - sdk "github.com/cosmos/cosmos-sdk/types" - sdkquery "github.com/cosmos/cosmos-sdk/types/query" - "github.com/cosmos/cosmos-sdk/types/rest" - - "github.com/OmniFlix/omniflixhub/x/marketplace/types" -) - -func registerQueryRoutes(cliCtx client.Context, r *mux.Router) { - r.HandleFunc(fmt.Sprintf("/%s/parameters", types.ModuleName), - queryParams(cliCtx), - ).Methods("GET") - - r.HandleFunc(fmt.Sprintf("/%s/listing/{%s}", - types.ModuleName, RestParamListingId), - queryListing(cliCtx), - ).Methods("GET") - - r.HandleFunc(fmt.Sprintf("/%s/listings", types.ModuleName), - queryAllListings(cliCtx), - ).Methods("GET") - - r.HandleFunc(fmt.Sprintf("/%s/listings/{%s}", types.ModuleName, RestParamOwner), - queryListingsByOwner(cliCtx), - ).Methods("GET") -} - -// queryParams -func queryParams(cliCtx client.Context) http.HandlerFunc { - return func(w http.ResponseWriter, r *http.Request) { - cliCtx, ok := rest.ParseQueryHeightOrReturnBadRequest(w, cliCtx, r) - if !ok { - return - } - - res, height, err := cliCtx.QueryWithData( - fmt.Sprintf("custom/%s/%s", types.QuerierRoute, types.QueryParams), nil, - ) - if err != nil { - rest.WriteErrorResponse(w, http.StatusInternalServerError, err.Error()) - return - } - - cliCtx = cliCtx.WithHeight(height) - rest.PostProcessResponse(w, cliCtx, res) - } -} - -// queryListing -func queryListing(cliCtx client.Context) http.HandlerFunc { - return func(w http.ResponseWriter, r *http.Request) { - vars := mux.Vars(r) - listingId := strings.TrimSpace(vars[RestParamListingId]) - params := types.QueryListingParams{ - Id: listingId, - } - - bz, err := cliCtx.LegacyAmino.MarshalJSON(params) - if err != nil { - rest.WriteErrorResponse(w, http.StatusBadRequest, err.Error()) - return - } - - cliCtx, ok := rest.ParseQueryHeightOrReturnBadRequest(w, cliCtx, r) - if !ok { - return - } - - res, height, err := cliCtx.QueryWithData( - fmt.Sprintf("custom/%s/%s", types.QuerierRoute, types.QueryListing), bz, - ) - if err != nil { - rest.WriteErrorResponse(w, http.StatusInternalServerError, err.Error()) - return - } - - cliCtx = cliCtx.WithHeight(height) - rest.PostProcessResponse(w, cliCtx, res) - } -} - -// queryAllListings -func queryAllListings(cliCtx client.Context) http.HandlerFunc { - return func(w http.ResponseWriter, r *http.Request) { - cliCtx, ok := rest.ParseQueryHeightOrReturnBadRequest(w, cliCtx, r) - if !ok { - return - } - var ( - qc = types.NewQueryClient(cliCtx) - query = r.URL.Query() - ) - - _, page, limit, err := rest.ParseHTTPArgs(r) - if rest.CheckBadRequestError(w, err) { - return - } - pageReq := sdkquery.PageRequest{ - Offset: uint64((page - 1) * limit), - Limit: uint64(limit), - CountTotal: true, - } - owner := query.Get("owner") - priceDenom := query.Get("priceDenom") - - listings, err := qc.Listings( - context.Background(), - &types.QueryListingsRequest{ - Owner: owner, - PriceDenom: priceDenom, - Pagination: &pageReq, - }, - ) - if rest.CheckInternalServerError(w, err) { - return - } - - rest.PostProcessResponse(w, cliCtx, listings) - } -} - -// queryListingsByOwner -func queryListingsByOwner(cliCtx client.Context) http.HandlerFunc { - return func(w http.ResponseWriter, r *http.Request) { - ownerStr := r.FormValue(RestParamOwner) - - var err error - var owner sdk.AccAddress - - if len(ownerStr) > 0 { - owner, err = sdk.AccAddressFromBech32(ownerStr) - if err != nil { - rest.WriteErrorResponse(w, http.StatusBadRequest, err.Error()) - return - } - } - - params := types.QueryListingsByOwnerParams{ - Owner: owner, - } - - bz, err := cliCtx.LegacyAmino.MarshalJSON(params) - if err != nil { - rest.WriteErrorResponse(w, http.StatusBadRequest, err.Error()) - return - } - - cliCtx, ok := rest.ParseQueryHeightOrReturnBadRequest(w, cliCtx, r) - if !ok { - return - } - - res, height, err := cliCtx.QueryWithData( - fmt.Sprintf("custom/%s/%s", types.QuerierRoute, types.QueryListingsByOwner), bz, - ) - if err != nil { - rest.WriteErrorResponse(w, http.StatusInternalServerError, err.Error()) - return - } - - cliCtx = cliCtx.WithHeight(height) - rest.PostProcessResponse(w, cliCtx, res) - } -} diff --git a/x/marketplace/client/rest/rest.go b/x/marketplace/client/rest/rest.go deleted file mode 100644 index c3c261d9..00000000 --- a/x/marketplace/client/rest/rest.go +++ /dev/null @@ -1,45 +0,0 @@ -package rest - -import ( - "github.com/OmniFlix/omniflixhub/x/marketplace/types" - "github.com/gorilla/mux" - - "github.com/cosmos/cosmos-sdk/client" - "github.com/cosmos/cosmos-sdk/types/rest" -) - -// Rest variable names -const ( - RestParamListingId = "listing_id" - RestParamOwner = "owner" -) - -func RegisterHandlers(cliCtx client.Context, r *mux.Router) { - registerQueryRoutes(cliCtx, r) - registerTxRoutes(cliCtx, r) -} - -type listNftReq struct { - BaseReq rest.BaseReq `json:"base_req"` - DenomId string `json:"denom_id"` - NftId string `json:"nft_id"` - Price string `json:"price"` - Owner string `json:"owner"` - SplitShares []types.WeightedAddress `json:"split_shares"` -} -type editListingReq struct { - BaseReq rest.BaseReq `json:"base_req"` - Price string `json:"price"` - Owner string `json:"owner"` -} - -type deListNftReq struct { - BaseReq rest.BaseReq `json:"base_req"` - Owner string `json:"owner"` -} - -type buyNftReq struct { - BaseReq rest.BaseReq `json:"base_req"` - Price string `json:"price"` - Buyer string `json:"buyer"` -} diff --git a/x/marketplace/client/rest/tx.go b/x/marketplace/client/rest/tx.go deleted file mode 100644 index f5d3fb56..00000000 --- a/x/marketplace/client/rest/tx.go +++ /dev/null @@ -1,176 +0,0 @@ -package rest - -import ( - "fmt" - "net/http" - "strings" - - "github.com/gorilla/mux" - - "github.com/cosmos/cosmos-sdk/client" - "github.com/cosmos/cosmos-sdk/client/tx" - "github.com/cosmos/cosmos-sdk/types/rest" - - "github.com/OmniFlix/omniflixhub/x/marketplace/types" - sdk "github.com/cosmos/cosmos-sdk/types" -) - -func registerTxRoutes(cliCtx client.Context, r *mux.Router) { - r.HandleFunc( - fmt.Sprintf("/%s/list-nft", types.ModuleName), - ListNft(cliCtx), - ).Methods("POST") - - r.HandleFunc( - fmt.Sprintf("/%s/listings/{%s}/edit-listing", types.ModuleName, RestParamListingId), - editListing(cliCtx), - ).Methods("PUT") - - r.HandleFunc( - fmt.Sprintf("/%s/listings/{%s}/de-list-nft", types.ModuleName, RestParamListingId), - deListNft(cliCtx), - ).Methods("PUT") - - r.HandleFunc( - fmt.Sprintf("/%s/listings/{%s}/buy-nft", types.ModuleName, RestParamListingId), - buyNft(cliCtx), - ).Methods("POST") -} - -func ListNft(cliCtx client.Context) http.HandlerFunc { - return func(w http.ResponseWriter, r *http.Request) { - var req listNftReq - if !rest.ReadRESTReq(w, r, cliCtx.LegacyAmino, &req) { - return - } - - baseReq := req.BaseReq.Sanitize() - if !baseReq.ValidateBasic(w) { - return - } - owner, err := sdk.AccAddressFromBech32(req.Owner) - if err != nil { - rest.WriteErrorResponse(w, http.StatusBadRequest, - fmt.Sprintf("invalid bech32 account address: %s", req.Owner)) - return - } - - price, err := sdk.ParseCoinNormalized(req.Price) - if err != nil { - rest.WriteErrorResponse(w, http.StatusBadRequest, fmt.Sprintf("failed to parse min amount: %s", req.Price)) - return - } - - msg := types.NewMsgListNFT(req.DenomId, req.NftId, price, owner, req.SplitShares) - - if err := msg.ValidateBasic(); err != nil { - rest.WriteErrorResponse(w, http.StatusBadRequest, err.Error()) - return - } - - tx.WriteGeneratedTxResponse(cliCtx, w, req.BaseReq, msg) - } -} - -func editListing(cliCtx client.Context) http.HandlerFunc { - return func(w http.ResponseWriter, r *http.Request) { - vars := mux.Vars(r) - listingId := strings.TrimSpace(vars[RestParamListingId]) - var req editListingReq - if !rest.ReadRESTReq(w, r, cliCtx.LegacyAmino, &req) { - return - } - - baseReq := req.BaseReq.Sanitize() - if !baseReq.ValidateBasic(w) { - return - } - owner, err := sdk.AccAddressFromBech32(req.Owner) - if err != nil { - rest.WriteErrorResponse(w, http.StatusBadRequest, - fmt.Sprintf("invalid bech32 account address: %s", req.Owner)) - return - } - - price, err := sdk.ParseCoinNormalized(req.Price) - if err != nil { - rest.WriteErrorResponse(w, http.StatusBadRequest, fmt.Sprintf("failed to parse min amount: %s", req.Price)) - return - } - - msg := types.NewMsgEditListing(listingId, price, owner) - if err := msg.ValidateBasic(); err != nil { - rest.WriteErrorResponse(w, http.StatusBadRequest, err.Error()) - return - } - - tx.WriteGeneratedTxResponse(cliCtx, w, req.BaseReq, msg) - } -} - -func deListNft(cliCtx client.Context) http.HandlerFunc { - return func(w http.ResponseWriter, r *http.Request) { - vars := mux.Vars(r) - listingId := strings.TrimSpace(vars[RestParamListingId]) - var req deListNftReq - if !rest.ReadRESTReq(w, r, cliCtx.LegacyAmino, &req) { - return - } - - baseReq := req.BaseReq.Sanitize() - if !baseReq.ValidateBasic(w) { - return - } - owner, err := sdk.AccAddressFromBech32(req.Owner) - if err != nil { - rest.WriteErrorResponse(w, http.StatusBadRequest, - fmt.Sprintf("invalid bech32 account address: %s", req.Owner)) - return - } - - msg := types.NewMsgDeListNFT(listingId, owner) - if err := msg.ValidateBasic(); err != nil { - rest.WriteErrorResponse(w, http.StatusBadRequest, err.Error()) - return - } - - tx.WriteGeneratedTxResponse(cliCtx, w, req.BaseReq, msg) - } -} - -func buyNft(cliCtx client.Context) http.HandlerFunc { - return func(w http.ResponseWriter, r *http.Request) { - vars := mux.Vars(r) - listingId := strings.TrimSpace(vars[RestParamListingId]) - - var req buyNftReq - if !rest.ReadRESTReq(w, r, cliCtx.LegacyAmino, &req) { - return - } - - baseReq := req.BaseReq.Sanitize() - if !baseReq.ValidateBasic(w) { - return - } - buyer, err := sdk.AccAddressFromBech32(req.Buyer) - if err != nil { - rest.WriteErrorResponse(w, http.StatusBadRequest, - fmt.Sprintf("invalid bech32 account address: %s", req.Buyer)) - return - } - - price, err := sdk.ParseCoinNormalized(req.Price) - if err != nil { - rest.WriteErrorResponse(w, http.StatusBadRequest, fmt.Sprintf("failed to parse min amount: %s", req.Price)) - return - } - - msg := types.NewMsgBuyNFT(listingId, price, buyer) - if err := msg.ValidateBasic(); err != nil { - rest.WriteErrorResponse(w, http.StatusBadRequest, err.Error()) - return - } - - tx.WriteGeneratedTxResponse(cliCtx, w, req.BaseReq, msg) - } -} diff --git a/x/marketplace/exported/marketplace.go b/x/marketplace/exported/marketplace.go index 81f140c4..13ac52a2 100644 --- a/x/marketplace/exported/marketplace.go +++ b/x/marketplace/exported/marketplace.go @@ -3,6 +3,8 @@ package exported import ( "time" + paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" + sdk "github.com/cosmos/cosmos-sdk/types" ) @@ -32,3 +34,15 @@ type BidI interface { GetAmount() sdk.Coin GetBidder() sdk.AccAddress } + +type ( + ParamSet = paramtypes.ParamSet + + // Subspace defines an interface that implements the legacy x/params Subspace + // type. + // + // NOTE: This is used solely for migration of x/params managed parameters. + Subspace interface { + GetParamSet(ctx sdk.Context, ps ParamSet) + } +) diff --git a/x/marketplace/genesis.go b/x/marketplace/genesis.go index 2d95a6ab..a9a59ccf 100644 --- a/x/marketplace/genesis.go +++ b/x/marketplace/genesis.go @@ -3,8 +3,8 @@ package marketplace import ( "fmt" - "github.com/OmniFlix/omniflixhub/x/marketplace/keeper" - "github.com/OmniFlix/omniflixhub/x/marketplace/types" + "github.com/OmniFlix/omniflixhub/v2/x/marketplace/keeper" + "github.com/OmniFlix/omniflixhub/v2/x/marketplace/types" sdk "github.com/cosmos/cosmos-sdk/types" ) @@ -20,7 +20,10 @@ func InitGenesis(ctx sdk.Context, k keeper.Keeper, genState types.GenesisState) k.SetWithPriceDenom(ctx, l.Price.GetDenom(), l.GetId()) } k.SetListingCount(ctx, genState.ListingCount) - k.SetParams(ctx, genState.Params) + err := k.SetParams(ctx, genState.Params) + if err != nil { + panic(err) + } for _, al := range genState.Auctions { k.SetAuctionListing(ctx, al) diff --git a/x/marketplace/handler.go b/x/marketplace/handler.go deleted file mode 100644 index 0517cdda..00000000 --- a/x/marketplace/handler.go +++ /dev/null @@ -1,50 +0,0 @@ -package marketplace - -import ( - "fmt" - - "github.com/OmniFlix/omniflixhub/x/marketplace/keeper" - "github.com/OmniFlix/omniflixhub/x/marketplace/types" - - sdk "github.com/cosmos/cosmos-sdk/types" - sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" -) - -// NewHandler ... -func NewHandler(k keeper.Keeper) sdk.Handler { - msgServer := keeper.NewMsgServerImpl(k) - - return func(ctx sdk.Context, msg sdk.Msg) (*sdk.Result, error) { - ctx = ctx.WithEventManager(sdk.NewEventManager()) - - switch msg := msg.(type) { - case *types.MsgListNFT: - res, err := msgServer.ListNFT(sdk.WrapSDKContext(ctx), msg) - return sdk.WrapServiceResult(ctx, res, err) - case *types.MsgEditListing: - res, err := msgServer.EditListing(sdk.WrapSDKContext(ctx), msg) - return sdk.WrapServiceResult(ctx, res, err) - case *types.MsgDeListNFT: - res, err := msgServer.DeListNFT(sdk.WrapSDKContext(ctx), msg) - return sdk.WrapServiceResult(ctx, res, err) - case *types.MsgBuyNFT: - res, err := msgServer.BuyNFT(sdk.WrapSDKContext(ctx), msg) - return sdk.WrapServiceResult(ctx, res, err) - - // Auction messages - case *types.MsgCreateAuction: - res, err := msgServer.CreateAuction(sdk.WrapSDKContext(ctx), msg) - return sdk.WrapServiceResult(ctx, res, err) - case *types.MsgCancelAuction: - res, err := msgServer.CancelAuction(sdk.WrapSDKContext(ctx), msg) - return sdk.WrapServiceResult(ctx, res, err) - case *types.MsgPlaceBid: - res, err := msgServer.PlaceBid(sdk.WrapSDKContext(ctx), msg) - return sdk.WrapServiceResult(ctx, res, err) - - default: - errMsg := fmt.Sprintf("unrecognized %s message type: %T", types.ModuleName, msg) - return nil, sdkerrors.Wrap(sdkerrors.ErrUnknownRequest, errMsg) - } - } -} diff --git a/x/marketplace/keeper/alias.go b/x/marketplace/keeper/alias.go index ad75207c..dc3d8b79 100644 --- a/x/marketplace/keeper/alias.go +++ b/x/marketplace/keeper/alias.go @@ -1,7 +1,7 @@ package keeper import ( - "github.com/OmniFlix/omniflixhub/x/marketplace/types" + "github.com/OmniFlix/omniflixhub/v2/x/marketplace/types" sdk "github.com/cosmos/cosmos-sdk/types" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" diff --git a/x/marketplace/keeper/auction.go b/x/marketplace/keeper/auction.go index 217deb13..2640ae0c 100644 --- a/x/marketplace/keeper/auction.go +++ b/x/marketplace/keeper/auction.go @@ -3,10 +3,10 @@ package keeper import ( "fmt" - "github.com/OmniFlix/omniflixhub/x/marketplace/types" + "github.com/OmniFlix/omniflixhub/v2/x/marketplace/types" "github.com/cosmos/cosmos-sdk/store/prefix" sdk "github.com/cosmos/cosmos-sdk/types" - gogotypes "github.com/gogo/protobuf/types" + gogotypes "github.com/cosmos/gogoproto/types" ) // GetNextAuctionNumber get the next auction number diff --git a/x/marketplace/keeper/bid.go b/x/marketplace/keeper/bid.go index b07e2a1e..05a4353b 100644 --- a/x/marketplace/keeper/bid.go +++ b/x/marketplace/keeper/bid.go @@ -1,10 +1,10 @@ package keeper import ( - "github.com/OmniFlix/omniflixhub/x/marketplace/types" + "github.com/OmniFlix/omniflixhub/v2/x/marketplace/types" "github.com/cosmos/cosmos-sdk/store/prefix" sdk "github.com/cosmos/cosmos-sdk/types" - gogotypes "github.com/gogo/protobuf/types" + gogotypes "github.com/cosmos/gogoproto/types" ) // SetBid set a specific bid for an auction listing in the store diff --git a/x/marketplace/keeper/events.go b/x/marketplace/keeper/events.go index 0b7e8d63..15ca5a36 100644 --- a/x/marketplace/keeper/events.go +++ b/x/marketplace/keeper/events.go @@ -3,7 +3,7 @@ package keeper import ( "fmt" - "github.com/OmniFlix/omniflixhub/x/marketplace/types" + "github.com/OmniFlix/omniflixhub/v2/x/marketplace/types" sdk "github.com/cosmos/cosmos-sdk/types" ) diff --git a/x/marketplace/keeper/grpc_query.go b/x/marketplace/keeper/grpc_query.go index 1f13c180..c047fdeb 100644 --- a/x/marketplace/keeper/grpc_query.go +++ b/x/marketplace/keeper/grpc_query.go @@ -5,11 +5,11 @@ import ( "fmt" "time" - "github.com/OmniFlix/omniflixhub/x/marketplace/types" + "github.com/OmniFlix/omniflixhub/v2/x/marketplace/types" "github.com/cosmos/cosmos-sdk/store/prefix" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/query" - gogotypes "github.com/gogo/protobuf/types" + gogotypes "github.com/cosmos/gogoproto/types" "google.golang.org/grpc/codes" "google.golang.org/grpc/status" ) @@ -19,8 +19,7 @@ var _ types.QueryServer = Keeper{} // Params queries params of marketplace module func (k Keeper) Params(c context.Context, req *types.QueryParamsRequest) (*types.QueryParamsResponse, error) { ctx := sdk.UnwrapSDKContext(c) - var params types.Params - k.paramSpace.GetParamSet(ctx, ¶ms) + params := k.GetParams(ctx) return &types.QueryParamsResponse{Params: params}, nil } diff --git a/x/marketplace/keeper/keeper.go b/x/marketplace/keeper/keeper.go index cc46d181..60d73940 100644 --- a/x/marketplace/keeper/keeper.go +++ b/x/marketplace/keeper/keeper.go @@ -3,47 +3,46 @@ package keeper import ( "fmt" + errorsmod "cosmossdk.io/errors" + + storetypes "github.com/cosmos/cosmos-sdk/store/types" + + "github.com/OmniFlix/omniflixhub/v2/x/marketplace/types" + "github.com/cometbft/cometbft/libs/log" "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" - sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" - paramstypes "github.com/cosmos/cosmos-sdk/x/params/types" - "github.com/tendermint/tendermint/libs/log" - - "github.com/OmniFlix/omniflixhub/x/marketplace/types" ) type Keeper struct { - storeKey sdk.StoreKey + storeKey storetypes.StoreKey cdc codec.BinaryCodec accountKeeper types.AccountKeeper bankKeeper types.BankKeeper nftKeeper types.NftKeeper distributionKeeper types.DistributionKeeper - paramSpace paramstypes.Subspace + + // the address capable of executing a MsgUpdateParams message. Typically, this + // should be the x/gov module account. + authority string } func NewKeeper( cdc codec.BinaryCodec, - key sdk.StoreKey, + key storetypes.StoreKey, accountKeeper types.AccountKeeper, bankKeeper types.BankKeeper, nftKeeper types.NftKeeper, distrKeeper types.DistributionKeeper, - paramSpace paramstypes.Subspace, + authority string, ) Keeper { // ensure marketplace module account is set if addr := accountKeeper.GetModuleAddress(types.ModuleName); addr == nil { panic(fmt.Sprintf("%s module account has not been set", types.ModuleName)) } - // set KeyTable if it has not already been set - if !paramSpace.HasKeyTable() { - paramSpace = paramSpace.WithKeyTable(types.ParamKeyTable()) - } - return Keeper{ storeKey: key, cdc: cdc, @@ -51,10 +50,15 @@ func NewKeeper( bankKeeper: bankKeeper, nftKeeper: nftKeeper, distributionKeeper: distrKeeper, - paramSpace: paramSpace, + authority: authority, } } +// GetAuthority returns the x/marketplace module's authority. +func (k Keeper) GetAuthority() string { + return k.authority +} + // Logger returns a module-specific logger. func (k Keeper) Logger(ctx sdk.Context) log.Logger { return ctx.Logger().With("module", fmt.Sprintf("OmniFlix/%s", types.ModuleName)) @@ -64,7 +68,7 @@ func (k Keeper) Logger(ctx sdk.Context) log.Logger { func (k Keeper) AddListing(ctx sdk.Context, listing types.Listing) error { // check listing already exists if k.HasListing(ctx, listing.GetId()) { - return sdkerrors.Wrapf(types.ErrListingAlreadyExists, "listing already exists: %s", listing.GetId()) + return errorsmod.Wrapf(types.ErrListingAlreadyExists, "listing already exists: %s", listing.GetId()) } err := k.nftKeeper.TransferOwnership(ctx, @@ -186,7 +190,7 @@ func (k Keeper) Buy(ctx sdk.Context, listing types.Listing, buyer sdk.AccAddress } func (k Keeper) GetProportions(totalCoin sdk.Coin, ratio sdk.Dec) sdk.Coin { - return sdk.NewCoin(totalCoin.Denom, totalCoin.Amount.ToDec().Mul(ratio).TruncateInt()) + return sdk.NewCoin(totalCoin.Denom, sdk.NewDecFromInt(totalCoin.Amount).Mul(ratio).TruncateInt()) } func (k Keeper) DistributeCommission(ctx sdk.Context, marketplaceCoin sdk.Coin) error { @@ -227,7 +231,7 @@ func (k Keeper) DistributeCommission(ctx sdk.Context, marketplaceCoin sdk.Coin) func (k Keeper) CreateAuctionListing(ctx sdk.Context, auction types.AuctionListing) error { // check auction already exists or not if k.HasAuctionListing(ctx, auction.GetId()) { - return sdkerrors.Wrapf(types.ErrListingAlreadyExists, "auction listing already exists: %d", auction.GetId()) + return errorsmod.Wrapf(types.ErrListingAlreadyExists, "auction listing already exists: %d", auction.GetId()) } err := k.nftKeeper.TransferOwnership(ctx, @@ -257,7 +261,7 @@ func (k Keeper) CreateAuctionListing(ctx sdk.Context, auction types.AuctionListi func (k Keeper) CancelAuctionListing(ctx sdk.Context, auction types.AuctionListing) error { // Check bid Exists or Not if k.HasBid(ctx, auction.Id) { - return sdkerrors.Wrapf(types.ErrBidExists, "cannot cancel auction %d, bid exists ", auction.Id) + return errorsmod.Wrapf(types.ErrBidExists, "cannot cancel auction %d, bid exists ", auction.Id) } // Transfer Back NFT ownership to auction owner @@ -282,7 +286,7 @@ func (k Keeper) PlaceBid(ctx sdk.Context, auction types.AuctionListing, newBid t newBidPrice = k.GetNewBidPrice(auction.StartPrice.Denom, prevBid.Amount, auction.IncrementPercentage) } if newBid.Amount.IsLT(newBidPrice) { - return sdkerrors.Wrapf(types.ErrBidAmountNotEnough, + return errorsmod.Wrapf(types.ErrBidAmountNotEnough, "cannot place bid for given auction %d, required amount to bid is %s", auction.Id, newBidPrice.String()) } @@ -303,5 +307,5 @@ func (k Keeper) PlaceBid(ctx sdk.Context, auction types.AuctionListing, newBid t } func (k Keeper) GetNewBidPrice(denom string, amount sdk.Coin, increment sdk.Dec) sdk.Coin { - return sdk.NewCoin(denom, amount.Amount.Add(amount.Amount.ToDec().Mul(increment).TruncateInt())) + return sdk.NewCoin(denom, amount.Amount.Add(sdk.NewDecFromInt(amount.Amount).Mul(increment).TruncateInt())) } diff --git a/x/marketplace/keeper/listing.go b/x/marketplace/keeper/listing.go index 97549379..594a576a 100644 --- a/x/marketplace/keeper/listing.go +++ b/x/marketplace/keeper/listing.go @@ -3,10 +3,10 @@ package keeper import ( "encoding/binary" - "github.com/OmniFlix/omniflixhub/x/marketplace/types" + "github.com/OmniFlix/omniflixhub/v2/x/marketplace/types" "github.com/cosmos/cosmos-sdk/store/prefix" sdk "github.com/cosmos/cosmos-sdk/types" - gogotypes "github.com/gogo/protobuf/types" + gogotypes "github.com/cosmos/gogoproto/types" ) // GetListingCount get the total number of listings diff --git a/x/marketplace/keeper/migrator.go b/x/marketplace/keeper/migrator.go new file mode 100644 index 00000000..474d91ec --- /dev/null +++ b/x/marketplace/keeper/migrator.go @@ -0,0 +1,28 @@ +package keeper + +import ( + "github.com/OmniFlix/omniflixhub/v2/x/marketplace/exported" + v3 "github.com/OmniFlix/omniflixhub/v2/x/marketplace/migrations/v3" + sdk "github.com/cosmos/cosmos-sdk/types" +) + +// Migrator is a struct for handling in-place state migrations. +type Migrator struct { + keeper Keeper + legacySubspace exported.Subspace +} + +func NewMigrator(k Keeper, ss exported.Subspace) Migrator { + return Migrator{ + keeper: k, + legacySubspace: ss, + } +} + +// Migrate2to3 migrates the x/marketplace module state from the consensus version 2 to +// version 3. Specifically, it takes the parameters that are currently stored +// and managed by the x/params modules and stores them directly into the x/marketplace +// module state. +func (m Migrator) Migrate2to3(ctx sdk.Context) error { + return v3.Migrate(ctx, ctx.KVStore(m.keeper.storeKey), m.legacySubspace, m.keeper.cdc) +} diff --git a/x/marketplace/keeper/msg_server.go b/x/marketplace/keeper/msg_server.go index d80dd373..467e4d79 100644 --- a/x/marketplace/keeper/msg_server.go +++ b/x/marketplace/keeper/msg_server.go @@ -4,9 +4,12 @@ import ( "context" "time" - "github.com/OmniFlix/omniflixhub/x/marketplace/types" + govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" + + errorsmod "cosmossdk.io/errors" + + "github.com/OmniFlix/omniflixhub/v2/x/marketplace/types" sdk "github.com/cosmos/cosmos-sdk/types" - sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" "golang.org/x/exp/slices" ) @@ -22,6 +25,19 @@ func NewMsgServerImpl(keeper Keeper) types.MsgServer { return &msgServer{Keeper: keeper} } +func (m msgServer) UpdateParams(goCtx context.Context, req *types.MsgUpdateParams) (*types.MsgUpdateParamsResponse, error) { + if m.authority != req.Authority { + return nil, errorsmod.Wrapf(govtypes.ErrInvalidSigner, "invalid authority; expected %s, got %s", m.authority, req.Authority) + } + + ctx := sdk.UnwrapSDKContext(goCtx) + if err := m.SetParams(ctx, req.Params); err != nil { + return nil, err + } + + return &types.MsgUpdateParamsResponse{}, nil +} + func (m msgServer) ListNFT(goCtx context.Context, msg *types.MsgListNFT) (*types.MsgListNFTResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) @@ -32,14 +48,14 @@ func (m msgServer) ListNFT(goCtx context.Context, msg *types.MsgListNFT) (*types nft, err := m.nftKeeper.GetONFT(ctx, msg.DenomId, msg.NftId) if err != nil { - return nil, sdkerrors.Wrapf(types.ErrNftNotExists, + return nil, errorsmod.Wrapf(types.ErrNftNotExists, "invalid nft and or denomId, nftId %s, denomId %s", msg.NftId, msg.DenomId) } if owner.String() != nft.GetOwner().String() { - return nil, sdkerrors.Wrapf(types.ErrUnauthorized, "unauthorized address %s", owner) + return nil, errorsmod.Wrapf(types.ErrUnauthorized, "unauthorized address %s", owner) } if !nft.IsTransferable() { - return nil, sdkerrors.Wrapf( + return nil, errorsmod.Wrapf( types.ErrNftNonTransferable, "non-transferable nfts not allowed to list in marketplace") } @@ -66,10 +82,10 @@ func (m msgServer) EditListing(goCtx context.Context, listing, found := m.Keeper.GetListing(ctx, msg.Id) if !found { - return nil, sdkerrors.Wrapf(types.ErrListingDoesNotExists, "listing id %s not exists", msg.Id) + return nil, errorsmod.Wrapf(types.ErrListingDoesNotExists, "listing id %s not exists", msg.Id) } if owner.String() != listing.Owner { - return nil, sdkerrors.Wrapf(types.ErrUnauthorized, "unauthorized address %s", owner) + return nil, errorsmod.Wrapf(types.ErrUnauthorized, "unauthorized address %s", owner) } if err := types.ValidatePrice(msg.Price); err != nil { return nil, err @@ -93,10 +109,10 @@ func (m msgServer) DeListNFT(goCtx context.Context, } listing, found := m.Keeper.GetListing(ctx, msg.Id) if !found { - return nil, sdkerrors.Wrapf(types.ErrListingDoesNotExists, "listing id %s not exists", msg.Id) + return nil, errorsmod.Wrapf(types.ErrListingDoesNotExists, "listing id %s not exists", msg.Id) } if owner.String() != listing.Owner { - return nil, sdkerrors.Wrapf(types.ErrUnauthorized, "unauthorized address %s", owner) + return nil, errorsmod.Wrapf(types.ErrUnauthorized, "unauthorized address %s", owner) } err = m.nftKeeper.TransferOwnership(ctx, listing.GetDenomId(), listing.GetNftId(), m.accountKeeper.GetModuleAddress(types.ModuleName), listing.GetOwner()) @@ -120,20 +136,20 @@ func (m msgServer) BuyNFT(goCtx context.Context, msg *types.MsgBuyNFT) (*types.M listing, found := m.Keeper.GetListing(ctx, msg.Id) if !found { - return nil, sdkerrors.Wrapf(types.ErrListingDoesNotExists, "listing id %s not exists", msg.Id) + return nil, errorsmod.Wrapf(types.ErrListingDoesNotExists, "listing id %s not exists", msg.Id) } if err := types.ValidatePrice(msg.Price); err != nil { return nil, err } if !msg.Price.Equal(listing.Price) { if msg.Price.Denom != listing.Price.Denom { - return nil, sdkerrors.Wrapf(types.ErrInvalidPriceDenom, "invalid price denom %s", msg.Price.Denom) + return nil, errorsmod.Wrapf(types.ErrInvalidPriceDenom, "invalid price denom %s", msg.Price.Denom) } if msg.Price.Amount.LT(listing.Price.Amount) { - return nil, sdkerrors.Wrapf(types.ErrNotEnoughAmount, + return nil, errorsmod.Wrapf(types.ErrNotEnoughAmount, "%s is not enough, to buy %s required", msg.Price.String(), listing.Price.String()) } - return nil, sdkerrors.Wrapf(types.ErrInvalidPrice, + return nil, errorsmod.Wrapf(types.ErrInvalidPrice, "price %s not matched with listing price", msg.Price.String()) } err = m.Keeper.Buy(ctx, listing, buyer) @@ -160,27 +176,27 @@ func (m msgServer) CreateAuction(goCtx context.Context, msg *types.MsgCreateAuct nft, err := m.nftKeeper.GetONFT(ctx, msg.DenomId, msg.NftId) if err != nil { - return nil, sdkerrors.Wrapf(types.ErrNftNotExists, + return nil, errorsmod.Wrapf(types.ErrNftNotExists, "invalid nft and or denomId, nftId %s, denomId %s", msg.NftId, msg.DenomId) } if owner.String() != nft.GetOwner().String() { - return nil, sdkerrors.Wrapf(types.ErrUnauthorized, "unauthorized address %s", owner) + return nil, errorsmod.Wrapf(types.ErrUnauthorized, "unauthorized address %s", owner) } if !nft.IsTransferable() { - return nil, sdkerrors.Wrapf( + return nil, errorsmod.Wrapf( types.ErrNftNonTransferable, "non-transferable nfts not allowed to list in marketplace") } var endTime *time.Time if msg.Duration != nil { maxAuctionDuration := m.Keeper.GetMaxAuctionDuration(ctx) if msg.Duration.Seconds() > maxAuctionDuration.Seconds() { - return nil, sdkerrors.Wrapf(types.ErrInvalidDuration, + return nil, errorsmod.Wrapf(types.ErrInvalidDuration, "duration %s exceeds max auction duration %s", msg.Duration.String(), maxAuctionDuration.String()) } endAt := msg.StartTime.Add(*msg.Duration) endTime = &endAt if endTime.Before(msg.StartTime) || endTime.Equal(msg.StartTime) { - return nil, sdkerrors.Wrapf(types.ErrInvalidDuration, "duration must be positive or nil") + return nil, errorsmod.Wrapf(types.ErrInvalidDuration, "duration must be positive or nil") } } auctionNumber := m.Keeper.GetNextAuctionNumber(ctx) @@ -210,10 +226,10 @@ func (m msgServer) CancelAuction(goCtx context.Context, msg *types.MsgCancelAuct auction, found := m.Keeper.GetAuctionListing(ctx, msg.AuctionId) if !found { - return nil, sdkerrors.Wrapf(types.ErrAuctionDoesNotExists, "auction id %d not exists", msg.AuctionId) + return nil, errorsmod.Wrapf(types.ErrAuctionDoesNotExists, "auction id %d not exists", msg.AuctionId) } if owner.String() != auction.Owner { - return nil, sdkerrors.Wrapf(types.ErrUnauthorized, "unauthorized address %s", owner.String()) + return nil, errorsmod.Wrapf(types.ErrUnauthorized, "unauthorized address %s", owner.String()) } err = m.Keeper.CancelAuctionListing(ctx, auction) @@ -237,16 +253,16 @@ func (m msgServer) PlaceBid(goCtx context.Context, msg *types.MsgPlaceBid) (*typ auction, found := m.Keeper.GetAuctionListing(ctx, msg.AuctionId) if !found { - return nil, sdkerrors.Wrapf(types.ErrAuctionDoesNotExists, "auction id %d not exists", msg.AuctionId) + return nil, errorsmod.Wrapf(types.ErrAuctionDoesNotExists, "auction id %d not exists", msg.AuctionId) } if !auction.StartTime.Before(ctx.BlockTime()) { - return nil, sdkerrors.Wrapf(types.ErrInActiveAuction, "cannot place a bid for inactive auction %d, ", auction.Id) + return nil, errorsmod.Wrapf(types.ErrInActiveAuction, "cannot place a bid for inactive auction %d, ", auction.Id) } if len(auction.WhitelistAccounts) > 0 && !slices.Contains(auction.WhitelistAccounts, bidder.String()) { - return nil, sdkerrors.Wrapf(types.ErrUnauthorized, "cannot place a bid for this auction %d, only whitelisted accounts allowed to bid", auction.Id) + return nil, errorsmod.Wrapf(types.ErrUnauthorized, "cannot place a bid for this auction %d, only whitelisted accounts allowed to bid", auction.Id) } if msg.Amount.GetDenom() != auction.StartPrice.GetDenom() { - return nil, sdkerrors.Wrapf(types.ErrInvalidPriceDenom, "given auction only accepts bids in %s, ", auction.StartPrice.GetDenom()) + return nil, errorsmod.Wrapf(types.ErrInvalidPriceDenom, "given auction only accepts bids in %s, ", auction.StartPrice.GetDenom()) } bid := types.NewBid(auction.Id, msg.Amount, ctx.BlockTime(), bidder) diff --git a/x/marketplace/keeper/params.go b/x/marketplace/keeper/params.go index f840d44f..63d7d4cc 100644 --- a/x/marketplace/keeper/params.go +++ b/x/marketplace/keeper/params.go @@ -3,41 +3,53 @@ package keeper import ( "time" - "github.com/OmniFlix/omniflixhub/x/marketplace/types" + "github.com/OmniFlix/omniflixhub/v2/x/marketplace/types" sdk "github.com/cosmos/cosmos-sdk/types" ) // GetParams gets the parameters for the marketplace module. func (k Keeper) GetParams(ctx sdk.Context) (params types.Params) { - k.paramSpace.GetParamSet(ctx, ¶ms) + store := ctx.KVStore(k.storeKey) + bz := store.Get(types.ParamsKey) + if bz == nil { + return params + } + k.cdc.MustUnmarshal(bz, ¶ms) return params } // SetParams sets the parameters for the marketplace module. -func (k Keeper) SetParams(ctx sdk.Context, params types.Params) { - k.paramSpace.SetParamSet(ctx, ¶ms) +func (k Keeper) SetParams(ctx sdk.Context, params types.Params) error { + if err := params.ValidateBasic(); err != nil { + return err + } + + store := ctx.KVStore(k.storeKey) + bz := k.cdc.MustMarshal(¶ms) + store.Set(types.ParamsKey, bz) + return nil } // GetSaleCommission returns the current sale commission of marketplace. func (k Keeper) GetSaleCommission(ctx sdk.Context) (percent sdk.Dec) { - k.paramSpace.Get(ctx, types.ParamStoreKeySaleCommission, &percent) - return percent + params := k.GetParams(ctx) + return params.SaleCommission } // GetMarketplaceDistributionParams returns the current distribution of marketplace commission. func (k Keeper) GetMarketplaceDistributionParams(ctx sdk.Context) (distParams types.Distribution) { - k.paramSpace.Get(ctx, types.ParamStoreKeyDistribution, &distParams) - return distParams + params := k.GetParams(ctx) + return params.Distribution } // GetBidCloseDuration returns the closing duration for bid for auctions. func (k Keeper) GetBidCloseDuration(ctx sdk.Context) (duration time.Duration) { - k.paramSpace.Get(ctx, types.ParamStoreKeyBidCloseDuration, &duration) - return duration + params := k.GetParams(ctx) + return params.BidCloseDuration } // GetMaxAuctionDuration returns the maximum duration for auctions. func (k Keeper) GetMaxAuctionDuration(ctx sdk.Context) (duration time.Duration) { - k.paramSpace.Get(ctx, types.ParamStoreKeyMaxAuctionDuration, &duration) - return duration + params := k.GetParams(ctx) + return params.MaxAuctionDuration } diff --git a/x/marketplace/keeper/querier.go b/x/marketplace/keeper/querier.go deleted file mode 100644 index 4011dd41..00000000 --- a/x/marketplace/keeper/querier.go +++ /dev/null @@ -1,162 +0,0 @@ -package keeper - -import ( - "fmt" - "strings" - - abci "github.com/tendermint/tendermint/abci/types" - - "github.com/cosmos/cosmos-sdk/codec" - sdk "github.com/cosmos/cosmos-sdk/types" - sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" - - "github.com/OmniFlix/omniflixhub/x/marketplace/types" -) - -func NewQuerier(k Keeper, legacyQuerierCdc *codec.LegacyAmino) sdk.Querier { - return func(ctx sdk.Context, path []string, req abci.RequestQuery) (res []byte, err error) { - switch path[0] { - case types.QueryParams: - return queryParams(ctx, path[1:], req, k, legacyQuerierCdc) - case types.QueryListing: - return queryListing(ctx, req, k, legacyQuerierCdc) - case types.QueryAllListings: - return queryAllListings(ctx, req, k, legacyQuerierCdc) - case types.QueryListingsByOwner: - return queryListingsByOwner(ctx, req, k, legacyQuerierCdc) - case types.QueryAuction: - return queryAuction(ctx, req, k, legacyQuerierCdc) - case types.QueryAllAuctions: - return queryAllAuctions(ctx, req, k, legacyQuerierCdc) - case types.QueryAuctionsByOwner: - return queryAuctionsByOwner(ctx, req, k, legacyQuerierCdc) - case types.QueryBid: - return queryBid(ctx, req, k, legacyQuerierCdc) - case types.QueryAllBids: - return queryAllBids(ctx, req, k, legacyQuerierCdc) - default: - return nil, sdkerrors.Wrapf(sdkerrors.ErrUnknownRequest, "unknown query path: %s", path[0]) - } - } -} - -func queryParams(ctx sdk.Context, _ []string, _ abci.RequestQuery, k Keeper, legacyQuerierCdc *codec.LegacyAmino) ([]byte, error) { - params := k.GetParams(ctx) - - res, err := codec.MarshalJSONIndent(legacyQuerierCdc, params) - if err != nil { - return nil, sdkerrors.Wrap(sdkerrors.ErrJSONMarshal, err.Error()) - } - - return res, nil -} - -func queryListing(ctx sdk.Context, req abci.RequestQuery, k Keeper, legacyQuerierCdc *codec.LegacyAmino) ([]byte, error) { - var params types.QueryListingParams - - err := legacyQuerierCdc.UnmarshalJSON(req.Data, ¶ms) - if err != nil { - return nil, sdkerrors.Wrap(sdkerrors.ErrJSONUnmarshal, err.Error()) - } - - id := strings.ToLower(strings.TrimSpace(params.Id)) - - listing, found := k.GetListing(ctx, id) - if !found { - return nil, sdkerrors.Wrap(types.ErrListingDoesNotExists, fmt.Sprintf("listing %s does not exist", id)) - } - return codec.MarshalJSONIndent(legacyQuerierCdc, listing) -} - -func queryAllListings(ctx sdk.Context, req abci.RequestQuery, k Keeper, legacyQuerierCdc *codec.LegacyAmino) ([]byte, error) { - var params types.QueryAllListingsParams - - err := legacyQuerierCdc.UnmarshalJSON(req.Data, ¶ms) - if err != nil { - return nil, sdkerrors.Wrap(sdkerrors.ErrJSONUnmarshal, err.Error()) - } - - listings := k.GetAllListings(ctx) - - return codec.MarshalJSONIndent(legacyQuerierCdc, listings) -} - -func queryListingsByOwner(ctx sdk.Context, req abci.RequestQuery, k Keeper, legacyQuerierCdc *codec.LegacyAmino) ([]byte, error) { - var params types.QueryListingsByOwnerParams - - err := legacyQuerierCdc.UnmarshalJSON(req.Data, ¶ms) - if err != nil { - return nil, sdkerrors.Wrap(sdkerrors.ErrJSONUnmarshal, err.Error()) - } - - listings := k.GetListingsByOwner(ctx, params.Owner) - return codec.MarshalJSONIndent(legacyQuerierCdc, listings) -} - -func queryAuction(ctx sdk.Context, req abci.RequestQuery, k Keeper, legacyQuerierCdc *codec.LegacyAmino) ([]byte, error) { - var params types.QueryAuctionParams - - err := legacyQuerierCdc.UnmarshalJSON(req.Data, ¶ms) - if err != nil { - return nil, sdkerrors.Wrap(sdkerrors.ErrJSONUnmarshal, err.Error()) - } - - auction, found := k.GetAuctionListing(ctx, params.Id) - if !found { - return nil, sdkerrors.Wrap(types.ErrAuctionDoesNotExists, fmt.Sprintf("auction %d does not exist", params.Id)) - } - return codec.MarshalJSONIndent(legacyQuerierCdc, auction) -} - -func queryAllAuctions(ctx sdk.Context, req abci.RequestQuery, k Keeper, legacyQuerierCdc *codec.LegacyAmino) ([]byte, error) { - var params types.QueryAllAuctionsParams - - err := legacyQuerierCdc.UnmarshalJSON(req.Data, ¶ms) - if err != nil { - return nil, sdkerrors.Wrap(sdkerrors.ErrJSONUnmarshal, err.Error()) - } - - auctions := k.GetAllAuctionListings(ctx) - - return codec.MarshalJSONIndent(legacyQuerierCdc, auctions) -} - -func queryAuctionsByOwner(ctx sdk.Context, req abci.RequestQuery, k Keeper, legacyQuerierCdc *codec.LegacyAmino) ([]byte, error) { - var params types.QueryAuctionsByOwnerParams - - err := legacyQuerierCdc.UnmarshalJSON(req.Data, ¶ms) - if err != nil { - return nil, sdkerrors.Wrap(sdkerrors.ErrJSONUnmarshal, err.Error()) - } - - auctions := k.GetAuctionListingsByOwner(ctx, params.Owner) - return codec.MarshalJSONIndent(legacyQuerierCdc, auctions) -} - -func queryBid(ctx sdk.Context, req abci.RequestQuery, k Keeper, legacyQuerierCdc *codec.LegacyAmino) ([]byte, error) { - var params types.QueryBidParams - - err := legacyQuerierCdc.UnmarshalJSON(req.Data, ¶ms) - if err != nil { - return nil, sdkerrors.Wrap(sdkerrors.ErrJSONUnmarshal, err.Error()) - } - - bid, found := k.GetBid(ctx, params.Id) - if !found { - return nil, sdkerrors.Wrap(types.ErrBidDoesNotExists, fmt.Sprintf("auction %d does not have any bid", params.Id)) - } - return codec.MarshalJSONIndent(legacyQuerierCdc, bid) -} - -func queryAllBids(ctx sdk.Context, req abci.RequestQuery, k Keeper, legacyQuerierCdc *codec.LegacyAmino) ([]byte, error) { - var params types.QueryAllBidsParams - - err := legacyQuerierCdc.UnmarshalJSON(req.Data, ¶ms) - if err != nil { - return nil, sdkerrors.Wrap(sdkerrors.ErrJSONUnmarshal, err.Error()) - } - - bids := k.GetAllBids(ctx) - - return codec.MarshalJSONIndent(legacyQuerierCdc, bids) -} diff --git a/x/marketplace/migrations/v3/migrate.go b/x/marketplace/migrations/v3/migrate.go new file mode 100644 index 00000000..8255ac59 --- /dev/null +++ b/x/marketplace/migrations/v3/migrate.go @@ -0,0 +1,36 @@ +package v3 + +import ( + "github.com/OmniFlix/omniflixhub/v2/x/marketplace/exported" + "github.com/OmniFlix/omniflixhub/v2/x/marketplace/types" + "github.com/cosmos/cosmos-sdk/codec" + sdk "github.com/cosmos/cosmos-sdk/types" +) + +const ( + ModuleName = "marketplace" +) + +var ParamsKey = []byte{0x15} + +// Migrate migrates the x/marketplace module state from the consensus version 2 to +// version 3. Specifically, it takes the parameters that are currently stored +// and managed by the x/params modules and stores them directly into the x/marketplace +// module state. +func Migrate( + ctx sdk.Context, + store sdk.KVStore, + legacySubspace exported.Subspace, + cdc codec.BinaryCodec, +) error { + var currParams types.Params + legacySubspace.GetParamSet(ctx, &currParams) + + if err := currParams.ValidateBasic(); err != nil { + return err + } + bz := cdc.MustMarshal(&currParams) + store.Set(ParamsKey, bz) + + return nil +} diff --git a/x/marketplace/migrations/v3/migrator_test.go b/x/marketplace/migrations/v3/migrator_test.go new file mode 100644 index 00000000..cde5dad4 --- /dev/null +++ b/x/marketplace/migrations/v3/migrator_test.go @@ -0,0 +1,45 @@ +package v3_test + +import ( + "testing" + + "github.com/stretchr/testify/require" + + "github.com/OmniFlix/omniflixhub/v2/x/marketplace" + "github.com/OmniFlix/omniflixhub/v2/x/marketplace/exported" + v3 "github.com/OmniFlix/omniflixhub/v2/x/marketplace/migrations/v3" + "github.com/OmniFlix/omniflixhub/v2/x/marketplace/types" + "github.com/cosmos/cosmos-sdk/testutil" + sdk "github.com/cosmos/cosmos-sdk/types" + moduletestutil "github.com/cosmos/cosmos-sdk/types/module/testutil" +) + +type mockSubspace struct { + ps types.Params +} + +func newMockSubspace(ps types.Params) mockSubspace { + return mockSubspace{ps: ps} +} + +func (ms mockSubspace) GetParamSet(ctx sdk.Context, ps exported.ParamSet) { + *ps.(*types.Params) = ms.ps +} + +func TestMigrate(t *testing.T) { + encCfg := moduletestutil.MakeTestEncodingConfig(marketplace.AppModuleBasic{}) + cdc := encCfg.Codec + + storeKey := sdk.NewKVStoreKey(v3.ModuleName) + tKey := sdk.NewTransientStoreKey("transient_test") + ctx := testutil.DefaultContext(storeKey, tKey) + store := ctx.KVStore(storeKey) + + legacySubspace := newMockSubspace(types.DefaultParams()) + require.NoError(t, v3.Migrate(ctx, store, legacySubspace, cdc)) + + var res types.Params + bz := store.Get(v3.ParamsKey) + require.NoError(t, cdc.Unmarshal(bz, &res)) + require.Equal(t, legacySubspace.ps, res) +} diff --git a/x/marketplace/module.go b/x/marketplace/module.go index 22bf43a3..d0fdab6e 100644 --- a/x/marketplace/module.go +++ b/x/marketplace/module.go @@ -5,18 +5,18 @@ import ( "encoding/json" "fmt" - "github.com/OmniFlix/omniflixhub/x/marketplace/client/cli" - "github.com/OmniFlix/omniflixhub/x/marketplace/client/rest" + "github.com/OmniFlix/omniflixhub/v2/x/marketplace/exported" + + "github.com/OmniFlix/omniflixhub/v2/x/marketplace/client/cli" "github.com/cosmos/cosmos-sdk/types/module" "github.com/spf13/cobra" - "github.com/gorilla/mux" "github.com/grpc-ecosystem/grpc-gateway/runtime" - abci "github.com/tendermint/tendermint/abci/types" + abci "github.com/cometbft/cometbft/abci/types" - "github.com/OmniFlix/omniflixhub/x/marketplace/keeper" - "github.com/OmniFlix/omniflixhub/x/marketplace/types" + "github.com/OmniFlix/omniflixhub/v2/x/marketplace/keeper" + "github.com/OmniFlix/omniflixhub/v2/x/marketplace/types" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/codec" cdctypes "github.com/cosmos/cosmos-sdk/codec/types" @@ -32,6 +32,9 @@ var ( // AppModuleBasic // ---------------------------------------------------------------------------- +// ConsensusVersion defines the current x/marketplace module consensus version. +const ConsensusVersion = 3 + // AppModuleBasic implements the AppModuleBasic interface for the marketplace module. type AppModuleBasic struct { cdc codec.BinaryCodec @@ -69,11 +72,6 @@ func (AppModuleBasic) ValidateGenesis(cdc codec.JSONCodec, config client.TxEncod return genState.ValidateGenesis() } -// RegisterRESTRoutes registers the marketplace module's REST service handlers. -func (AppModuleBasic) RegisterRESTRoutes(clientCtx client.Context, rtr *mux.Router) { - rest.RegisterHandlers(clientCtx, rtr) -} - // RegisterGRPCGatewayRoutes registers the gRPC Gateway routes for the module. func (AppModuleBasic) RegisterGRPCGatewayRoutes(clientCtx client.Context, mux *runtime.ServeMux) { types.RegisterQueryHandlerClient(context.Background(), mux, types.NewQueryClient(clientCtx)) @@ -97,13 +95,15 @@ func (AppModuleBasic) GetQueryCmd() *cobra.Command { type AppModule struct { AppModuleBasic - keeper keeper.Keeper + keeper keeper.Keeper + legacySubspace exported.Subspace } -func NewAppModule(cdc codec.Codec, keeper keeper.Keeper) AppModule { +func NewAppModule(cdc codec.Codec, keeper keeper.Keeper, ss exported.Subspace) AppModule { return AppModule{ AppModuleBasic: NewAppModuleBasic(cdc), keeper: keeper, + legacySubspace: ss, } } @@ -112,24 +112,20 @@ func (am AppModule) Name() string { return am.AppModuleBasic.Name() } -// Route returns the marketplace module's message routing key. -func (am AppModule) Route() sdk.Route { - return sdk.NewRoute(types.RouterKey, NewHandler(am.keeper)) -} - // QuerierRoute returns the marketplace module's query routing key. func (AppModule) QuerierRoute() string { return types.QuerierRoute } -// LegacyQuerierHandler returns the marketplace module's Querier. -func (am AppModule) LegacyQuerierHandler(legacyQuerierCdc *codec.LegacyAmino) sdk.Querier { - return keeper.NewQuerier(am.keeper, legacyQuerierCdc) -} - // RegisterServices registers a GRPC query service to respond to the // module-specific GRPC queries. func (am AppModule) RegisterServices(cfg module.Configurator) { types.RegisterMsgServer(cfg.MsgServer(), keeper.NewMsgServerImpl(am.keeper)) types.RegisterQueryServer(cfg.QueryServer(), am.keeper) + // x/params migration + m := keeper.NewMigrator(am.keeper, am.legacySubspace) + + if err := cfg.RegisterMigration(types.ModuleName, 2, m.Migrate2to3); err != nil { + panic(fmt.Sprintf("failed to migrate x/%s from version 2 to 3: %v", types.ModuleName, err)) + } } // RegisterInvariants registers the marketplace module's invariants. @@ -154,7 +150,9 @@ func (am AppModule) ExportGenesis(ctx sdk.Context, cdc codec.JSONCodec) json.Raw } // ConsensusVersion implements ConsensusVersion. -func (AppModule) ConsensusVersion() uint64 { return 2 } +func (AppModule) ConsensusVersion() uint64 { + return ConsensusVersion +} // BeginBlock executes all ABCI BeginBlock logic respective to the marketplace module. func (am AppModule) BeginBlock(_ sdk.Context, _ abci.RequestBeginBlock) {} diff --git a/x/marketplace/types/auction.go b/x/marketplace/types/auction.go index 490d9361..4812270b 100644 --- a/x/marketplace/types/auction.go +++ b/x/marketplace/types/auction.go @@ -3,9 +3,9 @@ package types import ( "time" - "github.com/OmniFlix/omniflixhub/x/marketplace/exported" + "github.com/OmniFlix/omniflixhub/v2/x/marketplace/exported" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/gogo/protobuf/proto" + "github.com/cosmos/gogoproto/proto" ) var ( diff --git a/x/marketplace/types/auction.pb.go b/x/marketplace/types/auction.pb.go index 1dcf86e4..1117fe3e 100644 --- a/x/marketplace/types/auction.pb.go +++ b/x/marketplace/types/auction.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: omniflix/marketplace/v1beta1/auction.proto +// source: OmniFlix/marketplace/v1beta1/auction.proto package types @@ -7,9 +7,9 @@ import ( fmt "fmt" github_com_cosmos_cosmos_sdk_types "github.com/cosmos/cosmos-sdk/types" types "github.com/cosmos/cosmos-sdk/types" - _ "github.com/gogo/protobuf/gogoproto" - proto "github.com/gogo/protobuf/proto" - github_com_gogo_protobuf_types "github.com/gogo/protobuf/types" + _ "github.com/cosmos/gogoproto/gogoproto" + proto "github.com/cosmos/gogoproto/proto" + github_com_gogo_protobuf_types "github.com/cosmos/gogoproto/types" _ "google.golang.org/protobuf/types/known/timestamppb" io "io" math "math" @@ -54,7 +54,7 @@ func (x AuctionStatus) String() string { } func (AuctionStatus) EnumDescriptor() ([]byte, []int) { - return fileDescriptor_67ff771a16a600e4, []int{0} + return fileDescriptor_b7c419bfddde4ca0, []int{0} } type AuctionListing struct { @@ -74,7 +74,7 @@ func (m *AuctionListing) Reset() { *m = AuctionListing{} } func (m *AuctionListing) String() string { return proto.CompactTextString(m) } func (*AuctionListing) ProtoMessage() {} func (*AuctionListing) Descriptor() ([]byte, []int) { - return fileDescriptor_67ff771a16a600e4, []int{0} + return fileDescriptor_b7c419bfddde4ca0, []int{0} } func (m *AuctionListing) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -114,7 +114,7 @@ func (m *Bid) Reset() { *m = Bid{} } func (m *Bid) String() string { return proto.CompactTextString(m) } func (*Bid) ProtoMessage() {} func (*Bid) Descriptor() ([]byte, []int) { - return fileDescriptor_67ff771a16a600e4, []int{1} + return fileDescriptor_b7c419bfddde4ca0, []int{1} } func (m *Bid) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -150,59 +150,59 @@ func init() { } func init() { - proto.RegisterFile("omniflix/marketplace/v1beta1/auction.proto", fileDescriptor_67ff771a16a600e4) + proto.RegisterFile("OmniFlix/marketplace/v1beta1/auction.proto", fileDescriptor_b7c419bfddde4ca0) } -var fileDescriptor_67ff771a16a600e4 = []byte{ - // 758 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x54, 0x41, 0x6f, 0xe3, 0x44, - 0x14, 0x8e, 0x93, 0x34, 0x4d, 0x26, 0xec, 0xb2, 0x9d, 0x76, 0x59, 0x37, 0x05, 0x3b, 0xf8, 0x00, - 0xd1, 0x4a, 0x6b, 0x6b, 0x77, 0x91, 0x40, 0x7b, 0x8b, 0xb3, 0x59, 0xc9, 0x12, 0xa4, 0x91, 0x93, - 0x00, 0xe2, 0x62, 0x39, 0x9e, 0x89, 0x33, 0x6a, 0xec, 0x89, 0xec, 0x09, 0x6d, 0x6f, 0xc0, 0x2f, - 0xe8, 0x4f, 0xe0, 0xcc, 0x2f, 0xe9, 0x81, 0x43, 0x8f, 0x88, 0x43, 0x4a, 0xdb, 0x0b, 0xe7, 0xfc, - 0x02, 0xe4, 0x99, 0x71, 0x13, 0x0a, 0x6a, 0xf7, 0x94, 0x79, 0xef, 0x7d, 0xef, 0xcb, 0xe7, 0x6f, - 0xde, 0x1b, 0xf0, 0x9c, 0x46, 0x31, 0x99, 0xcc, 0xc8, 0x89, 0x15, 0xf9, 0xc9, 0x11, 0x66, 0xf3, - 0x99, 0x1f, 0x60, 0xeb, 0xc7, 0x97, 0x63, 0xcc, 0xfc, 0x97, 0x96, 0xbf, 0x08, 0x18, 0xa1, 0xb1, - 0x39, 0x4f, 0x28, 0xa3, 0xf0, 0xe3, 0xc3, 0x28, 0x26, 0xef, 0x66, 0xe4, 0xc4, 0xdc, 0xc0, 0x9a, - 0x12, 0xdb, 0xd0, 0x02, 0x9a,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, 0x17, 0x57, 0x5a, 0xe1, 0xfc, 0x5a, 0x53, 0x2e, 0xae, 0x35, - 0xe5, 0xaf, 0x6b, 0x4d, 0x39, 0xbb, 0xd1, 0x0a, 0x17, 0x37, 0x5a, 0xe1, 0x8f, 0x1b, 0xad, 0xf0, - 0xc3, 0xeb, 0x8d, 0xb1, 0xcb, 0x2f, 0xcf, 0xca, 0x9f, 0xa7, 0xe9, 0x62, 0x6c, 0xfd, 0xfb, 0x8d, - 0xe2, 0x73, 0x38, 0xae, 0xf0, 0x2f, 0x7d, 0xfd, 0x4f, 0x00, 0x00, 0x00, 0xff, 0xff, 0x72, 0x67, - 0xd5, 0xdc, 0x69, 0x05, 0x00, 0x00, +var fileDescriptor_b7c419bfddde4ca0 = []byte{ + // 760 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x54, 0x4f, 0x6f, 0xe3, 0x44, + 0x14, 0x8f, 0x93, 0x34, 0x4d, 0x26, 0xec, 0xb2, 0x9d, 0x76, 0x59, 0x37, 0x05, 0x3b, 0xf8, 0x00, + 0xd1, 0x4a, 0x6b, 0x6b, 0x0b, 0x02, 0xb4, 0xb7, 0x38, 0x9b, 0x95, 0x2c, 0x41, 0x1a, 0x39, 0x29, + 0x54, 0x5c, 0x2c, 0xc7, 0x33, 0x71, 0x46, 0x8d, 0x3d, 0x91, 0x3d, 0xe9, 0x9f, 0x1b, 0xf0, 0x09, + 0xfa, 0x11, 0x38, 0xf3, 0x49, 0x7a, 0xe0, 0xd0, 0x23, 0xe2, 0x90, 0xd2, 0xf6, 0xc2, 0x39, 0x9f, + 0x00, 0x79, 0x66, 0xf2, 0x87, 0x82, 0xda, 0x3d, 0x65, 0xde, 0x7b, 0xbf, 0xf7, 0xcb, 0xcf, 0xbf, + 0x79, 0x6f, 0xc0, 0xcb, 0x83, 0x28, 0x26, 0xef, 0xc6, 0xe4, 0xcc, 0x8a, 0xfc, 0xe4, 0x18, 0xb3, + 0xc9, 0xd8, 0x0f, 0xb0, 0x75, 0xf2, 0x7a, 0x80, 0x99, 0xff, 0xda, 0xf2, 0xa7, 0x01, 0x23, 0x34, + 0x36, 0x27, 0x09, 0x65, 0x14, 0x7e, 0xbc, 0xc0, 0x9a, 0x6b, 0x58, 0x53, 0x62, 0x6b, 0x5a, 0x40, + 0xd3, 0x88, 0xa6, 0xd6, 0xc0, 0x4f, 0x57, 0x04, 0x01, 0x25, 0xb2, 0xbb, 0xb6, 0x13, 0xd2, 0x90, + 0xf2, 0xa3, 0x95, 0x9d, 0x64, 0x56, 0x0f, 0x29, 0x0d, 0xc7, 0xd8, 0xe2, 0xd1, 0x60, 0x3a, 0xb4, + 0x18, 0x89, 0x70, 0xca, 0xfc, 0x68, 0x22, 0x01, 0x0f, 0x0b, 0x1c, 0x93, 0x94, 0x91, 0x38, 0x14, + 0x58, 0xe3, 0x97, 0x12, 0x78, 0xda, 0x14, 0x92, 0xbf, 0x15, 0x05, 0xf8, 0x14, 0xe4, 0x09, 0x52, + 0x95, 0xba, 0xd2, 0x28, 0xba, 0x79, 0x82, 0x60, 0x03, 0x94, 0xe2, 0x21, 0xf3, 0x08, 0x52, 0xf3, + 0x75, 0xa5, 0x51, 0xb1, 0xb7, 0xe6, 0x33, 0xfd, 0xc9, 0xb9, 0x1f, 0x8d, 0xdf, 0x18, 0x22, 0x6f, + 0xb8, 0x1b, 0xf1, 0x90, 0x39, 0x08, 0x9a, 0xa0, 0x8c, 0x70, 0x4c, 0xa3, 0x0c, 0x5b, 0xe0, 0xd8, + 0xed, 0xf9, 0x4c, 0xff, 0x50, 0x60, 0x17, 0x15, 0xc3, 0xdd, 0xe4, 0x47, 0x07, 0xc1, 0x9f, 0x15, + 0x50, 0x4d, 0x99, 0x9f, 0x30, 0x6f, 0x92, 0x90, 0x00, 0xab, 0xc5, 0xba, 0xd2, 0xa8, 0xee, 0xef, + 0x9a, 0xc2, 0x16, 0x33, 0xb3, 0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d, 0xd3, 0x7e, 0xfb, 0x2c, 0x07, 0xf7, 0xc0, 0x8b, 0x7b, 0x75, 0xa7, 0xd3, 0x6c, 0xf5, + 0x9d, 0xef, 0xdb, 0xcf, 0x14, 0xb8, 0x0b, 0x9e, 0xdf, 0x2b, 0xca, 0x52, 0xde, 0x3e, 0xba, 0xbc, + 0xd1, 0x72, 0x57, 0x37, 0x5a, 0xee, 0xf2, 0x56, 0x53, 0xae, 0x6e, 0x35, 0xe5, 0xaf, 0x5b, 0x4d, + 0xb9, 0xb8, 0xd3, 0x72, 0x57, 0x77, 0x5a, 0xee, 0x8f, 0x3b, 0x2d, 0xf7, 0xe3, 0x57, 0x6b, 0x63, + 0xb7, 0x7c, 0x95, 0x68, 0x14, 0x93, 0xe1, 0x98, 0x9c, 0x8d, 0xa6, 0x03, 0xeb, 0x64, 0xdf, 0xfa, + 0xf7, 0x33, 0xc5, 0x47, 0x71, 0x50, 0xe2, 0x1f, 0xfb, 0xc5, 0x3f, 0x01, 0x00, 0x00, 0xff, 0xff, + 0x98, 0x0b, 0xa4, 0xd9, 0x6c, 0x05, 0x00, 0x00, } func (this *Bid) Equal(that interface{}) bool { diff --git a/x/marketplace/types/bid.go b/x/marketplace/types/bid.go index e1a0abba..4d94d8f7 100644 --- a/x/marketplace/types/bid.go +++ b/x/marketplace/types/bid.go @@ -3,9 +3,9 @@ package types import ( "time" - "github.com/OmniFlix/omniflixhub/x/marketplace/exported" + "github.com/OmniFlix/omniflixhub/v2/x/marketplace/exported" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/gogo/protobuf/proto" + "github.com/cosmos/gogoproto/proto" ) var ( diff --git a/x/marketplace/types/codec.go b/x/marketplace/types/codec.go index a8000a7d..7f29948a 100644 --- a/x/marketplace/types/codec.go +++ b/x/marketplace/types/codec.go @@ -5,9 +5,11 @@ import ( "github.com/cosmos/cosmos-sdk/codec/types" cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" sdk "github.com/cosmos/cosmos-sdk/types" - gogotypes "github.com/gogo/protobuf/types" + "github.com/cosmos/cosmos-sdk/types/msgservice" + authzcodec "github.com/cosmos/cosmos-sdk/x/authz/codec" + gogotypes "github.com/cosmos/gogoproto/types" - "github.com/OmniFlix/omniflixhub/x/marketplace/exported" + "github.com/OmniFlix/omniflixhub/v2/x/marketplace/exported" ) func RegisterLegacyAminoCodec(cdc *codec.LegacyAmino) { @@ -18,11 +20,13 @@ func RegisterLegacyAminoCodec(cdc *codec.LegacyAmino) { cdc.RegisterConcrete(&MsgCreateAuction{}, "OmniFlix/marketplace/MsgCreateAuction", nil) cdc.RegisterConcrete(&MsgCancelAuction{}, "OmniFlix/marketplace/MsgCancelAuction", nil) cdc.RegisterConcrete(&MsgPlaceBid{}, "OmniFlix/marketplace/MsgPlaceBid", nil) + cdc.RegisterConcrete(&MsgUpdateParams{}, "OmniFlix/marketplace/MsgUpdateParams", nil) cdc.RegisterInterface((*exported.ListingI)(nil), nil) cdc.RegisterConcrete(&Listing{}, "OmniFlix/marketplace/Listing", nil) cdc.RegisterInterface((*exported.AuctionListingI)(nil), nil) cdc.RegisterConcrete(&AuctionListing{}, "OmniFlix/marketplace/AuctionListing", nil) + cdc.RegisterConcrete(&Params{}, "OmniFlix/marketplace/Params", nil) } func RegisterInterfaces(registry types.InterfaceRegistry) { @@ -34,6 +38,7 @@ func RegisterInterfaces(registry types.InterfaceRegistry) { &MsgCreateAuction{}, &MsgCancelAuction{}, &MsgPlaceBid{}, + &MsgUpdateParams{}, ) registry.RegisterImplementations((*exported.ListingI)(nil), @@ -42,6 +47,7 @@ func RegisterInterfaces(registry types.InterfaceRegistry) { registry.RegisterImplementations((*exported.AuctionListingI)(nil), &AuctionListing{}, ) + msgservice.RegisterMsgServiceDesc(registry, &_Msg_serviceDesc) } var ( @@ -53,6 +59,10 @@ var ( func init() { RegisterLegacyAminoCodec(amino) cryptocodec.RegisterCrypto(amino) + // Register all Amino interfaces and concrete types on the authz Amino codec + // so that this can later be used to properly serialize MsgGrant and MsgExec + // instances. + RegisterLegacyAminoCodec(authzcodec.Amino) amino.Seal() } diff --git a/x/marketplace/types/errors.go b/x/marketplace/types/errors.go index a2068bae..6e80cbff 100644 --- a/x/marketplace/types/errors.go +++ b/x/marketplace/types/errors.go @@ -1,36 +1,36 @@ package types import ( - sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" + errorsmod "cosmossdk.io/errors" ) // Listing module errors var ( - ErrListingNotExists = sdkerrors.Register(ModuleName, 2, "Listing does not exist") - ErrInvalidOwner = sdkerrors.Register(ModuleName, 3, "invalid Listing owner") - ErrInvalidPrice = sdkerrors.Register(ModuleName, 4, "invalid amount") - ErrInvalidListing = sdkerrors.Register(ModuleName, 5, "invalid Listing") - ErrListingAlreadyExists = sdkerrors.Register(ModuleName, 6, "Listing already exists") - ErrNotEnoughAmount = sdkerrors.Register(ModuleName, 7, "amount is not enough to buy") - ErrInvalidPriceDenom = sdkerrors.Register(ModuleName, 8, "invalid price denom") - ErrInvalidListingId = sdkerrors.Register(ModuleName, 9, "invalid Listing id") - ErrInvalidNftId = sdkerrors.Register(ModuleName, 10, "invalid nft id") - ErrNftNotExists = sdkerrors.Register(ModuleName, 11, "nft not exists with given details") - ErrUnauthorized = sdkerrors.Register(ModuleName, 12, "unauthorized") - ErrNftNonTransferable = sdkerrors.Register(ModuleName, 13, "non-transferable nft") - ErrListingDoesNotExists = sdkerrors.Register(ModuleName, 14, "listing doesn't exists") - ErrInvalidSplits = sdkerrors.Register(ModuleName, 15, "invalid split shares") - ErrNonPositiveNumber = sdkerrors.Register(ModuleName, 16, "non positive number") - ErrInvalidAuctionId = sdkerrors.Register(ModuleName, 17, "invalid auction id") - ErrInvalidWhitelistAccounts = sdkerrors.Register(ModuleName, 18, "invalid whitelist accounts") - ErrAuctionDoesNotExists = sdkerrors.Register(ModuleName, 19, "auction listing doesn't exists") - ErrBidExists = sdkerrors.Register(ModuleName, 20, "bid exists") - ErrEndedAuction = sdkerrors.Register(ModuleName, 21, "auction ended") - ErrInActiveAuction = sdkerrors.Register(ModuleName, 22, "inactive auction") - ErrBidAmountNotEnough = sdkerrors.Register(ModuleName, 23, "amount is not enough to bid") - ErrBidDoesNotExists = sdkerrors.Register(ModuleName, 24, "bid does not exists") - ErrInvalidStartTime = sdkerrors.Register(ModuleName, 25, "invalid start time") - ErrInvalidPercentage = sdkerrors.Register(ModuleName, 26, "invalid percentage decimal value") - ErrInvalidTime = sdkerrors.Register(ModuleName, 27, "invalid timestamp value") - ErrInvalidDuration = sdkerrors.Register(ModuleName, 28, "invalid duration") + ErrListingNotExists = errorsmod.Register(ModuleName, 2, "Listing does not exist") + ErrInvalidOwner = errorsmod.Register(ModuleName, 3, "invalid Listing owner") + ErrInvalidPrice = errorsmod.Register(ModuleName, 4, "invalid amount") + ErrInvalidListing = errorsmod.Register(ModuleName, 5, "invalid Listing") + ErrListingAlreadyExists = errorsmod.Register(ModuleName, 6, "Listing already exists") + ErrNotEnoughAmount = errorsmod.Register(ModuleName, 7, "amount is not enough to buy") + ErrInvalidPriceDenom = errorsmod.Register(ModuleName, 8, "invalid price denom") + ErrInvalidListingId = errorsmod.Register(ModuleName, 9, "invalid Listing id") + ErrInvalidNftId = errorsmod.Register(ModuleName, 10, "invalid nft id") + ErrNftNotExists = errorsmod.Register(ModuleName, 11, "nft not exists with given details") + ErrUnauthorized = errorsmod.Register(ModuleName, 12, "unauthorized") + ErrNftNonTransferable = errorsmod.Register(ModuleName, 13, "non-transferable nft") + ErrListingDoesNotExists = errorsmod.Register(ModuleName, 14, "listing doesn't exists") + ErrInvalidSplits = errorsmod.Register(ModuleName, 15, "invalid split shares") + ErrNonPositiveNumber = errorsmod.Register(ModuleName, 16, "non positive number") + ErrInvalidAuctionId = errorsmod.Register(ModuleName, 17, "invalid auction id") + ErrInvalidWhitelistAccounts = errorsmod.Register(ModuleName, 18, "invalid whitelist accounts") + ErrAuctionDoesNotExists = errorsmod.Register(ModuleName, 19, "auction listing doesn't exists") + ErrBidExists = errorsmod.Register(ModuleName, 20, "bid exists") + ErrEndedAuction = errorsmod.Register(ModuleName, 21, "auction ended") + ErrInActiveAuction = errorsmod.Register(ModuleName, 22, "inactive auction") + ErrBidAmountNotEnough = errorsmod.Register(ModuleName, 23, "amount is not enough to bid") + ErrBidDoesNotExists = errorsmod.Register(ModuleName, 24, "bid does not exists") + ErrInvalidStartTime = errorsmod.Register(ModuleName, 25, "invalid start time") + ErrInvalidPercentage = errorsmod.Register(ModuleName, 26, "invalid percentage decimal value") + ErrInvalidTime = errorsmod.Register(ModuleName, 27, "invalid timestamp value") + ErrInvalidDuration = errorsmod.Register(ModuleName, 28, "invalid duration") ) diff --git a/x/marketplace/types/events.pb.go b/x/marketplace/types/events.pb.go index 3cfbb77a..d4b5f01a 100644 --- a/x/marketplace/types/events.pb.go +++ b/x/marketplace/types/events.pb.go @@ -1,11 +1,11 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: omniflix/marketplace/v1beta1/events.proto +// source: OmniFlix/marketplace/v1beta1/events.proto package types import ( fmt "fmt" - proto "github.com/gogo/protobuf/proto" + proto "github.com/cosmos/gogoproto/proto" io "io" math "math" math_bits "math/bits" @@ -34,7 +34,7 @@ func (m *EventListNFT) Reset() { *m = EventListNFT{} } func (m *EventListNFT) String() string { return proto.CompactTextString(m) } func (*EventListNFT) ProtoMessage() {} func (*EventListNFT) Descriptor() ([]byte, []int) { - return fileDescriptor_1f26db43bc3ef6c8, []int{0} + return fileDescriptor_0b9bdbdeacba8581, []int{0} } func (m *EventListNFT) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -103,7 +103,7 @@ func (m *EventEditListing) Reset() { *m = EventEditListing{} } func (m *EventEditListing) String() string { return proto.CompactTextString(m) } func (*EventEditListing) ProtoMessage() {} func (*EventEditListing) Descriptor() ([]byte, []int) { - return fileDescriptor_1f26db43bc3ef6c8, []int{1} + return fileDescriptor_0b9bdbdeacba8581, []int{1} } func (m *EventEditListing) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -172,7 +172,7 @@ func (m *EventDeListNFT) Reset() { *m = EventDeListNFT{} } func (m *EventDeListNFT) String() string { return proto.CompactTextString(m) } func (*EventDeListNFT) ProtoMessage() {} func (*EventDeListNFT) Descriptor() ([]byte, []int) { - return fileDescriptor_1f26db43bc3ef6c8, []int{2} + return fileDescriptor_0b9bdbdeacba8581, []int{2} } func (m *EventDeListNFT) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -242,7 +242,7 @@ func (m *EventBuyNFT) Reset() { *m = EventBuyNFT{} } func (m *EventBuyNFT) String() string { return proto.CompactTextString(m) } func (*EventBuyNFT) ProtoMessage() {} func (*EventBuyNFT) Descriptor() ([]byte, []int) { - return fileDescriptor_1f26db43bc3ef6c8, []int{3} + return fileDescriptor_0b9bdbdeacba8581, []int{3} } func (m *EventBuyNFT) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -319,7 +319,7 @@ func (m *EventCreateAuction) Reset() { *m = EventCreateAuction{} } func (m *EventCreateAuction) String() string { return proto.CompactTextString(m) } func (*EventCreateAuction) ProtoMessage() {} func (*EventCreateAuction) Descriptor() ([]byte, []int) { - return fileDescriptor_1f26db43bc3ef6c8, []int{4} + return fileDescriptor_0b9bdbdeacba8581, []int{4} } func (m *EventCreateAuction) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -395,7 +395,7 @@ func (m *EventCancelAuction) Reset() { *m = EventCancelAuction{} } func (m *EventCancelAuction) String() string { return proto.CompactTextString(m) } func (*EventCancelAuction) ProtoMessage() {} func (*EventCancelAuction) Descriptor() ([]byte, []int) { - return fileDescriptor_1f26db43bc3ef6c8, []int{5} + return fileDescriptor_0b9bdbdeacba8581, []int{5} } func (m *EventCancelAuction) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -465,7 +465,7 @@ func (m *EventPlaceBid) Reset() { *m = EventPlaceBid{} } func (m *EventPlaceBid) String() string { return proto.CompactTextString(m) } func (*EventPlaceBid) ProtoMessage() {} func (*EventPlaceBid) Descriptor() ([]byte, []int) { - return fileDescriptor_1f26db43bc3ef6c8, []int{6} + return fileDescriptor_0b9bdbdeacba8581, []int{6} } func (m *EventPlaceBid) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -540,35 +540,35 @@ func init() { } func init() { - proto.RegisterFile("omniflix/marketplace/v1beta1/events.proto", fileDescriptor_1f26db43bc3ef6c8) -} - -var fileDescriptor_1f26db43bc3ef6c8 = []byte{ - // 374 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xb4, 0x93, 0xcf, 0x4e, 0xea, 0x40, - 0x14, 0xc6, 0x29, 0xf7, 0xc2, 0x85, 0x73, 0xef, 0x25, 0xa6, 0x51, 0x53, 0xa3, 0x36, 0xa6, 0x2b, - 0xdd, 0xb4, 0x21, 0x3c, 0x81, 0x28, 0x24, 0x24, 0xfe, 0x21, 0xc6, 0x95, 0x1b, 0x32, 0xed, 0x4c, - 0xe1, 0x68, 0x67, 0xa6, 0x29, 0x53, 0x84, 0xf8, 0x04, 0xee, 0x78, 0x2c, 0x97, 0x2c, 0x5d, 0x1a, - 0x78, 0x11, 0xd3, 0xa1, 0x10, 0xdd, 0x9a, 0x74, 0xf9, 0x7d, 0xe7, 0x4c, 0x7e, 0xdf, 0x4c, 0xe6, - 0x83, 0x33, 0xc9, 0x05, 0x86, 0x11, 0x4e, 0x3d, 0x4e, 0x92, 0x27, 0xa6, 0xe2, 0x88, 0x04, 0xcc, - 0x9b, 0x34, 0x7d, 0xa6, 0x48, 0xd3, 0x63, 0x13, 0x26, 0xd4, 0xd8, 0x8d, 0x13, 0xa9, 0xa4, 0x79, - 0x74, 0xcb, 0x05, 0x76, 0x23, 0x9c, 0xba, 0x5f, 0x56, 0xdd, 0x7c, 0xd5, 0x09, 0xe1, 0x5f, 0x27, - 0xdb, 0xbe, 0xc2, 0xb1, 0xba, 0xe9, 0xde, 0x9b, 0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0xd2, - 0x36, 0xe6, 0x2b, 0xbb, 0xb4, 0x58, 0xd9, 0xa5, 0xf7, 0x95, 0x5d, 0x7a, 0x68, 0x0d, 0x51, 0x8d, - 0x52, 0xdf, 0x0d, 0x24, 0xf7, 0x36, 0x55, 0xf4, 0x36, 0xf5, 0x1d, 0xa5, 0xbe, 0xf7, 0xbd, 0xc3, - 0x6a, 0x16, 0xb3, 0xb1, 0x5f, 0xd5, 0xdd, 0x6d, 0x7d, 0x06, 0x00, 0x00, 0xff, 0xff, 0xdb, 0x3b, - 0xfa, 0xf0, 0xe8, 0x03, 0x00, 0x00, + proto.RegisterFile("OmniFlix/marketplace/v1beta1/events.proto", fileDescriptor_0b9bdbdeacba8581) +} + +var fileDescriptor_0b9bdbdeacba8581 = []byte{ + // 375 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xb4, 0x93, 0x41, 0x4f, 0xea, 0x40, + 0x14, 0x85, 0x29, 0xef, 0xc1, 0x83, 0xfb, 0xde, 0x23, 0xa6, 0x51, 0x53, 0xa3, 0x36, 0xa6, 0x2b, + 0xdd, 0xb4, 0x41, 0x13, 0xf7, 0xa2, 0x90, 0x90, 0x18, 0x25, 0xc6, 0x95, 0x1b, 0x32, 0xed, 0x4c, + 0xe1, 0x6a, 0x67, 0xa6, 0x29, 0x53, 0x84, 0xf8, 0x0b, 0xdc, 0xf1, 0xb3, 0x5c, 0xb2, 0x74, 0x69, + 0xe0, 0x8f, 0x98, 0x0e, 0x85, 0xe8, 0xd6, 0xa4, 0xcb, 0x73, 0xee, 0x99, 0x7c, 0x67, 0x26, 0x73, + 0xe1, 0xe4, 0x96, 0x0b, 0xec, 0x44, 0x38, 0xf1, 0x38, 0x49, 0x9e, 0x98, 0x8a, 0x23, 0x12, 0x30, + 0x6f, 0xdc, 0xf4, 0x99, 0x22, 0x4d, 0x8f, 0x8d, 0x99, 0x50, 0x23, 0x37, 0x4e, 0xa4, 0x92, 0xe6, + 0xc1, 0x3a, 0xea, 0x7e, 0x89, 0xba, 0x79, 0xd4, 0x09, 0xe1, 0x5f, 0x3b, 0x4b, 0x5f, 0xe3, 0x48, + 0xdd, 0x74, 0xee, 0xcd, 0x06, 0x94, 0x91, 0x5a, 0xc6, 0x91, 0x71, 0x5c, 0xbf, 0x2b, 0x23, 0x35, + 0x77, 0xa0, 0x2a, 0x42, 0xd5, 0x47, 0x6a, 0x95, 0xb5, 0x57, 0x11, 0xa1, 0xea, 0x52, 0x73, 0x0f, + 0x6a, 0x94, 0x09, 0xc9, 0xb3, 0xc1, 0x2f, 0x3d, 0xf8, 0xa3, 0x75, 0x97, 0x9a, 0xdb, 0x50, 0x91, + 0xcf, 0x82, 0x25, 0xd6, 0xef, 0xd5, 0x01, 0x2d, 0x9c, 0x47, 0xd8, 0xd2, 0x9c, 0x36, 0x45, 0xcd, + 0x42, 0x31, 0x28, 0x8c, 0x35, 0x84, 0x86, 0x66, 0x5d, 0xb1, 0xa2, 0x6f, 0xf5, 0x02, 0x7f, 0x35, + 0xa9, 0x95, 0x4e, 0x0b, 0xc4, 0x64, 0xae, 0x9f, 0x4e, 0x59, 0x62, 0x55, 0x56, 0xae, 0x16, 0xce, + 0xab, 0x01, 0xa6, 0xa6, 0x5f, 0x26, 0x8c, 0x28, 0x76, 0x91, 0x06, 0x0a, 0xa5, 0x28, 0xac, 0xc4, + 0x3e, 0xd4, 0x39, 0x8a, 0x7e, 0x9c, 0x60, 0xc0, 0xf2, 0x22, 0x35, 0x8e, 0xa2, 0x97, 0x69, 0x27, + 0x5a, 0x57, 0x21, 0x22, 0x60, 0x51, 0xc1, 0x55, 0x9c, 0x99, 0x01, 0xff, 0x35, 0xae, 0x97, 0xfd, + 0xe5, 0x16, 0x52, 0xf3, 0x10, 0x80, 0xac, 0xa0, 0xfd, 0x0d, 0xb1, 0x9e, 0x3b, 0xdd, 0x9f, 0x80, + 0x77, 0xa1, 0xea, 0x23, 0xa5, 0x1b, 0x72, 0xae, 0x32, 0x9f, 0x70, 0x99, 0x0a, 0x95, 0x3f, 0x41, + 0xae, 0x5a, 0xbd, 0xb7, 0x85, 0x6d, 0xcc, 0x17, 0xb6, 0xf1, 0xb1, 0xb0, 0x8d, 0xd9, 0xd2, 0x2e, + 0xcd, 0x97, 0x76, 0xe9, 0x7d, 0x69, 0x97, 0x1e, 0xce, 0x07, 0xa8, 0x86, 0xa9, 0xef, 0x06, 0x92, + 0x7b, 0x9b, 0xad, 0x95, 0x5c, 0x60, 0x18, 0xe1, 0x64, 0x98, 0xfa, 0xde, 0xf8, 0xd4, 0xfb, 0xbe, + 0xc6, 0x6a, 0x1a, 0xb3, 0x91, 0x5f, 0xd5, 0xeb, 0x7b, 0xf6, 0x19, 0x00, 0x00, 0xff, 0xff, 0xfe, + 0xb1, 0x3b, 0x56, 0xeb, 0x03, 0x00, 0x00, } func (m *EventListNFT) Marshal() (dAtA []byte, err error) { diff --git a/x/marketplace/types/expected_keepers.go b/x/marketplace/types/expected_keepers.go index 7e5ca8cc..896f8f8e 100644 --- a/x/marketplace/types/expected_keepers.go +++ b/x/marketplace/types/expected_keepers.go @@ -25,7 +25,7 @@ type BankKeeper interface { type NftKeeper interface { // methods imported from nft should be defined here - GetONFT(ctx sdk.Context, denomId, onftId string) (nft nft.ONFT, err error) + GetONFT(ctx sdk.Context, denomId, onftId string) (nft nft.ONFTI, err error) GetDenom(ctx sdk.Context, denomId string) (nftypes.Denom, error) TransferOwnership(ctx sdk.Context, denomId, nftId string, srcOwner, dstOwner sdk.AccAddress) error } diff --git a/x/marketplace/types/genesis.go b/x/marketplace/types/genesis.go index 62eee785..1f233506 100644 --- a/x/marketplace/types/genesis.go +++ b/x/marketplace/types/genesis.go @@ -1,6 +1,9 @@ package types -import sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" +import ( + errorsmod "cosmossdk.io/errors" + sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" +) func NewGenesisState(listings []Listing, listingCount uint64, params Params, auctions []AuctionListing, bids []Bid, nextAuctionNumber uint64, @@ -18,7 +21,7 @@ func NewGenesisState(listings []Listing, listingCount uint64, params Params, func (m *GenesisState) ValidateGenesis() error { for _, l := range m.Listings { if l.GetOwner().Empty() { - return sdkerrors.Wrap(sdkerrors.ErrInvalidAddress, "missing nft owner") + return errorsmod.Wrap(sdkerrors.ErrInvalidAddress, "missing nft owner") } if err := ValidateListing(l); err != nil { return err @@ -38,7 +41,7 @@ func (m *GenesisState) ValidateGenesis() error { } } if m.NextAuctionNumber <= 0 { - return sdkerrors.Wrap(ErrNonPositiveNumber, "must be a number and greater than 0.") + return errorsmod.Wrap(ErrNonPositiveNumber, "must be a number and greater than 0.") } return nil } diff --git a/x/marketplace/types/genesis.pb.go b/x/marketplace/types/genesis.pb.go index 34771e13..f73e8bdd 100644 --- a/x/marketplace/types/genesis.pb.go +++ b/x/marketplace/types/genesis.pb.go @@ -1,12 +1,12 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: omniflix/marketplace/v1beta1/genesis.proto +// source: OmniFlix/marketplace/v1beta1/genesis.proto package types import ( fmt "fmt" - _ "github.com/gogo/protobuf/gogoproto" - proto "github.com/gogo/protobuf/proto" + _ "github.com/cosmos/gogoproto/gogoproto" + proto "github.com/cosmos/gogoproto/proto" io "io" math "math" math_bits "math/bits" @@ -37,7 +37,7 @@ func (m *GenesisState) Reset() { *m = GenesisState{} } func (m *GenesisState) String() string { return proto.CompactTextString(m) } func (*GenesisState) ProtoMessage() {} func (*GenesisState) Descriptor() ([]byte, []int) { - return fileDescriptor_2158df64a6fb9282, []int{0} + return fileDescriptor_8a65cfd42fa482d5, []int{0} } func (m *GenesisState) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -113,33 +113,34 @@ func init() { } func init() { - proto.RegisterFile("omniflix/marketplace/v1beta1/genesis.proto", fileDescriptor_2158df64a6fb9282) + proto.RegisterFile("OmniFlix/marketplace/v1beta1/genesis.proto", fileDescriptor_8a65cfd42fa482d5) } -var fileDescriptor_2158df64a6fb9282 = []byte{ - // 348 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x91, 0x4d, 0x4f, 0xc2, 0x30, - 0x18, 0xc7, 0x37, 0x98, 0x84, 0x14, 0x2e, 0x56, 0x0f, 0x0b, 0x31, 0x13, 0x89, 0x26, 0x68, 0x4c, - 0x1b, 0xe0, 0xe8, 0xc9, 0x99, 0xc8, 0x45, 0xd1, 0xe0, 0xcd, 0x0b, 0xe9, 0xa0, 0x8e, 0xc6, 0xad, - 0x5d, 0xd6, 0xce, 0xe0, 0xb7, 0xf0, 0x63, 0x71, 0xe4, 0xe8, 0xc9, 0x18, 0xf8, 0x1a, 0x1e, 0x0c, - 0x5d, 0x31, 0xe2, 0x61, 0xf1, 0xd6, 0xf4, 0xf9, 0x3d, 0xff, 0x97, 0x3c, 0xe0, 0x4c, 0xc4, 0x9c, - 0x3d, 0x45, 0x6c, 0x86, 0x63, 0x92, 0x3e, 0x53, 0x95, 0x44, 0x64, 0x4c, 0xf1, 0x4b, 0x27, 0xa0, - 0x8a, 0x74, 0x70, 0x48, 0x39, 0x95, 0x4c, 0xa2, 0x24, 0x15, 0x4a, 0xc0, 0x83, 0xbb, 0x98, 0xb3, - 0xeb, 0x88, 0xcd, 0xd0, 0x2f, 0x16, 0x19, 0xb6, 0xb1, 0x1f, 0x8a, 0x50, 0x68, 0x10, 0xaf, 0x5f, - 0xf9, 0x4e, 0xa3, 0x58, 0x3f, 0x62, 0x52, 0x31, 0x1e, 0xfe, 0x8b, 0x25, 0xd9, 0x58, 0x31, 0xc1, - 0x0d, 0x7b, 0x5a, 0xc8, 0x26, 0x24, 0x25, 0xb1, 0x89, 0xdd, 0xfa, 0x2a, 0x81, 0x7a, 0x3f, 0x2f, - 0xf2, 0xa0, 0x88, 0xa2, 0xb0, 0x0f, 0xaa, 0xc6, 0x58, 0xba, 0x76, 0xb3, 0xdc, 0xae, 0x75, 0x4f, - 0x50, 0x51, 0x35, 0x74, 0x93, 0xd3, 0xbe, 0x33, 0xff, 0x38, 0xb4, 0x86, 0x3f, 0xcb, 0xb0, 0x05, - 0xea, 0x66, 0x74, 0x25, 0x32, 0xae, 0xdc, 0x52, 0xd3, 0x6e, 0x3b, 0xc3, 0xad, 0x3f, 0xe8, 0x83, - 0x4a, 0x9e, 0xc6, 0x2d, 0x37, 0xed, 0x76, 0xad, 0x7b, 0x5c, 0x6c, 0x75, 0xaf, 0x59, 0xe3, 0x64, - 0x36, 0xe1, 0x00, 0x54, 0x4d, 0x7b, 0xe9, 0x3a, 0x3a, 0xf0, 0x79, 0xb1, 0xca, 0x65, 0x4e, 0xff, - 0xc9, 0xbd, 0xd1, 0x80, 0x17, 0xc0, 0x09, 0xd8, 0x44, 0xba, 0x3b, 0x5a, 0xeb, 0xa8, 0x58, 0xcb, - 0x67, 0x13, 0x23, 0xa0, 0x97, 0x20, 0x02, 0x7b, 0x9c, 0xce, 0xd4, 0xc8, 0xa8, 0x8d, 0x78, 0x16, - 0x07, 0x34, 0x75, 0x2b, 0xba, 0xfb, 0xee, 0x7a, 0x64, 0xdc, 0x07, 0x7a, 0xe0, 0xdf, 0xce, 0x97, - 0x9e, 0xbd, 0x58, 0x7a, 0xf6, 0xe7, 0xd2, 0xb3, 0xdf, 0x56, 0x9e, 0xb5, 0x58, 0x79, 0xd6, 0xfb, - 0xca, 0xb3, 0x1e, 0x7b, 0x21, 0x53, 0xd3, 0x2c, 0x40, 0x63, 0x11, 0xe3, 0x4d, 0x04, 0xbc, 0xb9, - 0xeb, 0x34, 0x0b, 0xf0, 0xf6, 0x71, 0xd5, 0x6b, 0x42, 0x65, 0x50, 0xd1, 0x47, 0xed, 0x7d, 0x07, - 0x00, 0x00, 0xff, 0xff, 0xe7, 0x61, 0xce, 0x68, 0xb9, 0x02, 0x00, 0x00, +var fileDescriptor_8a65cfd42fa482d5 = []byte{ + // 353 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x91, 0x4f, 0x4f, 0xf2, 0x30, + 0x1c, 0xc7, 0x37, 0xd8, 0x43, 0x48, 0xe1, 0xf2, 0xf4, 0x79, 0x0e, 0x0b, 0x31, 0x13, 0x89, 0x26, + 0x68, 0x4c, 0x1b, 0x30, 0xf1, 0xe2, 0xc9, 0x99, 0xc8, 0xc5, 0x20, 0xc1, 0x9b, 0x17, 0xd2, 0x41, + 0x1d, 0x8d, 0x5b, 0xbb, 0xac, 0x1d, 0xc1, 0x77, 0xe1, 0xcb, 0xe2, 0xc8, 0xd1, 0x93, 0x31, 0xf0, + 0x36, 0x3c, 0x18, 0xba, 0x42, 0xc4, 0xc3, 0xe2, 0xad, 0xe9, 0xef, 0xf3, 0xfb, 0xfe, 0xc9, 0x0f, + 0x9c, 0xdd, 0xc7, 0x9c, 0xdd, 0x46, 0x6c, 0x8e, 0x63, 0x92, 0x3e, 0x53, 0x95, 0x44, 0x64, 0x4c, + 0xf1, 0xac, 0x13, 0x50, 0x45, 0x3a, 0x38, 0xa4, 0x9c, 0x4a, 0x26, 0x51, 0x92, 0x0a, 0x25, 0xe0, + 0xc1, 0x96, 0x45, 0xdf, 0x58, 0x64, 0xd8, 0xc6, 0xff, 0x50, 0x84, 0x42, 0x83, 0x78, 0xf3, 0xca, + 0x77, 0x1a, 0xc5, 0xfa, 0x11, 0x93, 0x8a, 0xf1, 0xf0, 0x57, 0x2c, 0xc9, 0xc6, 0x8a, 0x09, 0x6e, + 0xd8, 0xd3, 0x42, 0x36, 0x21, 0x29, 0x89, 0x4d, 0xec, 0xd6, 0x67, 0x09, 0xd4, 0x7b, 0x79, 0x91, + 0x07, 0x45, 0x14, 0x85, 0x3d, 0x50, 0x35, 0xc6, 0xd2, 0xb5, 0x9b, 0xe5, 0x76, 0xad, 0x7b, 0x82, + 0x8a, 0xaa, 0xa1, 0xbb, 0x9c, 0xf6, 0x9d, 0xc5, 0xfb, 0xa1, 0x35, 0xdc, 0x2d, 0xc3, 0x16, 0xa8, + 0x9b, 0xd1, 0x8d, 0xc8, 0xb8, 0x72, 0x4b, 0x4d, 0xbb, 0xed, 0x0c, 0xf7, 0xfe, 0xa0, 0x0f, 0x2a, + 0x79, 0x1a, 0xb7, 0xdc, 0xb4, 0xdb, 0xb5, 0xee, 0x71, 0xb1, 0xd5, 0x40, 0xb3, 0xc6, 0xc9, 0x6c, + 0xc2, 0x3e, 0xa8, 0x9a, 0xf6, 0xd2, 0x75, 0x74, 0xe0, 0xf3, 0x62, 0x95, 0xeb, 0x9c, 0xfe, 0x91, + 0x7b, 0xab, 0x01, 0xaf, 0x80, 0x13, 0xb0, 0x89, 0x74, 0xff, 0x68, 0xad, 0xa3, 0x62, 0x2d, 0x9f, + 0x4d, 0x8c, 0x80, 0x5e, 0x82, 0x08, 0xfc, 0xe3, 0x74, 0xae, 0x46, 0x46, 0x6d, 0xc4, 0xb3, 0x38, + 0xa0, 0xa9, 0x5b, 0xd1, 0xdd, 0xff, 0x6e, 0x46, 0xc6, 0xbd, 0xaf, 0x07, 0xfe, 0x60, 0xb1, 0xf2, + 0xec, 0xe5, 0xca, 0xb3, 0x3f, 0x56, 0x9e, 0xfd, 0xba, 0xf6, 0xac, 0xe5, 0xda, 0xb3, 0xde, 0xd6, + 0x9e, 0xf5, 0x78, 0x19, 0x32, 0x35, 0xcd, 0x02, 0x34, 0x16, 0x31, 0xde, 0x9d, 0x53, 0xc4, 0x9c, + 0x3d, 0x45, 0x6c, 0x3e, 0xcd, 0x02, 0x3c, 0xeb, 0xe2, 0xfd, 0xfb, 0xaa, 0x97, 0x84, 0xca, 0xa0, + 0xa2, 0xef, 0x7a, 0xf1, 0x15, 0x00, 0x00, 0xff, 0xff, 0x81, 0xea, 0x1b, 0x28, 0xbc, 0x02, 0x00, + 0x00, } func (m *GenesisState) Marshal() (dAtA []byte, err error) { diff --git a/x/marketplace/types/keys.go b/x/marketplace/types/keys.go index 9bb499bd..866d3ef2 100644 --- a/x/marketplace/types/keys.go +++ b/x/marketplace/types/keys.go @@ -27,6 +27,8 @@ var ( PrefixBidByBidder = []byte{0x12} PrefixInactiveAuction = []byte{0x13} PrefixActiveAuction = []byte{0x14} + + ParamsKey = []byte{0x15} ) func KeyListingIdPrefix(id string) []byte { diff --git a/x/marketplace/types/listing.go b/x/marketplace/types/listing.go index 1fbe1aae..0de2dcf3 100644 --- a/x/marketplace/types/listing.go +++ b/x/marketplace/types/listing.go @@ -1,9 +1,9 @@ package types import ( - "github.com/OmniFlix/omniflixhub/x/marketplace/exported" + "github.com/OmniFlix/omniflixhub/v2/x/marketplace/exported" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/gogo/protobuf/proto" + "github.com/cosmos/gogoproto/proto" ) var ( diff --git a/x/marketplace/types/listing.pb.go b/x/marketplace/types/listing.pb.go index e584e5b8..753b7ece 100644 --- a/x/marketplace/types/listing.pb.go +++ b/x/marketplace/types/listing.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: omniflix/marketplace/v1beta1/listing.proto +// source: OmniFlix/marketplace/v1beta1/listing.proto package types @@ -7,8 +7,8 @@ import ( fmt "fmt" github_com_cosmos_cosmos_sdk_types "github.com/cosmos/cosmos-sdk/types" types "github.com/cosmos/cosmos-sdk/types" - _ "github.com/gogo/protobuf/gogoproto" - proto "github.com/gogo/protobuf/proto" + _ "github.com/cosmos/gogoproto/gogoproto" + proto "github.com/cosmos/gogoproto/proto" io "io" math "math" math_bits "math/bits" @@ -38,7 +38,7 @@ func (m *Listing) Reset() { *m = Listing{} } func (m *Listing) String() string { return proto.CompactTextString(m) } func (*Listing) ProtoMessage() {} func (*Listing) Descriptor() ([]byte, []int) { - return fileDescriptor_a9dd475f3f5b4525, []int{0} + return fileDescriptor_300685922a0a2983, []int{0} } func (m *Listing) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -76,7 +76,7 @@ func (m *WeightedAddress) Reset() { *m = WeightedAddress{} } func (m *WeightedAddress) String() string { return proto.CompactTextString(m) } func (*WeightedAddress) ProtoMessage() {} func (*WeightedAddress) Descriptor() ([]byte, []int) { - return fileDescriptor_a9dd475f3f5b4525, []int{1} + return fileDescriptor_300685922a0a2983, []int{1} } func (m *WeightedAddress) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -111,41 +111,42 @@ func init() { } func init() { - proto.RegisterFile("omniflix/marketplace/v1beta1/listing.proto", fileDescriptor_a9dd475f3f5b4525) + proto.RegisterFile("OmniFlix/marketplace/v1beta1/listing.proto", fileDescriptor_300685922a0a2983) } -var fileDescriptor_a9dd475f3f5b4525 = []byte{ - // 477 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x52, 0x31, 0x6f, 0xd4, 0x30, - 0x14, 0x4e, 0xae, 0xbd, 0x2b, 0xf8, 0x4a, 0x0b, 0x2e, 0x43, 0x28, 0x28, 0x39, 0x65, 0x28, 0x27, - 0x44, 0x6d, 0xb5, 0xdd, 0xba, 0x20, 0x02, 0x42, 0xaa, 0x84, 0x84, 0x08, 0x43, 0x25, 0x96, 0x92, - 0xc4, 0xbe, 0x9c, 0xd5, 0xc4, 0x8e, 0x62, 0x97, 0xb6, 0xff, 0x82, 0x5f, 0x80, 0x98, 0xf9, 0x25, - 0x37, 0x76, 0x44, 0x0c, 0x01, 0xee, 0x16, 0x06, 0xa6, 0xfc, 0x02, 0x14, 0x3b, 0x51, 0x0f, 0x06, - 0xc4, 0xe4, 0xe7, 0xf7, 0xbe, 0xf7, 0x7d, 0x9f, 0x9f, 0x1f, 0x78, 0x24, 0x72, 0xce, 0x26, 0x19, - 0xbb, 0xc0, 0x79, 0x54, 0x9e, 0x52, 0x55, 0x64, 0x51, 0x42, 0xf1, 0xfb, 0xbd, 0x98, 0xaa, 0x68, - 0x0f, 0x67, 0x4c,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, 0xed, 0xdc, 0xae, 0x2b, 0x6f, 0xdd, 0xd8, 0xd1, - 0x69, 0x3f, 0x34, 0x65, 0x98, 0x83, 0x75, 0x59, 0x64, 0x4c, 0x9d, 0xc8, 0x69, 0x54, 0x52, 0xe9, - 0x0c, 0x46, 0x2b, 0xe3, 0xe1, 0xfe, 0x2e, 0xfa, 0xd7, 0xa8, 0xd1, 0x31, 0x65, 0xe9, 0x54, 0x51, - 0xf2, 0x94, 0x90, 0x92, 0x4a, 0x19, 0xdc, 0x6f, 0x4c, 0xd6, 0x95, 0xb7, 0x65, 0x14, 0x96, 0x09, - 0xfd, 0x70, 0xa8, 0xaf, 0x6f, 0xcc, 0xed, 0xa3, 0x0d, 0x36, 0xff, 0xea, 0x86, 0x8f, 0xc1, 0x5a, - 0x64, 0x42, 0x33, 0xfb, 0x00, 0xd6, 0x95, 0xb7, 0x61, 0xa8, 0xda, 0x82, 0x1f, 0x76, 0x10, 0x78, - 0x0c, 0x06, 0xe7, 0x9a, 0xa0, 0xfd, 0x94, 0x27, 0x8d, 0xf6, 0xd7, 0xca, 0xdb, 0xf9, 0x8f, 0x01, - 0x3d, 0xa7, 0xc9, 0xf5, 0x17, 0x1a, 0x16, 0x3f, 0x6c, 0xe9, 0x0e, 0x57, 0x7f, 0x7e, 0xf2, 0xec, - 0xe0, 0xf5, 0xec, 0x87, 0x6b, 0xcd, 0xe6, 0xae, 0x7d, 0x35, 0x77, 0xed, 0xef, 0x73, 0xd7, 0xfe, - 0xb0, 0x70, 0xad, 0xab, 0x85, 0x6b, 0x7d, 0x59, 0xb8, 0xd6, 0xdb, 0x83, 0x25, 0x91, 0x6e, 0x42, - 0xb8, 0xdb, 0xe0, 0xe9, 0x59, 0x8c, 0xff, 0x5c, 0x63, 0xad, 0x1a, 0x0f, 0xf4, 0xa6, 0x1d, 0xfc, - 0x0e, 0x00, 0x00, 0xff, 0xff, 0x20, 0x4a, 0x49, 0x47, 0xeb, 0x02, 0x00, 0x00, +var fileDescriptor_300685922a0a2983 = []byte{ + // 481 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x52, 0xcd, 0x6e, 0xd4, 0x30, + 0x10, 0x4e, 0xb6, 0xdd, 0x2d, 0x78, 0x4b, 0x0b, 0x2e, 0x87, 0x50, 0x50, 0xb2, 0xca, 0xa1, 0xac, + 0x10, 0xb5, 0xd5, 0x45, 0xe2, 0xd0, 0x0b, 0x22, 0x20, 0xa4, 0x4a, 0x48, 0x48, 0x01, 0xa9, 0x12, + 0x97, 0x92, 0xc4, 0xde, 0xac, 0xd5, 0xc4, 0x8e, 0x62, 0xf7, 0xef, 0x2d, 0x78, 0x02, 0xc4, 0x99, + 0x27, 0xd9, 0x63, 0x8f, 0x88, 0x43, 0x80, 0xdd, 0x0b, 0x07, 0x4e, 0x79, 0x02, 0x14, 0x3b, 0x4b, + 0x17, 0x0e, 0x88, 0x93, 0xc7, 0x33, 0xdf, 0x7c, 0xdf, 0xe7, 0xf1, 0x80, 0x07, 0xaf, 0x72, 0xce, + 0x5e, 0x64, 0xec, 0x1c, 0xe7, 0x51, 0x79, 0x4c, 0x55, 0x91, 0x45, 0x09, 0xc5, 0xa7, 0x7b, 0x31, + 0x55, 0xd1, 0x1e, 0xce, 0x98, 0x54, 0x8c, 0xa7, 0xa8, 0x28, 0x85, 0x12, 0xf0, 0xde, 0x02, 0x8b, + 0x96, 0xb0, 0xa8, 0xc5, 0x6e, 0xbb, 0x89, 0x90, 0xb9, 0x90, 0x38, 0x8e, 0xe4, 0x15, 0x41, 0x22, + 0x18, 0x37, 0xdd, 0xdb, 0xb7, 0x53, 0x91, 0x0a, 0x1d, 0xe2, 0x26, 0x32, 0x59, 0xff, 0x67, 0x07, + 0xac, 0xbd, 0x34, 0x2a, 0x70, 0x03, 0x74, 0x18, 0x71, 0xec, 0x81, 0x3d, 0xbc, 0x1e, 0x76, 0x18, + 0x81, 0x43, 0xd0,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, 0x3e, 0x04, 0x6b, 0x91, 0x09, 0xcd, + 0xec, 0x03, 0x58, 0x57, 0xde, 0x86, 0xa1, 0x6a, 0x0b, 0x7e, 0xb8, 0x80, 0xc0, 0x43, 0xd0, 0x3b, + 0xd3, 0x04, 0xed, 0xa7, 0x3c, 0x69, 0xb4, 0xbf, 0x54, 0xde, 0xce, 0x7f, 0x0c, 0xe8, 0x39, 0x4d, + 0xae, 0xbe, 0xd0, 0xb0, 0xf8, 0x61, 0x4b, 0xb7, 0xbf, 0xfa, 0xe3, 0xa3, 0x67, 0x07, 0x6f, 0xa6, + 0xdf, 0x5d, 0x6b, 0x3a, 0x73, 0xed, 0xcb, 0x99, 0x6b, 0x7f, 0x9b, 0xb9, 0xf6, 0xfb, 0xb9, 0x6b, + 0x5d, 0xce, 0x5d, 0xeb, 0xf3, 0xdc, 0xb5, 0xde, 0x3e, 0x5e, 0x12, 0xf9, 0xbd, 0xb8, 0x22, 0xe7, + 0x6c, 0x9c, 0xb1, 0xf3, 0xc9, 0x49, 0x8c, 0x4f, 0x47, 0xf8, 0xcf, 0x4d, 0xd6, 0xc2, 0x71, 0x4f, + 0x2f, 0xdb, 0xa3, 0x5f, 0x01, 0x00, 0x00, 0xff, 0xff, 0xfc, 0xf5, 0xb7, 0xf1, 0xee, 0x02, 0x00, + 0x00, } func (this *WeightedAddress) Equal(that interface{}) bool { diff --git a/x/marketplace/types/msgs.go b/x/marketplace/types/msgs.go index 9457e47e..ad35d6eb 100644 --- a/x/marketplace/types/msgs.go +++ b/x/marketplace/types/msgs.go @@ -3,6 +3,8 @@ package types import ( "time" + errorsmod "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" ) @@ -24,6 +26,7 @@ const ( ) var ( + _ sdk.Msg = &MsgUpdateParams{} _ sdk.Msg = &MsgListNFT{} _ sdk.Msg = &MsgEditListing{} _ sdk.Msg = &MsgDeListNFT{} @@ -94,7 +97,7 @@ func (msg MsgEditListing) Type() string { return TypeMsgEditListing } func (msg MsgEditListing) ValidateBasic() error { _, err := sdk.AccAddressFromBech32(msg.Owner) if err != nil { - return sdkerrors.Wrapf(sdkerrors.ErrInvalidAddress, "invalid owner address (%s)", err) + return errorsmod.Wrapf(sdkerrors.ErrInvalidAddress, "invalid owner address (%s)", err) } return ValidatePrice(msg.Price) } @@ -135,7 +138,7 @@ func (msg MsgDeListNFT) Type() string { return TypeMsgDeListNFT } func (msg MsgDeListNFT) ValidateBasic() error { _, err := sdk.AccAddressFromBech32(msg.Owner) if err != nil { - return sdkerrors.Wrapf(sdkerrors.ErrInvalidAddress, "invalid owner address (%s)", err) + return errorsmod.Wrapf(sdkerrors.ErrInvalidAddress, "invalid owner address (%s)", err) } return nil } @@ -177,7 +180,7 @@ func (msg MsgBuyNFT) Type() string { return TypeMsgBuyNFT } func (msg MsgBuyNFT) ValidateBasic() error { _, err := sdk.AccAddressFromBech32(msg.Buyer) if err != nil { - return sdkerrors.Wrapf(sdkerrors.ErrInvalidAddress, "invalid sender address (%s)", err) + return errorsmod.Wrapf(sdkerrors.ErrInvalidAddress, "invalid sender address (%s)", err) } return ValidatePrice(msg.Price) } @@ -225,7 +228,7 @@ func (msg MsgCreateAuction) Type() string { return TypeMsgCreateAuction } func (msg MsgCreateAuction) ValidateBasic() error { _, err := sdk.AccAddressFromBech32(msg.Owner) if err != nil { - return sdkerrors.Wrapf(sdkerrors.ErrInvalidAddress, "invalid sender address (%s)", err) + return errorsmod.Wrapf(sdkerrors.ErrInvalidAddress, "invalid sender address (%s)", err) } if err = ValidatePrice(msg.StartPrice); err != nil { return err @@ -236,7 +239,7 @@ func (msg MsgCreateAuction) ValidateBasic() error { } } if !msg.IncrementPercentage.IsPositive() || !msg.IncrementPercentage.LTE(sdk.NewDec(1)) { - return sdkerrors.Wrapf(ErrInvalidPercentage, "invalid percentage value (%s)", msg.IncrementPercentage.String()) + return errorsmod.Wrapf(ErrInvalidPercentage, "invalid percentage value (%s)", msg.IncrementPercentage.String()) } if err = ValidateSplitShares(msg.SplitShares); err != nil { return err @@ -252,7 +255,7 @@ func (msg MsgCreateAuction) Validate(now time.Time) error { return err } if msg.StartTime.Before(now) { - return sdkerrors.Wrapf(ErrInvalidStartTime, "start time must be after current time %s", now.String()) + return errorsmod.Wrapf(ErrInvalidStartTime, "start time must be after current time %s", now.String()) } return nil } @@ -289,7 +292,7 @@ func (msg MsgCancelAuction) Type() string { return TypeMsgCancelAuction } func (msg MsgCancelAuction) ValidateBasic() error { _, err := sdk.AccAddressFromBech32(msg.Owner) if err != nil { - return sdkerrors.Wrapf(sdkerrors.ErrInvalidAddress, "invalid owner address (%s)", err) + return errorsmod.Wrapf(sdkerrors.ErrInvalidAddress, "invalid owner address (%s)", err) } return nil } @@ -327,7 +330,7 @@ func (msg MsgPlaceBid) Type() string { return TypeMsgPlaceBid } func (msg MsgPlaceBid) ValidateBasic() error { _, err := sdk.AccAddressFromBech32(msg.Bidder) if err != nil { - return sdkerrors.Wrapf(sdkerrors.ErrInvalidAddress, "invalid bidder address (%s)", err) + return errorsmod.Wrapf(sdkerrors.ErrInvalidAddress, "invalid bidder address (%s)", err) } if err := ValidatePrice(msg.Amount); err != nil { return err @@ -352,3 +355,25 @@ func (msg MsgPlaceBid) GetSigners() []sdk.AccAddress { } return []sdk.AccAddress{from} } + +// MsgUpdateParams + +// GetSignBytes implements the LegacyMsg interface. +func (m MsgUpdateParams) GetSignBytes() []byte { + return sdk.MustSortJSON(ModuleCdc.MustMarshalJSON(&m)) +} + +// GetSigners returns the expected signers for a MsgUpdateParams message. +func (m *MsgUpdateParams) GetSigners() []sdk.AccAddress { + addr, _ := sdk.AccAddressFromBech32(m.Authority) + return []sdk.AccAddress{addr} +} + +// ValidateBasic does a sanity check on the provided data. +func (m *MsgUpdateParams) ValidateBasic() error { + if _, err := sdk.AccAddressFromBech32(m.Authority); err != nil { + return errorsmod.Wrap(err, "invalid authority address") + } + + return m.Params.ValidateBasic() +} diff --git a/x/marketplace/types/params.go b/x/marketplace/types/params.go index 22c6f7d6..cc6ad526 100644 --- a/x/marketplace/types/params.go +++ b/x/marketplace/types/params.go @@ -5,7 +5,6 @@ import ( "time" sdk "github.com/cosmos/cosmos-sdk/types" - paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" ) const ( @@ -14,21 +13,6 @@ const ( DefaultMaxAuctionDuration time.Duration = time.Hour * 24 * 90 // 90 Days ) -// Parameter keys -var ( - ParamStoreKeySaleCommission = []byte("SaleCommission") - ParamStoreKeyDistribution = []byte("MarketplaceDistribution") - ParamStoreKeyBidCloseDuration = []byte("BidCloseDuration") - ParamStoreKeyMaxAuctionDuration = []byte("MaxAuctionDuration") -) - -var _ paramtypes.ParamSet = (*Params)(nil) - -// ParamKeyTable returns the parameter key table. -func ParamKeyTable() paramtypes.KeyTable { - return paramtypes.NewKeyTable().RegisterParamSet(&Params{}) -} - func NewMarketplaceParams( saleCommission sdk.Dec, distribution Distribution, @@ -56,16 +40,6 @@ func DefaultParams() Params { ) } -// ParamSetPairs returns the parameter set pairs. -func (p *Params) ParamSetPairs() paramtypes.ParamSetPairs { - return paramtypes.ParamSetPairs{ - paramtypes.NewParamSetPair(ParamStoreKeySaleCommission, &p.SaleCommission, validateSaleCommission), - paramtypes.NewParamSetPair(ParamStoreKeyDistribution, &p.Distribution, validateMarketplaceDistributionParams), - paramtypes.NewParamSetPair(ParamStoreKeyBidCloseDuration, &p.BidCloseDuration, validateBidCloseDuration), - paramtypes.NewParamSetPair(ParamStoreKeyMaxAuctionDuration, &p.MaxAuctionDuration, validateMaxAuctionDuration), - } -} - // ValidateBasic performs basic validation on marketplace parameters. func (p Params) ValidateBasic() error { if err := validateSaleCommission(p.SaleCommission); err != nil { diff --git a/x/marketplace/types/params.pb.go b/x/marketplace/types/params.pb.go index 892b6b61..dd6b9950 100644 --- a/x/marketplace/types/params.pb.go +++ b/x/marketplace/types/params.pb.go @@ -1,14 +1,14 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: omniflix/marketplace/v1beta1/params.proto +// source: OmniFlix/marketplace/v1beta1/params.proto package types import ( fmt "fmt" github_com_cosmos_cosmos_sdk_types "github.com/cosmos/cosmos-sdk/types" - _ "github.com/gogo/protobuf/gogoproto" - proto "github.com/gogo/protobuf/proto" - github_com_gogo_protobuf_types "github.com/gogo/protobuf/types" + _ "github.com/cosmos/gogoproto/gogoproto" + proto "github.com/cosmos/gogoproto/proto" + github_com_gogo_protobuf_types "github.com/cosmos/gogoproto/types" _ "google.golang.org/protobuf/types/known/durationpb" io "io" math "math" @@ -39,7 +39,7 @@ func (m *Params) Reset() { *m = Params{} } func (m *Params) String() string { return proto.CompactTextString(m) } func (*Params) ProtoMessage() {} func (*Params) Descriptor() ([]byte, []int) { - return fileDescriptor_782e8767fdab5ddb, []int{0} + return fileDescriptor_f06a231652c41f78, []int{0} } func (m *Params) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -77,7 +77,7 @@ func (m *Distribution) Reset() { *m = Distribution{} } func (m *Distribution) String() string { return proto.CompactTextString(m) } func (*Distribution) ProtoMessage() {} func (*Distribution) Descriptor() ([]byte, []int) { - return fileDescriptor_782e8767fdab5ddb, []int{1} + return fileDescriptor_f06a231652c41f78, []int{1} } func (m *Distribution) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -112,41 +112,41 @@ func init() { } func init() { - proto.RegisterFile("omniflix/marketplace/v1beta1/params.proto", fileDescriptor_782e8767fdab5ddb) + proto.RegisterFile("OmniFlix/marketplace/v1beta1/params.proto", fileDescriptor_f06a231652c41f78) } -var fileDescriptor_782e8767fdab5ddb = []byte{ - // 467 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x94, 0x93, 0xcf, 0x6e, 0xd4, 0x30, - 0x10, 0xc6, 0x13, 0x5a, 0x15, 0xd5, 0x94, 0x05, 0x59, 0x05, 0x6d, 0x0b, 0x4a, 0xa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0x18, 0xc4, 0xb2, 0x9a, 0x17, - 0xdc, 0xbc, 0x0a, 0x1c, 0x03, 0x08, 0xff, 0xdd, 0xe4, 0x87, 0x63, 0x4d, 0x66, 0x8e, 0x7d, 0x3e, - 0x73, 0xec, 0xef, 0x33, 0xc7, 0xfe, 0x34, 0x77, 0xac, 0xf3, 0xb9, 0x63, 0x7d, 0x9d, 0x3b, 0xd6, - 0xc9, 0xe1, 0x02, 0xad, 0xbb, 0x2a, 0xb4, 0x7b, 0x47, 0x67, 0x55, 0x44, 0x97, 0x1f, 0x53, 0x83, - 0x8f, 0x36, 0x9a, 0xf9, 0x1f, 0xfe, 0x0c, 0x00, 0x00, 0xff, 0xff, 0xe0, 0x4c, 0x4c, 0xe3, 0x71, - 0x03, 0x00, 0x00, +var fileDescriptor_f06a231652c41f78 = []byte{ + // 470 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x94, 0x93, 0x4f, 0x6e, 0xd4, 0x30, + 0x14, 0xc6, 0x13, 0x5a, 0x15, 0xd5, 0x94, 0x82, 0xac, 0x82, 0xa6, 0x05, 0x25, 0x55, 0x24, 0xa0, + 0x20, 0x61, 0xab, 0x45, 0x62, 0xc1, 0x0a, 0xd2, 0x11, 0xb0, 0xa3, 0x8a, 0xba, 0xea, 0x26, 0x72, + 0xfe, 0x34, 0xb5, 0xc6, 0xce, 0x0b, 0xb1, 0x53, 0xcd, 0xdc, 0x82, 0x25, 0x37, 0xe1, 0x0a, 0xb3, + 0xec, 0x12, 0x75, 0x31, 0xc0, 0xcc, 0x0d, 0x7a, 0x02, 0x94, 0x38, 0x19, 0x66, 0x00, 0x81, 0xba, + 0x4a, 0xfc, 0xfc, 0xbd, 0xef, 0xf7, 0xec, 0x4f, 0x46, 0x4f, 0x3f, 0xc8, 0x9c, 0xbf, 0x15, 0x7c, + 0x48, 0x25, 0x2b, 0x07, 0xa9, 0x2e, 0x04, 0x8b,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00, 0x00, } func (m *Params) Marshal() (dAtA []byte, err error) { diff --git a/x/marketplace/types/params_legacy.go b/x/marketplace/types/params_legacy.go new file mode 100644 index 00000000..58eb90b7 --- /dev/null +++ b/x/marketplace/types/params_legacy.go @@ -0,0 +1,28 @@ +package types + +import paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" + +// Parameter keys +var ( + ParamStoreKeySaleCommission = []byte("SaleCommission") + ParamStoreKeyDistribution = []byte("MarketplaceDistribution") + ParamStoreKeyBidCloseDuration = []byte("BidCloseDuration") + ParamStoreKeyMaxAuctionDuration = []byte("MaxAuctionDuration") +) + +var _ paramtypes.ParamSet = (*Params)(nil) + +// ParamKeyTable returns the parameter key table. +func ParamKeyTable() paramtypes.KeyTable { + return paramtypes.NewKeyTable().RegisterParamSet(&Params{}) +} + +// ParamSetPairs returns the parameter set pairs. +func (p *Params) ParamSetPairs() paramtypes.ParamSetPairs { + return paramtypes.ParamSetPairs{ + paramtypes.NewParamSetPair(ParamStoreKeySaleCommission, &p.SaleCommission, validateSaleCommission), + paramtypes.NewParamSetPair(ParamStoreKeyDistribution, &p.Distribution, validateMarketplaceDistributionParams), + paramtypes.NewParamSetPair(ParamStoreKeyBidCloseDuration, &p.BidCloseDuration, validateBidCloseDuration), + paramtypes.NewParamSetPair(ParamStoreKeyMaxAuctionDuration, &p.MaxAuctionDuration, validateMaxAuctionDuration), + } +} diff --git a/x/marketplace/types/query.pb.go b/x/marketplace/types/query.pb.go index f578ed95..a9f682fe 100644 --- a/x/marketplace/types/query.pb.go +++ b/x/marketplace/types/query.pb.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: omniflix/marketplace/v1beta1/query.proto +// source: OmniFlix/marketplace/v1beta1/query.proto package types @@ -7,9 +7,9 @@ import ( context "context" fmt "fmt" query "github.com/cosmos/cosmos-sdk/types/query" - _ "github.com/gogo/protobuf/gogoproto" - grpc1 "github.com/gogo/protobuf/grpc" - proto "github.com/gogo/protobuf/proto" + _ "github.com/cosmos/gogoproto/gogoproto" + grpc1 "github.com/cosmos/gogoproto/grpc" + proto "github.com/cosmos/gogoproto/proto" _ "google.golang.org/genproto/googleapis/api/annotations" grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" @@ -38,7 +38,7 @@ func (m *QueryParamsRequest) Reset() { *m = QueryParamsRequest{} } func (m *QueryParamsRequest) String() string { return proto.CompactTextString(m) } func (*QueryParamsRequest) ProtoMessage() {} func (*QueryParamsRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_1a332bb20b3f9d15, []int{0} + return fileDescriptor_b4af30053dbf18ec, []int{0} } func (m *QueryParamsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -77,7 +77,7 @@ func (m *QueryParamsResponse) Reset() { *m = QueryParamsResponse{} } func (m *QueryParamsResponse) String() string { return proto.CompactTextString(m) } func (*QueryParamsResponse) ProtoMessage() {} func (*QueryParamsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_1a332bb20b3f9d15, []int{1} + return fileDescriptor_b4af30053dbf18ec, []int{1} } func (m *QueryParamsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -123,7 +123,7 @@ func (m *QueryListingsRequest) Reset() { *m = QueryListingsRequest{} } func (m *QueryListingsRequest) String() string { return proto.CompactTextString(m) } func (*QueryListingsRequest) ProtoMessage() {} func (*QueryListingsRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_1a332bb20b3f9d15, []int{2} + return fileDescriptor_b4af30053dbf18ec, []int{2} } func (m *QueryListingsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -182,7 +182,7 @@ func (m *QueryListingsResponse) Reset() { *m = QueryListingsResponse{} } func (m *QueryListingsResponse) String() string { return proto.CompactTextString(m) } func (*QueryListingsResponse) ProtoMessage() {} func (*QueryListingsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_1a332bb20b3f9d15, []int{3} + return fileDescriptor_b4af30053dbf18ec, []int{3} } func (m *QueryListingsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -233,7 +233,7 @@ func (m *QueryListingRequest) Reset() { *m = QueryListingRequest{} } func (m *QueryListingRequest) String() string { return proto.CompactTextString(m) } func (*QueryListingRequest) ProtoMessage() {} func (*QueryListingRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_1a332bb20b3f9d15, []int{4} + return fileDescriptor_b4af30053dbf18ec, []int{4} } func (m *QueryListingRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -277,7 +277,7 @@ func (m *QueryListingResponse) Reset() { *m = QueryListingResponse{} } func (m *QueryListingResponse) String() string { return proto.CompactTextString(m) } func (*QueryListingResponse) ProtoMessage() {} func (*QueryListingResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_1a332bb20b3f9d15, []int{5} + return fileDescriptor_b4af30053dbf18ec, []int{5} } func (m *QueryListingResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -322,7 +322,7 @@ func (m *QueryListingsByOwnerRequest) Reset() { *m = QueryListingsByOwne func (m *QueryListingsByOwnerRequest) String() string { return proto.CompactTextString(m) } func (*QueryListingsByOwnerRequest) ProtoMessage() {} func (*QueryListingsByOwnerRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_1a332bb20b3f9d15, []int{6} + return fileDescriptor_b4af30053dbf18ec, []int{6} } func (m *QueryListingsByOwnerRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -374,7 +374,7 @@ func (m *QueryListingsByOwnerResponse) Reset() { *m = QueryListingsByOwn func (m *QueryListingsByOwnerResponse) String() string { return proto.CompactTextString(m) } func (*QueryListingsByOwnerResponse) ProtoMessage() {} func (*QueryListingsByOwnerResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_1a332bb20b3f9d15, []int{7} + return fileDescriptor_b4af30053dbf18ec, []int{7} } func (m *QueryListingsByOwnerResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -425,7 +425,7 @@ func (m *QueryListingByNFTIDRequest) Reset() { *m = QueryListingByNFTIDR func (m *QueryListingByNFTIDRequest) String() string { return proto.CompactTextString(m) } func (*QueryListingByNFTIDRequest) ProtoMessage() {} func (*QueryListingByNFTIDRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_1a332bb20b3f9d15, []int{8} + return fileDescriptor_b4af30053dbf18ec, []int{8} } func (m *QueryListingByNFTIDRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -470,7 +470,7 @@ func (m *QueryListingsByPriceDenomRequest) Reset() { *m = QueryListingsB func (m *QueryListingsByPriceDenomRequest) String() string { return proto.CompactTextString(m) } func (*QueryListingsByPriceDenomRequest) ProtoMessage() {} func (*QueryListingsByPriceDenomRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_1a332bb20b3f9d15, []int{9} + return fileDescriptor_b4af30053dbf18ec, []int{9} } func (m *QueryListingsByPriceDenomRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -522,7 +522,7 @@ func (m *QueryListingsByPriceDenomResponse) Reset() { *m = QueryListings func (m *QueryListingsByPriceDenomResponse) String() string { return proto.CompactTextString(m) } func (*QueryListingsByPriceDenomResponse) ProtoMessage() {} func (*QueryListingsByPriceDenomResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_1a332bb20b3f9d15, []int{10} + return fileDescriptor_b4af30053dbf18ec, []int{10} } func (m *QueryListingsByPriceDenomResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -576,7 +576,7 @@ func (m *QueryAuctionsRequest) Reset() { *m = QueryAuctionsRequest{} } func (m *QueryAuctionsRequest) String() string { return proto.CompactTextString(m) } func (*QueryAuctionsRequest) ProtoMessage() {} func (*QueryAuctionsRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_1a332bb20b3f9d15, []int{11} + return fileDescriptor_b4af30053dbf18ec, []int{11} } func (m *QueryAuctionsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -642,7 +642,7 @@ func (m *QueryAuctionsResponse) Reset() { *m = QueryAuctionsResponse{} } func (m *QueryAuctionsResponse) String() string { return proto.CompactTextString(m) } func (*QueryAuctionsResponse) ProtoMessage() {} func (*QueryAuctionsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_1a332bb20b3f9d15, []int{12} + return fileDescriptor_b4af30053dbf18ec, []int{12} } func (m *QueryAuctionsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -693,7 +693,7 @@ func (m *QueryAuctionRequest) Reset() { *m = QueryAuctionRequest{} } func (m *QueryAuctionRequest) String() string { return proto.CompactTextString(m) } func (*QueryAuctionRequest) ProtoMessage() {} func (*QueryAuctionRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_1a332bb20b3f9d15, []int{13} + return fileDescriptor_b4af30053dbf18ec, []int{13} } func (m *QueryAuctionRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -737,7 +737,7 @@ func (m *QueryAuctionResponse) Reset() { *m = QueryAuctionResponse{} } func (m *QueryAuctionResponse) String() string { return proto.CompactTextString(m) } func (*QueryAuctionResponse) ProtoMessage() {} func (*QueryAuctionResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_1a332bb20b3f9d15, []int{14} + return fileDescriptor_b4af30053dbf18ec, []int{14} } func (m *QueryAuctionResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -782,7 +782,7 @@ func (m *QueryAuctionsByOwnerRequest) Reset() { *m = QueryAuctionsByOwne func (m *QueryAuctionsByOwnerRequest) String() string { return proto.CompactTextString(m) } func (*QueryAuctionsByOwnerRequest) ProtoMessage() {} func (*QueryAuctionsByOwnerRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_1a332bb20b3f9d15, []int{15} + return fileDescriptor_b4af30053dbf18ec, []int{15} } func (m *QueryAuctionsByOwnerRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -833,7 +833,7 @@ func (m *QueryAuctionByNFTIDRequest) Reset() { *m = QueryAuctionByNFTIDR func (m *QueryAuctionByNFTIDRequest) String() string { return proto.CompactTextString(m) } func (*QueryAuctionByNFTIDRequest) ProtoMessage() {} func (*QueryAuctionByNFTIDRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_1a332bb20b3f9d15, []int{16} + return fileDescriptor_b4af30053dbf18ec, []int{16} } func (m *QueryAuctionByNFTIDRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -878,7 +878,7 @@ func (m *QueryAuctionsByPriceDenomRequest) Reset() { *m = QueryAuctionsB func (m *QueryAuctionsByPriceDenomRequest) String() string { return proto.CompactTextString(m) } func (*QueryAuctionsByPriceDenomRequest) ProtoMessage() {} func (*QueryAuctionsByPriceDenomRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_1a332bb20b3f9d15, []int{17} + return fileDescriptor_b4af30053dbf18ec, []int{17} } func (m *QueryAuctionsByPriceDenomRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -930,7 +930,7 @@ func (m *QueryBidsRequest) Reset() { *m = QueryBidsRequest{} } func (m *QueryBidsRequest) String() string { return proto.CompactTextString(m) } func (*QueryBidsRequest) ProtoMessage() {} func (*QueryBidsRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_1a332bb20b3f9d15, []int{18} + return fileDescriptor_b4af30053dbf18ec, []int{18} } func (m *QueryBidsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -982,7 +982,7 @@ func (m *QueryBidsResponse) Reset() { *m = QueryBidsResponse{} } func (m *QueryBidsResponse) String() string { return proto.CompactTextString(m) } func (*QueryBidsResponse) ProtoMessage() {} func (*QueryBidsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_1a332bb20b3f9d15, []int{19} + return fileDescriptor_b4af30053dbf18ec, []int{19} } func (m *QueryBidsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -1033,7 +1033,7 @@ func (m *QueryBidRequest) Reset() { *m = QueryBidRequest{} } func (m *QueryBidRequest) String() string { return proto.CompactTextString(m) } func (*QueryBidRequest) ProtoMessage() {} func (*QueryBidRequest) Descriptor() ([]byte, []int) { - return fileDescriptor_1a332bb20b3f9d15, []int{20} + return fileDescriptor_b4af30053dbf18ec, []int{20} } func (m *QueryBidRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -1077,7 +1077,7 @@ func (m *QueryBidResponse) Reset() { *m = QueryBidResponse{} } func (m *QueryBidResponse) String() string { return proto.CompactTextString(m) } func (*QueryBidResponse) ProtoMessage() {} func (*QueryBidResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_1a332bb20b3f9d15, []int{21} + return fileDescriptor_b4af30053dbf18ec, []int{21} } func (m *QueryBidResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -1139,83 +1139,83 @@ func init() { } func init() { - proto.RegisterFile("omniflix/marketplace/v1beta1/query.proto", fileDescriptor_1a332bb20b3f9d15) + proto.RegisterFile("OmniFlix/marketplace/v1beta1/query.proto", fileDescriptor_b4af30053dbf18ec) } -var fileDescriptor_1a332bb20b3f9d15 = []byte{ - // 1140 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xcc, 0x98, 0x51, 0x6f, 0xdb, 0x54, +var fileDescriptor_b4af30053dbf18ec = []byte{ + // 1143 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xcc, 0x98, 0xdf, 0x6f, 0xdb, 0x54, 0x14, 0xc7, 0x7b, 0x93, 0x34, 0x2d, 0xa7, 0xa2, 0x65, 0x97, 0x6c, 0xaa, 0x42, 0x95, 0xae, 0x56, - 0xd7, 0x65, 0xdd, 0x62, 0xd3, 0x44, 0xa8, 0x6c, 0x08, 0x2a, 0xbc, 0x91, 0x6a, 0x02, 0xb6, 0x61, - 0x90, 0x10, 0x3c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 0xfe, 0x17, 0x00, 0x00, 0xff, 0xff, 0x00, + 0x3c, 0x81, 0x07, 0x03, 0x15, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -1731,7 +1731,7 @@ var _Query_serviceDesc = grpc.ServiceDesc{ }, }, Streams: []grpc.StreamDesc{}, - Metadata: "omniflix/marketplace/v1beta1/query.proto", + Metadata: "OmniFlix/marketplace/v1beta1/query.proto", } func (m *QueryParamsRequest) Marshal() (dAtA []byte, err error) { diff --git a/x/marketplace/types/query.pb.gw.go b/x/marketplace/types/query.pb.gw.go index 98c7c1ad..88558264 100644 --- a/x/marketplace/types/query.pb.gw.go +++ b/x/marketplace/types/query.pb.gw.go @@ -1,5 +1,5 @@ // Code generated by protoc-gen-grpc-gateway. DO NOT EDIT. -// source: omniflix/marketplace/v1beta1/query.proto +// source: OmniFlix/marketplace/v1beta1/query.proto /* Package types is a reverse proxy. @@ -1327,31 +1327,31 @@ func RegisterQueryHandlerClient(ctx context.Context, mux *runtime.ServeMux, clie } var ( - pattern_Query_Params_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"omniflix", "marketplace", "v1beta1", "params"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_Params_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"omniflix", "marketplace", "v1beta1", "params"}, "", runtime.AssumeColonVerbOpt(false))) - pattern_Query_Listings_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"omniflix", "marketplace", "v1beta1", "listings"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_Listings_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"omniflix", "marketplace", "v1beta1", "listings"}, "", runtime.AssumeColonVerbOpt(false))) - pattern_Query_Listing_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4}, []string{"omniflix", "marketplace", "v1beta1", "listings", "id"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_Listing_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4}, []string{"omniflix", "marketplace", "v1beta1", "listings", "id"}, "", runtime.AssumeColonVerbOpt(false))) - pattern_Query_ListingsByOwner_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4}, []string{"omniflix", "marketplace", "v1beta1", "listings-by-owner", "owner"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_ListingsByOwner_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4}, []string{"omniflix", "marketplace", "v1beta1", "listings-by-owner", "owner"}, "", runtime.AssumeColonVerbOpt(false))) - pattern_Query_ListingsByPriceDenom_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4}, []string{"omniflix", "marketplace", "v1beta1", "listings-by-price-denom", "price_denom"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_ListingsByPriceDenom_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4}, []string{"omniflix", "marketplace", "v1beta1", "listings-by-price-denom", "price_denom"}, "", runtime.AssumeColonVerbOpt(false))) - pattern_Query_ListingByNftId_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4}, []string{"omniflix", "marketplace", "v1beta1", "listing-by-nft", "nft_id"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_ListingByNftId_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4}, []string{"omniflix", "marketplace", "v1beta1", "listing-by-nft", "nft_id"}, "", runtime.AssumeColonVerbOpt(false))) - pattern_Query_Auctions_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"omniflix", "marketplace", "v1beta1", "auctions"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_Auctions_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"omniflix", "marketplace", "v1beta1", "auctions"}, "", runtime.AssumeColonVerbOpt(false))) - pattern_Query_Auction_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4}, []string{"omniflix", "marketplace", "v1beta1", "auctions", "id"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_Auction_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4}, []string{"omniflix", "marketplace", "v1beta1", "auctions", "id"}, "", runtime.AssumeColonVerbOpt(false))) - pattern_Query_AuctionsByOwner_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4}, []string{"omniflix", "marketplace", "v1beta1", "auctions-by-owner", "owner"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_AuctionsByOwner_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4}, []string{"omniflix", "marketplace", "v1beta1", "auctions-by-owner", "owner"}, "", runtime.AssumeColonVerbOpt(false))) - pattern_Query_AuctionsByPriceDenom_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4}, []string{"omniflix", "marketplace", "v1beta1", "auctions-by-price-denom", "price_denom"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_AuctionsByPriceDenom_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4}, []string{"omniflix", "marketplace", "v1beta1", "auctions-by-price-denom", "price_denom"}, "", runtime.AssumeColonVerbOpt(false))) - pattern_Query_AuctionByNftId_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4}, []string{"omniflix", "marketplace", "v1beta1", "auction-by-nft", "nft_id"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_AuctionByNftId_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4}, []string{"omniflix", "marketplace", "v1beta1", "auction-by-nft", "nft_id"}, "", runtime.AssumeColonVerbOpt(false))) - pattern_Query_Bids_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"omniflix", "marketplace", "v1beta1", "bids"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_Bids_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"omniflix", "marketplace", "v1beta1", "bids"}, "", runtime.AssumeColonVerbOpt(false))) - pattern_Query_Bid_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4}, []string{"omniflix", "marketplace", "v1beta1", "bids", "id"}, "", runtime.AssumeColonVerbOpt(true))) + pattern_Query_Bid_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4}, []string{"omniflix", "marketplace", "v1beta1", "bids", "id"}, "", runtime.AssumeColonVerbOpt(false))) ) var ( diff --git a/x/marketplace/types/tx.pb.go b/x/marketplace/types/tx.pb.go index c5dfab6e..fde23d8c 100644 --- a/x/marketplace/types/tx.pb.go +++ b/x/marketplace/types/tx.pb.go @@ -1,17 +1,19 @@ // Code generated by protoc-gen-gogo. DO NOT EDIT. -// source: omniflix/marketplace/v1beta1/tx.proto +// source: OmniFlix/marketplace/v1beta1/tx.proto package types import ( context "context" fmt "fmt" + _ "github.com/cosmos/cosmos-proto" github_com_cosmos_cosmos_sdk_types "github.com/cosmos/cosmos-sdk/types" types "github.com/cosmos/cosmos-sdk/types" - _ "github.com/gogo/protobuf/gogoproto" - grpc1 "github.com/gogo/protobuf/grpc" - proto "github.com/gogo/protobuf/proto" - github_com_gogo_protobuf_types "github.com/gogo/protobuf/types" + _ "github.com/cosmos/cosmos-sdk/types/msgservice" + _ "github.com/cosmos/gogoproto/gogoproto" + grpc1 "github.com/cosmos/gogoproto/grpc" + proto "github.com/cosmos/gogoproto/proto" + github_com_gogo_protobuf_types "github.com/cosmos/gogoproto/types" grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" @@ -48,7 +50,7 @@ func (m *MsgListNFT) Reset() { *m = MsgListNFT{} } func (m *MsgListNFT) String() string { return proto.CompactTextString(m) } func (*MsgListNFT) ProtoMessage() {} func (*MsgListNFT) Descriptor() ([]byte, []int) { - return fileDescriptor_9ef324d37a95f547, []int{0} + return fileDescriptor_a8128523fd16ea70, []int{0} } func (m *MsgListNFT) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -84,7 +86,7 @@ func (m *MsgListNFTResponse) Reset() { *m = MsgListNFTResponse{} } func (m *MsgListNFTResponse) String() string { return proto.CompactTextString(m) } func (*MsgListNFTResponse) ProtoMessage() {} func (*MsgListNFTResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_9ef324d37a95f547, []int{1} + return fileDescriptor_a8128523fd16ea70, []int{1} } func (m *MsgListNFTResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -123,7 +125,7 @@ func (m *MsgEditListing) Reset() { *m = MsgEditListing{} } func (m *MsgEditListing) String() string { return proto.CompactTextString(m) } func (*MsgEditListing) ProtoMessage() {} func (*MsgEditListing) Descriptor() ([]byte, []int) { - return fileDescriptor_9ef324d37a95f547, []int{2} + return fileDescriptor_a8128523fd16ea70, []int{2} } func (m *MsgEditListing) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -159,7 +161,7 @@ func (m *MsgEditListingResponse) Reset() { *m = MsgEditListingResponse{} func (m *MsgEditListingResponse) String() string { return proto.CompactTextString(m) } func (*MsgEditListingResponse) ProtoMessage() {} func (*MsgEditListingResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_9ef324d37a95f547, []int{3} + return fileDescriptor_a8128523fd16ea70, []int{3} } func (m *MsgEditListingResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -197,7 +199,7 @@ func (m *MsgDeListNFT) Reset() { *m = MsgDeListNFT{} } func (m *MsgDeListNFT) String() string { return proto.CompactTextString(m) } func (*MsgDeListNFT) ProtoMessage() {} func (*MsgDeListNFT) Descriptor() ([]byte, []int) { - return fileDescriptor_9ef324d37a95f547, []int{4} + return fileDescriptor_a8128523fd16ea70, []int{4} } func (m *MsgDeListNFT) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -233,7 +235,7 @@ func (m *MsgDeListNFTResponse) Reset() { *m = MsgDeListNFTResponse{} } func (m *MsgDeListNFTResponse) String() string { return proto.CompactTextString(m) } func (*MsgDeListNFTResponse) ProtoMessage() {} func (*MsgDeListNFTResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_9ef324d37a95f547, []int{5} + return fileDescriptor_a8128523fd16ea70, []int{5} } func (m *MsgDeListNFTResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -272,7 +274,7 @@ func (m *MsgBuyNFT) Reset() { *m = MsgBuyNFT{} } func (m *MsgBuyNFT) String() string { return proto.CompactTextString(m) } func (*MsgBuyNFT) ProtoMessage() {} func (*MsgBuyNFT) Descriptor() ([]byte, []int) { - return fileDescriptor_9ef324d37a95f547, []int{6} + return fileDescriptor_a8128523fd16ea70, []int{6} } func (m *MsgBuyNFT) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -308,7 +310,7 @@ func (m *MsgBuyNFTResponse) Reset() { *m = MsgBuyNFTResponse{} } func (m *MsgBuyNFTResponse) String() string { return proto.CompactTextString(m) } func (*MsgBuyNFTResponse) ProtoMessage() {} func (*MsgBuyNFTResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_9ef324d37a95f547, []int{7} + return fileDescriptor_a8128523fd16ea70, []int{7} } func (m *MsgBuyNFTResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -353,7 +355,7 @@ func (m *MsgCreateAuction) Reset() { *m = MsgCreateAuction{} } func (m *MsgCreateAuction) String() string { return proto.CompactTextString(m) } func (*MsgCreateAuction) ProtoMessage() {} func (*MsgCreateAuction) Descriptor() ([]byte, []int) { - return fileDescriptor_9ef324d37a95f547, []int{8} + return fileDescriptor_a8128523fd16ea70, []int{8} } func (m *MsgCreateAuction) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -390,7 +392,7 @@ func (m *MsgCreateAuctionResponse) Reset() { *m = MsgCreateAuctionRespon func (m *MsgCreateAuctionResponse) String() string { return proto.CompactTextString(m) } func (*MsgCreateAuctionResponse) ProtoMessage() {} func (*MsgCreateAuctionResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_9ef324d37a95f547, []int{9} + return fileDescriptor_a8128523fd16ea70, []int{9} } func (m *MsgCreateAuctionResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -428,7 +430,7 @@ func (m *MsgCancelAuction) Reset() { *m = MsgCancelAuction{} } func (m *MsgCancelAuction) String() string { return proto.CompactTextString(m) } func (*MsgCancelAuction) ProtoMessage() {} func (*MsgCancelAuction) Descriptor() ([]byte, []int) { - return fileDescriptor_9ef324d37a95f547, []int{10} + return fileDescriptor_a8128523fd16ea70, []int{10} } func (m *MsgCancelAuction) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -464,7 +466,7 @@ func (m *MsgCancelAuctionResponse) Reset() { *m = MsgCancelAuctionRespon func (m *MsgCancelAuctionResponse) String() string { return proto.CompactTextString(m) } func (*MsgCancelAuctionResponse) ProtoMessage() {} func (*MsgCancelAuctionResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_9ef324d37a95f547, []int{11} + return fileDescriptor_a8128523fd16ea70, []int{11} } func (m *MsgCancelAuctionResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -503,7 +505,7 @@ func (m *MsgPlaceBid) Reset() { *m = MsgPlaceBid{} } func (m *MsgPlaceBid) String() string { return proto.CompactTextString(m) } func (*MsgPlaceBid) ProtoMessage() {} func (*MsgPlaceBid) Descriptor() ([]byte, []int) { - return fileDescriptor_9ef324d37a95f547, []int{12} + return fileDescriptor_a8128523fd16ea70, []int{12} } func (m *MsgPlaceBid) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -539,7 +541,7 @@ func (m *MsgPlaceBidResponse) Reset() { *m = MsgPlaceBidResponse{} } func (m *MsgPlaceBidResponse) String() string { return proto.CompactTextString(m) } func (*MsgPlaceBidResponse) ProtoMessage() {} func (*MsgPlaceBidResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_9ef324d37a95f547, []int{13} + return fileDescriptor_a8128523fd16ea70, []int{13} } func (m *MsgPlaceBidResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -568,6 +570,91 @@ func (m *MsgPlaceBidResponse) XXX_DiscardUnknown() { var xxx_messageInfo_MsgPlaceBidResponse proto.InternalMessageInfo +// MsgUpdateParams is the Msg/UpdateParams request type. +// +// Since: cosmos-sdk 0.47 +type MsgUpdateParams struct { + // authority is the address of the governance account. + Authority string `protobuf:"bytes,1,opt,name=authority,proto3" json:"authority,omitempty"` + // params defines the x/marketplace parameters to update. + // + // NOTE: All parameters must be supplied. + Params Params `protobuf:"bytes,2,opt,name=params,proto3" json:"params"` +} + +func (m *MsgUpdateParams) Reset() { *m = MsgUpdateParams{} } +func (m *MsgUpdateParams) String() string { return proto.CompactTextString(m) } +func (*MsgUpdateParams) ProtoMessage() {} +func (*MsgUpdateParams) Descriptor() ([]byte, []int) { + return fileDescriptor_a8128523fd16ea70, []int{14} +} +func (m *MsgUpdateParams) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *MsgUpdateParams) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_MsgUpdateParams.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 *MsgUpdateParams) XXX_Merge(src proto.Message) { + xxx_messageInfo_MsgUpdateParams.Merge(m, src) +} +func (m *MsgUpdateParams) XXX_Size() int { + return m.Size() +} +func (m *MsgUpdateParams) XXX_DiscardUnknown() { + xxx_messageInfo_MsgUpdateParams.DiscardUnknown(m) +} + +var xxx_messageInfo_MsgUpdateParams proto.InternalMessageInfo + +// MsgUpdateParamsResponse defines the response structure for executing a +// MsgUpdateParams message. +// +// Since: cosmos-sdk 0.47 +type MsgUpdateParamsResponse struct { +} + +func (m *MsgUpdateParamsResponse) Reset() { *m = MsgUpdateParamsResponse{} } +func (m *MsgUpdateParamsResponse) String() string { return proto.CompactTextString(m) } +func (*MsgUpdateParamsResponse) ProtoMessage() {} +func (*MsgUpdateParamsResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_a8128523fd16ea70, []int{15} +} +func (m *MsgUpdateParamsResponse) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *MsgUpdateParamsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_MsgUpdateParamsResponse.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 *MsgUpdateParamsResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_MsgUpdateParamsResponse.Merge(m, src) +} +func (m *MsgUpdateParamsResponse) XXX_Size() int { + return m.Size() +} +func (m *MsgUpdateParamsResponse) XXX_DiscardUnknown() { + xxx_messageInfo_MsgUpdateParamsResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_MsgUpdateParamsResponse proto.InternalMessageInfo + func init() { proto.RegisterType((*MsgListNFT)(nil), "OmniFlix.marketplace.v1beta1.MsgListNFT") proto.RegisterType((*MsgListNFTResponse)(nil), "OmniFlix.marketplace.v1beta1.MsgListNFTResponse") @@ -583,76 +670,86 @@ func init() { proto.RegisterType((*MsgCancelAuctionResponse)(nil), "OmniFlix.marketplace.v1beta1.MsgCancelAuctionResponse") proto.RegisterType((*MsgPlaceBid)(nil), "OmniFlix.marketplace.v1beta1.MsgPlaceBid") proto.RegisterType((*MsgPlaceBidResponse)(nil), "OmniFlix.marketplace.v1beta1.MsgPlaceBidResponse") + proto.RegisterType((*MsgUpdateParams)(nil), "OmniFlix.marketplace.v1beta1.MsgUpdateParams") + proto.RegisterType((*MsgUpdateParamsResponse)(nil), "OmniFlix.marketplace.v1beta1.MsgUpdateParamsResponse") } func init() { - proto.RegisterFile("omniflix/marketplace/v1beta1/tx.proto", fileDescriptor_9ef324d37a95f547) -} - -var fileDescriptor_9ef324d37a95f547 = []byte{ - // 980 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xbc, 0x56, 0x4d, 0x6f, 0xe3, 0x44, - 0x18, 0x8e, 0x93, 0x26, 0x6d, 0xde, 0x2c, 0x2b, 0xea, 0xa6, 0x95, 0xeb, 0x05, 0xa7, 0x58, 0x82, - 0x0d, 0xab, 0x5d, 0x9b, 0x66, 0x2b, 0x0e, 0x70, 0xaa, 0xb7, 0x5b, 0xa9, 0xd2, 0x06, 0x4a, 0x58, - 0x09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 0x94, 0xb1, 0xa7, 0x48, 0x6b, 0x52, 0xbb, 0xde, 0x2b, - 0x63, 0x4f, 0x5e, 0x86, 0x5a, 0xb8, 0x47, 0xfb, 0xd8, 0x53, 0xca, 0x6c, 0xaf, 0x1a, 0xee, 0xd1, - 0x1d, 0x4f, 0x5e, 0x85, 0x05, 0x0f, 0x85, 0x51, 0x90, 0x1c, 0x54, 0xd8, 0xc1, 0x3c, 0x5b, 0xef, - 0x78, 0xf2, 0x77, 0x50, 0x1d, 0xc5, 0xd8, 0x45, 0xca, 0xdc, 0x9a, 0xd4, 0x6e, 0x74, 0x56, 0x0d, - 0x5e, 0x2f, 0x23, 0xa9, 0x57, 0x56, 0x44, 0xe3, 0x49, 0x84, 0x43, 0xcb, 0x3c, 0x3e, 0x69, 0x95, - 0x7e, 0x7d, 0xdd, 0xba, 0xef, 0x63, 0x3a, 0x18, 0x3b, 0x86, 0x1b, 0x05, 0x66, 0x5a, 0x5c, 0xfe, - 0xf3, 0x88, 0x78, 0xfb, 0x26, 0x3d, 0x1a, 0x21, 0xc2, 0x0c, 0x7a, 0x9c, 0x58, 0x6e, 0x42, 0x35, - 0x3a, 0x08, 0x51, 0xac, 0x54, 0x79, 0x48, 0x6c, 0x21, 0x07, 0x70, 0x87, 0x8c, 0x86, 0x98, 0xf6, - 0xc9, 0xc0, 0x8e, 0x11, 0x51, 0x6a, 0x6b, 0x95, 0x76, 0xa3, 0xf3, 0xc8, 0xb8, 0xee, 0x32, 0x8d, - 0xaf, 0x10, 0xf6, 0x07, 0x14, 0x79, 0x9b, 0x9e, 0x17, 0x23, 0x42, 0xac, 0x7b, 0x49, 0x48, 0x6f, - 0x4e, 0x5a, 0x4b, 0x47, 0x76, 0x30, 0xfc, 0x44, 0xcf, 0x13, 0xea, 0xbd, 0x06, 0x5b, 0x7e, 0xc9, - 0x57, 0x4d, 0x90, 0x27, 0x65, 0xeb, 0x21, 0x32, 0x8a, 0x42, 0x82, 0xf4, 0x97, 0x12, 0xdc, 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 0x5f, 0xce, 0x4c, - 0x9d, 0x4e, 0x8d, 0xbd, 0x4b, 0x8f, 0xff, 0x0d, 0x00, 0x00, 0xff, 0xff, 0x23, 0x14, 0x66, 0xc5, - 0xef, 0x0b, 0x00, 0x00, + proto.RegisterFile("OmniFlix/marketplace/v1beta1/tx.proto", fileDescriptor_a8128523fd16ea70) +} + +var fileDescriptor_a8128523fd16ea70 = []byte{ + // 1111 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xbc, 0x57, 0x4b, 0x53, 0x23, 0xd5, + 0x17, 0xa7, 0x03, 0x04, 0x72, 0xc2, 0x9f, 0xbf, 0x34, 0x81, 0x09, 0x3d, 0x9a, 0x60, 0x97, 0x3a, + 0x0c, 0x35, 0x74, 0x4b, 0x44, 0x16, 0xe3, 0x8a, 0x1e, 0x86, 0x2a, 0xaa, 0x26, 0x4a, 0x65, 0xb0, + 0xb4, 0x5c, 0x18, 0xfb, 0x71, 0xe9, 0xdc, 0x22, 0xdd, 0x1d, 0xfb, 0xde, 0xf0, 0xd8, 0xe9, 0x7c, + 0x82, 0xa9, 0x72, 0x33, 0x1b, 0xbf, 0x80, 0x2b, 0x17, 0xba, 0x70, 0xe5, 0x96, 0xe5, 0x94, 0x2b, + 0xcb, 0x05, 0xa3, 0xb0, 0x70, 0x3f, 0x9f, 0xc0, 0xea, 0xbe, 0xb7, 0x6f, 0x77, 0x78, 0x24, 0xc1, + 0x2a, 0x5c, 0x85, 0x73, 0xcf, 0xef, 0xfc, 0xce, 0xe3, 0x9e, 0x73, 0x2e, 0x0d, 0xef, 0x7e, 0xe2, + 0xf9, 0x78, 0xab, 0x8d, 0x8f, 0x74, 0xcf, 0x0c, 0xf7, 0x11, 0xed, 0xb4, 0x4d, 0x1b, 0xe9, 0x07, + 0xab, 0x16, 0xa2, 0xe6, 0xaa, 0x4e, 0x8f, 0xb4, 0x4e, 0x18, 0xd0, 0x40, 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e7, 0x59, 0x45, 0x7a, 0x7e, + 0x5e, 0x19, 0x79, 0x79, 0x5e, 0x19, 0xf9, 0xfd, 0xbc, 0x32, 0xf2, 0xc5, 0x7a, 0x66, 0x7b, 0x89, + 0x6f, 0x8b, 0xc0, 0xf3, 0xf1, 0x5e, 0x1b, 0x1f, 0xb5, 0xba, 0x96, 0x7e, 0x50, 0xd3, 0x7b, 0x3f, + 0x36, 0xe2, 0x8d, 0x66, 0xe5, 0xe3, 0xb7, 0xfc, 0x83, 0x7f, 0x02, 0x00, 0x00, 0xff, 0xff, 0xb4, + 0xb5, 0x4a, 0x84, 0x82, 0x0d, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -674,6 +771,11 @@ type MsgClient interface { CreateAuction(ctx context.Context, in *MsgCreateAuction, opts ...grpc.CallOption) (*MsgCreateAuctionResponse, error) CancelAuction(ctx context.Context, in *MsgCancelAuction, opts ...grpc.CallOption) (*MsgCancelAuctionResponse, error) PlaceBid(ctx context.Context, in *MsgPlaceBid, opts ...grpc.CallOption) (*MsgPlaceBidResponse, error) + // UpdateParams defines a governance operation for updating the x/marketplace module + // parameters. The authority is hard-coded to the x/marketplace module account. + // + // Since: cosmos-sdk 0.47 + UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) } type msgClient struct { @@ -747,6 +849,15 @@ func (c *msgClient) PlaceBid(ctx context.Context, in *MsgPlaceBid, opts ...grpc. return out, nil } +func (c *msgClient) UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) { + out := new(MsgUpdateParamsResponse) + err := c.cc.Invoke(ctx, "/OmniFlix.marketplace.v1beta1.Msg/UpdateParams", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + // MsgServer is the server API for Msg service. type MsgServer interface { ListNFT(context.Context, *MsgListNFT) (*MsgListNFTResponse, error) @@ -756,6 +867,11 @@ type MsgServer interface { CreateAuction(context.Context, *MsgCreateAuction) (*MsgCreateAuctionResponse, error) CancelAuction(context.Context, *MsgCancelAuction) (*MsgCancelAuctionResponse, error) PlaceBid(context.Context, *MsgPlaceBid) (*MsgPlaceBidResponse, error) + // UpdateParams defines a governance operation for updating the x/marketplace module + // parameters. The authority is hard-coded to the x/marketplace module account. + // + // Since: cosmos-sdk 0.47 + UpdateParams(context.Context, *MsgUpdateParams) (*MsgUpdateParamsResponse, error) } // UnimplementedMsgServer can be embedded to have forward compatible implementations. @@ -783,6 +899,9 @@ func (*UnimplementedMsgServer) CancelAuction(ctx context.Context, req *MsgCancel func (*UnimplementedMsgServer) PlaceBid(ctx context.Context, req *MsgPlaceBid) (*MsgPlaceBidResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method PlaceBid not implemented") } +func (*UnimplementedMsgServer) UpdateParams(ctx context.Context, req *MsgUpdateParams) (*MsgUpdateParamsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method UpdateParams not implemented") +} func RegisterMsgServer(s grpc1.Server, srv MsgServer) { s.RegisterService(&_Msg_serviceDesc, srv) @@ -914,6 +1033,24 @@ func _Msg_PlaceBid_Handler(srv interface{}, ctx context.Context, dec func(interf return interceptor(ctx, in, info, handler) } +func _Msg_UpdateParams_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(MsgUpdateParams) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(MsgServer).UpdateParams(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/OmniFlix.marketplace.v1beta1.Msg/UpdateParams", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(MsgServer).UpdateParams(ctx, req.(*MsgUpdateParams)) + } + return interceptor(ctx, in, info, handler) +} + var _Msg_serviceDesc = grpc.ServiceDesc{ ServiceName: "OmniFlix.marketplace.v1beta1.Msg", HandlerType: (*MsgServer)(nil), @@ -946,9 +1083,13 @@ var _Msg_serviceDesc = grpc.ServiceDesc{ MethodName: "PlaceBid", Handler: _Msg_PlaceBid_Handler, }, + { + MethodName: "UpdateParams", + Handler: _Msg_UpdateParams_Handler, + }, }, Streams: []grpc.StreamDesc{}, - Metadata: "omniflix/marketplace/v1beta1/tx.proto", + Metadata: "OmniFlix/marketplace/v1beta1/tx.proto", } func (m *MsgListNFT) Marshal() (dAtA []byte, err error) { @@ -1515,6 +1656,69 @@ func (m *MsgPlaceBidResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { return len(dAtA) - i, nil } +func (m *MsgUpdateParams) 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 *MsgUpdateParams) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *MsgUpdateParams) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + { + size, err := m.Params.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintTx(dAtA, i, uint64(size)) + } + 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 *MsgUpdateParamsResponse) 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 *MsgUpdateParamsResponse) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *MsgUpdateParamsResponse) 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 @@ -1758,6 +1962,30 @@ func (m *MsgPlaceBidResponse) Size() (n int) { return n } +func (m *MsgUpdateParams) 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 = m.Params.Size() + n += 1 + l + sovTx(uint64(l)) + return n +} + +func (m *MsgUpdateParamsResponse) 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 } @@ -3386,6 +3614,171 @@ func (m *MsgPlaceBidResponse) Unmarshal(dAtA []byte) error { } return nil } +func (m *MsgUpdateParams) 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: MsgUpdateParams: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: MsgUpdateParams: 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 Params", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTx + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthTx + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthTx + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Params.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 *MsgUpdateParamsResponse) 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: MsgUpdateParamsResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: MsgUpdateParamsResponse: 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 skipTx(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 diff --git a/x/marketplace/types/validation.go b/x/marketplace/types/validation.go index 86aaa7a8..c01b2229 100644 --- a/x/marketplace/types/validation.go +++ b/x/marketplace/types/validation.go @@ -4,6 +4,8 @@ import ( "strings" "time" + errorsmod "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" ) @@ -12,7 +14,7 @@ import ( func ValidateListing(listing Listing) error { if len(listing.Owner) > 0 { if _, err := sdk.AccAddressFromBech32(listing.Owner); err != nil { - return sdkerrors.Wrapf(sdkerrors.ErrInvalidAddress, "invalid owner address (%s)", err) + return errorsmod.Wrapf(sdkerrors.ErrInvalidAddress, "invalid owner address (%s)", err) } } if err := ValidateId(listing.Id); err != nil { @@ -30,7 +32,7 @@ func ValidateListing(listing Listing) error { // ValidatePrice func ValidatePrice(price sdk.Coin) error { if price.IsZero() || price.IsNegative() { - return sdkerrors.Wrapf(ErrInvalidPrice, "invalid price %s, only accepts positive amount", price.String()) + return errorsmod.Wrapf(ErrInvalidPrice, "invalid price %s, only accepts positive amount", price.String()) } return nil } @@ -38,10 +40,10 @@ func ValidatePrice(price sdk.Coin) error { func ValidateDuration(t interface{}) error { duration, ok := t.(*time.Duration) if !ok { - return sdkerrors.Wrapf(ErrInvalidDuration, "invalid value for duration: %T", t) + return errorsmod.Wrapf(ErrInvalidDuration, "invalid value for duration: %T", t) } if duration.Nanoseconds() <= 0 { - return sdkerrors.Wrapf(ErrInvalidDuration, "invalid duration %s, only accepts positive value", duration.String()) + return errorsmod.Wrapf(ErrInvalidDuration, "invalid duration %s, only accepts positive value", duration.String()) } return nil } @@ -49,20 +51,20 @@ func ValidateDuration(t interface{}) error { func ValidateId(id string) error { id = strings.TrimSpace(id) if len(id) < MinListingIdLength || len(id) > MaxListingIdLength { - return sdkerrors.Wrapf( + return errorsmod.Wrapf( ErrInvalidListingId, "invalid id %s, only accepts value [%d, %d]", id, MinListingIdLength, MaxListingIdLength, ) } if !IsBeginWithAlpha(id) || !IsAlphaNumeric(id) { - return sdkerrors.Wrapf(ErrInvalidListingId, "invalid id %s, only accepts alphanumeric characters,and begin with an english letter", id) + return errorsmod.Wrapf(ErrInvalidListingId, "invalid id %s, only accepts alphanumeric characters,and begin with an english letter", id) } return nil } func ValidateSplitShares(splitShares []WeightedAddress) error { if len(splitShares) > MaxSplits { - return sdkerrors.Wrapf(ErrInvalidSplits, "number of splits are more than the limit, len must be less than or equal to %d ", MaxSplits) + return errorsmod.Wrapf(ErrInvalidSplits, "number of splits are more than the limit, len must be less than or equal to %d ", MaxSplits) } totalWeight := sdk.NewDec(0) for _, share := range splitShares { @@ -73,14 +75,14 @@ func ValidateSplitShares(splitShares []WeightedAddress) error { totalWeight = totalWeight.Add(share.Weight) } if !totalWeight.LTE(sdk.OneDec()) { - return sdkerrors.Wrapf(ErrInvalidSplits, "invalid weights, total sum of weights must be less than %d", 1) + return errorsmod.Wrapf(ErrInvalidSplits, "invalid weights, total sum of weights must be less than %d", 1) } return nil } func ValidateWhiteListAccounts(whitelistAccounts []string) error { if len(whitelistAccounts) > MaxWhitelistAccounts { - return sdkerrors.Wrapf(ErrInvalidWhitelistAccounts, + return errorsmod.Wrapf(ErrInvalidWhitelistAccounts, "number of whitelist accounts are more than the limit, len must be less than or equal to %d ", MaxWhitelistAccounts) } for _, address := range whitelistAccounts { @@ -94,14 +96,14 @@ func ValidateWhiteListAccounts(whitelistAccounts []string) error { func validateIncrementPercentage(increment sdk.Dec) error { if !increment.IsPositive() || !increment.LTE(sdk.NewDec(1)) { - return sdkerrors.Wrapf(ErrInvalidPercentage, "invalid percentage value (%s)", increment.String()) + return errorsmod.Wrapf(ErrInvalidPercentage, "invalid percentage value (%s)", increment.String()) } return nil } func validateAuctionId(id uint64) error { if id <= 0 { - return sdkerrors.Wrapf(ErrInvalidAuctionId, "invalid auction id (%d)", id) + return errorsmod.Wrapf(ErrInvalidAuctionId, "invalid auction id (%d)", id) } return nil } @@ -110,7 +112,7 @@ func validateAuctionId(id uint64) error { func ValidateAuctionListing(auction AuctionListing) error { if len(auction.Owner) > 0 { if _, err := sdk.AccAddressFromBech32(auction.Owner); err != nil { - return sdkerrors.Wrapf(sdkerrors.ErrInvalidAddress, "invalid owner address (%s)", err) + return errorsmod.Wrapf(sdkerrors.ErrInvalidAddress, "invalid owner address (%s)", err) } } if err := validateAuctionId(auction.Id); err != nil { @@ -135,14 +137,14 @@ func ValidateAuctionListing(auction AuctionListing) error { func ValidateBid(bid Bid) error { if len(bid.Bidder) > 0 { if _, err := sdk.AccAddressFromBech32(bid.Bidder); err != nil { - return sdkerrors.Wrapf(sdkerrors.ErrInvalidAddress, "invalid bidder address (%s)", bid.Bidder) + return errorsmod.Wrapf(sdkerrors.ErrInvalidAddress, "invalid bidder address (%s)", bid.Bidder) } } if err := ValidatePrice(bid.Amount); err != nil { return err } if bid.Time.IsZero() { - return sdkerrors.Wrapf(ErrInvalidTime, "invalid time (%s)", bid.Time.String()) + return errorsmod.Wrapf(ErrInvalidTime, "invalid time (%s)", bid.Time.String()) } return nil }