From be1abe294a50448f78a0360081bd21a39540000f Mon Sep 17 00:00:00 2001 From: Carlton N Hanna Date: Wed, 1 Nov 2023 14:38:29 -0600 Subject: [PATCH 01/11] cast client state to 07-tendermint obj, fail to unknown --- x/ibchooks/marker_hooks.go | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/x/ibchooks/marker_hooks.go b/x/ibchooks/marker_hooks.go index 7dd9fb33af..9c3eb53fe2 100644 --- a/x/ibchooks/marker_hooks.go +++ b/x/ibchooks/marker_hooks.go @@ -139,11 +139,9 @@ func (h MarkerHooks) GetChainID(ctx sdktypes.Context, packet exported.PacketI, i if !found { return chainID } - if clientState.ClientType() == "07-tendermint" { - tmClientState, ok := clientState.(*tendermintclient.ClientState) - if ok { - chainID = tmClientState.ChainId - } + tmClientState, ok := clientState.(*tendermintclient.ClientState) + if ok { + chainID = tmClientState.ChainId } return chainID } From 64590ce7e1671f4a67eb0e12274dfff92d63a38b Mon Sep 17 00:00:00 2001 From: Carlton N Hanna Date: Wed, 1 Nov 2023 14:41:12 -0600 Subject: [PATCH 02/11] return chainid instead of assign --- x/ibchooks/marker_hooks.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/x/ibchooks/marker_hooks.go b/x/ibchooks/marker_hooks.go index 9c3eb53fe2..fc527dd35c 100644 --- a/x/ibchooks/marker_hooks.go +++ b/x/ibchooks/marker_hooks.go @@ -141,7 +141,7 @@ func (h MarkerHooks) GetChainID(ctx sdktypes.Context, packet exported.PacketI, i } tmClientState, ok := clientState.(*tendermintclient.ClientState) if ok { - chainID = tmClientState.ChainId + return tmClientState.ChainId } return chainID } From e485fec3ee1562cb12fd99f8ce5d7e6bcc6c3f0e Mon Sep 17 00:00:00 2001 From: Carlton N Hanna Date: Wed, 1 Nov 2023 14:47:28 -0600 Subject: [PATCH 03/11] update comment --- x/ibchooks/marker_hooks.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/x/ibchooks/marker_hooks.go b/x/ibchooks/marker_hooks.go index fc527dd35c..660d199068 100644 --- a/x/ibchooks/marker_hooks.go +++ b/x/ibchooks/marker_hooks.go @@ -124,7 +124,7 @@ func (h MarkerHooks) addDenomMetaData(ctx sdktypes.Context, packet exported.Pack return h.MarkerKeeper.SetDenomMetaData(ctx, markerMetadata, authtypes.NewModuleAddress(types.ModuleName)) } -// GetChainID returns the source chain id from packet for `07-tendermint` client connection or returns `unknown` +// GetChainID returns the source chain id from packet for a `07-tendermint` client connection or returns `unknown` func (h MarkerHooks) GetChainID(ctx sdktypes.Context, packet exported.PacketI, ibcKeeper *ibckeeper.Keeper) string { chainID := "unknown" channel, found := ibcKeeper.ChannelKeeper.GetChannel(ctx, packet.GetSourcePort(), packet.GetSourceChannel()) From 67f9e745d90a57f423b9cd0bf559855345390d1f Mon Sep 17 00:00:00 2001 From: Carlton N Hanna Date: Wed, 1 Nov 2023 15:40:34 -0600 Subject: [PATCH 04/11] change GetChainID method signature, add upgrade handler for creating denom metadata --- app/upgrades.go | 44 +++++++++++++++++++++++++++++++++++++- x/ibchooks/marker_hooks.go | 6 +++--- 2 files changed, 46 insertions(+), 4 deletions(-) diff --git a/app/upgrades.go b/app/upgrades.go index f1464af68c..12e992b958 100644 --- a/app/upgrades.go +++ b/app/upgrades.go @@ -2,6 +2,7 @@ package app import ( "fmt" + "strings" icqtypes "github.com/strangelove-ventures/async-icq/v6/types" @@ -11,15 +12,19 @@ import ( storetypes "github.com/cosmos/cosmos-sdk/store/types" 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" govtypesv1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1" govtypesv1beta1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1" upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types" + transfertypes "github.com/cosmos/ibc-go/v6/modules/apps/transfer/types" attributekeeper "github.com/provenance-io/provenance/x/attribute/keeper" attributetypes "github.com/provenance-io/provenance/x/attribute/types" "github.com/provenance-io/provenance/x/exchange" "github.com/provenance-io/provenance/x/hold" ibchookstypes "github.com/provenance-io/provenance/x/ibchooks/types" + "github.com/provenance-io/provenance/x/marker/types" msgfeetypes "github.com/provenance-io/provenance/x/msgfees/types" oracletypes "github.com/provenance-io/provenance/x/oracle/types" triggertypes "github.com/provenance-io/provenance/x/trigger/types" @@ -120,7 +125,19 @@ var upgrades = map[string]appUpgrade{ }, Added: []string{icqtypes.ModuleName, oracletypes.ModuleName, ibchookstypes.StoreKey, hold.ModuleName, exchange.ModuleName}, }, - "saffron-rc2": {}, // upgrade for v1.17.0-rc2 + "saffron-rc2": { + Handler: func(ctx sdk.Context, app *App, vm module.VersionMap) (module.VersionMap, error) { + var err error + vm, err = runModuleMigrations(ctx, app, vm) + if err != nil { + return nil, err + } + + updateIbcMarkerDenomMetadata(ctx, app) + + return vm, nil + }, + }, // upgrade for v1.17.0-rc2 "saffron": { // upgrade for v1.17.0, Handler: func(ctx sdk.Context, app *App, vm module.VersionMap) (module.VersionMap, error) { var err error @@ -361,3 +378,28 @@ func setExchangeParams(ctx sdk.Context, app *App) { } ctx.Logger().Info("Done ensuring exchange module params are set.") } + +// updateIbcMarkerDenomMetadata iterates markers and creates denom metadata for ibc markers +// TODO: Remove with the saffron handlers. +func updateIbcMarkerDenomMetadata(ctx sdk.Context, app *App) { + app.MarkerKeeper.IterateMarkers(ctx, func(record types.MarkerAccountI) bool { + if strings.HasSuffix(record.GetDenom(), "ibc/") { + denomTrace := transfertypes.ParseDenomTrace(record.GetDenom()) + parts := strings.Split(denomTrace.Path, "/") + if len(parts) == 2 && parts[0] == "transfer" { + chainID := app.Ics20MarkerHooks.GetChainID(ctx, parts[0], parts[1], app.IBCKeeper) + markerMetadata := banktypes.Metadata{ + Base: record.GetDenom(), + Name: chainID + "/" + record.GetDenom(), + Display: chainID + "/" + record.GetDenom(), + Description: record.GetDenom() + " from chain " + chainID, + } + err := app.MarkerKeeper.SetDenomMetaData(ctx, markerMetadata, authtypes.NewModuleAddress(types.ModuleName)) + if err != nil { + panic(fmt.Sprintf("unable to set denom metadata for %v on chain-id %v: %v", record.GetDenom(), chainID, err)) + } + } + } + return false + }) +} diff --git a/x/ibchooks/marker_hooks.go b/x/ibchooks/marker_hooks.go index 660d199068..95d8069b31 100644 --- a/x/ibchooks/marker_hooks.go +++ b/x/ibchooks/marker_hooks.go @@ -114,7 +114,7 @@ func (h MarkerHooks) getExistingSupply(ctx sdktypes.Context, marker *markertypes // addDenomMetaData adds denom metadata for ibc token func (h MarkerHooks) addDenomMetaData(ctx sdktypes.Context, packet exported.PacketI, ibcKeeper *ibckeeper.Keeper, ibcDenom string, data transfertypes.FungibleTokenPacketData) error { - chainID := h.GetChainID(ctx, packet, ibcKeeper) + chainID := h.GetChainID(ctx, packet.GetSourcePort(), packet.GetSourceChannel(), ibcKeeper) markerMetadata := banktypes.Metadata{ Base: ibcDenom, Name: chainID + "/" + data.Denom, @@ -125,9 +125,9 @@ func (h MarkerHooks) addDenomMetaData(ctx sdktypes.Context, packet exported.Pack } // GetChainID returns the source chain id from packet for a `07-tendermint` client connection or returns `unknown` -func (h MarkerHooks) GetChainID(ctx sdktypes.Context, packet exported.PacketI, ibcKeeper *ibckeeper.Keeper) string { +func (h MarkerHooks) GetChainID(ctx sdktypes.Context, sourcePort, sourceChannel string, ibcKeeper *ibckeeper.Keeper) string { chainID := "unknown" - channel, found := ibcKeeper.ChannelKeeper.GetChannel(ctx, packet.GetSourcePort(), packet.GetSourceChannel()) + channel, found := ibcKeeper.ChannelKeeper.GetChannel(ctx, sourcePort, sourceChannel) if !found { return chainID } From 3e718631dd2d32c82a87197d9c2ad1d670c277de Mon Sep 17 00:00:00 2001 From: Carlton N Hanna Date: Wed, 1 Nov 2023 15:43:22 -0600 Subject: [PATCH 05/11] fix denom setting in markerMetadata --- app/upgrades.go | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/app/upgrades.go b/app/upgrades.go index 12e992b958..e52df8dbc8 100644 --- a/app/upgrades.go +++ b/app/upgrades.go @@ -390,13 +390,13 @@ func updateIbcMarkerDenomMetadata(ctx sdk.Context, app *App) { chainID := app.Ics20MarkerHooks.GetChainID(ctx, parts[0], parts[1], app.IBCKeeper) markerMetadata := banktypes.Metadata{ Base: record.GetDenom(), - Name: chainID + "/" + record.GetDenom(), - Display: chainID + "/" + record.GetDenom(), - Description: record.GetDenom() + " from chain " + chainID, + Name: chainID + "/" + denomTrace.BaseDenom, + Display: chainID + "/" + denomTrace.BaseDenom, + Description: denomTrace.BaseDenom + " from chain " + chainID, } err := app.MarkerKeeper.SetDenomMetaData(ctx, markerMetadata, authtypes.NewModuleAddress(types.ModuleName)) if err != nil { - panic(fmt.Sprintf("unable to set denom metadata for %v on chain-id %v: %v", record.GetDenom(), chainID, err)) + panic(fmt.Sprintf("unable to set denom metadata for %v with base denom %v and chain-id %v: %v", record.GetDenom(), denomTrace.BaseDenom, chainID, err)) } } } From 2c6f53e17fb4a5ffba277dace7145f98bfc547f4 Mon Sep 17 00:00:00 2001 From: Matthew Witkowski Date: Thu, 2 Nov 2023 13:53:45 -0400 Subject: [PATCH 06/11] Add updateIbcMarkerDenomMetadata to saffron and add logs to method. Create test for rc2 and update existing tests to have logs. --- app/upgrades.go | 8 ++++++-- app/upgrades_test.go | 14 ++++++++++++++ 2 files changed, 20 insertions(+), 2 deletions(-) diff --git a/app/upgrades.go b/app/upgrades.go index e52df8dbc8..1784bdc491 100644 --- a/app/upgrades.go +++ b/app/upgrades.go @@ -125,7 +125,7 @@ var upgrades = map[string]appUpgrade{ }, Added: []string{icqtypes.ModuleName, oracletypes.ModuleName, ibchookstypes.StoreKey, hold.ModuleName, exchange.ModuleName}, }, - "saffron-rc2": { + "saffron-rc2": { // upgrade for v1.17.0-rc2 Handler: func(ctx sdk.Context, app *App, vm module.VersionMap) (module.VersionMap, error) { var err error vm, err = runModuleMigrations(ctx, app, vm) @@ -137,7 +137,7 @@ var upgrades = map[string]appUpgrade{ return vm, nil }, - }, // upgrade for v1.17.0-rc2 + }, "saffron": { // upgrade for v1.17.0, Handler: func(ctx sdk.Context, app *App, vm module.VersionMap) (module.VersionMap, error) { var err error @@ -153,6 +153,7 @@ var upgrades = map[string]appUpgrade{ setupICQ(ctx, app) updateMaxSupply(ctx, app) setExchangeParams(ctx, app) + updateIbcMarkerDenomMetadata(ctx, app) return vm, nil }, @@ -382,11 +383,13 @@ func setExchangeParams(ctx sdk.Context, app *App) { // updateIbcMarkerDenomMetadata iterates markers and creates denom metadata for ibc markers // TODO: Remove with the saffron handlers. func updateIbcMarkerDenomMetadata(ctx sdk.Context, app *App) { + ctx.Logger().Info("Updating ibc marker denom metadata") app.MarkerKeeper.IterateMarkers(ctx, func(record types.MarkerAccountI) bool { if strings.HasSuffix(record.GetDenom(), "ibc/") { denomTrace := transfertypes.ParseDenomTrace(record.GetDenom()) parts := strings.Split(denomTrace.Path, "/") if len(parts) == 2 && parts[0] == "transfer" { + ctx.Logger().Info(fmt.Sprintf("Adding metadata to %s", record.GetDenom())) chainID := app.Ics20MarkerHooks.GetChainID(ctx, parts[0], parts[1], app.IBCKeeper) markerMetadata := banktypes.Metadata{ Base: record.GetDenom(), @@ -402,4 +405,5 @@ func updateIbcMarkerDenomMetadata(ctx sdk.Context, app *App) { } return false }) + ctx.Logger().Info("Done updating ibc marker denom metadata") } diff --git a/app/upgrades_test.go b/app/upgrades_test.go index f264b24dee..1a7aa2a0bc 100644 --- a/app/upgrades_test.go +++ b/app/upgrades_test.go @@ -433,6 +433,18 @@ func (s *UpgradeTestSuite) TestSaffronRC1() { s.AssertUpgradeHandlerLogs("saffron-rc1", expInLog, nil) } +func (s *UpgradeTestSuite) TestSaffronRC2() { + // Each part is (hopefully) tested thoroughly on its own. + // So for this test, just make sure there's log entries for each part being done. + + expInLog := []string{ + "INF Updating ibc marker denom metadata", + "INF Done updating ibc marker denom metadata", + } + + s.AssertUpgradeHandlerLogs("saffron-rc2", expInLog, nil) +} + func (s *UpgradeTestSuite) TestSaffron() { // Each part is (hopefully) tested thoroughly on its own. // So for this test, just make sure there's log entries for each part being done. @@ -445,6 +457,8 @@ func (s *UpgradeTestSuite) TestSaffron() { "INF Updating MaxSupply marker param", "INF Done updating MaxSupply marker param", "INF Ensuring exchange module params are set.", + "INF Updating ibc marker denom metadata", + "INF Done updating ibc marker denom metadata", } s.AssertUpgradeHandlerLogs("saffron", expInLog, nil) From 84a3901a3342927da6d8c41628bc1f280585543c Mon Sep 17 00:00:00 2001 From: Matthew Witkowski Date: Thu, 2 Nov 2023 16:37:56 -0400 Subject: [PATCH 07/11] Add fix to get correct denom trace. --- app/upgrades.go | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/app/upgrades.go b/app/upgrades.go index 1784bdc491..ec9933cdae 100644 --- a/app/upgrades.go +++ b/app/upgrades.go @@ -385,8 +385,16 @@ func setExchangeParams(ctx sdk.Context, app *App) { func updateIbcMarkerDenomMetadata(ctx sdk.Context, app *App) { ctx.Logger().Info("Updating ibc marker denom metadata") app.MarkerKeeper.IterateMarkers(ctx, func(record types.MarkerAccountI) bool { - if strings.HasSuffix(record.GetDenom(), "ibc/") { - denomTrace := transfertypes.ParseDenomTrace(record.GetDenom()) + if strings.HasPrefix(record.GetDenom(), "ibc/") { + hash, err := transfertypes.ParseHexHash(strings.TrimPrefix(record.GetDenom(), "ibc/")) + if err != nil { + panic(fmt.Sprintf("invalid denom trace hash: %s, error: %s", hash.String(), err)) + } + denomTrace, found := app.TransferKeeper.GetDenomTrace(ctx, hash) + if !found { + panic(fmt.Sprintf("trace not found: %s, error: %s", hash.String(), err)) + } + parts := strings.Split(denomTrace.Path, "/") if len(parts) == 2 && parts[0] == "transfer" { ctx.Logger().Info(fmt.Sprintf("Adding metadata to %s", record.GetDenom())) From d93b9391e5f8d9f106b27a288d08ba25830b7aae Mon Sep 17 00:00:00 2001 From: Matthew Witkowski Date: Thu, 2 Nov 2023 17:21:44 -0400 Subject: [PATCH 08/11] Change panics to logs. Remove some indentation that is not needed. --- app/upgrades.go | 51 +++++++++++++++++++++++++++---------------------- 1 file changed, 28 insertions(+), 23 deletions(-) diff --git a/app/upgrades.go b/app/upgrades.go index ec9933cdae..accb1cd2dd 100644 --- a/app/upgrades.go +++ b/app/upgrades.go @@ -385,32 +385,37 @@ func setExchangeParams(ctx sdk.Context, app *App) { func updateIbcMarkerDenomMetadata(ctx sdk.Context, app *App) { ctx.Logger().Info("Updating ibc marker denom metadata") app.MarkerKeeper.IterateMarkers(ctx, func(record types.MarkerAccountI) bool { - if strings.HasPrefix(record.GetDenom(), "ibc/") { - hash, err := transfertypes.ParseHexHash(strings.TrimPrefix(record.GetDenom(), "ibc/")) - if err != nil { - panic(fmt.Sprintf("invalid denom trace hash: %s, error: %s", hash.String(), err)) - } - denomTrace, found := app.TransferKeeper.GetDenomTrace(ctx, hash) - if !found { - panic(fmt.Sprintf("trace not found: %s, error: %s", hash.String(), err)) - } + if !strings.HasPrefix(record.GetDenom(), "ibc/") { + return false + } - parts := strings.Split(denomTrace.Path, "/") - if len(parts) == 2 && parts[0] == "transfer" { - ctx.Logger().Info(fmt.Sprintf("Adding metadata to %s", record.GetDenom())) - chainID := app.Ics20MarkerHooks.GetChainID(ctx, parts[0], parts[1], app.IBCKeeper) - markerMetadata := banktypes.Metadata{ - Base: record.GetDenom(), - Name: chainID + "/" + denomTrace.BaseDenom, - Display: chainID + "/" + denomTrace.BaseDenom, - Description: denomTrace.BaseDenom + " from chain " + chainID, - } - err := app.MarkerKeeper.SetDenomMetaData(ctx, markerMetadata, authtypes.NewModuleAddress(types.ModuleName)) - if err != nil { - panic(fmt.Sprintf("unable to set denom metadata for %v with base denom %v and chain-id %v: %v", record.GetDenom(), denomTrace.BaseDenom, chainID, err)) - } + hash, err := transfertypes.ParseHexHash(strings.TrimPrefix(record.GetDenom(), "ibc/")) + if err != nil { + ctx.Logger().Error(fmt.Sprintf("invalid denom trace hash: %s, error: %s", hash.String(), err)) + return false + } + denomTrace, found := app.TransferKeeper.GetDenomTrace(ctx, hash) + if !found { + ctx.Logger().Error(fmt.Sprintf("trace not found: %s, error: %s", hash.String(), err)) + return false + } + + parts := strings.Split(denomTrace.Path, "/") + if len(parts) == 2 && parts[0] == "transfer" { + ctx.Logger().Info(fmt.Sprintf("Adding metadata to %s", record.GetDenom())) + chainID := app.Ics20MarkerHooks.GetChainID(ctx, parts[0], parts[1], app.IBCKeeper) + markerMetadata := banktypes.Metadata{ + Base: record.GetDenom(), + Name: chainID + "/" + denomTrace.BaseDenom, + Display: chainID + "/" + denomTrace.BaseDenom, + Description: denomTrace.BaseDenom + " from chain " + chainID, + } + err := app.MarkerKeeper.SetDenomMetaData(ctx, markerMetadata, authtypes.NewModuleAddress(types.ModuleName)) + if err != nil { + ctx.Logger().Error(fmt.Sprintf("unable to set denom metadata for %v with base denom %v and chain-id %v: %v", record.GetDenom(), denomTrace.BaseDenom, chainID, err)) } } + return false }) ctx.Logger().Info("Done updating ibc marker denom metadata") From 52a4b5493a56bae66ff63f83044fef9be31701ca Mon Sep 17 00:00:00 2001 From: Matthew Witkowski Date: Thu, 2 Nov 2023 17:22:28 -0400 Subject: [PATCH 09/11] Remove chain from description. --- app/upgrades.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/upgrades.go b/app/upgrades.go index accb1cd2dd..04812c899e 100644 --- a/app/upgrades.go +++ b/app/upgrades.go @@ -408,7 +408,7 @@ func updateIbcMarkerDenomMetadata(ctx sdk.Context, app *App) { Base: record.GetDenom(), Name: chainID + "/" + denomTrace.BaseDenom, Display: chainID + "/" + denomTrace.BaseDenom, - Description: denomTrace.BaseDenom + " from chain " + chainID, + Description: denomTrace.BaseDenom + " from " + chainID, } err := app.MarkerKeeper.SetDenomMetaData(ctx, markerMetadata, authtypes.NewModuleAddress(types.ModuleName)) if err != nil { From 3e79d44342e8ac109dfb13a845339c7b4d8389df Mon Sep 17 00:00:00 2001 From: Matthew Witkowski Date: Thu, 2 Nov 2023 17:24:32 -0400 Subject: [PATCH 10/11] Remove chain from description in hooks. Use BankKeeper.SetDenomMetadata. --- app/upgrades.go | 6 +----- x/ibchooks/marker_hooks.go | 2 +- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/app/upgrades.go b/app/upgrades.go index 04812c899e..dcd1945508 100644 --- a/app/upgrades.go +++ b/app/upgrades.go @@ -12,7 +12,6 @@ import ( storetypes "github.com/cosmos/cosmos-sdk/store/types" 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" govtypesv1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1" govtypesv1beta1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1" @@ -410,10 +409,7 @@ func updateIbcMarkerDenomMetadata(ctx sdk.Context, app *App) { Display: chainID + "/" + denomTrace.BaseDenom, Description: denomTrace.BaseDenom + " from " + chainID, } - err := app.MarkerKeeper.SetDenomMetaData(ctx, markerMetadata, authtypes.NewModuleAddress(types.ModuleName)) - if err != nil { - ctx.Logger().Error(fmt.Sprintf("unable to set denom metadata for %v with base denom %v and chain-id %v: %v", record.GetDenom(), denomTrace.BaseDenom, chainID, err)) - } + app.BankKeeper.SetDenomMetaData(ctx, markerMetadata) } return false diff --git a/x/ibchooks/marker_hooks.go b/x/ibchooks/marker_hooks.go index 95d8069b31..73f86e61e9 100644 --- a/x/ibchooks/marker_hooks.go +++ b/x/ibchooks/marker_hooks.go @@ -119,7 +119,7 @@ func (h MarkerHooks) addDenomMetaData(ctx sdktypes.Context, packet exported.Pack Base: ibcDenom, Name: chainID + "/" + data.Denom, Display: chainID + "/" + data.Denom, - Description: data.Denom + " from chain " + chainID, + Description: data.Denom + " from " + chainID, } return h.MarkerKeeper.SetDenomMetaData(ctx, markerMetadata, authtypes.NewModuleAddress(types.ModuleName)) } From a29bc247d7bbf537cb125b9ac3598a643874f5d8 Mon Sep 17 00:00:00 2001 From: Matthew Witkowski Date: Thu, 2 Nov 2023 17:28:01 -0400 Subject: [PATCH 11/11] Update tests --- x/ibchooks/marker_hooks_test.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/x/ibchooks/marker_hooks_test.go b/x/ibchooks/marker_hooks_test.go index f991f353cb..70a6b61eb8 100644 --- a/x/ibchooks/marker_hooks_test.go +++ b/x/ibchooks/marker_hooks_test.go @@ -160,7 +160,7 @@ func (suite *MarkerHooksTestSuite) TestAddUpdateMarker() { assert.Equal(t, marker.GetDenom(), metadata.Base, "Metadata Base should equal marker denom") assert.Equal(t, "testchain2/"+tc.denom, metadata.Name, "Metadata Name should be chainid/denom") assert.Equal(t, "testchain2/"+tc.denom, metadata.Display, "Metadata Display should be chainid/denom") - assert.Equal(t, tc.denom+" from chain testchain2", metadata.Description, "Metadata Description is incorrect") + assert.Equal(t, tc.denom+" from testchain2", metadata.Description, "Metadata Description is incorrect") assert.Len(t, marker.GetAccessList(), len(tc.expTransAuths), "Resulting access list does not equal expect length") for _, access := range marker.GetAccessList() { assert.Len(t, access.GetAccessList(), 1, "Expecting permissions list to only one item")