From d2a6a59321830763485b84d7a6309cb4f0666ea4 Mon Sep 17 00:00:00 2001 From: kienn6034 Date: Mon, 20 May 2024 02:28:16 +0700 Subject: [PATCH] fix: register subspace ibc transfer --- Makefile | 4 ++-- app/keepers/keepers.go | 2 +- app/upgrades/v7_0_1/upgrade.go | 5 ++++- scripts/relayer_hyperspace/config-chain-b.toml | 4 ++-- scripts/upgrade/upgrade.sh | 4 ++-- 5 files changed, 11 insertions(+), 8 deletions(-) diff --git a/Makefile b/Makefile index ea146c8ce..e5ec23302 100644 --- a/Makefile +++ b/Makefile @@ -200,9 +200,9 @@ localnet-pica: bash ./scripts/run-node.sh picad bash ./scripts/50/store-wasm-code.sh -localnet-picasso: +localnet-parachain: @echo "Starting localnet" - bash ./scripts/relayer_hyperspace/run-picasso.sh + bash ./scripts/upgrade/setup-polkadot-node.sh relayer-create-clients: @echo "Starting relayer" diff --git a/app/keepers/keepers.go b/app/keepers/keepers.go index 1a4c7dd0c..4d5c1a9bb 100644 --- a/app/keepers/keepers.go +++ b/app/keepers/keepers.go @@ -566,7 +566,7 @@ func (appKeepers *AppKeepers) initParamsKeeper(appCodec codec.BinaryCodec, legac keyTable := ibcclienttypes.ParamKeyTable() keyTable.RegisterParamSet(&ibcconnectiontypes.Params{}) paramsKeeper.Subspace(ibcexported.ModuleName).WithKeyTable(keyTable) - paramsKeeper.Subspace(ibctransfertypes.ModuleName) + paramsKeeper.Subspace(ibctransfertypes.ModuleName).WithKeyTable(ibctransfertypes.ParamKeyTable()) paramsKeeper.Subspace(icacontrollertypes.SubModuleName).WithKeyTable(icacontrollertypes.ParamKeyTable()) paramsKeeper.Subspace(icahosttypes.SubModuleName).WithKeyTable(icahosttypes.ParamKeyTable()) diff --git a/app/upgrades/v7_0_1/upgrade.go b/app/upgrades/v7_0_1/upgrade.go index e608bab7b..7d86057d7 100644 --- a/app/upgrades/v7_0_1/upgrade.go +++ b/app/upgrades/v7_0_1/upgrade.go @@ -2,9 +2,10 @@ package v7_0_1 import ( "context" - upgradetypes "cosmossdk.io/x/upgrade/types" "encoding/hex" "fmt" + + upgradetypes "cosmossdk.io/x/upgrade/types" "github.com/cosmos/cosmos-sdk/runtime" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" @@ -53,6 +54,8 @@ func CreateUpgradeHandler( listCheckSum = append(listCheckSum, checksumStr) } + // Register SendEnabled for legacy subspace + checksum := types.Checksums{Checksums: listCheckSum} bz, err := codec.Marshal(&checksum) if err != nil { diff --git a/scripts/relayer_hyperspace/config-chain-b.toml b/scripts/relayer_hyperspace/config-chain-b.toml index 5fb4d827a..532aa4864 100644 --- a/scripts/relayer_hyperspace/config-chain-b.toml +++ b/scripts/relayer_hyperspace/config-chain-b.toml @@ -4,7 +4,7 @@ rpc_url = "http://127.0.0.1:26657/" grpc_url = "http://127.0.0.1:9090/" websocket_url = "ws://127.0.0.1:26657/websocket" chain_id = "centauri-dev" -client_id = "07-tendermint-2" +client_id = "07-tendermint-0" connection_id = "connection-0" account_prefix = "pica" fee_denom = "ppica" @@ -12,7 +12,7 @@ fee_amount = "9223372036854776" gas_limit = 9223372036854775806 store_prefix = "ibc" max_tx_size = 20000000 -wasm_checksum = "3e743bf804a60e5fd1dfab6c61bba0f2e76cda260edc66d6b7b10691fb5096c1" +wasm_code_id = "9d5056f2b551213094a03b788db80274445175bae78c8fede38bf25a2ddc84bc" channel_whitelist = [["channel-0", "transfer"], ["channel-0", "transfer"], ["channel-0", "transfer"]] mnemonic = "decorate bright ozone fork gallery riot bus exhaust worth way bone indoor calm squirrel merry zero scheme cotton until shop any excess stage laundry" skip_optional_client_updates = false diff --git a/scripts/upgrade/upgrade.sh b/scripts/upgrade/upgrade.sh index 000babe67..d071cfa5f 100755 --- a/scripts/upgrade/upgrade.sh +++ b/scripts/upgrade/upgrade.sh @@ -7,8 +7,8 @@ ROOT=$(pwd) DENOM=ppica CHAIN_ID=centauri-dev SOFTWARE_UPGRADE_NAME="v7_0_1" -ADDITIONAL_PRE_SCRIPTS="./scripts/upgrade/v_6_4_8/pre-script.sh" -ADDITIONAL_AFTER_SCRIPTS="./scripts/upgrade/v_6_4_8/post-script.sh" +ADDITIONAL_PRE_SCRIPTS="./scripts/upgrade/v_6_6_0/pre-script.sh" +ADDITIONAL_AFTER_SCRIPTS="./scripts/upgrade/v_6_6_0/post-script.sh" KEY="mykey" KEY1="mykey1"