diff --git a/go.mod b/go.mod index 818c2432..743a419e 100644 --- a/go.mod +++ b/go.mod @@ -13,14 +13,11 @@ require ( cosmossdk.io/simapp v0.0.0-20231211060251-d8fb76d4c267 cosmossdk.io/store v1.0.1 cosmossdk.io/x/tx v0.12.0 - cosmossdk.io/x/upgrade v0.1.1 github.com/cometbft/cometbft v0.38.2 github.com/cosmos/cosmos-db v1.0.0 github.com/cosmos/cosmos-proto v1.0.0-beta.3 github.com/cosmos/cosmos-sdk v0.50.2 github.com/cosmos/gogoproto v1.4.11 - github.com/cosmos/ibc-go/modules/capability v1.0.0 - github.com/cosmos/ibc-go/v8 v8.0.0 github.com/golang/protobuf v1.5.3 github.com/grpc-ecosystem/grpc-gateway v1.16.0 github.com/spf13/cobra v1.7.0 @@ -47,6 +44,7 @@ require ( cosmossdk.io/x/evidence v0.1.0 // indirect cosmossdk.io/x/feegrant v0.1.0 // indirect cosmossdk.io/x/nft v0.1.0 // indirect + cosmossdk.io/x/upgrade v0.1.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 @@ -118,6 +116,7 @@ require ( github.com/hashicorp/go-metrics v0.5.2 // indirect github.com/hashicorp/go-plugin v1.5.2 // indirect github.com/hashicorp/go-safetemp v1.0.0 // indirect + github.com/hashicorp/go-uuid v1.0.2 // indirect github.com/hashicorp/go-version v1.6.0 // indirect github.com/hashicorp/golang-lru v1.0.2 // indirect github.com/hashicorp/hcl v1.0.0 // indirect @@ -147,6 +146,7 @@ require ( github.com/mtibben/percent v0.2.1 // indirect github.com/oasisprotocol/curve25519-voi v0.0.0-20230904125328-1f23a7beb09a // indirect github.com/oklog/run v1.1.0 // indirect + github.com/onsi/ginkgo v1.16.4 // indirect github.com/pelletier/go-toml/v2 v2.1.0 // indirect github.com/petermattis/goid v0.0.0-20230904192822-1876fd5063bc // indirect github.com/pkg/errors v0.9.1 // indirect @@ -168,6 +168,7 @@ require ( 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.7.0 // indirect + github.com/ugorji/go/codec v1.2.11 // indirect github.com/ulikunitz/xz v0.5.11 // indirect github.com/zondax/hid v0.9.2 // indirect github.com/zondax/ledger-go v0.14.3 // indirect diff --git a/go.sum b/go.sum index 8edbf95c..e2d7fe02 100644 --- a/go.sum +++ b/go.sum @@ -365,10 +365,6 @@ github.com/cosmos/gogoproto v1.4.11 h1:LZcMHrx4FjUgrqQSWeaGC1v/TeuVFqSLa43CC6aWR github.com/cosmos/gogoproto v1.4.11/go.mod h1:/g39Mh8m17X8Q/GDEs5zYTSNaNnInBSohtaxzQnYq1Y= github.com/cosmos/iavl v1.0.0 h1:bw6t0Mv/mVCJvlMTOPHWLs5uUE3BRBfVWCRelOzl+so= github.com/cosmos/iavl v1.0.0/go.mod h1:CmTGqMnRnucjxbjduneZXT+0vPgNElYvdefjX2q9tYc= -github.com/cosmos/ibc-go/modules/capability v1.0.0 h1:r/l++byFtn7jHYa09zlAdSeevo8ci1mVZNO9+V0xsLE= -github.com/cosmos/ibc-go/modules/capability v1.0.0/go.mod h1:D81ZxzjZAe0ZO5ambnvn1qedsFQ8lOwtqicG6liLBco= -github.com/cosmos/ibc-go/v8 v8.0.0 h1:QKipnr/NGwc+9L7NZipURvmSIu+nw9jOIWTJuDBqOhg= -github.com/cosmos/ibc-go/v8 v8.0.0/go.mod h1:C6IiJom0F3cIQCD5fKwVPDrDK9j/xTu563AWuOmXois= 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= @@ -477,6 +473,7 @@ github.com/go-playground/validator/v10 v10.11.1 h1:prmOlTVv+YjZjmRmNSF3VmspqJIxJ github.com/go-playground/validator/v10 v10.11.1/go.mod h1:i+3WkQ1FvaUjjxh1kSvIA4dMGDBiPU55YFDl0WbKdWU= github.com/go-sql-driver/mysql v1.4.0/go.mod h1:zAC/RDZ24gD3HViQzih4MyKcchzm+sOG5ZlKdlhCg5w= github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY= +github.com/go-task/slim-sprig v0.0.0-20210107165309-348f09dbbbc0/go.mod h1:fyg7847qk6SyHyPtNmDHnmrv/HOrqktSC+C9fM+CJOE= github.com/gobwas/httphead v0.0.0-20180130184737-2c6c146eadee h1:s+21KNqlpePfkah2I+gwHF8xmJWRjooY+5248k6m4A0= github.com/gobwas/httphead v0.0.0-20180130184737-2c6c146eadee/go.mod h1:L0fX3K22YWvt/FAX9NnzrNzcI4wNYi9Yku4O0LKYflo= github.com/gobwas/pool v0.2.0 h1:QEmUOlnSjWtnpRGHF3SauEiOsy82Cup83Vf2LcMlnc8= @@ -1008,7 +1005,6 @@ github.com/tidwall/btree v1.7.0 h1:L1fkJH/AuEh5zBnnBbmTwQ5Lt+bRJ5A8EWecslvo9iI= github.com/tidwall/btree v1.7.0/go.mod h1:twD9XRA5jj9VUQGELzDO4HPQTNJsoWWfYEL+EUQ2cKY= github.com/tmc/grpc-websocket-proxy v0.0.0-20170815181823-89b8d40f7ca8/go.mod h1:ncp9v5uamzpCO7NfCPTXjqaC+bZgJeR0sMTm6dMHP7U= github.com/tv42/httpunix v0.0.0-20150427012821-b75d8614f926/go.mod h1:9ESjWnEqriFuLhtthL60Sar/7RFoluCcXsuvEwTV5KM= -github.com/ugorji/go v1.2.7 h1:qYhyWUUd6WbiM+C6JZAUkIJt/1WrjzNHY9+KCIjVqTo= github.com/ugorji/go v1.2.7/go.mod h1:nF9osbDWLy6bDVv/Rtoh6QgnvNDpmCalQV5urGCCS6M= github.com/ugorji/go/codec v0.0.0-20181204163529-d75b2dcb6bc8/go.mod h1:VFNgLljTbGfSG7qAOspJ7OScBnGdDN/yBr0sguwnwf0= github.com/ugorji/go/codec v1.2.7/go.mod h1:WGN1fab3R1fzQlVQTkfxVtIBhWDRqOviHU95kRgeqEY= @@ -1277,6 +1273,7 @@ golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7w 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-20210112080510-489259a85091/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210119212857-b64e53b001e4/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= @@ -1400,6 +1397,7 @@ golang.org/x/tools v0.0.0-20200904185747-39188db58858/go.mod h1:Cj7w3i3Rnn0Xh82u 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= +golang.org/x/tools v0.0.0-20201224043029-2b0845dc783e/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.0.0-20210105154028-b0ab187a4818/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= 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= diff --git a/proto/opinit/opchild/v1/tx.proto b/proto/opinit/opchild/v1/tx.proto index 82c005bf..4f6a20d1 100644 --- a/proto/opinit/opchild/v1/tx.proto +++ b/proto/opinit/opchild/v1/tx.proto @@ -22,10 +22,6 @@ service Msg { // ExecuteMessages defines a rpc handler method for MsgExecuteMessages. rpc ExecuteMessages(MsgExecuteMessages) returns (MsgExecuteMessagesResponse); - // ExecuteLegacyContents defines a rpc handler method for - // MsgExecuteLegacyContents. - rpc ExecuteLegacyContents(MsgExecuteLegacyContents) returns (MsgExecuteLegacyContentsResponse); - //////////////////////////// // Bridge Executor Messages @@ -74,23 +70,6 @@ message MsgExecuteMessages { // MsgExecuteMessagesResponse returns MsgExecuteMessages message result data message MsgExecuteMessagesResponse {} -// MsgExecuteLegacyContents is a message to execute legacy -// (gov) contents with validator permission. -message MsgExecuteLegacyContents { - option (cosmos.msg.v1.signer) = "sender"; - option (amino.name) = "opchild/MsgExecuteLegacyContents"; - - // Sender is the that actor that signed a messages - string sender = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // contents are the arbitrary legacy (gov) contents to be executed. - repeated google.protobuf.Any contents = 2; -} - -// MsgExecuteLegacyContentsResponse returns MsgExecuteLegacyContents message -// result data -message MsgExecuteLegacyContentsResponse {} - ///////////////////////////// // Bridge Executor messages diff --git a/x/opchild/client/cli/legacy_contents.go b/x/opchild/client/cli/legacy_contents.go deleted file mode 100644 index f812b248..00000000 --- a/x/opchild/client/cli/legacy_contents.go +++ /dev/null @@ -1,233 +0,0 @@ -package cli - -import ( - "fmt" - "os" - "strconv" - "strings" - - "github.com/spf13/cobra" - - "cosmossdk.io/core/address" - upgradetypes "cosmossdk.io/x/upgrade/types" - "github.com/cosmos/cosmos-sdk/client" - "github.com/cosmos/cosmos-sdk/client/tx" - "github.com/cosmos/cosmos-sdk/codec" - "github.com/cosmos/cosmos-sdk/version" - govcli "github.com/cosmos/cosmos-sdk/x/gov/client/cli" - govv1beta1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1" - paramscutils "github.com/cosmos/cosmos-sdk/x/params/client/utils" - paramproposal "github.com/cosmos/cosmos-sdk/x/params/types/proposal" - - ibcclienttypes "github.com/cosmos/ibc-go/v8/modules/core/02-client/types" - "github.com/cosmos/ibc-go/v8/modules/core/exported" - - "github.com/initia-labs/OPinit/x/opchild/types" -) - -// NewLegacyContentParamChangeTxCmd returns a CLI command handler for creating -// a parameter change legacy content validator transaction. -func NewLegacyContentParamChangeTxCmd(ac address.Codec) *cobra.Command { - return &cobra.Command{ - Use: "param-change [proposal-file]", - Args: cobra.ExactArgs(1), - Short: "Submit a parameter change proposal", - Long: strings.TrimSpace( - fmt.Sprintf(`Submit a parameter proposal along with an initial deposit. -The proposal details must be supplied via a JSON file. For values that contains -objects, only non-empty fields will be updated. - -IMPORTANT: Currently parameter changes are evaluated but not validated, so it is -very important that any "value" change is valid (ie. correct type and within bounds) -for its respective parameter, eg. "MaxValidators" should be an integer and not a decimal. - -Proper vetting of a parameter change proposal should prevent this from happening -(no deposits should occur during the governance process), but it should be noted -regardless. - -Example: -$ %s tx gov submit-proposal param-change --from= - -Where proposal.json contains: - -{ - "title": "Staking Param Change", - "description": "Update max validators", - "changes": [ - { - "subspace": "staking", - "key": "MaxValidators", - "value": 105 - } - ] -} -`, - version.AppName, - ), - ), - RunE: func(cmd *cobra.Command, args []string) error { - clientCtx, err := client.GetClientTxContext(cmd) - if err != nil { - return err - } - proposal, err := paramscutils.ParseParamChangeProposalJSON(clientCtx.LegacyAmino, args[0]) - if err != nil { - return err - } - - from := clientCtx.GetFromAddress() - content := paramproposal.NewParameterChangeProposal( - proposal.Title, proposal.Description, proposal.Changes.ToParamChanges(), - ) - - msg, err := types.NewMsgExecuteLegacyContents(from, []govv1beta1.Content{content}) - if err != nil { - return err - } - - if err := msg.Validate(ac); err != nil { - return err - } - - return tx.GenerateOrBroadcastTxCLI(clientCtx, cmd.Flags(), msg) - }, - } -} - -// NewLegacyContentSubmitUpdateClientCmd implements a command handler for submitting an update IBC client transaction. -func NewLegacyContentSubmitUpdateClientCmd(ac address.Codec) *cobra.Command { - cmd := &cobra.Command{ - Use: "update-client [subject-client-id] [substitute-client-id]", - Args: cobra.ExactArgs(2), - Short: "Submit an update IBC client proposal", - Long: "Submit an update IBC client proposal along with an initial deposit.\n" + - "Please specify a subject client identifier you want to update..\n" + - "Please specify the substitute client the subject client will be updated to.", - RunE: func(cmd *cobra.Command, args []string) error { - clientCtx, err := client.GetClientTxContext(cmd) - if err != nil { - return err - } - - title, err := cmd.Flags().GetString(govcli.FlagTitle) //nolint:staticcheck // need this till full govv1 conversion. - if err != nil { - return err - } - - description, err := cmd.Flags().GetString(govcli.FlagDescription) //nolint:staticcheck // need this till full govv1 conversion. - if err != nil { - return err - } - - subjectClientID := args[0] - substituteClientID := args[1] - - content := ibcclienttypes.NewClientUpdateProposal(title, description, subjectClientID, substituteClientID) - - from := clientCtx.GetFromAddress() - msg, err := types.NewMsgExecuteLegacyContents(from, []govv1beta1.Content{content}) - if err != nil { - return err - } - - if err = msg.Validate(ac); err != nil { - return err - } - - return tx.GenerateOrBroadcastTxCLI(clientCtx, cmd.Flags(), msg) - }, - } - - cmd.Flags().String(govcli.FlagTitle, "", "title of proposal") //nolint:staticcheck // need this till full govv1 conversion. - cmd.Flags().String(govcli.FlagDescription, "", "description of proposal") //nolint:staticcheck // need this till full govv1 conversion. - - return cmd -} - -// NewLegacyContentSubmitUpgradeCmd implements a command handler for submitting an upgrade IBC client transaction. -func NewLegacyContentSubmitUpgradeCmd(ac address.Codec) *cobra.Command { - cmd := &cobra.Command{ - Use: "ibc-upgrade [name] [height] [path/to/upgraded_client_state.json] [flags]", - Args: cobra.ExactArgs(3), - Short: "Submit an IBC upgrade proposal", - Long: "Submit an IBC client breaking upgrade proposal along with an initial deposit.\n" + - "The client state specified is the upgraded client state representing the upgraded chain\n" + - `Example Upgraded Client State JSON: -{ - "@type":"/ibc.lightclients.tendermint.v1.ClientState", - "chain_id":"testchain1", - "unbonding_period":"1814400s", - "latest_height":{"revision_number":"0","revision_height":"2"}, - "proof_specs":[{"leaf_spec":{"hash":"SHA256","prehash_key":"NO_HASH","prehash_value":"SHA256","length":"VAR_PROTO","prefix":"AA=="},"inner_spec":{"child_order":[0,1],"child_size":33,"min_prefix_length":4,"max_prefix_length":12,"empty_child":null,"hash":"SHA256"},"max_depth":0,"min_depth":0},{"leaf_spec":{"hash":"SHA256","prehash_key":"NO_HASH","prehash_value":"SHA256","length":"VAR_PROTO","prefix":"AA=="},"inner_spec":{"child_order":[0,1],"child_size":32,"min_prefix_length":1,"max_prefix_length":1,"empty_child":null,"hash":"SHA256"},"max_depth":0,"min_depth":0}], - "upgrade_path":["upgrade","upgradedIBCState"], -} - `, - RunE: func(cmd *cobra.Command, args []string) error { - clientCtx, err := client.GetClientTxContext(cmd) - if err != nil { - return err - } - cdc := codec.NewProtoCodec(clientCtx.InterfaceRegistry) - - title, err := cmd.Flags().GetString(govcli.FlagTitle) //nolint:staticcheck // need this till full govv1 conversion. - if err != nil { - return err - } - - description, err := cmd.Flags().GetString(govcli.FlagDescription) //nolint:staticcheck // need this till full govv1 conversion. - if err != nil { - return err - } - - name := args[0] - - height, err := strconv.ParseInt(args[1], 10, 64) - if err != nil { - return err - } - - plan := upgradetypes.Plan{ - Name: name, - Height: height, - } - - // attempt to unmarshal client state argument - var clientState exported.ClientState - clientContentOrFileName := args[2] - if err := cdc.UnmarshalInterfaceJSON([]byte(clientContentOrFileName), &clientState); err != nil { - - // check for file path if JSON input is not provided - contents, err := os.ReadFile(clientContentOrFileName) - if err != nil { - return fmt.Errorf("neither JSON input nor path to .json file for client state were provided: %w", err) - } - - if err := cdc.UnmarshalInterfaceJSON(contents, &clientState); err != nil { - return fmt.Errorf("error unmarshalling client state file: %w", err) - } - } - - content, err := ibcclienttypes.NewUpgradeProposal(title, description, plan, clientState) - if err != nil { - return err - } - - from := clientCtx.GetFromAddress() - msg, err := types.NewMsgExecuteLegacyContents(from, []govv1beta1.Content{content}) - if err != nil { - return err - } - - if err = msg.Validate(ac); err != nil { - return err - } - - return tx.GenerateOrBroadcastTxCLI(clientCtx, cmd.Flags(), msg) - }, - } - - cmd.Flags().String(govcli.FlagTitle, "", "title of proposal") //nolint:staticcheck // need this till full govv1 conversion. - cmd.Flags().String(govcli.FlagDescription, "", "description of proposal") //nolint:staticcheck // need this till full govv1 conversion. - - return cmd -} diff --git a/x/opchild/client/cli/tx.go b/x/opchild/client/cli/tx.go index 9797051b..02a7e002 100644 --- a/x/opchild/client/cli/tx.go +++ b/x/opchild/client/cli/tx.go @@ -31,9 +31,6 @@ func GetTxCmd(ac address.Codec) *cobra.Command { NewExecuteMessagesCmd(ac), NewDepositCmd(ac), NewWithdrawCmd(ac), - NewLegacyContentParamChangeTxCmd(ac), - NewLegacyContentSubmitUpdateClientCmd(ac), - NewLegacyContentSubmitUpgradeCmd(ac), ) return opchildTxCmd diff --git a/x/opchild/keeper/common_test.go b/x/opchild/keeper/common_test.go index 9dba8569..9ecd0663 100644 --- a/x/opchild/keeper/common_test.go +++ b/x/opchild/keeper/common_test.go @@ -45,7 +45,6 @@ import ( govv1beta1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" "github.com/cosmos/gogoproto/proto" - capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" opchild "github.com/initia-labs/OPinit/x/opchild" opchildkeeper "github.com/initia-labs/OPinit/x/opchild/keeper" @@ -241,7 +240,7 @@ func _createTestInput( for _, v := range keys { ms.MountStoreWithDB(v, storetypes.StoreTypeIAVL, db) } - memKeys := storetypes.NewMemoryStoreKeys(capabilitytypes.MemStoreKey) + memKeys := storetypes.NewMemoryStoreKeys() for _, v := range memKeys { ms.MountStoreWithDB(v, storetypes.StoreTypeMemory, db) } diff --git a/x/opchild/keeper/msg_server.go b/x/opchild/keeper/msg_server.go index bf28f828..1824db80 100644 --- a/x/opchild/keeper/msg_server.go +++ b/x/opchild/keeper/msg_server.go @@ -132,33 +132,6 @@ func (ms MsgServer) ExecuteMessages(ctx context.Context, req *types.MsgExecuteMe return &types.MsgExecuteMessagesResponse{}, nil } -// ExecuteLegacyContents implements a ExecuteLegacyContents message handling -func (ms MsgServer) ExecuteLegacyContents(ctx context.Context, req *types.MsgExecuteLegacyContents) (*types.MsgExecuteLegacyContentsResponse, error) { - if err := req.Validate(ms.authKeeper.AddressCodec()); err != nil { - return nil, err - } - - // permission check - if err := ms.checkValidatorPermission(ctx, req.Sender); err != nil { - return nil, err - } - - sdkCtx := sdk.UnwrapSDKContext(ctx) - for _, content := range req.GetContents() { - // Ensure that the content has a respective handler - if !ms.Keeper.legacyRouter.HasRoute(content.ProposalRoute()) { - return nil, errors.Wrap(govtypes.ErrNoProposalHandlerExists, content.ProposalRoute()) - } - - handler := ms.Keeper.legacyRouter.GetRoute(content.ProposalRoute()) - if err := handler(sdkCtx, content); err != nil { - return nil, errors.Wrapf(govtypes.ErrInvalidProposalContent, "failed to run legacy handler %s, %+v", content.ProposalRoute(), err) - } - } - - return &types.MsgExecuteLegacyContentsResponse{}, nil -} - ////////////////////////////////////////////// // Authority messages diff --git a/x/opchild/keeper/msg_server_test.go b/x/opchild/keeper/msg_server_test.go index 75d8452b..dd265e87 100644 --- a/x/opchild/keeper/msg_server_test.go +++ b/x/opchild/keeper/msg_server_test.go @@ -13,7 +13,6 @@ import ( testutilsims "github.com/cosmos/cosmos-sdk/testutil/sims" sdk "github.com/cosmos/cosmos-sdk/types" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" - govv1beta1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1" "github.com/initia-labs/OPinit/x/opchild/keeper" "github.com/initia-labs/OPinit/x/opchild/types" @@ -58,49 +57,6 @@ func Test_MsgServer_ExecuteMessages(t *testing.T) { require.Equal(t, vals[0].Moniker, "val2") } -func Test_MsgServer_ExecuteLegacyContents(t *testing.T) { - ctx, input := createDefaultTestInput(t) - - ms := keeper.NewMsgServerImpl(input.OPChildKeeper) - valPubKeys := testutilsims.CreateTestPubKeys(2) - - // register validator - val, err := types.NewValidator(valAddrs[0], valPubKeys[0], "val1") - require.NoError(t, err) - - input.OPChildKeeper.SetValidator(ctx, val) - - // apply validator updates - input.OPChildKeeper.BlockValidatorUpdates(ctx) - - // valid legacy content - legacyContent := testLegacyContent{ - Title: "title", - Description: "description", - Message: "test", - } - msg, err := types.NewMsgExecuteLegacyContents(addrs[0], []govv1beta1.Content{&legacyContent}) - require.NoError(t, err) - - _, err = ms.ExecuteLegacyContents(ctx, msg) - require.NoError(t, err) - - // unauthorized executor - msg, err = types.NewMsgExecuteLegacyContents(addrs[1], []govv1beta1.Content{&legacyContent}) - require.NoError(t, err) - - _, err = ms.ExecuteLegacyContents(ctx, msg) - require.Error(t, err) - - // legacy content with wrong message - legacyContent.Message = "wrong message" - msg, err = types.NewMsgExecuteLegacyContents(addrs[0], []govv1beta1.Content{&legacyContent}) - require.NoError(t, err) - - _, err = ms.ExecuteLegacyContents(ctx, msg) - require.Error(t, err) -} - ///////////////////////////////////////// // The messages for Authority diff --git a/x/opchild/types/codec.go b/x/opchild/types/codec.go index aba33409..c99a844b 100644 --- a/x/opchild/types/codec.go +++ b/x/opchild/types/codec.go @@ -6,14 +6,12 @@ import ( codectypes "github.com/cosmos/cosmos-sdk/codec/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/msgservice" - govv1beta1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1" ) // RegisterLegacyAminoCodec registers the move types and interface func RegisterLegacyAminoCodec(cdc *codec.LegacyAmino) { legacy.RegisterAminoMsg(cdc, &MsgExecuteMessages{}, "opchild/MsgExecuteMessages") - legacy.RegisterAminoMsg(cdc, &MsgExecuteLegacyContents{}, "opchild/MsgExecuteLegacyContents") legacy.RegisterAminoMsg(cdc, &MsgAddValidator{}, "opchild/MsgAddValidator") legacy.RegisterAminoMsg(cdc, &MsgRemoveValidator{}, "opchild/MsgRemoveAddValidator") legacy.RegisterAminoMsg(cdc, &MsgUpdateParams{}, "opchild/MsgUpdateParams") @@ -33,10 +31,6 @@ func RegisterInterfaces(registry codectypes.InterfaceRegistry) { &MsgFinalizeTokenDeposit{}, &MsgInitiateTokenWithdrawal{}, ) - registry.RegisterInterface( - "cosmos.gov.v1beta1.Content", - (*govv1beta1.Content)(nil), - ) msgservice.RegisterMsgServiceDesc(registry, &_Msg_serviceDesc) } diff --git a/x/opchild/types/tx.go b/x/opchild/types/tx.go index 3a9f894f..2e56b712 100644 --- a/x/opchild/types/tx.go +++ b/x/opchild/types/tx.go @@ -1,8 +1,6 @@ package types import ( - "fmt" - "cosmossdk.io/core/address" errors "cosmossdk.io/errors" codectypes "github.com/cosmos/cosmos-sdk/codec/types" @@ -11,14 +9,11 @@ import ( sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" sdktx "github.com/cosmos/cosmos-sdk/types/tx" govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" - govv1beta1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1" - "github.com/cosmos/gogoproto/proto" ) // rollup message types const ( - TypeMsgExecuteMessages = "execute_messages" - TypeMsgExecuteLegacyContents = "execute_legacy_contents" + TypeMsgExecuteMessages = "execute_messages" TypeMsgAddValidator = "add_validator" TypeMsgRemoveValidator = "remove_validator" @@ -32,7 +27,6 @@ const ( var ( _ sdk.Msg = &MsgExecuteMessages{} - _ sdk.Msg = &MsgExecuteLegacyContents{} _ sdk.Msg = &MsgAddValidator{} _ sdk.Msg = &MsgRemoveValidator{} _ sdk.Msg = &MsgUpdateParams{} @@ -40,7 +34,7 @@ var ( _ sdk.Msg = &MsgFinalizeTokenDeposit{} _ sdk.Msg = &MsgInitiateTokenWithdrawal{} - _, _ codectypes.UnpackInterfacesMessage = &MsgExecuteMessages{}, &MsgExecuteLegacyContents{} + _ codectypes.UnpackInterfacesMessage = &MsgExecuteMessages{} ) // should refer initiavm/precompile/modules/minlib/sources/coin.move @@ -91,92 +85,6 @@ func (m MsgExecuteMessages) UnpackInterfaces(unpacker codectypes.AnyUnpacker) er return sdktx.UnpackInterfaces(unpacker, m.Messages) } -/* MsgExecuteLegacyContents */ - -// NewMsgExecuteLegacyContents creates a new MsgExecuteLegacyContents instance. -func NewMsgExecuteLegacyContents( - sender sdk.AccAddress, //nolint:interfacer - contents []govv1beta1.Content, -) (*MsgExecuteLegacyContents, error) { - msg := &MsgExecuteLegacyContents{ - Sender: sender.String(), - } - - if err := msg.SetContents(contents); err != nil { - return nil, err - } - - return msg, nil -} - -// GetContents returns the contents of MsgExecuteLegacyContents. -func (m *MsgExecuteLegacyContents) GetContents() []govv1beta1.Content { - contents := make([]govv1beta1.Content, len(m.Contents)) - for i, content := range m.Contents { - content, ok := content.GetCachedValue().(govv1beta1.Content) - if !ok { - return nil - } - - contents[i] = content - } - - return contents -} - -// SetContents sets the contents for MsgExecuteLegacyContents. -func (m *MsgExecuteLegacyContents) SetContents(contents []govv1beta1.Content) error { - anys := make([]*codectypes.Any, len(contents)) - for i, content := range contents { - msg, ok := content.(proto.Message) - if !ok { - return fmt.Errorf("can't proto marshal %T", msg) - } - any, err := codectypes.NewAnyWithValue(msg) - if err != nil { - return err - } - - anys[i] = any - } - - m.Contents = anys - return nil -} - -// Validate performs basic MsgExecuteLegacyContents message validation. -func (msg MsgExecuteLegacyContents) Validate(ac address.Codec) error { - if _, err := ac.StringToBytes(msg.Sender); err != nil { - return err - } - - // Check Msgs length is non nil. - if len(msg.Contents) == 0 { - return errors.Wrap(govtypes.ErrNoProposalMsgs, "Contents length must be non-zero") - } - - contents := msg.GetContents() - for idx, content := range contents { - if err := content.ValidateBasic(); err != nil { - return errors.Wrapf(govtypes.ErrInvalidProposalContent, "content: %d, err: %s", idx, err.Error()) - } - } - - return nil -} - -// UnpackInterfaces implements UnpackInterfacesMessage.UnpackInterfaces -func (c MsgExecuteLegacyContents) UnpackInterfaces(unpacker codectypes.AnyUnpacker) error { - for _, anyContent := range c.Contents { - var content govv1beta1.Content - if err := unpacker.UnpackAny(anyContent, &content); err != nil { - return err - } - } - - return nil -} - /* MsgAddValidator */ // NewMsgAddValidator creates a new MsgAddValidator instance. diff --git a/x/opchild/types/tx.pb.go b/x/opchild/types/tx.pb.go index 7c4eac0c..c745c292 100644 --- a/x/opchild/types/tx.pb.go +++ b/x/opchild/types/tx.pb.go @@ -113,86 +113,6 @@ func (m *MsgExecuteMessagesResponse) XXX_DiscardUnknown() { var xxx_messageInfo_MsgExecuteMessagesResponse proto.InternalMessageInfo -// MsgExecuteLegacyContents is a message to execute legacy -// (gov) contents with validator permission. -type MsgExecuteLegacyContents struct { - // Sender is the that actor that signed a messages - Sender string `protobuf:"bytes,1,opt,name=sender,proto3" json:"sender,omitempty"` - // contents are the arbitrary legacy (gov) contents to be executed. - Contents []*types.Any `protobuf:"bytes,2,rep,name=contents,proto3" json:"contents,omitempty"` -} - -func (m *MsgExecuteLegacyContents) Reset() { *m = MsgExecuteLegacyContents{} } -func (m *MsgExecuteLegacyContents) String() string { return proto.CompactTextString(m) } -func (*MsgExecuteLegacyContents) ProtoMessage() {} -func (*MsgExecuteLegacyContents) Descriptor() ([]byte, []int) { - return fileDescriptor_1ee96a503651b6e4, []int{2} -} -func (m *MsgExecuteLegacyContents) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *MsgExecuteLegacyContents) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - if deterministic { - return xxx_messageInfo_MsgExecuteLegacyContents.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 *MsgExecuteLegacyContents) XXX_Merge(src proto.Message) { - xxx_messageInfo_MsgExecuteLegacyContents.Merge(m, src) -} -func (m *MsgExecuteLegacyContents) XXX_Size() int { - return m.Size() -} -func (m *MsgExecuteLegacyContents) XXX_DiscardUnknown() { - xxx_messageInfo_MsgExecuteLegacyContents.DiscardUnknown(m) -} - -var xxx_messageInfo_MsgExecuteLegacyContents proto.InternalMessageInfo - -// MsgExecuteLegacyContentsResponse returns MsgExecuteLegacyContents message -// result data -type MsgExecuteLegacyContentsResponse struct { -} - -func (m *MsgExecuteLegacyContentsResponse) Reset() { *m = MsgExecuteLegacyContentsResponse{} } -func (m *MsgExecuteLegacyContentsResponse) String() string { return proto.CompactTextString(m) } -func (*MsgExecuteLegacyContentsResponse) ProtoMessage() {} -func (*MsgExecuteLegacyContentsResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_1ee96a503651b6e4, []int{3} -} -func (m *MsgExecuteLegacyContentsResponse) XXX_Unmarshal(b []byte) error { - return m.Unmarshal(b) -} -func (m *MsgExecuteLegacyContentsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { - if deterministic { - return xxx_messageInfo_MsgExecuteLegacyContentsResponse.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 *MsgExecuteLegacyContentsResponse) XXX_Merge(src proto.Message) { - xxx_messageInfo_MsgExecuteLegacyContentsResponse.Merge(m, src) -} -func (m *MsgExecuteLegacyContentsResponse) XXX_Size() int { - return m.Size() -} -func (m *MsgExecuteLegacyContentsResponse) XXX_DiscardUnknown() { - xxx_messageInfo_MsgExecuteLegacyContentsResponse.DiscardUnknown(m) -} - -var xxx_messageInfo_MsgExecuteLegacyContentsResponse proto.InternalMessageInfo - // MsgFinalizeTokenDeposit is a message to submit deposit funds from upper layer type MsgFinalizeTokenDeposit struct { // the sender address @@ -215,7 +135,7 @@ func (m *MsgFinalizeTokenDeposit) Reset() { *m = MsgFinalizeTokenDeposit func (m *MsgFinalizeTokenDeposit) String() string { return proto.CompactTextString(m) } func (*MsgFinalizeTokenDeposit) ProtoMessage() {} func (*MsgFinalizeTokenDeposit) Descriptor() ([]byte, []int) { - return fileDescriptor_1ee96a503651b6e4, []int{4} + return fileDescriptor_1ee96a503651b6e4, []int{2} } func (m *MsgFinalizeTokenDeposit) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -252,7 +172,7 @@ func (m *MsgFinalizeTokenDepositResponse) Reset() { *m = MsgFinalizeToke func (m *MsgFinalizeTokenDepositResponse) String() string { return proto.CompactTextString(m) } func (*MsgFinalizeTokenDepositResponse) ProtoMessage() {} func (*MsgFinalizeTokenDepositResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_1ee96a503651b6e4, []int{5} + return fileDescriptor_1ee96a503651b6e4, []int{3} } func (m *MsgFinalizeTokenDepositResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -295,7 +215,7 @@ func (m *MsgInitiateTokenWithdrawal) Reset() { *m = MsgInitiateTokenWith func (m *MsgInitiateTokenWithdrawal) String() string { return proto.CompactTextString(m) } func (*MsgInitiateTokenWithdrawal) ProtoMessage() {} func (*MsgInitiateTokenWithdrawal) Descriptor() ([]byte, []int) { - return fileDescriptor_1ee96a503651b6e4, []int{6} + return fileDescriptor_1ee96a503651b6e4, []int{4} } func (m *MsgInitiateTokenWithdrawal) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -333,7 +253,7 @@ func (m *MsgInitiateTokenWithdrawalResponse) Reset() { *m = MsgInitiateT func (m *MsgInitiateTokenWithdrawalResponse) String() string { return proto.CompactTextString(m) } func (*MsgInitiateTokenWithdrawalResponse) ProtoMessage() {} func (*MsgInitiateTokenWithdrawalResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_1ee96a503651b6e4, []int{7} + return fileDescriptor_1ee96a503651b6e4, []int{5} } func (m *MsgInitiateTokenWithdrawalResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -376,7 +296,7 @@ func (m *MsgAddValidator) Reset() { *m = MsgAddValidator{} } func (m *MsgAddValidator) String() string { return proto.CompactTextString(m) } func (*MsgAddValidator) ProtoMessage() {} func (*MsgAddValidator) Descriptor() ([]byte, []int) { - return fileDescriptor_1ee96a503651b6e4, []int{8} + return fileDescriptor_1ee96a503651b6e4, []int{6} } func (m *MsgAddValidator) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -413,7 +333,7 @@ func (m *MsgAddValidatorResponse) Reset() { *m = MsgAddValidatorResponse func (m *MsgAddValidatorResponse) String() string { return proto.CompactTextString(m) } func (*MsgAddValidatorResponse) ProtoMessage() {} func (*MsgAddValidatorResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_1ee96a503651b6e4, []int{9} + return fileDescriptor_1ee96a503651b6e4, []int{7} } func (m *MsgAddValidatorResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -455,7 +375,7 @@ func (m *MsgRemoveValidator) Reset() { *m = MsgRemoveValidator{} } func (m *MsgRemoveValidator) String() string { return proto.CompactTextString(m) } func (*MsgRemoveValidator) ProtoMessage() {} func (*MsgRemoveValidator) Descriptor() ([]byte, []int) { - return fileDescriptor_1ee96a503651b6e4, []int{10} + return fileDescriptor_1ee96a503651b6e4, []int{8} } func (m *MsgRemoveValidator) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -492,7 +412,7 @@ func (m *MsgRemoveValidatorResponse) Reset() { *m = MsgRemoveValidatorRe func (m *MsgRemoveValidatorResponse) String() string { return proto.CompactTextString(m) } func (*MsgRemoveValidatorResponse) ProtoMessage() {} func (*MsgRemoveValidatorResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_1ee96a503651b6e4, []int{11} + return fileDescriptor_1ee96a503651b6e4, []int{9} } func (m *MsgRemoveValidatorResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -534,7 +454,7 @@ 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_1ee96a503651b6e4, []int{12} + return fileDescriptor_1ee96a503651b6e4, []int{10} } func (m *MsgUpdateParams) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -571,7 +491,7 @@ 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_1ee96a503651b6e4, []int{13} + return fileDescriptor_1ee96a503651b6e4, []int{11} } func (m *MsgUpdateParamsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -616,7 +536,7 @@ func (m *MsgSpendFeePool) Reset() { *m = MsgSpendFeePool{} } func (m *MsgSpendFeePool) String() string { return proto.CompactTextString(m) } func (*MsgSpendFeePool) ProtoMessage() {} func (*MsgSpendFeePool) Descriptor() ([]byte, []int) { - return fileDescriptor_1ee96a503651b6e4, []int{14} + return fileDescriptor_1ee96a503651b6e4, []int{12} } func (m *MsgSpendFeePool) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -653,7 +573,7 @@ func (m *MsgSpendFeePoolResponse) Reset() { *m = MsgSpendFeePoolResponse func (m *MsgSpendFeePoolResponse) String() string { return proto.CompactTextString(m) } func (*MsgSpendFeePoolResponse) ProtoMessage() {} func (*MsgSpendFeePoolResponse) Descriptor() ([]byte, []int) { - return fileDescriptor_1ee96a503651b6e4, []int{15} + return fileDescriptor_1ee96a503651b6e4, []int{13} } func (m *MsgSpendFeePoolResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -685,8 +605,6 @@ var xxx_messageInfo_MsgSpendFeePoolResponse proto.InternalMessageInfo func init() { proto.RegisterType((*MsgExecuteMessages)(nil), "opinit.opchild.v1.MsgExecuteMessages") proto.RegisterType((*MsgExecuteMessagesResponse)(nil), "opinit.opchild.v1.MsgExecuteMessagesResponse") - proto.RegisterType((*MsgExecuteLegacyContents)(nil), "opinit.opchild.v1.MsgExecuteLegacyContents") - proto.RegisterType((*MsgExecuteLegacyContentsResponse)(nil), "opinit.opchild.v1.MsgExecuteLegacyContentsResponse") proto.RegisterType((*MsgFinalizeTokenDeposit)(nil), "opinit.opchild.v1.MsgFinalizeTokenDeposit") proto.RegisterType((*MsgFinalizeTokenDepositResponse)(nil), "opinit.opchild.v1.MsgFinalizeTokenDepositResponse") proto.RegisterType((*MsgInitiateTokenWithdrawal)(nil), "opinit.opchild.v1.MsgInitiateTokenWithdrawal") @@ -704,75 +622,71 @@ func init() { func init() { proto.RegisterFile("opinit/opchild/v1/tx.proto", fileDescriptor_1ee96a503651b6e4) } var fileDescriptor_1ee96a503651b6e4 = []byte{ - // 1080 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xbc, 0x57, 0xcf, 0x8f, 0xdb, 0x44, - 0x14, 0x8e, 0x93, 0x6d, 0xda, 0x9d, 0x16, 0xb5, 0x6b, 0x2d, 0xac, 0xd7, 0xa2, 0x49, 0xb0, 0x84, - 0x14, 0x42, 0x63, 0x6f, 0x52, 0xc1, 0x21, 0x27, 0x36, 0xa5, 0x2b, 0x41, 0x89, 0x58, 0xa5, 0xfc, - 0x90, 0x38, 0x50, 0x4d, 0xec, 0xa9, 0x33, 0xda, 0x78, 0xc6, 0x78, 0x26, 0x61, 0xcd, 0x05, 0xc4, - 0x05, 0xc4, 0x89, 0x3f, 0xa1, 0x07, 0x0e, 0x88, 0xd3, 0x1e, 0x38, 0x21, 0xfe, 0x80, 0x15, 0xa7, - 0x8a, 0x03, 0xe2, 0xb4, 0xc0, 0xee, 0x61, 0x39, 0xef, 0x95, 0x0b, 0xb2, 0x3d, 0x71, 0x1c, 0xc7, - 0xde, 0x74, 0xab, 0xc2, 0xa5, 0xdd, 0x79, 0xef, 0x7b, 0xcf, 0xef, 0xfb, 0xde, 0xcc, 0x9b, 0x09, - 0x50, 0xa9, 0x8b, 0x09, 0xe6, 0x06, 0x75, 0xcd, 0x21, 0x1e, 0x59, 0xc6, 0xa4, 0x65, 0xf0, 0x7d, - 0xdd, 0xf5, 0x28, 0xa7, 0xf2, 0x5a, 0xe4, 0xd3, 0x85, 0x4f, 0x9f, 0xb4, 0xd4, 0x35, 0xe8, 0x60, - 0x42, 0x8d, 0xf0, 0xdf, 0x08, 0xa5, 0x56, 0x4c, 0xca, 0x1c, 0xca, 0x8c, 0x01, 0x64, 0xc8, 0x98, - 0xb4, 0x06, 0x88, 0xc3, 0x96, 0x61, 0x52, 0x4c, 0x84, 0x7f, 0x43, 0xf8, 0x1d, 0x66, 0x07, 0xd9, - 0x1d, 0x66, 0x0b, 0xc7, 0x66, 0xe4, 0x78, 0x10, 0xae, 0x8c, 0x68, 0x21, 0x5c, 0xeb, 0x36, 0xb5, - 0x69, 0x64, 0x0f, 0xfe, 0x9a, 0x06, 0xd8, 0x94, 0xda, 0x23, 0x64, 0x84, 0xab, 0xc1, 0xf8, 0xa1, - 0x01, 0x89, 0x2f, 0x5c, 0x37, 0x33, 0x68, 0xf8, 0x2e, 0x12, 0xf9, 0xb4, 0xef, 0x24, 0x20, 0xf7, - 0x98, 0x7d, 0x77, 0x1f, 0x99, 0x63, 0x8e, 0x7a, 0x88, 0x31, 0x68, 0x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e, 0x89, - 0xf3, 0xdb, 0xe0, 0x7a, 0x7a, 0xd6, 0xe6, 0x6c, 0x9e, 0x14, 0x2c, 0x6f, 0xf3, 0xe4, 0x4c, 0xb8, - 0x80, 0xc8, 0xdc, 0x74, 0xcb, 0x21, 0x92, 0xc4, 0xe4, 0x11, 0xc9, 0x9a, 0x33, 0x41, 0xfe, 0xb9, - 0x19, 0x93, 0x93, 0x3f, 0x89, 0xc9, 0xcb, 0x9f, 0x75, 0xda, 0xd4, 0x4b, 0x5f, 0x04, 0x67, 0xb8, - 0x7b, 0xef, 0xf0, 0xaf, 0x4a, 0xe1, 0xf0, 0xb8, 0x22, 0x3d, 0x3e, 0xae, 0x48, 0x7f, 0x1e, 0x57, - 0xa4, 0x6f, 0x4f, 0x2a, 0x85, 0xc7, 0x27, 0x95, 0xc2, 0xef, 0x27, 0x95, 0xc2, 0x47, 0xcd, 0xc4, - 0x40, 0xc0, 0x61, 0x67, 0x9b, 0x23, 0x38, 0x60, 0xc6, 0xbb, 0xbb, 0xe1, 0x8f, 0x9a, 0xfd, 0xf8, - 0x67, 0x4d, 0x38, 0x1b, 0x06, 0xe5, 0xf0, 0xae, 0xbd, 0xfd, 0x6f, 0x00, 0x00, 0x00, 0xff, 0xff, - 0x06, 0x99, 0x52, 0x24, 0xbc, 0x0d, 0x00, 0x00, + // 1020 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xbc, 0x56, 0xcf, 0x6f, 0xe3, 0x44, + 0x14, 0x8e, 0x93, 0x36, 0xbb, 0x9d, 0x5d, 0xd4, 0xad, 0x55, 0x51, 0xd7, 0x62, 0x93, 0x60, 0x09, + 0x29, 0x44, 0x1b, 0x7b, 0x13, 0x04, 0x87, 0x9c, 0x68, 0x60, 0x2b, 0xc1, 0x2a, 0xa2, 0xf2, 0xf2, + 0x43, 0xe2, 0xc0, 0x6a, 0x12, 0xcf, 0x3a, 0xa3, 0x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b, 0x85, 0x47, 0xe7, 0x95, 0xc2, 0x2f, 0xe7, + 0x95, 0xc2, 0xfb, 0xcd, 0xd4, 0xad, 0xc4, 0xb1, 0xb2, 0xcd, 0x11, 0xec, 0x33, 0xeb, 0xad, 0x83, + 0xf8, 0x09, 0x7e, 0x94, 0x3c, 0xc2, 0xe3, 0x0b, 0xda, 0x2f, 0xc7, 0x03, 0xef, 0xa5, 0xbf, 0x03, + 0x00, 0x00, 0xff, 0xff, 0x69, 0x1b, 0x7c, 0x6b, 0x6a, 0x0c, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -789,9 +703,6 @@ const _ = grpc.SupportPackageIsVersion4 type MsgClient interface { // ExecuteMessages defines a rpc handler method for MsgExecuteMessages. ExecuteMessages(ctx context.Context, in *MsgExecuteMessages, opts ...grpc.CallOption) (*MsgExecuteMessagesResponse, error) - // ExecuteLegacyContents defines a rpc handler method for - // MsgExecuteLegacyContents. - ExecuteLegacyContents(ctx context.Context, in *MsgExecuteLegacyContents, opts ...grpc.CallOption) (*MsgExecuteLegacyContentsResponse, error) // FinalizeTokenDeposit defines a rpc handler method for MsgFinalizeTokenDeposit. FinalizeTokenDeposit(ctx context.Context, in *MsgFinalizeTokenDeposit, opts ...grpc.CallOption) (*MsgFinalizeTokenDepositResponse, error) // InitiateTokenWithdrawal defines a user facing l2 => l1 token transfer interface. @@ -824,15 +735,6 @@ func (c *msgClient) ExecuteMessages(ctx context.Context, in *MsgExecuteMessages, return out, nil } -func (c *msgClient) ExecuteLegacyContents(ctx context.Context, in *MsgExecuteLegacyContents, opts ...grpc.CallOption) (*MsgExecuteLegacyContentsResponse, error) { - out := new(MsgExecuteLegacyContentsResponse) - err := c.cc.Invoke(ctx, "/opinit.opchild.v1.Msg/ExecuteLegacyContents", in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - func (c *msgClient) FinalizeTokenDeposit(ctx context.Context, in *MsgFinalizeTokenDeposit, opts ...grpc.CallOption) (*MsgFinalizeTokenDepositResponse, error) { out := new(MsgFinalizeTokenDepositResponse) err := c.cc.Invoke(ctx, "/opinit.opchild.v1.Msg/FinalizeTokenDeposit", in, out, opts...) @@ -891,9 +793,6 @@ func (c *msgClient) SpendFeePool(ctx context.Context, in *MsgSpendFeePool, opts type MsgServer interface { // ExecuteMessages defines a rpc handler method for MsgExecuteMessages. ExecuteMessages(context.Context, *MsgExecuteMessages) (*MsgExecuteMessagesResponse, error) - // ExecuteLegacyContents defines a rpc handler method for - // MsgExecuteLegacyContents. - ExecuteLegacyContents(context.Context, *MsgExecuteLegacyContents) (*MsgExecuteLegacyContentsResponse, error) // FinalizeTokenDeposit defines a rpc handler method for MsgFinalizeTokenDeposit. FinalizeTokenDeposit(context.Context, *MsgFinalizeTokenDeposit) (*MsgFinalizeTokenDepositResponse, error) // InitiateTokenWithdrawal defines a user facing l2 => l1 token transfer interface. @@ -916,9 +815,6 @@ type UnimplementedMsgServer struct { func (*UnimplementedMsgServer) ExecuteMessages(ctx context.Context, req *MsgExecuteMessages) (*MsgExecuteMessagesResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method ExecuteMessages not implemented") } -func (*UnimplementedMsgServer) ExecuteLegacyContents(ctx context.Context, req *MsgExecuteLegacyContents) (*MsgExecuteLegacyContentsResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method ExecuteLegacyContents not implemented") -} func (*UnimplementedMsgServer) FinalizeTokenDeposit(ctx context.Context, req *MsgFinalizeTokenDeposit) (*MsgFinalizeTokenDepositResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method FinalizeTokenDeposit not implemented") } @@ -960,24 +856,6 @@ func _Msg_ExecuteMessages_Handler(srv interface{}, ctx context.Context, dec func return interceptor(ctx, in, info, handler) } -func _Msg_ExecuteLegacyContents_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(MsgExecuteLegacyContents) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(MsgServer).ExecuteLegacyContents(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: "/opinit.opchild.v1.Msg/ExecuteLegacyContents", - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(MsgServer).ExecuteLegacyContents(ctx, req.(*MsgExecuteLegacyContents)) - } - return interceptor(ctx, in, info, handler) -} - func _Msg_FinalizeTokenDeposit_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgFinalizeTokenDeposit) if err := dec(in); err != nil { @@ -1094,10 +972,6 @@ var _Msg_serviceDesc = grpc.ServiceDesc{ MethodName: "ExecuteMessages", Handler: _Msg_ExecuteMessages_Handler, }, - { - MethodName: "ExecuteLegacyContents", - Handler: _Msg_ExecuteLegacyContents_Handler, - }, { MethodName: "FinalizeTokenDeposit", Handler: _Msg_FinalizeTokenDeposit_Handler, @@ -1194,73 +1068,6 @@ func (m *MsgExecuteMessagesResponse) MarshalToSizedBuffer(dAtA []byte) (int, err return len(dAtA) - i, nil } -func (m *MsgExecuteLegacyContents) 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 *MsgExecuteLegacyContents) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *MsgExecuteLegacyContents) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i - var l int - _ = l - if len(m.Contents) > 0 { - for iNdEx := len(m.Contents) - 1; iNdEx >= 0; iNdEx-- { - { - size, err := m.Contents[iNdEx].MarshalToSizedBuffer(dAtA[:i]) - if err != nil { - return 0, err - } - i -= size - i = encodeVarintTx(dAtA, i, uint64(size)) - } - i-- - dAtA[i] = 0x12 - } - } - if len(m.Sender) > 0 { - i -= len(m.Sender) - copy(dAtA[i:], m.Sender) - i = encodeVarintTx(dAtA, i, uint64(len(m.Sender))) - i-- - dAtA[i] = 0xa - } - return len(dAtA) - i, nil -} - -func (m *MsgExecuteLegacyContentsResponse) 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 *MsgExecuteLegacyContentsResponse) MarshalTo(dAtA []byte) (int, error) { - size := m.Size() - return m.MarshalToSizedBuffer(dAtA[:size]) -} - -func (m *MsgExecuteLegacyContentsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { - i := len(dAtA) - _ = i - var l int - _ = l - return len(dAtA) - i, nil -} - func (m *MsgFinalizeTokenDeposit) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) @@ -1747,34 +1554,6 @@ func (m *MsgExecuteMessagesResponse) Size() (n int) { return n } -func (m *MsgExecuteLegacyContents) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - l = len(m.Sender) - if l > 0 { - n += 1 + l + sovTx(uint64(l)) - } - if len(m.Contents) > 0 { - for _, e := range m.Contents { - l = e.Size() - n += 1 + l + sovTx(uint64(l)) - } - } - return n -} - -func (m *MsgExecuteLegacyContentsResponse) Size() (n int) { - if m == nil { - return 0 - } - var l int - _ = l - return n -} - func (m *MsgFinalizeTokenDeposit) Size() (n int) { if m == nil { return 0 @@ -2138,172 +1917,6 @@ func (m *MsgExecuteMessagesResponse) Unmarshal(dAtA []byte) error { } return nil } -func (m *MsgExecuteLegacyContents) 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: MsgExecuteLegacyContents: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: MsgExecuteLegacyContents: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Sender", 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.Sender = string(dAtA[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Contents", 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 - } - m.Contents = append(m.Contents, &types.Any{}) - if err := m.Contents[len(m.Contents)-1].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 *MsgExecuteLegacyContentsResponse) 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: MsgExecuteLegacyContentsResponse: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: MsgExecuteLegacyContentsResponse: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - default: - iNdEx = preIndex - skippy, err := skipTx(dAtA[iNdEx:]) - if err != nil { - return err - } - if (skippy < 0) || (iNdEx+skippy) < 0 { - return ErrInvalidLengthTx - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} func (m *MsgFinalizeTokenDeposit) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 diff --git a/x/ophost/keeper/common_test.go b/x/ophost/keeper/common_test.go index 160343df..936fd0f3 100644 --- a/x/ophost/keeper/common_test.go +++ b/x/ophost/keeper/common_test.go @@ -42,7 +42,6 @@ import ( govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" "github.com/cosmos/gogoproto/proto" - capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" ophost "github.com/initia-labs/OPinit/x/ophost" ophostkeeper "github.com/initia-labs/OPinit/x/ophost/keeper" @@ -226,7 +225,7 @@ func _createTestInput( for _, v := range keys { ms.MountStoreWithDB(v, storetypes.StoreTypeIAVL, db) } - memKeys := storetypes.NewMemoryStoreKeys(capabilitytypes.MemStoreKey) + memKeys := storetypes.NewMemoryStoreKeys() for _, v := range memKeys { ms.MountStoreWithDB(v, storetypes.StoreTypeMemory, db) }