From 105e0bc966e62e2f27e577fabfc18dbcc19d2b73 Mon Sep 17 00:00:00 2001 From: Charly Date: Tue, 19 Sep 2023 12:51:46 +0200 Subject: [PATCH 1/3] fix: update testconfig to use revision formatted chainIDs (#4630) --- e2e/sample.config.yaml | 4 ++-- e2e/tests/core/02-client/client_test.go | 4 ++-- e2e/testsuite/testconfig.go | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/e2e/sample.config.yaml b/e2e/sample.config.yaml index 5392ad5664d..e7e185737ac 100644 --- a/e2e/sample.config.yaml +++ b/e2e/sample.config.yaml @@ -5,7 +5,7 @@ --- chains: # the entry at index 0 corresponds to CHAIN_A -- chainId: chain-a +- chainId: chainA-1 numValidators: 1 numFullNodes: 0 image: ghcr.io/cosmos/ibc-go-simd # override with CHAIN_IMAGE @@ -13,7 +13,7 @@ chains: binary: simd # override with CHAIN_BINARY # the entry at index 1 corresponds to CHAIN_B -- chainId: chain-b +- chainId: chainB-1 numValidators: 1 numFullNodes: 0 image: ghcr.io/cosmos/ibc-go-simd # override with CHAIN_IMAGE diff --git a/e2e/tests/core/02-client/client_test.go b/e2e/tests/core/02-client/client_test.go index 319159a6d8b..a3dfedcc6f8 100644 --- a/e2e/tests/core/02-client/client_test.go +++ b/e2e/tests/core/02-client/client_test.go @@ -94,9 +94,9 @@ func (s *ClientTestSuite) TestScheduleIBCUpgrade_Succeeds() { s.Require().NoError(err) originalChainID := clientState.(*ibctm.ClientState).ChainId - revisionNumber := clienttypes.ParseChainID(fmt.Sprintf("%s-%d", originalChainID, 1)) + revisionNumber := clienttypes.ParseChainID(originalChainID) // increment revision number even with new chain ID to prevent loss of misbehaviour detection support - newChainID, err = clienttypes.SetRevisionNumber(fmt.Sprintf("%s-%d", originalChainID, 1), revisionNumber+1) + newChainID, err = clienttypes.SetRevisionNumber(originalChainID, revisionNumber+1) s.Require().NoError(err) s.Require().NotEqual(originalChainID, newChainID) diff --git a/e2e/testsuite/testconfig.go b/e2e/testsuite/testconfig.go index 541770be982..18c64bb2b67 100644 --- a/e2e/testsuite/testconfig.go +++ b/e2e/testsuite/testconfig.go @@ -114,7 +114,7 @@ func (tc TestConfig) GetChainAID() string { if tc.ChainConfigs[0].ChainID != "" { return tc.ChainConfigs[0].ChainID } - return "chain-a" + return "chainA-1" } // GetChainBID returns the chain-id for chain B. @@ -122,7 +122,7 @@ func (tc TestConfig) GetChainBID() string { if tc.ChainConfigs[1].ChainID != "" { return tc.ChainConfigs[1].ChainID } - return "chain-b" + return "chainB-1" } // UpgradeConfig holds values relevant to upgrade tests. From 94d6b7c01661690f18c4ba6230e12698ccaa2549 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?colin=20axn=C3=A9r?= <25233464+colin-axner@users.noreply.github.com> Date: Tue, 19 Sep 2023 13:05:21 +0200 Subject: [PATCH 2/3] imp: add empty address check on authority field (#4713) --- .../controller/keeper/keeper.go | 4 ++ .../controller/keeper/keeper_test.go | 53 ++++++++++++++ .../host/keeper/keeper.go | 4 ++ .../host/keeper/keeper_test.go | 71 +++++++++++++++++++ modules/apps/transfer/keeper/keeper.go | 4 ++ modules/apps/transfer/keeper/keeper_test.go | 70 ++++++++++++++++++ modules/core/keeper/keeper.go | 5 ++ modules/core/keeper/keeper_test.go | 38 +++++++--- 8 files changed, 238 insertions(+), 11 deletions(-) diff --git a/modules/apps/27-interchain-accounts/controller/keeper/keeper.go b/modules/apps/27-interchain-accounts/controller/keeper/keeper.go index 3dd1d3342a6..78980421d65 100644 --- a/modules/apps/27-interchain-accounts/controller/keeper/keeper.go +++ b/modules/apps/27-interchain-accounts/controller/keeper/keeper.go @@ -52,6 +52,10 @@ func NewKeeper( legacySubspace = legacySubspace.WithKeyTable(types.ParamKeyTable()) } + if strings.TrimSpace(authority) == "" { + panic(fmt.Errorf("authority must be non-empty")) + } + return Keeper{ storeKey: key, cdc: cdc, diff --git a/modules/apps/27-interchain-accounts/controller/keeper/keeper_test.go b/modules/apps/27-interchain-accounts/controller/keeper/keeper_test.go index 22e01d1a697..68abb999c2e 100644 --- a/modules/apps/27-interchain-accounts/controller/keeper/keeper_test.go +++ b/modules/apps/27-interchain-accounts/controller/keeper/keeper_test.go @@ -8,6 +8,7 @@ import ( authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" + "github.com/cosmos/ibc-go/v8/modules/apps/27-interchain-accounts/controller/keeper" "github.com/cosmos/ibc-go/v8/modules/apps/27-interchain-accounts/controller/types" genesistypes "github.com/cosmos/ibc-go/v8/modules/apps/27-interchain-accounts/genesis/types" icatypes "github.com/cosmos/ibc-go/v8/modules/apps/27-interchain-accounts/types" @@ -107,6 +108,58 @@ func TestKeeperTestSuite(t *testing.T) { testifysuite.Run(t, new(KeeperTestSuite)) } +func (suite *KeeperTestSuite) TestNewKeeper() { + testCases := []struct { + name string + instantiateFn func() + expPass bool + }{ + {"success", func() { + keeper.NewKeeper( + suite.chainA.GetSimApp().AppCodec(), + suite.chainA.GetSimApp().GetKey(types.StoreKey), + suite.chainA.GetSimApp().GetSubspace(types.SubModuleName), + suite.chainA.GetSimApp().IBCKeeper.ChannelKeeper, + suite.chainA.GetSimApp().IBCKeeper.ChannelKeeper, + &suite.chainA.GetSimApp().IBCKeeper.PortKeeper, + suite.chainA.GetSimApp().ScopedICAControllerKeeper, + suite.chainA.GetSimApp().MsgServiceRouter(), + suite.chainA.GetSimApp().ICAControllerKeeper.GetAuthority(), + ) + }, true}, + {"failure: empty authority", func() { + keeper.NewKeeper( + suite.chainA.GetSimApp().AppCodec(), + suite.chainA.GetSimApp().GetKey(types.StoreKey), + suite.chainA.GetSimApp().GetSubspace(types.SubModuleName), + suite.chainA.GetSimApp().IBCKeeper.ChannelKeeper, + suite.chainA.GetSimApp().IBCKeeper.ChannelKeeper, + &suite.chainA.GetSimApp().IBCKeeper.PortKeeper, + suite.chainA.GetSimApp().ScopedICAControllerKeeper, + suite.chainA.GetSimApp().MsgServiceRouter(), + "", // authority + ) + }, false}, + } + + for _, tc := range testCases { + tc := tc + suite.SetupTest() + + suite.Run(tc.name, func() { + if tc.expPass { + suite.Require().NotPanics( + tc.instantiateFn, + ) + } else { + suite.Require().Panics( + tc.instantiateFn, + ) + } + }) + } +} + func (suite *KeeperTestSuite) TestGetAllPorts() { suite.SetupTest() diff --git a/modules/apps/27-interchain-accounts/host/keeper/keeper.go b/modules/apps/27-interchain-accounts/host/keeper/keeper.go index c9e442854e6..b60ac4d652c 100644 --- a/modules/apps/27-interchain-accounts/host/keeper/keeper.go +++ b/modules/apps/27-interchain-accounts/host/keeper/keeper.go @@ -59,6 +59,10 @@ func NewKeeper( legacySubspace = legacySubspace.WithKeyTable(types.ParamKeyTable()) } + if strings.TrimSpace(authority) == "" { + panic(fmt.Errorf("authority must be non-empty")) + } + return Keeper{ storeKey: key, cdc: cdc, diff --git a/modules/apps/27-interchain-accounts/host/keeper/keeper_test.go b/modules/apps/27-interchain-accounts/host/keeper/keeper_test.go index 0c44b0f10d4..a0acc4b21d6 100644 --- a/modules/apps/27-interchain-accounts/host/keeper/keeper_test.go +++ b/modules/apps/27-interchain-accounts/host/keeper/keeper_test.go @@ -6,7 +6,10 @@ import ( testifysuite "github.com/stretchr/testify/suite" + authkeeper "github.com/cosmos/cosmos-sdk/x/auth/keeper" + genesistypes "github.com/cosmos/ibc-go/v8/modules/apps/27-interchain-accounts/genesis/types" + "github.com/cosmos/ibc-go/v8/modules/apps/27-interchain-accounts/host/keeper" "github.com/cosmos/ibc-go/v8/modules/apps/27-interchain-accounts/host/types" icatypes "github.com/cosmos/ibc-go/v8/modules/apps/27-interchain-accounts/types" ibcfeekeeper "github.com/cosmos/ibc-go/v8/modules/apps/29-fee/keeper" @@ -127,6 +130,74 @@ func TestKeeperTestSuite(t *testing.T) { testifysuite.Run(t, new(KeeperTestSuite)) } +func (suite *KeeperTestSuite) TestNewKeeper() { + testCases := []struct { + name string + instantiateFn func() + expPass bool + }{ + {"success", func() { + keeper.NewKeeper( + suite.chainA.GetSimApp().AppCodec(), + suite.chainA.GetSimApp().GetKey(types.StoreKey), + suite.chainA.GetSimApp().GetSubspace(types.SubModuleName), + suite.chainA.GetSimApp().IBCKeeper.ChannelKeeper, + suite.chainA.GetSimApp().IBCKeeper.ChannelKeeper, + &suite.chainA.GetSimApp().IBCKeeper.PortKeeper, + suite.chainA.GetSimApp().AccountKeeper, + suite.chainA.GetSimApp().ScopedICAHostKeeper, + suite.chainA.GetSimApp().MsgServiceRouter(), + suite.chainA.GetSimApp().ICAHostKeeper.GetAuthority(), + ) + }, true}, + {"failure: interchain accounts module account does not exist", func() { + keeper.NewKeeper( + suite.chainA.GetSimApp().AppCodec(), + suite.chainA.GetSimApp().GetKey(types.StoreKey), + suite.chainA.GetSimApp().GetSubspace(types.SubModuleName), + suite.chainA.GetSimApp().IBCKeeper.ChannelKeeper, + suite.chainA.GetSimApp().IBCKeeper.ChannelKeeper, + &suite.chainA.GetSimApp().IBCKeeper.PortKeeper, + authkeeper.AccountKeeper{}, // empty account keeper + suite.chainA.GetSimApp().ScopedICAHostKeeper, + suite.chainA.GetSimApp().MsgServiceRouter(), + suite.chainA.GetSimApp().ICAHostKeeper.GetAuthority(), + ) + }, false}, + {"failure: empty mock staking keeper", func() { + keeper.NewKeeper( + suite.chainA.GetSimApp().AppCodec(), + suite.chainA.GetSimApp().GetKey(types.StoreKey), + suite.chainA.GetSimApp().GetSubspace(types.SubModuleName), + suite.chainA.GetSimApp().IBCKeeper.ChannelKeeper, + suite.chainA.GetSimApp().IBCKeeper.ChannelKeeper, + &suite.chainA.GetSimApp().IBCKeeper.PortKeeper, + suite.chainA.GetSimApp().AccountKeeper, + suite.chainA.GetSimApp().ScopedICAHostKeeper, + suite.chainA.GetSimApp().MsgServiceRouter(), + "", // authority + ) + }, false}, + } + + for _, tc := range testCases { + tc := tc + suite.SetupTest() + + suite.Run(tc.name, func() { + if tc.expPass { + suite.Require().NotPanics( + tc.instantiateFn, + ) + } else { + suite.Require().Panics( + tc.instantiateFn, + ) + } + }) + } +} + func (suite *KeeperTestSuite) TestGetInterchainAccountAddress() { suite.SetupTest() diff --git a/modules/apps/transfer/keeper/keeper.go b/modules/apps/transfer/keeper/keeper.go index 5a033980d87..e3e0da974fc 100644 --- a/modules/apps/transfer/keeper/keeper.go +++ b/modules/apps/transfer/keeper/keeper.go @@ -63,6 +63,10 @@ func NewKeeper( legacySubspace = legacySubspace.WithKeyTable(types.ParamKeyTable()) } + if strings.TrimSpace(authority) == "" { + panic(fmt.Errorf("authority must be non-empty")) + } + return Keeper{ cdc: cdc, storeKey: key, diff --git a/modules/apps/transfer/keeper/keeper_test.go b/modules/apps/transfer/keeper/keeper_test.go index 56afd3fcbd5..281bebd9aff 100644 --- a/modules/apps/transfer/keeper/keeper_test.go +++ b/modules/apps/transfer/keeper/keeper_test.go @@ -12,7 +12,9 @@ import ( "github.com/cosmos/cosmos-sdk/baseapp" "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" + authkeeper "github.com/cosmos/cosmos-sdk/x/auth/keeper" + "github.com/cosmos/ibc-go/v8/modules/apps/transfer/keeper" "github.com/cosmos/ibc-go/v8/modules/apps/transfer/types" channelkeeper "github.com/cosmos/ibc-go/v8/modules/core/04-channel/keeper" ibctesting "github.com/cosmos/ibc-go/v8/testing" @@ -43,6 +45,74 @@ func TestKeeperTestSuite(t *testing.T) { testifysuite.Run(t, new(KeeperTestSuite)) } +func (suite *KeeperTestSuite) TestNewKeeper() { + testCases := []struct { + name string + instantiateFn func() + expPass bool + }{ + {"success", func() { + keeper.NewKeeper( + suite.chainA.GetSimApp().AppCodec(), + suite.chainA.GetSimApp().GetKey(types.StoreKey), + suite.chainA.GetSimApp().GetSubspace(types.ModuleName), + suite.chainA.GetSimApp().IBCKeeper.ChannelKeeper, + suite.chainA.GetSimApp().IBCKeeper.ChannelKeeper, + &suite.chainA.GetSimApp().IBCKeeper.PortKeeper, + suite.chainA.GetSimApp().AccountKeeper, + suite.chainA.GetSimApp().BankKeeper, + suite.chainA.GetSimApp().ScopedTransferKeeper, + suite.chainA.GetSimApp().ICAControllerKeeper.GetAuthority(), + ) + }, true}, + {"failure: transfer module account does not exist", func() { + keeper.NewKeeper( + suite.chainA.GetSimApp().AppCodec(), + suite.chainA.GetSimApp().GetKey(types.StoreKey), + suite.chainA.GetSimApp().GetSubspace(types.ModuleName), + suite.chainA.GetSimApp().IBCKeeper.ChannelKeeper, + suite.chainA.GetSimApp().IBCKeeper.ChannelKeeper, + &suite.chainA.GetSimApp().IBCKeeper.PortKeeper, + authkeeper.AccountKeeper{}, // empty account keeper + suite.chainA.GetSimApp().BankKeeper, + suite.chainA.GetSimApp().ScopedTransferKeeper, + suite.chainA.GetSimApp().ICAControllerKeeper.GetAuthority(), + ) + }, false}, + {"failure: empty authority", func() { + keeper.NewKeeper( + suite.chainA.GetSimApp().AppCodec(), + suite.chainA.GetSimApp().GetKey(types.StoreKey), + suite.chainA.GetSimApp().GetSubspace(types.ModuleName), + suite.chainA.GetSimApp().IBCKeeper.ChannelKeeper, + suite.chainA.GetSimApp().IBCKeeper.ChannelKeeper, + &suite.chainA.GetSimApp().IBCKeeper.PortKeeper, + suite.chainA.GetSimApp().AccountKeeper, + suite.chainA.GetSimApp().BankKeeper, + suite.chainA.GetSimApp().ScopedTransferKeeper, + "", // authority + ) + }, false}, + } + + for _, tc := range testCases { + tc := tc + suite.SetupTest() + + suite.Run(tc.name, func() { + if tc.expPass { + suite.Require().NotPanics( + tc.instantiateFn, + ) + } else { + suite.Require().Panics( + tc.instantiateFn, + ) + } + }) + } +} + func (suite *KeeperTestSuite) TestSetGetTotalEscrowForDenom() { const denom = "atom" var expAmount sdkmath.Int diff --git a/modules/core/keeper/keeper.go b/modules/core/keeper/keeper.go index 040d0a3ffed..5c42acbf6fb 100644 --- a/modules/core/keeper/keeper.go +++ b/modules/core/keeper/keeper.go @@ -3,6 +3,7 @@ package keeper import ( "fmt" "reflect" + "strings" storetypes "cosmossdk.io/store/types" @@ -64,6 +65,10 @@ func NewKeeper( panic(fmt.Errorf("cannot initialize IBC keeper: empty scoped keeper")) } + if strings.TrimSpace(authority) == "" { + panic(fmt.Errorf("authority must be non-empty")) + } + clientKeeper := clientkeeper.NewKeeper(cdc, key, paramSpace, stakingKeeper, upgradeKeeper) connectionKeeper := connectionkeeper.NewKeeper(cdc, key, paramSpace, clientKeeper) portKeeper := portkeeper.NewKeeper(scopedKeeper) diff --git a/modules/core/keeper/keeper_test.go b/modules/core/keeper/keeper_test.go index 58e8167fb1c..0cd6b2a5857 100644 --- a/modules/core/keeper/keeper_test.go +++ b/modules/core/keeper/keeper_test.go @@ -64,17 +64,7 @@ func (suite *KeeperTestSuite) TestNewKeeper() { stakingKeeper clienttypes.StakingKeeper upgradeKeeper clienttypes.UpgradeKeeper scopedKeeper capabilitykeeper.ScopedKeeper - newIBCKeeperFn = func() { - ibckeeper.NewKeeper( - suite.chainA.GetSimApp().AppCodec(), - suite.chainA.GetSimApp().GetKey(ibcexported.StoreKey), - suite.chainA.GetSimApp().GetSubspace(ibcexported.ModuleName), - stakingKeeper, - upgradeKeeper, - scopedKeeper, - suite.chainA.App.GetIBCKeeper().GetAuthority(), - ) - } + newIBCKeeperFn func() ) testCases := []struct { @@ -113,6 +103,19 @@ func (suite *KeeperTestSuite) TestNewKeeper() { scopedKeeper = emptyScopedKeeper }, false}, + {"failure: empty authority", func() { + newIBCKeeperFn = func() { + ibckeeper.NewKeeper( + suite.chainA.GetSimApp().AppCodec(), + suite.chainA.GetSimApp().GetKey(ibcexported.StoreKey), + suite.chainA.GetSimApp().GetSubspace(ibcexported.ModuleName), + stakingKeeper, + upgradeKeeper, + scopedKeeper, + "", // authority + ) + } + }, false}, {"success: replace stakingKeeper with non-empty MockStakingKeeper", func() { // use a different implementation of clienttypes.StakingKeeper mockStakingKeeper := MockStakingKeeper{"not empty"} @@ -126,6 +129,19 @@ func (suite *KeeperTestSuite) TestNewKeeper() { suite.SetupTest() suite.Run(tc.name, func() { + // set default behaviour + newIBCKeeperFn = func() { + ibckeeper.NewKeeper( + suite.chainA.GetSimApp().AppCodec(), + suite.chainA.GetSimApp().GetKey(ibcexported.StoreKey), + suite.chainA.GetSimApp().GetSubspace(ibcexported.ModuleName), + stakingKeeper, + upgradeKeeper, + scopedKeeper, + suite.chainA.App.GetIBCKeeper().GetAuthority(), + ) + } + stakingKeeper = suite.chainA.GetSimApp().StakingKeeper upgradeKeeper = suite.chainA.GetSimApp().UpgradeKeeper scopedKeeper = suite.chainA.GetSimApp().ScopedIBCKeeper From edbaf5048f0bd1dbaa6767f5e2604f9d6446a297 Mon Sep 17 00:00:00 2001 From: srdtrk <59252793+srdtrk@users.noreply.github.com> Date: Tue, 19 Sep 2023 14:19:51 +0300 Subject: [PATCH 3/3] docs: fix broken sdk links (#4716) * docs: fix broken sdk links * docs: fix broken sdk links --- .github/PULL_REQUEST_TEMPLATE.md | 2 +- docs/apps/transfer/metrics.md | 2 +- docs/dev/project-structure.md | 2 +- docs/ibc/apps.md | 2 +- docs/ibc/apps/apps.md | 2 +- docs/ibc/integration.md | 2 +- docs/ibc/overview.md | 2 +- docs/ibc/relayer.md | 2 +- docs/middleware/ics29-fee/fee-distribution.md | 6 +++--- 9 files changed, 11 insertions(+), 11 deletions(-) diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md index cf6c0168249..2866e868105 100644 --- a/.github/PULL_REQUEST_TEMPLATE.md +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -43,7 +43,7 @@ write a little note why. - [ ] Targeted PR against correct branch (see [CONTRIBUTING.md](https://github.com/cosmos/ibc-go/blob/main/docs/dev/pull-requests.md#pull-request-targeting)). - [ ] Linked to Github issue with discussion and accepted design OR link to spec that describes this work. -- [ ] Code follows the [module structure standards](https://github.com/cosmos/cosmos-sdk/blob/main/docs/docs/build/building-modules/11-structure.md) and [Go style guide](../docs/dev/go-style-guide.md). +- [ ] Code follows the [module structure standards](https://github.com/cosmos/cosmos-sdk/blob/main/docs/build/building-modules/11-structure.md) and [Go style guide](../docs/dev/go-style-guide.md). - [ ] Wrote unit and integration [tests](https://github.com/cosmos/ibc-go/blob/main/testing/README.md#ibc-testing-package). - [ ] Updated relevant documentation (`docs/`) or specification (`x//spec/`). - [ ] Added relevant `godoc` [comments](https://blog.golang.org/godoc-documenting-go-code). diff --git a/docs/apps/transfer/metrics.md b/docs/apps/transfer/metrics.md index 3d2bb4bd82f..9dc866deee8 100644 --- a/docs/apps/transfer/metrics.md +++ b/docs/apps/transfer/metrics.md @@ -4,7 +4,7 @@ order: 6 # Metrics -The IBC transfer application module exposes the following set of [metrics](https://github.com/cosmos/cosmos-sdk/blob/main/docs/docs/develop/advanced/09-telemetry.md). +The IBC transfer application module exposes the following set of [metrics](https://github.com/cosmos/cosmos-sdk/blob/main/docs/develop/advanced/09-telemetry.md). | Metric | Description | Unit | Type | |:--------------------------------|:------------------------------------------------------------------------------------------|:----------------|:--------| diff --git a/docs/dev/project-structure.md b/docs/dev/project-structure.md index bb8e697d904..5056b325625 100644 --- a/docs/dev/project-structure.md +++ b/docs/dev/project-structure.md @@ -1,6 +1,6 @@ # Project structure -If you're not familiar with the overall module structure from the SDK modules, please check this [document](https://github.com/cosmos/cosmos-sdk/blob/main/docs/docs/build/building-modules/11-structure.md) as prerequisite reading. +If you're not familiar with the overall module structure from the SDK modules, please check this [document](https://github.com/cosmos/cosmos-sdk/blob/main/docs/build/building-modules/11-structure.md) as prerequisite reading. Every Interchain Standard (ICS) has been developed in its own package. The development team separated the IBC TAO (Transport, Authentication, Ordering) ICS specifications from the IBC application level specification. The following sections describe the architecture of the most relevant directories that comprise this repository. diff --git a/docs/ibc/apps.md b/docs/ibc/apps.md index 7e5293bfd0a..acb05a9c8c7 100644 --- a/docs/ibc/apps.md +++ b/docs/ibc/apps.md @@ -488,4 +488,4 @@ callbacks](https://github.com/cosmos/ibc-go/blob/main/modules/apps/transfer/ibc_ ## Next {hide} -Learn about [building modules](https://github.com/cosmos/cosmos-sdk/blob/main/docs/docs/build/building-modules/00-intro.md) {hide} +Learn about [building modules](https://github.com/cosmos/cosmos-sdk/blob/main/docs/build/building-modules/00-intro.md) {hide} diff --git a/docs/ibc/apps/apps.md b/docs/ibc/apps/apps.md index 93f86d464b0..7798c903b6c 100644 --- a/docs/ibc/apps/apps.md +++ b/docs/ibc/apps/apps.md @@ -48,4 +48,4 @@ callbacks](https://github.com/cosmos/ibc-go/blob/main/modules/apps/transfer/ibc_ ## Next {hide} -Learn about [building modules](https://github.com/cosmos/cosmos-sdk/blob/main/docs/docs/build/building-modules/00-intro.md) {hide} +Learn about [building modules](https://github.com/cosmos/cosmos-sdk/blob/main/docs/build/building-modules/00-intro.md) {hide} diff --git a/docs/ibc/integration.md b/docs/ibc/integration.md index ec8a78765f9..97482bd450c 100644 --- a/docs/ibc/integration.md +++ b/docs/ibc/integration.md @@ -157,7 +157,7 @@ func NewApp(...args) *App { ### Module Managers -In order to use IBC, we need to add the new modules to the module `Manager` and to the `SimulationManager` in case your application supports [simulations](https://github.com/cosmos/cosmos-sdk/blob/main/docs/docs/build/building-modules/14-simulator.md). +In order to use IBC, we need to add the new modules to the module `Manager` and to the `SimulationManager` in case your application supports [simulations](https://github.com/cosmos/cosmos-sdk/blob/main/docs/build/building-modules/14-simulator.md). ```go // app.go diff --git a/docs/ibc/overview.md b/docs/ibc/overview.md index 68c6d31ed8e..ca7c406a6cf 100644 --- a/docs/ibc/overview.md +++ b/docs/ibc/overview.md @@ -136,7 +136,7 @@ Proofs are passed from core IBC to light-clients as bytes. It is up to light cli [ICS-24 Host State Machine Requirements](https://github.com/cosmos/ics/tree/master/spec/core/ics-024-host-requirements). - The proof format that all implementations must be able to produce and verify is defined in [ICS-23 Proofs](https://github.com/cosmos/ics23) implementation. -### [Capabilities](https://github.com/cosmos/cosmos-sdk/blob/main/docs/docs/develop/advanced/10-ocap.md) +### [Capabilities](https://github.com/cosmos/cosmos-sdk/blob/main/docs/develop/advanced/10-ocap.md) IBC is intended to work in execution environments where modules do not necessarily trust each other. Thus, IBC must authenticate module actions on ports and channels so that only modules with the diff --git a/docs/ibc/relayer.md b/docs/ibc/relayer.md index 7da4e73bf92..7348a854b09 100644 --- a/docs/ibc/relayer.md +++ b/docs/ibc/relayer.md @@ -7,7 +7,7 @@ order: 6 ## Pre-requisites Readings - [IBC Overview](./overview.md) {prereq} -- [Events](https://github.com/cosmos/cosmos-sdk/blob/main/docs/docs/develop/advanced/08-events.md) {prereq} +- [Events](https://github.com/cosmos/cosmos-sdk/blob/main/docs/develop/advanced/08-events.md) {prereq} ## Events diff --git a/docs/middleware/ics29-fee/fee-distribution.md b/docs/middleware/ics29-fee/fee-distribution.md index d1be7e2ff8a..6efb9972fd5 100644 --- a/docs/middleware/ics29-fee/fee-distribution.md +++ b/docs/middleware/ics29-fee/fee-distribution.md @@ -50,7 +50,7 @@ type MsgRegisterCounterpartyPayee struct { > > - `PortId` is invalid (see [24-host naming requirements](https://github.com/cosmos/ibc/blob/master/spec/core/ics-024-host-requirements/README.md#paths-identifiers-separators). > - `ChannelId` is invalid (see [24-host naming requirements](https://github.com/cosmos/ibc/blob/master/spec/core/ics-024-host-requirements/README.md#paths-identifiers-separators)). -> - `Relayer` is an invalid address (see [Cosmos SDK Addresses](https://github.com/cosmos/cosmos-sdk/blob/main/docs/docs/develop/beginner/03-accounts.md#addresses)). +> - `Relayer` is an invalid address (see [Cosmos SDK Addresses](https://github.com/cosmos/cosmos-sdk/blob/main/docs/develop/beginner/03-accounts.md#addresses)). > - `CounterpartyPayee` is empty. See below for an example CLI command: @@ -95,8 +95,8 @@ type MsgRegisterPayee struct { > > - `PortId` is invalid (see [24-host naming requirements](https://github.com/cosmos/ibc/blob/master/spec/core/ics-024-host-requirements/README.md#paths-identifiers-separators). > - `ChannelId` is invalid (see [24-host naming requirements](https://github.com/cosmos/ibc/blob/master/spec/core/ics-024-host-requirements/README.md#paths-identifiers-separators)). -> - `Relayer` is an invalid address (see [Cosmos SDK Addresses](https://github.com/cosmos/cosmos-sdk/blob/main/docs/docs/develop/beginner/03-accounts.md#addresses)). -> - `Payee` is an invalid address (see [Cosmos SDK Addresses](https://github.com/cosmos/cosmos-sdk/blob/main/docs/docs/develop/beginner/03-accounts.md#addresses)). +> - `Relayer` is an invalid address (see [Cosmos SDK Addresses](https://github.com/cosmos/cosmos-sdk/blob/main/docs/develop/beginner/03-accounts.md#addresses)). +> - `Payee` is an invalid address (see [Cosmos SDK Addresses](https://github.com/cosmos/cosmos-sdk/blob/main/docs/develop/beginner/03-accounts.md#addresses)). See below for an example CLI command: