From 51f52893f7756caca24bde34a97acb5e448dae99 Mon Sep 17 00:00:00 2001 From: hoon Date: Mon, 25 Mar 2024 15:02:29 +0900 Subject: [PATCH 1/6] move gen cmd to opinit --- cmd/minitiad/genvalidators.go | 120 ---------------------------------- cmd/minitiad/root.go | 4 +- 2 files changed, 3 insertions(+), 121 deletions(-) delete mode 100644 cmd/minitiad/genvalidators.go diff --git a/cmd/minitiad/genvalidators.go b/cmd/minitiad/genvalidators.go deleted file mode 100644 index df76e1c..0000000 --- a/cmd/minitiad/genvalidators.go +++ /dev/null @@ -1,120 +0,0 @@ -package main - -import ( - "encoding/json" - "fmt" - - "github.com/pkg/errors" - "github.com/spf13/cobra" - - "github.com/cosmos/cosmos-sdk/client" - "github.com/cosmos/cosmos-sdk/client/flags" - "github.com/cosmos/cosmos-sdk/server" - 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/genutil" - genutiltypes "github.com/cosmos/cosmos-sdk/x/genutil/types" - - "github.com/initia-labs/OPinit/x/opchild/client/cli" - opchildtypes "github.com/initia-labs/OPinit/x/opchild/types" -) - -// AddGenesisValidatorCmd builds the application's gentx command. -func AddGenesisValidatorCmd(mbm module.BasicManager, txEncCfg client.TxEncodingConfig, genBalIterator genutiltypes.GenesisBalancesIterator, defaultNodeHome string) *cobra.Command { - cmd := &cobra.Command{ - Use: "add-genesis-validator [key_name]", - Short: "Add a genesis validator", - Args: cobra.ExactArgs(1), - Long: fmt.Sprintf(`Add a genesis validator with the key in the Keyring referenced by a given name. - A Bech32 consensus pubkey may optionally be provided. - -Example: -$ %s add-genesis-validator my-key-name --home=/path/to/home/dir --keyring-backend=os --chain-id=test-chain-1 -`, version.AppName, - ), - RunE: func(cmd *cobra.Command, args []string) error { - serverCtx := server.GetServerContextFromCmd(cmd) - clientCtx, err := client.GetClientTxContext(cmd) - if err != nil { - return err - } - cdc := clientCtx.Codec - - config := serverCtx.Config - config.SetRoot(clientCtx.HomeDir) - - _ /*nodeId*/, valPubKey, err := genutil.InitializeNodeValidatorFiles(serverCtx.Config) - if err != nil { - return errors.Wrap(err, "failed to initialize node validator files") - } - - // read --pubkey, if empty take it from priv_validator.json - if pkStr, _ := cmd.Flags().GetString(cli.FlagPubKey); pkStr != "" { - if err := clientCtx.Codec.UnmarshalInterfaceJSON([]byte(pkStr), &valPubKey); err != nil { - return errors.Wrap(err, "failed to unmarshal validator public key") - } - } - - name := args[0] - key, err := clientCtx.Keyring.Key(name) - if err != nil { - return errors.Wrapf(err, "failed to fetch '%s' from the keyring", name) - } - - moniker := config.Moniker - if m, _ := cmd.Flags().GetString(cli.FlagMoniker); m != "" { - moniker = m - } - - addr, err := key.GetAddress() - if err != nil { - return err - } - valAddr := sdk.ValAddress(addr) - - validator, err := opchildtypes.NewValidator(valAddr, valPubKey, moniker) - if err != nil { - return err - } - - genFile := config.GenesisFile() - appState, genDoc, err := genutiltypes.GenesisStateFromGenFile(genFile) - if err != nil { - return fmt.Errorf("failed to unmarshal genesis state: %w", err) - } - - opchildState := opchildtypes.GetGenesisStateFromAppState(cdc, appState) - opchildState.Validators = append((*opchildState).Validators, validator) - if opchildState.Params.BridgeExecutor == "" { - opchildState.Params.BridgeExecutor = addr.String() - } - - opchildGenStateBz, err := cdc.MarshalJSON(opchildState) - if err != nil { - return fmt.Errorf("failed to marshal opchild genesis state: %w", err) - } - appState[opchildtypes.ModuleName] = opchildGenStateBz - - if err = mbm.ValidateGenesis(cdc, txEncCfg, appState); err != nil { - return errors.Wrap(err, "failed to validate genesis state") - } - appStateJSON, err := json.Marshal(appState) - if err != nil { - return fmt.Errorf("failed to marshal application genesis state: %w", err) - } - - genDoc.AppState = appStateJSON - if err = genutil.ExportGenesisFile(genDoc, config.GenesisFile()); err != nil { - return errors.Wrap(err, "Failed to export genesis file") - } - - return nil - }, - } - - cmd.Flags().String(flags.FlagHome, defaultNodeHome, "The application home directory") - flags.AddTxFlagsToCmd(cmd) - - return cmd -} diff --git a/cmd/minitiad/root.go b/cmd/minitiad/root.go index 8d0d1ee..908d022 100644 --- a/cmd/minitiad/root.go +++ b/cmd/minitiad/root.go @@ -43,6 +43,8 @@ import ( "github.com/initia-labs/initia/app/params" minitiaapp "github.com/initia-labs/miniwasm/app" + + opchildcli "github.com/initia-labs/OPinit/x/opchild/client/cli" ) // NewRootCmd creates a new root command for initiad. It is called once in the @@ -183,7 +185,7 @@ func genesisCommand(encodingConfig params.EncodingConfig, basicManager module.Ba cmd.AddCommand( genutilcli.AddGenesisAccountCmd(minitiaapp.DefaultNodeHome, ac), - AddGenesisValidatorCmd(basicManager, encodingConfig.TxConfig, banktypes.GenesisBalancesIterator{}, minitiaapp.DefaultNodeHome), + opchildcli.AddGenesisValidatorCmd(basicManager, encodingConfig.TxConfig, banktypes.GenesisBalancesIterator{}, minitiaapp.DefaultNodeHome), genutilcli.ValidateGenesisCmd(basicManager), genutilcli.GenTxCmd(basicManager, encodingConfig.TxConfig, banktypes.GenesisBalancesIterator{}, minitiaapp.DefaultNodeHome, ac), ) From c67ab01a680bd15f00f2eed229bccf20d2080c34 Mon Sep 17 00:00:00 2001 From: hoon Date: Tue, 26 Mar 2024 19:56:50 +0900 Subject: [PATCH 2/6] add sample RegisterExecutorChangePlans --- app/app.go | 3 +++ app/executor_change.go | 20 ++++++++++++++++++++ 2 files changed, 23 insertions(+) create mode 100644 app/executor_change.go diff --git a/app/app.go b/app/app.go index 78e94ea..b66c0ff 100644 --- a/app/app.go +++ b/app/app.go @@ -376,10 +376,13 @@ func NewMinitiaApp( apphook.NewWasmBridgeHook(ac, app.WasmKeeper).Hook, app.MsgServiceRouter(), authorityAddr, + ac, vc, cc, ) + app.RegisterExecutorChangePlans() + // get skipUpgradeHeights from the app options skipUpgradeHeights := map[int64]bool{} for _, h := range cast.ToIntSlice(appOpts.Get(server.FlagUnsafeSkipUpgrades)) { diff --git a/app/executor_change.go b/app/executor_change.go new file mode 100644 index 0000000..601c547 --- /dev/null +++ b/app/executor_change.go @@ -0,0 +1,20 @@ +package app + +// Executor change plans + +func (app *MinitiaApp) RegisterExecutorChangePlans() error { + // err := app.OPChildKeeper.RegisterExecutorChangePlan( + // 1, + // 153, + // "init158x0dpu5f4x703fhtseg5kpytsj02hw0p9ahpm", + // "op2", + // "GTJEksmVK7gkzPXdj+YIJxipfJ+yYUlc6jzIuh9s2t0=", + // "testestestestsetsetestsetest", + // ) + + // if err != nil { + // return err + // } + + return nil +} From c588c633ed3c67962a9a92f3dc49ec1f242f448d Mon Sep 17 00:00:00 2001 From: hoon Date: Fri, 29 Mar 2024 16:14:04 +0900 Subject: [PATCH 3/6] update go mod --- go.mod | 9 +++++---- go.sum | 16 ++++++++++------ 2 files changed, 15 insertions(+), 10 deletions(-) diff --git a/go.mod b/go.mod index 82a4730..f5226b6 100644 --- a/go.mod +++ b/go.mod @@ -32,8 +32,8 @@ require ( github.com/golang/protobuf v1.5.4 github.com/gorilla/mux v1.8.1 github.com/grpc-ecosystem/grpc-gateway v1.16.0 - github.com/initia-labs/OPinit v0.2.2 - github.com/initia-labs/initia v0.2.3 + github.com/initia-labs/OPinit v0.2.2-0.20240326110012-c9784a2d7baa + github.com/initia-labs/initia v0.2.2 github.com/pkg/errors v0.9.1 github.com/prometheus/client_golang v1.18.0 github.com/rakyll/statik v0.1.7 @@ -69,6 +69,7 @@ require ( github.com/bgentry/speakeasy v0.1.1-0.20220910012023-760eaf8b6816 // indirect github.com/bits-and-blooms/bitset v1.13.0 // indirect github.com/btcsuite/btcd/btcec/v2 v2.3.2 // indirect + github.com/celestiaorg/go-square v1.0.1 // indirect github.com/cenkalti/backoff/v4 v4.2.1 // indirect github.com/cespare/xxhash v1.1.0 // indirect github.com/cespare/xxhash/v2 v2.2.0 // indirect @@ -141,6 +142,7 @@ require ( github.com/iancoleman/strcase v0.3.0 // indirect github.com/improbable-eng/grpc-web v0.15.0 // indirect github.com/inconshreveable/mousetrap v1.1.0 // indirect + github.com/initia-labs/OPinit/api v0.0.0-20240326110012-c9784a2d7baa // indirect github.com/jmespath/go-jmespath v0.4.0 // indirect github.com/jmhodges/levigo v1.0.0 // indirect github.com/klauspost/compress v1.17.7 // indirect @@ -217,8 +219,8 @@ require ( replace ( // use cosmos fork of keyring github.com/99designs/keyring => github.com/cosmos/keyring v1.2.0 + github.com/cometbft/cometbft => github.com/initia-labs/cometbft v0.0.0-20240329070743-a3d01c08e362 - github.com/cometbft/cometbft => github.com/initia-labs/cometbft v0.0.0-20240104081544-34081fc84daf github.com/cosmos/cosmos-sdk => github.com/initia-labs/cosmos-sdk v0.0.0-20240313050640-ff14560eeb21 github.com/cosmos/iavl => github.com/initia-labs/iavl v0.0.0-20240208034922-5d81c449d4c0 @@ -233,7 +235,6 @@ replace ( github.com/gin-gonic/gin => github.com/gin-gonic/gin v1.9.1 github.com/gogo/protobuf => github.com/regen-network/protobuf v1.3.3-alpha.regen.1 - // Downgraded to avoid bugs in following commits which caused simulations to fail. github.com/syndtr/goleveldb => github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 ) diff --git a/go.sum b/go.sum index a603849..61c90a8 100644 --- a/go.sum +++ b/go.sum @@ -296,6 +296,8 @@ github.com/bytedance/sonic v1.5.0/go.mod h1:ED5hyg4y6t3/9Ku1R6dU/4KyJ48DZ4jPhfY1 github.com/bytedance/sonic v1.9.1 h1:6iJ6NqdoxCDr6mbY8h18oSO+cShGSMRGCEo7F2h0x8s= github.com/bytedance/sonic v1.9.1/go.mod h1:i736AoUSYt75HyZLoJW9ERYxcy6eaN6h4BZXU064P/U= github.com/casbin/casbin/v2 v2.1.2/go.mod h1:YcPU1XXisHhLzuxH9coDNf2FbKpjGlbCg3n9yuLkIJQ= +github.com/celestiaorg/go-square v1.0.1 h1:LEG1zrw4i03VBMElQF8GAbKYgh1bT1uGzWxasU2ePuo= +github.com/celestiaorg/go-square v1.0.1/go.mod h1:XMv5SGCeGSkynW2OOsedugaW/rQlvzxGzWGxTKsyYOU= 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= @@ -728,16 +730,18 @@ github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANyt 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/influxdb1-client v0.0.0-20191209144304-8bf82d3c094d/go.mod h1:qj24IKcXYK6Iy9ceXlo3Tc+vtHo9lIhSX5JddghvEPo= -github.com/initia-labs/OPinit v0.2.2 h1:lcBQCQcn7zgkpQaKqIfNLaj15Dy6qSDYv62/XJ1iISE= -github.com/initia-labs/OPinit v0.2.2/go.mod h1:1dn1iseG1S4wfXUtnb4mUkraJdL9/lWBQPpI+HbVzL0= -github.com/initia-labs/cometbft v0.0.0-20240104081544-34081fc84daf h1:7k3u0huB7OpiDfQKnfcwKUvByl7HyYs3itgROO/YpFg= -github.com/initia-labs/cometbft v0.0.0-20240104081544-34081fc84daf/go.mod h1:PIi48BpzwlHqtV3mzwPyQgOyOnU94BNBimLS2ebBHOg= +github.com/initia-labs/OPinit v0.2.2-0.20240326110012-c9784a2d7baa h1:G9Kv6aPj1OL7TslFxuA0jm6KN0D3amXvyUMYdJIJiSA= +github.com/initia-labs/OPinit v0.2.2-0.20240326110012-c9784a2d7baa/go.mod h1:1dn1iseG1S4wfXUtnb4mUkraJdL9/lWBQPpI+HbVzL0= +github.com/initia-labs/OPinit/api v0.0.0-20240326110012-c9784a2d7baa h1:KX1T38Rtxda2OHgeMTNxvlEr3zEpOMkJKhIoS8EZL/0= +github.com/initia-labs/OPinit/api v0.0.0-20240326110012-c9784a2d7baa/go.mod h1:ASCaZChzhQenOxDLIBicEgi5drhMV3YjPxzV29nGvwM= +github.com/initia-labs/cometbft v0.0.0-20240329070743-a3d01c08e362 h1:Q4I+AsOW0W2HvCRkQm146N2/vUXAr0DBflTb5mKcYsQ= +github.com/initia-labs/cometbft v0.0.0-20240329070743-a3d01c08e362/go.mod h1:ZMli4+rR21WUDz8NKoULmJttTi76s5Jg7LS0AJPenlc= github.com/initia-labs/cosmos-sdk v0.0.0-20240313050640-ff14560eeb21 h1:AwqnO5IR+3LWzjqR33MzOkce38ExWLtQwlqrLZVrMyw= github.com/initia-labs/cosmos-sdk v0.0.0-20240313050640-ff14560eeb21/go.mod h1:oV/k6GJgXV9QPoM2fsYDPPsyPBgQbdotv532O6Mz1OQ= github.com/initia-labs/iavl v0.0.0-20240208034922-5d81c449d4c0 h1:GQ7/UD5mB6q104roqZK5jxb6ff9sBk0/uwFxgERQIaU= github.com/initia-labs/iavl v0.0.0-20240208034922-5d81c449d4c0/go.mod h1:CmTGqMnRnucjxbjduneZXT+0vPgNElYvdefjX2q9tYc= -github.com/initia-labs/initia v0.2.3 h1:btg3UoX6oy7LOcsy03rZaYmxDk5RvOyBY+hQ4EtuxUg= -github.com/initia-labs/initia v0.2.3/go.mod h1:xLkPASIv+6EuE7BHCxB3ag2K9+rUwJ/6AC5fkYmSejw= +github.com/initia-labs/initia v0.2.2 h1:qbHs7TO9coC2iEMBKbmF5JoosbiGvs/TIve6nWOCQyE= +github.com/initia-labs/initia v0.2.2/go.mod h1:oSWtBjAI9hA8umlp1patsSzqlUL4aSymwRnC+WxHhQA= github.com/initia-labs/movevm v0.2.2 h1:T0FwprEEDWhNfPREthNDvRr+IGg9N7eQg+zXvT8V/U4= github.com/initia-labs/movevm v0.2.2/go.mod h1:1EyJ06+Hn43MfaXZ+30a2gmhS5zjqiFF8oSF5CHai28= github.com/jhump/protoreflect v1.15.3 h1:6SFRuqU45u9hIZPJAoZ8c28T3nK64BNdp9w6jFonzls= From 2ad9a7e9a5a82da1dfe29512031e512c1dece497 Mon Sep 17 00:00:00 2001 From: hoon Date: Wed, 3 Apr 2024 18:25:28 +0900 Subject: [PATCH 4/6] update recent comet & panic error when RegisterExecutorChangePlans incorrectly set --- app/app.go | 5 ++++- app/executor_change.go | 23 ++++++++++++----------- go.mod | 6 +++--- go.sum | 12 ++++++------ 4 files changed, 25 insertions(+), 21 deletions(-) diff --git a/app/app.go b/app/app.go index b66c0ff..321c50f 100644 --- a/app/app.go +++ b/app/app.go @@ -381,7 +381,10 @@ func NewMinitiaApp( cc, ) - app.RegisterExecutorChangePlans() + err = app.RegisterExecutorChangePlans() + if err != nil { + panic(err) + } // get skipUpgradeHeights from the app options skipUpgradeHeights := map[int64]bool{} diff --git a/app/executor_change.go b/app/executor_change.go index 601c547..bf8cac9 100644 --- a/app/executor_change.go +++ b/app/executor_change.go @@ -3,18 +3,19 @@ package app // Executor change plans func (app *MinitiaApp) RegisterExecutorChangePlans() error { - // err := app.OPChildKeeper.RegisterExecutorChangePlan( - // 1, - // 153, - // "init158x0dpu5f4x703fhtseg5kpytsj02hw0p9ahpm", - // "op2", - // "GTJEksmVK7gkzPXdj+YIJxipfJ+yYUlc6jzIuh9s2t0=", - // "testestestestsetsetestsetest", - // ) + err := app.OPChildKeeper.RegisterExecutorChangePlan( + 1, + 361, + "initvaloper158x0dpu5f4x703fhtseg5kpytsj02hw04qyw0t", + "init158x0dpu5f4x703fhtseg5kpytsj02hw0p9ahpm", + "op2", + "{\"@type\":\"/cosmos.crypto.ed25519.PubKey\",\"key\":\"GTJEksmVK7gkzPXdj+YIJxipfJ+yYUlc6jzIuh9s2t0=\"}", + "testestestestsetsetestsetest", + ) - // if err != nil { - // return err - // } + if err != nil { + return err + } return nil } diff --git a/go.mod b/go.mod index f5226b6..a66c8ef 100644 --- a/go.mod +++ b/go.mod @@ -32,7 +32,7 @@ require ( github.com/golang/protobuf v1.5.4 github.com/gorilla/mux v1.8.1 github.com/grpc-ecosystem/grpc-gateway v1.16.0 - github.com/initia-labs/OPinit v0.2.2-0.20240326110012-c9784a2d7baa + github.com/initia-labs/OPinit v0.2.2-0.20240403083804-4822c74aaf44 github.com/initia-labs/initia v0.2.2 github.com/pkg/errors v0.9.1 github.com/prometheus/client_golang v1.18.0 @@ -142,7 +142,7 @@ require ( github.com/iancoleman/strcase v0.3.0 // indirect github.com/improbable-eng/grpc-web v0.15.0 // indirect github.com/inconshreveable/mousetrap v1.1.0 // indirect - github.com/initia-labs/OPinit/api v0.0.0-20240326110012-c9784a2d7baa // indirect + github.com/initia-labs/OPinit/api v0.0.0-20240403083804-4822c74aaf44 // indirect github.com/jmespath/go-jmespath v0.4.0 // indirect github.com/jmhodges/levigo v1.0.0 // indirect github.com/klauspost/compress v1.17.7 // indirect @@ -219,7 +219,7 @@ require ( replace ( // use cosmos fork of keyring github.com/99designs/keyring => github.com/cosmos/keyring v1.2.0 - github.com/cometbft/cometbft => github.com/initia-labs/cometbft v0.0.0-20240329070743-a3d01c08e362 + github.com/cometbft/cometbft => github.com/initia-labs/cometbft v0.0.0-20240403092330-f3837726ba40 github.com/cosmos/cosmos-sdk => github.com/initia-labs/cosmos-sdk v0.0.0-20240313050640-ff14560eeb21 diff --git a/go.sum b/go.sum index 61c90a8..842fefe 100644 --- a/go.sum +++ b/go.sum @@ -730,12 +730,12 @@ github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANyt 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/influxdb1-client v0.0.0-20191209144304-8bf82d3c094d/go.mod h1:qj24IKcXYK6Iy9ceXlo3Tc+vtHo9lIhSX5JddghvEPo= -github.com/initia-labs/OPinit v0.2.2-0.20240326110012-c9784a2d7baa h1:G9Kv6aPj1OL7TslFxuA0jm6KN0D3amXvyUMYdJIJiSA= -github.com/initia-labs/OPinit v0.2.2-0.20240326110012-c9784a2d7baa/go.mod h1:1dn1iseG1S4wfXUtnb4mUkraJdL9/lWBQPpI+HbVzL0= -github.com/initia-labs/OPinit/api v0.0.0-20240326110012-c9784a2d7baa h1:KX1T38Rtxda2OHgeMTNxvlEr3zEpOMkJKhIoS8EZL/0= -github.com/initia-labs/OPinit/api v0.0.0-20240326110012-c9784a2d7baa/go.mod h1:ASCaZChzhQenOxDLIBicEgi5drhMV3YjPxzV29nGvwM= -github.com/initia-labs/cometbft v0.0.0-20240329070743-a3d01c08e362 h1:Q4I+AsOW0W2HvCRkQm146N2/vUXAr0DBflTb5mKcYsQ= -github.com/initia-labs/cometbft v0.0.0-20240329070743-a3d01c08e362/go.mod h1:ZMli4+rR21WUDz8NKoULmJttTi76s5Jg7LS0AJPenlc= +github.com/initia-labs/OPinit v0.2.2-0.20240403083804-4822c74aaf44 h1:yCWTpgZ6OBkFsnGRV46mGCAd3lPpLAKgdcg4r+mayEg= +github.com/initia-labs/OPinit v0.2.2-0.20240403083804-4822c74aaf44/go.mod h1:1dn1iseG1S4wfXUtnb4mUkraJdL9/lWBQPpI+HbVzL0= +github.com/initia-labs/OPinit/api v0.0.0-20240403083804-4822c74aaf44 h1:F3ZfAGt1Wa+PIUD5p039eY90eiAWBzk6lHQoy8iqz+4= +github.com/initia-labs/OPinit/api v0.0.0-20240403083804-4822c74aaf44/go.mod h1:ASCaZChzhQenOxDLIBicEgi5drhMV3YjPxzV29nGvwM= +github.com/initia-labs/cometbft v0.0.0-20240403092330-f3837726ba40 h1:qZP7RKmIdO/cRtorFxaIob5h/0NP3sfm8UVTGN0JSQw= +github.com/initia-labs/cometbft v0.0.0-20240403092330-f3837726ba40/go.mod h1:U88FpkeAJiOV0IL+8ZtBhfvWXUcV31dHgMEKKwVEHos= github.com/initia-labs/cosmos-sdk v0.0.0-20240313050640-ff14560eeb21 h1:AwqnO5IR+3LWzjqR33MzOkce38ExWLtQwlqrLZVrMyw= github.com/initia-labs/cosmos-sdk v0.0.0-20240313050640-ff14560eeb21/go.mod h1:oV/k6GJgXV9QPoM2fsYDPPsyPBgQbdotv532O6Mz1OQ= github.com/initia-labs/iavl v0.0.0-20240208034922-5d81c449d4c0 h1:GQ7/UD5mB6q104roqZK5jxb6ff9sBk0/uwFxgERQIaU= From 284a633a91ae3ea3d277cd844911451f5b50e77c Mon Sep 17 00:00:00 2001 From: hoon Date: Thu, 4 Apr 2024 18:17:44 +0900 Subject: [PATCH 5/6] update recent opinit cometbft version --- go.mod | 6 +++--- go.sum | 12 ++++++------ 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/go.mod b/go.mod index a66c8ef..9706469 100644 --- a/go.mod +++ b/go.mod @@ -32,7 +32,7 @@ require ( github.com/golang/protobuf v1.5.4 github.com/gorilla/mux v1.8.1 github.com/grpc-ecosystem/grpc-gateway v1.16.0 - github.com/initia-labs/OPinit v0.2.2-0.20240403083804-4822c74aaf44 + github.com/initia-labs/OPinit v0.2.3-0.20240404023002-8608273959a8 github.com/initia-labs/initia v0.2.2 github.com/pkg/errors v0.9.1 github.com/prometheus/client_golang v1.18.0 @@ -142,7 +142,7 @@ require ( github.com/iancoleman/strcase v0.3.0 // indirect github.com/improbable-eng/grpc-web v0.15.0 // indirect github.com/inconshreveable/mousetrap v1.1.0 // indirect - github.com/initia-labs/OPinit/api v0.0.0-20240403083804-4822c74aaf44 // indirect + github.com/initia-labs/OPinit/api v0.0.0-20240404023002-8608273959a8 // indirect github.com/jmespath/go-jmespath v0.4.0 // indirect github.com/jmhodges/levigo v1.0.0 // indirect github.com/klauspost/compress v1.17.7 // indirect @@ -219,7 +219,7 @@ require ( replace ( // use cosmos fork of keyring github.com/99designs/keyring => github.com/cosmos/keyring v1.2.0 - github.com/cometbft/cometbft => github.com/initia-labs/cometbft v0.0.0-20240403092330-f3837726ba40 + github.com/cometbft/cometbft => github.com/initia-labs/cometbft v0.0.0-20240404091408-238cddd887d3 github.com/cosmos/cosmos-sdk => github.com/initia-labs/cosmos-sdk v0.0.0-20240313050640-ff14560eeb21 diff --git a/go.sum b/go.sum index 842fefe..1605f62 100644 --- a/go.sum +++ b/go.sum @@ -730,12 +730,12 @@ github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANyt 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/influxdb1-client v0.0.0-20191209144304-8bf82d3c094d/go.mod h1:qj24IKcXYK6Iy9ceXlo3Tc+vtHo9lIhSX5JddghvEPo= -github.com/initia-labs/OPinit v0.2.2-0.20240403083804-4822c74aaf44 h1:yCWTpgZ6OBkFsnGRV46mGCAd3lPpLAKgdcg4r+mayEg= -github.com/initia-labs/OPinit v0.2.2-0.20240403083804-4822c74aaf44/go.mod h1:1dn1iseG1S4wfXUtnb4mUkraJdL9/lWBQPpI+HbVzL0= -github.com/initia-labs/OPinit/api v0.0.0-20240403083804-4822c74aaf44 h1:F3ZfAGt1Wa+PIUD5p039eY90eiAWBzk6lHQoy8iqz+4= -github.com/initia-labs/OPinit/api v0.0.0-20240403083804-4822c74aaf44/go.mod h1:ASCaZChzhQenOxDLIBicEgi5drhMV3YjPxzV29nGvwM= -github.com/initia-labs/cometbft v0.0.0-20240403092330-f3837726ba40 h1:qZP7RKmIdO/cRtorFxaIob5h/0NP3sfm8UVTGN0JSQw= -github.com/initia-labs/cometbft v0.0.0-20240403092330-f3837726ba40/go.mod h1:U88FpkeAJiOV0IL+8ZtBhfvWXUcV31dHgMEKKwVEHos= +github.com/initia-labs/OPinit v0.2.3-0.20240404023002-8608273959a8 h1:d4Wz4h9q/Kc+tmwP+S6Ra1aCTJKUDb0g2w2V5Z5uFuM= +github.com/initia-labs/OPinit v0.2.3-0.20240404023002-8608273959a8/go.mod h1:1dn1iseG1S4wfXUtnb4mUkraJdL9/lWBQPpI+HbVzL0= +github.com/initia-labs/OPinit/api v0.0.0-20240404023002-8608273959a8 h1:Wk/SJ6RCGA34Sr0i0t+pXL+cVreaptuuHFuWDO9KVu4= +github.com/initia-labs/OPinit/api v0.0.0-20240404023002-8608273959a8/go.mod h1:ASCaZChzhQenOxDLIBicEgi5drhMV3YjPxzV29nGvwM= +github.com/initia-labs/cometbft v0.0.0-20240404091408-238cddd887d3 h1:IX3182+BZ8ksVtAdIlU9ub01dmSAM9lvjHuUz9GWzjc= +github.com/initia-labs/cometbft v0.0.0-20240404091408-238cddd887d3/go.mod h1:qv+nhSohSXLgU45IxHDGM5x4+bG4khsqqyn+e0iEbfo= github.com/initia-labs/cosmos-sdk v0.0.0-20240313050640-ff14560eeb21 h1:AwqnO5IR+3LWzjqR33MzOkce38ExWLtQwlqrLZVrMyw= github.com/initia-labs/cosmos-sdk v0.0.0-20240313050640-ff14560eeb21/go.mod h1:oV/k6GJgXV9QPoM2fsYDPPsyPBgQbdotv532O6Mz1OQ= github.com/initia-labs/iavl v0.0.0-20240208034922-5d81c449d4c0 h1:GQ7/UD5mB6q104roqZK5jxb6ff9sBk0/uwFxgERQIaU= From f941875f08c6e249154f57191b91e505a401e427 Mon Sep 17 00:00:00 2001 From: hoon Date: Thu, 4 Apr 2024 18:27:29 +0900 Subject: [PATCH 6/6] comment out executor change plan --- app/executor_change.go | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/app/executor_change.go b/app/executor_change.go index bf8cac9..780378e 100644 --- a/app/executor_change.go +++ b/app/executor_change.go @@ -3,19 +3,19 @@ package app // Executor change plans func (app *MinitiaApp) RegisterExecutorChangePlans() error { - err := app.OPChildKeeper.RegisterExecutorChangePlan( - 1, - 361, - "initvaloper158x0dpu5f4x703fhtseg5kpytsj02hw04qyw0t", - "init158x0dpu5f4x703fhtseg5kpytsj02hw0p9ahpm", - "op2", - "{\"@type\":\"/cosmos.crypto.ed25519.PubKey\",\"key\":\"GTJEksmVK7gkzPXdj+YIJxipfJ+yYUlc6jzIuh9s2t0=\"}", - "testestestestsetsetestsetest", - ) + // err := app.OPChildKeeper.RegisterExecutorChangePlan( + // 1, + // 361, + // "initvaloper158x0dpu5f4x703fhtseg5kpytsj02hw04qyw0t", + // "init158x0dpu5f4x703fhtseg5kpytsj02hw0p9ahpm", + // "op2", + // "{\"@type\":\"/cosmos.crypto.ed25519.PubKey\",\"key\":\"GTJEksmVK7gkzPXdj+YIJxipfJ+yYUlc6jzIuh9s2t0=\"}", + // "testestestestsetsetestsetest", + // ) - if err != nil { - return err - } + // if err != nil { + // return err + // } return nil }