From eb23e9ef94cbbe8114bb6afff5ed9d89a5acba1d Mon Sep 17 00:00:00 2001 From: Charly Date: Mon, 30 Jan 2023 14:40:51 +0100 Subject: [PATCH 01/22] fix: moved non-verification misbehaviour checks to checkForMisbehaviour (#3046) * move misbehaviour check * add test coverage --- CHANGELOG.md | 1 + .../07-tendermint/misbehaviour_handle.go | 51 +++++++-------- .../07-tendermint/misbehaviour_handle_test.go | 64 ------------------- .../07-tendermint/update_test.go | 45 +++++++++++++ 4 files changed, 70 insertions(+), 91 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 35bdb13851c..37f779bc1af 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -92,6 +92,7 @@ Ref: https://keepachangelog.com/en/1.0.0/ * [\#2434](https://github.com/cosmos/ibc-go/pull/2478) Removed all `TypeMsg` constants * (modules/core/exported) [#1689] (https://github.com/cosmos/ibc-go/pull/2539) Removing `GetVersions` from `ConnectionI` interface. * (core/02-connection) [#2419](https://github.com/cosmos/ibc-go/pull/2419) Add optional proof data to proto definitions of `MsgConnectionOpenTry` and `MsgConnectionOpenAck` for host state machines that are unable to introspect their own consensus state. +* (modules/light-clients/07-tendermint) [#2007](https://github.com/cosmos/ibc-go/pull/3046) Moved non-verification misbehaviour checks to `CheckForMisbehaviour` ### Features diff --git a/modules/light-clients/07-tendermint/misbehaviour_handle.go b/modules/light-clients/07-tendermint/misbehaviour_handle.go index 961d9ea69cf..2ef567b70c1 100644 --- a/modules/light-clients/07-tendermint/misbehaviour_handle.go +++ b/modules/light-clients/07-tendermint/misbehaviour_handle.go @@ -15,6 +15,7 @@ import ( ) // CheckForMisbehaviour detects duplicate height misbehaviour and BFT time violation misbehaviour +// in a submitted Header message and verifies the correctness of a submitted Misbehaviour ClientMessage func (cs ClientState) CheckForMisbehaviour(ctx sdk.Context, cdc codec.BinaryCodec, clientStore sdk.KVStore, msg exported.ClientMessage) bool { switch msg := msg.(type) { case *Header: @@ -51,9 +52,29 @@ func (cs ClientState) CheckForMisbehaviour(ctx sdk.Context, cdc codec.BinaryCode return true } case *Misbehaviour: - // The correctness of Misbehaviour ClientMessage types is ensured by calling VerifyClientMessage prior to this function - // Thus, here we can return true, as ClientMessage is of type Misbehaviour - return true + // if heights are equal check that this is valid misbehaviour of a fork + // otherwise if heights are unequal check that this is valid misbehavior of BFT time violation + if msg.Header1.GetHeight().EQ(msg.Header2.GetHeight()) { + blockID1, err := tmtypes.BlockIDFromProto(&msg.Header1.SignedHeader.Commit.BlockID) + if err != nil { + return false + } + + blockID2, err := tmtypes.BlockIDFromProto(&msg.Header2.SignedHeader.Commit.BlockID) + if err != nil { + return false + } + + // Ensure that Commit Hashes are different + if !bytes.Equal(blockID1.Hash, blockID2.Hash) { + return true + } + + } else if !msg.Header1.SignedHeader.Header.Time.After(msg.Header2.SignedHeader.Header.Time) { + // Header1 is at greater height than Header2, therefore Header1 time must be less than or equal to + // Header2 time in order to be valid misbehaviour (violation of monotonic time). + return true + } } return false @@ -68,30 +89,6 @@ func (cs ClientState) CheckForMisbehaviour(ctx sdk.Context, cdc codec.BinaryCode // to misbehaviour.Header2 // Misbehaviour sets frozen height to {0, 1} since it is only used as a boolean value (zero or non-zero). func (cs *ClientState) verifyMisbehaviour(ctx sdk.Context, clientStore sdk.KVStore, cdc codec.BinaryCodec, misbehaviour *Misbehaviour) error { - // if heights are equal check that this is valid misbehaviour of a fork - // otherwise if heights are unequal check that this is valid misbehavior of BFT time violation - if misbehaviour.Header1.GetHeight().EQ(misbehaviour.Header2.GetHeight()) { - blockID1, err := tmtypes.BlockIDFromProto(&misbehaviour.Header1.SignedHeader.Commit.BlockID) - if err != nil { - return sdkerrors.Wrap(err, "invalid block ID from header 1 in misbehaviour") - } - - blockID2, err := tmtypes.BlockIDFromProto(&misbehaviour.Header2.SignedHeader.Commit.BlockID) - if err != nil { - return sdkerrors.Wrap(err, "invalid block ID from header 2 in misbehaviour") - } - - // Ensure that Commit Hashes are different - if bytes.Equal(blockID1.Hash, blockID2.Hash) { - return sdkerrors.Wrap(clienttypes.ErrInvalidMisbehaviour, "headers block hashes are equal") - } - - } else if misbehaviour.Header1.SignedHeader.Header.Time.After(misbehaviour.Header2.SignedHeader.Header.Time) { - // Header1 is at greater height than Header2, therefore Header1 time must be less than or equal to - // Header2 time in order to be valid misbehaviour (violation of monotonic time). - return sdkerrors.Wrap(clienttypes.ErrInvalidMisbehaviour, "headers are not at same height and are monotonically increasing") - } - // Regardless of the type of misbehaviour, ensure that both headers are valid and would have been accepted by light-client // Retrieve trusted consensus states for each Header in misbehaviour diff --git a/modules/light-clients/07-tendermint/misbehaviour_handle_test.go b/modules/light-clients/07-tendermint/misbehaviour_handle_test.go index aa458dbc69c..ae7a2dd126b 100644 --- a/modules/light-clients/07-tendermint/misbehaviour_handle_test.go +++ b/modules/light-clients/07-tendermint/misbehaviour_handle_test.go @@ -204,38 +204,6 @@ func (suite *TendermintTestSuite) TestVerifyMisbehaviour() { } }, true, }, - { - "invalid fork misbehaviour: identical headers", func() { - trustedHeight := path.EndpointA.GetClientState().GetLatestHeight().(clienttypes.Height) - - trustedVals, found := suite.chainB.GetValsAtHeight(int64(trustedHeight.RevisionHeight) + 1) - suite.Require().True(found) - - err := path.EndpointA.UpdateClient() - suite.Require().NoError(err) - - height := path.EndpointA.GetClientState().GetLatestHeight().(clienttypes.Height) - - misbehaviourHeader := suite.chainB.CreateTMClientHeader(suite.chainB.ChainID, int64(height.RevisionHeight), trustedHeight, suite.chainB.CurrentHeader.Time.Add(time.Minute), suite.chainB.Vals, suite.chainB.NextVals, trustedVals, suite.chainB.Signers) - misbehaviour = &ibctm.Misbehaviour{ - Header1: misbehaviourHeader, - Header2: misbehaviourHeader, - } - }, false, - }, - { - "invalid time misbehaviour: monotonically increasing time", func() { - trustedHeight := path.EndpointA.GetClientState().GetLatestHeight().(clienttypes.Height) - - trustedVals, found := suite.chainB.GetValsAtHeight(int64(trustedHeight.RevisionHeight) + 1) - suite.Require().True(found) - - misbehaviour = &ibctm.Misbehaviour{ - Header1: suite.chainB.CreateTMClientHeader(suite.chainB.ChainID, suite.chainB.CurrentHeader.Height+3, trustedHeight, suite.chainB.CurrentHeader.Time.Add(time.Minute), suite.chainB.Vals, suite.chainB.NextVals, trustedVals, suite.chainB.Signers), - Header2: suite.chainB.CreateTMClientHeader(suite.chainB.ChainID, suite.chainB.CurrentHeader.Height, trustedHeight, suite.chainB.CurrentHeader.Time, suite.chainB.Vals, suite.chainB.NextVals, trustedVals, suite.chainB.Signers), - } - }, false, - }, { "invalid misbehaviour: misbehaviour from different chain", func() { trustedHeight := path.EndpointA.GetClientState().GetLatestHeight().(clienttypes.Height) @@ -523,38 +491,6 @@ func (suite *TendermintTestSuite) TestVerifyMisbehaviourNonRevisionChainID() { } }, true, }, - { - "invalid fork misbehaviour: identical headers", func() { - trustedHeight := path.EndpointA.GetClientState().GetLatestHeight().(clienttypes.Height) - - trustedVals, found := suite.chainB.GetValsAtHeight(int64(trustedHeight.RevisionHeight) + 1) - suite.Require().True(found) - - err := path.EndpointA.UpdateClient() - suite.Require().NoError(err) - - height := path.EndpointA.GetClientState().GetLatestHeight().(clienttypes.Height) - - misbehaviourHeader := suite.chainB.CreateTMClientHeader(suite.chainB.ChainID, int64(height.RevisionHeight), trustedHeight, suite.chainB.CurrentHeader.Time.Add(time.Minute), suite.chainB.Vals, suite.chainB.NextVals, trustedVals, suite.chainB.Signers) - misbehaviour = &ibctm.Misbehaviour{ - Header1: misbehaviourHeader, - Header2: misbehaviourHeader, - } - }, false, - }, - { - "invalid time misbehaviour: monotonically increasing time", func() { - trustedHeight := path.EndpointA.GetClientState().GetLatestHeight().(clienttypes.Height) - - trustedVals, found := suite.chainB.GetValsAtHeight(int64(trustedHeight.RevisionHeight) + 1) - suite.Require().True(found) - - misbehaviour = &ibctm.Misbehaviour{ - Header1: suite.chainB.CreateTMClientHeader(suite.chainB.ChainID, suite.chainB.CurrentHeader.Height+3, trustedHeight, suite.chainB.CurrentHeader.Time.Add(time.Minute), suite.chainB.Vals, suite.chainB.NextVals, trustedVals, suite.chainB.Signers), - Header2: suite.chainB.CreateTMClientHeader(suite.chainB.ChainID, suite.chainB.CurrentHeader.Height, trustedHeight, suite.chainB.CurrentHeader.Time, suite.chainB.Vals, suite.chainB.NextVals, trustedVals, suite.chainB.Signers), - } - }, false, - }, { "invalid misbehaviour: misbehaviour from different chain", func() { trustedHeight := path.EndpointA.GetClientState().GetLatestHeight().(clienttypes.Height) diff --git a/modules/light-clients/07-tendermint/update_test.go b/modules/light-clients/07-tendermint/update_test.go index 366e5787078..81374e6ffb1 100644 --- a/modules/light-clients/07-tendermint/update_test.go +++ b/modules/light-clients/07-tendermint/update_test.go @@ -635,6 +635,38 @@ func (suite *TendermintTestSuite) TestCheckForMisbehaviour() { }, false, }, + { + "invalid fork misbehaviour: identical headers", func() { + trustedHeight := path.EndpointA.GetClientState().GetLatestHeight().(clienttypes.Height) + + trustedVals, found := suite.chainB.GetValsAtHeight(int64(trustedHeight.RevisionHeight) + 1) + suite.Require().True(found) + + err := path.EndpointA.UpdateClient() + suite.Require().NoError(err) + + height := path.EndpointA.GetClientState().GetLatestHeight().(clienttypes.Height) + + misbehaviourHeader := suite.chainB.CreateTMClientHeader(suite.chainB.ChainID, int64(height.RevisionHeight), trustedHeight, suite.chainB.CurrentHeader.Time.Add(time.Minute), suite.chainB.Vals, suite.chainB.NextVals, trustedVals, suite.chainB.Signers) + clientMessage = &ibctm.Misbehaviour{ + Header1: misbehaviourHeader, + Header2: misbehaviourHeader, + } + }, false, + }, + { + "invalid time misbehaviour: monotonically increasing time", func() { + trustedHeight := path.EndpointA.GetClientState().GetLatestHeight().(clienttypes.Height) + + trustedVals, found := suite.chainB.GetValsAtHeight(int64(trustedHeight.RevisionHeight) + 1) + suite.Require().True(found) + + clientMessage = &ibctm.Misbehaviour{ + Header1: suite.chainB.CreateTMClientHeader(suite.chainB.ChainID, suite.chainB.CurrentHeader.Height+3, trustedHeight, suite.chainB.CurrentHeader.Time.Add(time.Minute), suite.chainB.Vals, suite.chainB.NextVals, trustedVals, suite.chainB.Signers), + Header2: suite.chainB.CreateTMClientHeader(suite.chainB.ChainID, suite.chainB.CurrentHeader.Height, trustedHeight, suite.chainB.CurrentHeader.Time, suite.chainB.Vals, suite.chainB.NextVals, trustedVals, suite.chainB.Signers), + } + }, false, + }, { "consensus state already exists, app hash mismatch", func() { @@ -705,6 +737,19 @@ func (suite *TendermintTestSuite) TestCheckForMisbehaviour() { }, true, }, + { + "valid time misbehaviour: not monotonically increasing time", func() { + trustedHeight := path.EndpointA.GetClientState().GetLatestHeight().(clienttypes.Height) + + trustedVals, found := suite.chainB.GetValsAtHeight(int64(trustedHeight.RevisionHeight) + 1) + suite.Require().True(found) + + clientMessage = &ibctm.Misbehaviour{ + Header2: suite.chainB.CreateTMClientHeader(suite.chainB.ChainID, suite.chainB.CurrentHeader.Height+3, trustedHeight, suite.chainB.CurrentHeader.Time.Add(time.Minute), suite.chainB.Vals, suite.chainB.NextVals, trustedVals, suite.chainB.Signers), + Header1: suite.chainB.CreateTMClientHeader(suite.chainB.ChainID, suite.chainB.CurrentHeader.Height, trustedHeight, suite.chainB.CurrentHeader.Time, suite.chainB.Vals, suite.chainB.NextVals, trustedVals, suite.chainB.Signers), + } + }, true, + }, } for _, tc := range testCases { From 0a066f4e9bd8679c466547cb01d5bb82fbde9e71 Mon Sep 17 00:00:00 2001 From: Cian Hatton Date: Mon, 30 Jan 2023 16:46:37 +0000 Subject: [PATCH 02/22] Fix dockerfile on main (#3069) --- .github/workflows/e2e-test-workflow-call.yml | 4 +- .github/workflows/release.yml | 43 ++++++++++++-------- Dockerfile | 24 +++++++---- 3 files changed, 44 insertions(+), 27 deletions(-) diff --git a/.github/workflows/e2e-test-workflow-call.yml b/.github/workflows/e2e-test-workflow-call.yml index 1967eaa20fe..2122bab4ac0 100644 --- a/.github/workflows/e2e-test-workflow-call.yml +++ b/.github/workflows/e2e-test-workflow-call.yml @@ -57,6 +57,7 @@ jobs: echo "Chain B Tag: ${{ inputs.chain-b-tag }}" echo "Relayer Tag: ${{ inputs.relayer-tag }}" echo "Test Entry Point: ${{ inputs.test-entry-point }}" + echo "Github Ref Name: ${{ github.ref_name }}" # we skip individual steps rather than the full job as e2e-tests will not run if this task # is skipped. But will run if every individual task is skipped. There is no current way of conditionally needing @@ -88,7 +89,8 @@ jobs: context: . push: true tags: ${{ steps.meta.outputs.tags }} - labels: ${{ steps.meta.outputs.labels }} + build-args: | + IBC_GO_VERSION=${{ github.ref_name }} # dynamically build a matrix of test/test suite pairs to run build-test-matrix: diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 85961bfc954..1b7ad3ff3fa 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -32,23 +32,30 @@ jobs: env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - - name: Log in to the Container registry - uses: docker/login-action@f4ef78c080cd8ba55a85445d5b36e214a81df20a - with: - registry: ${{ env.REGISTRY }} - username: ${{ github.actor }} - password: ${{ secrets.GITHUB_TOKEN }} + publish-docker-image: + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v3 - - name: Extract metadata (tags, labels) for Docker - id: meta - uses: docker/metadata-action@507c2f2dc502c992ad446e3d7a5dfbe311567a96 - with: - images: ${{ env.REGISTRY }}/cosmos/${{ env.IMAGE_NAME }} + - name: Log in to the Container registry + uses: docker/login-action@f4ef78c080cd8ba55a85445d5b36e214a81df20a + with: + registry: ${{ env.REGISTRY }} + username: ${{ github.actor }} + password: ${{ secrets.GITHUB_TOKEN }} - - name: Build and push Docker image - uses: docker/build-push-action@37abcedcc1da61a57767b7588cb9d03eb57e28b3 - with: - context: . - push: true - tags: ${{ steps.meta.outputs.tags }} - labels: ${{ steps.meta.outputs.labels }} + - name: Extract metadata (tags, labels) for Docker + id: meta + uses: docker/metadata-action@507c2f2dc502c992ad446e3d7a5dfbe311567a96 + with: + images: ${{ env.REGISTRY }}/cosmos/${{ env.IMAGE_NAME }} + + - name: Build and push Docker image + uses: docker/build-push-action@37abcedcc1da61a57767b7588cb9d03eb57e28b3 + with: + context: . + push: true + tags: ${{ steps.meta.outputs.tags }} + build-args: | + IBC_GO_VERSION="${{ github.ref_name }}" diff --git a/Dockerfile b/Dockerfile index ffad721277c..64f76ec298a 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,27 +1,35 @@ FROM golang:1.19 as builder +ARG IBC_GO_VERSION + ENV GOPATH="" ENV GOMODULE="on" +# ensure the ibc go version is being specified for this image. +RUN test -n "${IBC_GO_VERSION}" + COPY go.mod . COPY go.sum . RUN go mod download -# TODO: add specific Dockerfile to each branch adding only the required directories. -#ADD internal internal -#ADD testing testing -#ADD modules modules -#ADD LICENSE LICENSE -#COPY contrib/devtools/Makefile contrib/devtools/Makefile -#COPY Makefile . +ADD internal internal +ADD testing testing +ADD modules modules +ADD LICENSE LICENSE + +COPY contrib/devtools/Makefile contrib/devtools/Makefile +COPY Makefile . -ADD . . RUN make build FROM ubuntu:20.04 +ARG IBC_GO_VERSION + +LABEL "org.cosmos.ibc-go" "${IBC_GO_VERSION}" + COPY --from=builder /go/build/simd /bin/simd ENTRYPOINT ["simd"] From 360f271798c150e9c36be70920bc1461bedb23c1 Mon Sep 17 00:00:00 2001 From: Cian Hatton Date: Mon, 30 Jan 2023 17:15:13 +0000 Subject: [PATCH 03/22] Updating build simd image workflow (#3060) --- .github/workflows/build-simd-image-from-tag.yml | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build-simd-image-from-tag.yml b/.github/workflows/build-simd-image-from-tag.yml index fb3d481d6cd..5ac105b9c88 100644 --- a/.github/workflows/build-simd-image-from-tag.yml +++ b/.github/workflows/build-simd-image-from-tag.yml @@ -6,6 +6,10 @@ on: description: 'The tag of the image to build' required: true type: string + ibc-go-version: + description: 'The ibc-go version to be added as a label' + required: true + type: string env: REGISTRY: ghcr.io @@ -27,11 +31,9 @@ jobs: registry: ${{ env.REGISTRY }} username: ${{ github.actor }} password: ${{ secrets.GITHUB_TOKEN }} - - name: Fetch latest Dockerfile - run: curl https://raw.githubusercontent.com/cosmos/ibc-go/main/Dockerfile -o Dockerfile - name: Build image run: | # remove any `/` characters from the docker tag and replace them with a - docker_tag="$(echo $GIT_TAG | sed 's/\//-/')" - docker build . -t "${REGISTRY}/${ORG}/${IMAGE_NAME}:${docker_tag}" + docker build . -t "${REGISTRY}/${ORG}/${IMAGE_NAME}:${docker_tag}" --build-arg IBC_GO_VERSION=${{ inputs.ibc-go-version }} docker push "${REGISTRY}/${ORG}/${IMAGE_NAME}:${docker_tag}" From 05c21483c0219f6b592a8307efe386d7320b3cfa Mon Sep 17 00:00:00 2001 From: Cian Hatton Date: Tue, 31 Jan 2023 09:23:32 +0000 Subject: [PATCH 04/22] Ensure we never use the Dockerfile on main when working with other branches (#3071) --- .github/workflows/e2e-compatibility.yaml | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/.github/workflows/e2e-compatibility.yaml b/.github/workflows/e2e-compatibility.yaml index a1f55cb0b9d..3b87973655c 100644 --- a/.github/workflows/e2e-compatibility.yaml +++ b/.github/workflows/e2e-compatibility.yaml @@ -15,6 +15,10 @@ on: - release/v6.1.x - release/v7.0.x - main + ibc-go-version: + description: 'The version of ibc-go that is going to be released' + required: true + type: string env: REGISTRY: ghcr.io @@ -62,20 +66,17 @@ jobs: registry: ${{ env.REGISTRY }} username: ${{ github.actor }} password: ${{ secrets.GITHUB_TOKEN }} - - name: Fetch Makefile dependencies - if: env.RELEASE_BRANCH == matrix.release-branch - run: | - mkdir -p contrib/devtools - curl https://raw.githubusercontent.com/cosmos/ibc-go/main/contrib/devtools/Makefile -o contrib/devtools/Makefile - - name: Fetch latest Dockerfile - if: env.RELEASE_BRANCH == matrix.release-branch - run: curl https://raw.githubusercontent.com/cosmos/ibc-go/main/Dockerfile -o Dockerfile - name: Build image if: env.RELEASE_BRANCH == matrix.release-branch run: | docker_tag="$(echo ${{ matrix.release-branch }} | sed 's/\//-/')" - docker build . -t "${REGISTRY}/${ORG}/${IMAGE_NAME}:$docker_tag" + docker build . -t "${REGISTRY}/${ORG}/${IMAGE_NAME}:$docker_tag" --build-arg IBC_GO_VERSION=${{ inputs.ibc-go-version }} docker push "${REGISTRY}/${ORG}/${IMAGE_NAME}:$docker_tag" + - name: Display image details + if: env.RELEASE_BRANCH == matrix.release-branch + run: | + docker_tag="$(echo ${{ matrix.release-branch }} | sed 's/\//-/')" + docker inspect "${REGISTRY}/${ORG}/${IMAGE_NAME}:$docker_tag" transfer-chain-a: needs: From b2fb1192245134607e0e7a294d09d2aa1145f017 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Federico=20Kunze=20K=C3=BCllmer?= <31522760+fedekunze@users.noreply.github.com> Date: Tue, 31 Jan 2023 14:02:31 +0100 Subject: [PATCH 05/22] chore: Add `HasConnection` and `HasChannel` methods. (#3082) --- CHANGELOG.md | 1 + modules/apps/29-fee/keeper/keeper.go | 2 +- modules/apps/transfer/keeper/keeper.go | 2 +- modules/core/02-client/keeper/keeper.go | 6 +++--- modules/core/02-client/migrations/v7/store.go | 2 +- modules/core/03-connection/keeper/keeper.go | 13 +++++++++--- modules/core/04-channel/keeper/keeper.go | 20 ++++++++++++------- modules/core/04-channel/keeper/keeper_test.go | 2 +- modules/light-clients/07-tendermint/store.go | 8 ++++---- 9 files changed, 35 insertions(+), 21 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 37f779bc1af..8a57b0c155e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -68,6 +68,7 @@ Ref: https://keepachangelog.com/en/1.0.0/ ### Improvements +* (core) [\#3082](https://github.com/cosmos/ibc-go/pull/3082) Add `HasConnection` and `HasChannel` methods. * (tests) [\#2926](https://github.com/cosmos/ibc-go/pull/2926) Lint tests * (apps/transfer) [\#2643](https://github.com/cosmos/ibc-go/pull/2643) Add amount, denom, and memo to transfer event emission. * (core) [\#2746](https://github.com/cosmos/ibc-go/pull/2746) Allow proof height to be zero for all core IBC `sdk.Msg` types that contain proofs. diff --git a/modules/apps/29-fee/keeper/keeper.go b/modules/apps/29-fee/keeper/keeper.go index 7db7cbd3e46..e2c1691041e 100644 --- a/modules/apps/29-fee/keeper/keeper.go +++ b/modules/apps/29-fee/keeper/keeper.go @@ -291,7 +291,7 @@ func (k Keeper) GetFeesInEscrow(ctx sdk.Context, packetID channeltypes.PacketId) store := ctx.KVStore(k.storeKey) key := types.KeyFeesInEscrow(packetID) bz := store.Get(key) - if bz == nil { + if len(bz) == 0 { return types.PacketFees{}, false } diff --git a/modules/apps/transfer/keeper/keeper.go b/modules/apps/transfer/keeper/keeper.go index 9b382966ef4..c478b5a6eea 100644 --- a/modules/apps/transfer/keeper/keeper.go +++ b/modules/apps/transfer/keeper/keeper.go @@ -93,7 +93,7 @@ func (k Keeper) SetPort(ctx sdk.Context, portID string) { func (k Keeper) GetDenomTrace(ctx sdk.Context, denomTraceHash tmbytes.HexBytes) (types.DenomTrace, bool) { store := prefix.NewStore(ctx.KVStore(k.storeKey), types.DenomTraceKey) bz := store.Get(denomTraceHash) - if bz == nil { + if len(bz) == 0 { return types.DenomTrace{}, false } diff --git a/modules/core/02-client/keeper/keeper.go b/modules/core/02-client/keeper/keeper.go index a3ce022f9b0..55c577d609d 100644 --- a/modules/core/02-client/keeper/keeper.go +++ b/modules/core/02-client/keeper/keeper.go @@ -67,7 +67,7 @@ func (k Keeper) GenerateClientIdentifier(ctx sdk.Context, clientType string) str func (k Keeper) GetClientState(ctx sdk.Context, clientID string) (exported.ClientState, bool) { store := k.ClientStore(ctx, clientID) bz := store.Get(host.ClientStateKey()) - if bz == nil { + if len(bz) == 0 { return nil, false } @@ -85,7 +85,7 @@ func (k Keeper) SetClientState(ctx sdk.Context, clientID string, clientState exp func (k Keeper) GetClientConsensusState(ctx sdk.Context, clientID string, height exported.Height) (exported.ConsensusState, bool) { store := k.ClientStore(ctx, clientID) bz := store.Get(host.ConsensusStateKey(height)) - if bz == nil { + if len(bz) == 0 { return nil, false } @@ -104,7 +104,7 @@ func (k Keeper) SetClientConsensusState(ctx sdk.Context, clientID string, height func (k Keeper) GetNextClientSequence(ctx sdk.Context) uint64 { store := ctx.KVStore(k.storeKey) bz := store.Get([]byte(types.KeyNextClientSequence)) - if bz == nil { + if len(bz) == 0 { panic("next client sequence is nil") } diff --git a/modules/core/02-client/migrations/v7/store.go b/modules/core/02-client/migrations/v7/store.go index e62a975341b..b70e541e671 100644 --- a/modules/core/02-client/migrations/v7/store.go +++ b/modules/core/02-client/migrations/v7/store.go @@ -58,7 +58,7 @@ func handleSolomachineMigration(ctx sdk.Context, store sdk.KVStore, cdc codec.Bi clientStore := clientKeeper.ClientStore(ctx, clientID) bz := clientStore.Get(host.ClientStateKey()) - if bz == nil { + if len(bz) == 0 { return sdkerrors.Wrapf(clienttypes.ErrClientNotFound, "clientID %s", clientID) } diff --git a/modules/core/03-connection/keeper/keeper.go b/modules/core/03-connection/keeper/keeper.go index 9a4335148d9..3eb291cf8ad 100644 --- a/modules/core/03-connection/keeper/keeper.go +++ b/modules/core/03-connection/keeper/keeper.go @@ -66,7 +66,7 @@ func (k Keeper) GenerateConnectionIdentifier(ctx sdk.Context) string { func (k Keeper) GetConnection(ctx sdk.Context, connectionID string) (types.ConnectionEnd, bool) { store := ctx.KVStore(k.storeKey) bz := store.Get(host.ConnectionKey(connectionID)) - if bz == nil { + if len(bz) == 0 { return types.ConnectionEnd{}, false } @@ -76,6 +76,13 @@ func (k Keeper) GetConnection(ctx sdk.Context, connectionID string) (types.Conne return connection, true } +// HasConnection returns a true if the connection with the given identifier +// exists in the store. +func (k Keeper) HasConnection(ctx sdk.Context, connectionID string) bool { + store := ctx.KVStore(k.storeKey) + return store.Has(host.ConnectionKey(connectionID)) +} + // SetConnection sets a connection to the store func (k Keeper) SetConnection(ctx sdk.Context, connectionID string, connection types.ConnectionEnd) { store := ctx.KVStore(k.storeKey) @@ -106,7 +113,7 @@ func (k Keeper) GetTimestampAtHeight(ctx sdk.Context, connection types.Connectio func (k Keeper) GetClientConnectionPaths(ctx sdk.Context, clientID string) ([]string, bool) { store := ctx.KVStore(k.storeKey) bz := store.Get(host.ClientConnectionsKey(clientID)) - if bz == nil { + if len(bz) == 0 { return nil, false } @@ -127,7 +134,7 @@ func (k Keeper) SetClientConnectionPaths(ctx sdk.Context, clientID string, paths func (k Keeper) GetNextConnectionSequence(ctx sdk.Context) uint64 { store := ctx.KVStore(k.storeKey) bz := store.Get([]byte(types.KeyNextConnectionSequence)) - if bz == nil { + if len(bz) == 0 { panic("next connection sequence is nil") } diff --git a/modules/core/04-channel/keeper/keeper.go b/modules/core/04-channel/keeper/keeper.go index d86f0d9bf5f..b83d6b2f6bf 100644 --- a/modules/core/04-channel/keeper/keeper.go +++ b/modules/core/04-channel/keeper/keeper.go @@ -66,11 +66,17 @@ func (k Keeper) GenerateChannelIdentifier(ctx sdk.Context) string { return channelID } +// HasChannel true if the channel with the given identifiers exists in state. +func (k Keeper) HasChannel(ctx sdk.Context, portID, channelID string) bool { + store := ctx.KVStore(k.storeKey) + return store.Has(host.ChannelKey(portID, channelID)) +} + // GetChannel returns a channel with a particular identifier binded to a specific port func (k Keeper) GetChannel(ctx sdk.Context, portID, channelID string) (types.Channel, bool) { store := ctx.KVStore(k.storeKey) bz := store.Get(host.ChannelKey(portID, channelID)) - if bz == nil { + if len(bz) == 0 { return types.Channel{}, false } @@ -100,7 +106,7 @@ func (k Keeper) GetAppVersion(ctx sdk.Context, portID, channelID string) (string func (k Keeper) GetNextChannelSequence(ctx sdk.Context) uint64 { store := ctx.KVStore(k.storeKey) bz := store.Get([]byte(types.KeyNextChannelSequence)) - if bz == nil { + if len(bz) == 0 { panic("next channel sequence is nil") } @@ -118,7 +124,7 @@ func (k Keeper) SetNextChannelSequence(ctx sdk.Context, sequence uint64) { func (k Keeper) GetNextSequenceSend(ctx sdk.Context, portID, channelID string) (uint64, bool) { store := ctx.KVStore(k.storeKey) bz := store.Get(host.NextSequenceSendKey(portID, channelID)) - if bz == nil { + if len(bz) == 0 { return 0, false } @@ -136,7 +142,7 @@ func (k Keeper) SetNextSequenceSend(ctx sdk.Context, portID, channelID string, s func (k Keeper) GetNextSequenceRecv(ctx sdk.Context, portID, channelID string) (uint64, bool) { store := ctx.KVStore(k.storeKey) bz := store.Get(host.NextSequenceRecvKey(portID, channelID)) - if bz == nil { + if len(bz) == 0 { return 0, false } @@ -154,7 +160,7 @@ func (k Keeper) SetNextSequenceRecv(ctx sdk.Context, portID, channelID string, s func (k Keeper) GetNextSequenceAck(ctx sdk.Context, portID, channelID string) (uint64, bool) { store := ctx.KVStore(k.storeKey) bz := store.Get(host.NextSequenceAckKey(portID, channelID)) - if bz == nil { + if len(bz) == 0 { return 0, false } @@ -172,7 +178,7 @@ func (k Keeper) SetNextSequenceAck(ctx sdk.Context, portID, channelID string, se func (k Keeper) GetPacketReceipt(ctx sdk.Context, portID, channelID string, sequence uint64) (string, bool) { store := ctx.KVStore(k.storeKey) bz := store.Get(host.PacketReceiptKey(portID, channelID, sequence)) - if bz == nil { + if len(bz) == 0 { return "", false } @@ -219,7 +225,7 @@ func (k Keeper) SetPacketAcknowledgement(ctx sdk.Context, portID, channelID stri func (k Keeper) GetPacketAcknowledgement(ctx sdk.Context, portID, channelID string, sequence uint64) ([]byte, bool) { store := ctx.KVStore(k.storeKey) bz := store.Get(host.PacketAcknowledgementKey(portID, channelID, sequence)) - if bz == nil { + if len(bz) == 0 { return nil, false } return bz, true diff --git a/modules/core/04-channel/keeper/keeper_test.go b/modules/core/04-channel/keeper/keeper_test.go index 0a262508ae5..92afaba9135 100644 --- a/modules/core/04-channel/keeper/keeper_test.go +++ b/modules/core/04-channel/keeper/keeper_test.go @@ -46,7 +46,7 @@ func (suite *KeeperTestSuite) TestSetChannel() { suite.coordinator.SetupConnections(path) // check for channel to be created on chainA - _, found := suite.chainA.App.GetIBCKeeper().ChannelKeeper.GetChannel(suite.chainA.GetContext(), path.EndpointA.ChannelConfig.PortID, path.EndpointA.ChannelID) + found := suite.chainA.App.GetIBCKeeper().ChannelKeeper.HasChannel(suite.chainA.GetContext(), path.EndpointA.ChannelConfig.PortID, path.EndpointA.ChannelID) suite.False(found) path.SetChannelOrdered() diff --git a/modules/light-clients/07-tendermint/store.go b/modules/light-clients/07-tendermint/store.go index da5e2a4e9c3..8f992bc5183 100644 --- a/modules/light-clients/07-tendermint/store.go +++ b/modules/light-clients/07-tendermint/store.go @@ -60,7 +60,7 @@ func setConsensusState(clientStore sdk.KVStore, cdc codec.BinaryCodec, consensus // If the ConsensusState does not exist in state for the provided height a nil value and false boolean flag is returned func GetConsensusState(store sdk.KVStore, cdc codec.BinaryCodec, height exported.Height) (*ConsensusState, bool) { bz := store.Get(host.ConsensusStateKey(height)) - if bz == nil { + if len(bz) == 0 { return nil, false } @@ -129,7 +129,7 @@ func SetProcessedTime(clientStore sdk.KVStore, height exported.Height, timeNs ui func GetProcessedTime(clientStore sdk.KVStore, height exported.Height) (uint64, bool) { key := ProcessedTimeKey(height) bz := clientStore.Get(key) - if bz == nil { + if len(bz) == 0 { return 0, false } return sdk.BigEndianToUint64(bz), true @@ -160,7 +160,7 @@ func SetProcessedHeight(clientStore sdk.KVStore, consHeight, processedHeight exp func GetProcessedHeight(clientStore sdk.KVStore, height exported.Height) (exported.Height, bool) { key := ProcessedHeightKey(height) bz := clientStore.Get(key) - if bz == nil { + if len(bz) == 0 { return nil, false } processedHeight, err := clienttypes.ParseHeight(string(bz)) @@ -306,7 +306,7 @@ func PruneAllExpiredConsensusStates( // Helper function for GetNextConsensusState and GetPreviousConsensusState func getTmConsensusState(clientStore sdk.KVStore, cdc codec.BinaryCodec, key []byte) (*ConsensusState, bool) { bz := clientStore.Get(key) - if bz == nil { + if len(bz) == 0 { return nil, false } From 3b1e06c18af7c227b96d9d8351283135f216d726 Mon Sep 17 00:00:00 2001 From: Cian Hatton Date: Wed, 1 Feb 2023 11:19:42 +0000 Subject: [PATCH 06/22] Allow specification of arbitrary values when running e2e tests (#3036) --- .github/workflows/e2e-manual-simd.yaml | 19 ++++++++++++++++--- 1 file changed, 16 insertions(+), 3 deletions(-) diff --git a/.github/workflows/e2e-manual-simd.yaml b/.github/workflows/e2e-manual-simd.yaml index 5fd0176e835..55fb1e771c2 100644 --- a/.github/workflows/e2e-manual-simd.yaml +++ b/.github/workflows/e2e-manual-simd.yaml @@ -22,6 +22,11 @@ on: required: true type: string default: "ghcr.io/cosmos/ibc-go-simd" + chain-binary: + description: 'Specify the chain binary to be used' + required: true + type: string + default: "simd" chain-a-tag: description: 'The tag to use for chain A' required: true @@ -37,6 +42,10 @@ on: - v3.3.1 - v2.5.0 - v2.4.2 + chain-a-tag-override: + description: 'Specify an arbitrary tag for chain A' + required: false + type: string chain-b-tag: default: v6.0.0 description: 'The tag to use for chain B' @@ -52,6 +61,10 @@ on: - v3.3.1 - v2.5.0 - v2.4.2 + chain-b-tag-override: + description: 'Specify an arbitrary tag for chain B' + required: false + type: string relayer-tag: description: 'The tag to use for the relayer' required: true @@ -64,8 +77,8 @@ jobs: uses: ./.github/workflows/e2e-test-workflow-call.yml with: chain-image: "${{ github.event.inputs.chain-image }}" - chain-a-tag: "${{ github.event.inputs.chain-a-tag }}" - chain-b-tag: "${{ github.event.inputs.chain-b-tag }}" + chain-a-tag: "${{ github.event.inputs.chain-a-tag-override || github.event.inputs.chain-a-tag }}" + chain-b-tag: "${{ github.event.inputs.chain-b-tag-override || github.event.inputs.chain-b-tag }}" relayer-tag: "${{ github.event.inputs.relayer-tag }}" test-entry-point: "${{ github.event.inputs.test-entry-point }}" - chain-binary: "simd" + chain-binary: "${{ github.event.inputs.chain-binary }}" From 519e4acb1832c787afa0fa16f1131d6ec3c15ad1 Mon Sep 17 00:00:00 2001 From: Carlos Rodriguez Date: Wed, 1 Feb 2023 15:23:04 +0100 Subject: [PATCH 07/22] followup from review comments for #2709 (#3027) ## Description This PR addresses these two comments from #2709: - [This comment about using the suffix `Fn`](https://github.com/cosmos/ibc-go/pull/2709#discussion_r1024070188). - [This comment about adding `doc.go` for packages](https://github.com/cosmos/ibc-go/pull/2709#discussion_r1080734398). closes: #XXXX ### Commit Message / Changelog Entry ```bash type: commit message ``` see the [guidelines](https://github.com/cosmos/ibc-go/blob/main/CONTRIBUTING.md#commit-messages) for commit messages. (view raw markdown for examples) --- Before we can merge this PR, please make sure that all the following items have been checked off. If any of the checklist items are not applicable, please leave them but write a little note why. - [ ] Targeted PR against correct branch (see [CONTRIBUTING.md](https://github.com/cosmos/ibc-go/blob/master/CONTRIBUTING.md#pr-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/building-modules/10-structure.md). - [ ] Wrote unit and integration [tests](https://github.com/cosmos/ibc-go/blob/master/CONTRIBUTING.md#testing). - [ ] Updated relevant documentation (`docs/`) or specification (`x//spec/`). - [ ] Added relevant `godoc` [comments](https://blog.golang.org/godoc-documenting-go-code). - [ ] Provide a [commit message](https://github.com/cosmos/ibc-go/blob/main/CONTRIBUTING.md#commit-messages) to be used for the changelog entry in the PR description for review. - [ ] Re-reviewed `Files changed` in the Github PR explorer. - [ ] Review `Codecov Report` in the comment section below once CI passes. --- modules/apps/27-interchain-accounts/doc.go | 8 ++++++++ modules/apps/29-fee/doc.go | 9 +++++++++ modules/apps/transfer/doc.go | 8 ++++++++ modules/apps/transfer/keeper/mbt_relay_test.go | 8 ++++---- modules/core/02-client/doc.go | 7 ++----- modules/core/03-connection/doc.go | 12 ++++++++++++ modules/core/04-channel/doc.go | 17 +++++++++++++++++ modules/core/05-port/doc.go | 7 +++++++ modules/core/24-host/doc.go | 6 +++--- modules/core/keeper/keeper_test.go | 12 ++++++------ modules/light-clients/06-solomachine/doc.go | 8 ++++---- modules/light-clients/07-tendermint/doc.go | 6 ++++-- testing/simapp/params/doc.go | 4 ++-- 13 files changed, 86 insertions(+), 26 deletions(-) create mode 100644 modules/apps/27-interchain-accounts/doc.go create mode 100644 modules/apps/29-fee/doc.go create mode 100644 modules/apps/transfer/doc.go create mode 100644 modules/core/03-connection/doc.go create mode 100644 modules/core/04-channel/doc.go create mode 100644 modules/core/05-port/doc.go diff --git a/modules/apps/27-interchain-accounts/doc.go b/modules/apps/27-interchain-accounts/doc.go new file mode 100644 index 00000000000..b31e3a63d3e --- /dev/null +++ b/modules/apps/27-interchain-accounts/doc.go @@ -0,0 +1,8 @@ +/* +Package ica implements the packet data structure, state machine handling logic, +and encoding details for the account management system over an IBC channel +between separate chains. +This implementation is based off the ICS 27 specification +(https://github.com/cosmos/ibc/tree/main/spec/app/ics-027-interchain-accounts) +*/ +package ica diff --git a/modules/apps/29-fee/doc.go b/modules/apps/29-fee/doc.go new file mode 100644 index 00000000000..236b88b522c --- /dev/null +++ b/modules/apps/29-fee/doc.go @@ -0,0 +1,9 @@ +/* +Package fee implements the packet data structure, state machine handling logic, +and encoding details for handling fee payments on top of any ICS application protocol. +This implementation is based off the ICS 29 specification +(https://github.com/cosmos/ibc/tree/main/spec/app/ics-029-fee-payment) and follows +the middleware pattern specified in the ICS 30 specification +(https://github.com/cosmos/ibc/tree/main/spec/app/ics-030-middleware). +*/ +package fee diff --git a/modules/apps/transfer/doc.go b/modules/apps/transfer/doc.go new file mode 100644 index 00000000000..e1e1d79b424 --- /dev/null +++ b/modules/apps/transfer/doc.go @@ -0,0 +1,8 @@ +/* +Package transfer implements the packet data structure, state machine handling logic, +and encoding details for the transfer of fungible tokens over an IBC channel between +two modules on separate chains. +This implementation is based off the ICS 20 specification +(https://github.com/cosmos/ibc/blob/main/spec/app/ics-020-fungible-token-transfer) +*/ +package transfer diff --git a/modules/apps/transfer/keeper/mbt_relay_test.go b/modules/apps/transfer/keeper/mbt_relay_test.go index 2a8f2f84132..92e190ce9b3 100644 --- a/modules/apps/transfer/keeper/mbt_relay_test.go +++ b/modules/apps/transfer/keeper/mbt_relay_test.go @@ -303,7 +303,7 @@ func (suite *KeeperTestSuite) TestModelBasedRelay() { for i, tlaTc := range tlaTestCases { tc := OnRecvPacketTestCaseFromTla(tlaTc) - registerDenom := func() { + registerDenomFn := func() { denomTrace := types.ParseDenomTrace(tc.packet.Data.Denom) traceHash := denomTrace.Hash() if !suite.chainB.GetSimApp().TransferKeeper.HasDenomTrace(suite.chainB.GetContext(), traceHash) { @@ -330,7 +330,7 @@ func (suite *KeeperTestSuite) TestModelBasedRelay() { if err != nil { panic("MBT failed to convert sender address") } - registerDenom() + registerDenomFn() denomTrace := types.ParseDenomTrace(tc.packet.Data.Denom) denom := denomTrace.IBCDenom() err = sdk.ValidateDenom(denom) @@ -355,14 +355,14 @@ func (suite *KeeperTestSuite) TestModelBasedRelay() { case "OnRecvPacket": err = suite.chainB.GetSimApp().TransferKeeper.OnRecvPacket(suite.chainB.GetContext(), packet, tc.packet.Data) case "OnTimeoutPacket": - registerDenom() + registerDenomFn() err = suite.chainB.GetSimApp().TransferKeeper.OnTimeoutPacket(suite.chainB.GetContext(), packet, tc.packet.Data) case "OnRecvAcknowledgementResult": err = suite.chainB.GetSimApp().TransferKeeper.OnAcknowledgementPacket( suite.chainB.GetContext(), packet, tc.packet.Data, channeltypes.NewResultAcknowledgement(nil)) case "OnRecvAcknowledgementError": - registerDenom() + registerDenomFn() err = suite.chainB.GetSimApp().TransferKeeper.OnAcknowledgementPacket( suite.chainB.GetContext(), packet, tc.packet.Data, channeltypes.NewErrorAcknowledgement(fmt.Errorf("MBT Error Acknowledgement"))) diff --git a/modules/core/02-client/doc.go b/modules/core/02-client/doc.go index abb7f35fff3..34fcb5d432d 100644 --- a/modules/core/02-client/doc.go +++ b/modules/core/02-client/doc.go @@ -1,10 +1,7 @@ /* Package client implements the ICS 02 - Client Semantics specification -https://github.com/cosmos/ibc/tree/master/spec/core/ics-002-client-semantics. This -concrete implementations defines types and method to store and update light +(https://github.com/cosmos/ibc/tree/master/spec/core/ics-002-client-semantics). This +concrete implementation defines types and methods to store and update light clients which tracks on other chain's state. - -The main type is `Client`, which provides `commitment.Root` to verify state proofs and `ConsensusState` to -verify header proofs. */ package client diff --git a/modules/core/03-connection/doc.go b/modules/core/03-connection/doc.go new file mode 100644 index 00000000000..9f89e3bbf67 --- /dev/null +++ b/modules/core/03-connection/doc.go @@ -0,0 +1,12 @@ +/* +Package connection implements the ICS 03 - Connection Semantics specification +(https://github.com/cosmos/ibc/tree/main/spec/core/ics-003-connection-semantics). This +concrete implementation defines types and methods for safely creating two +stateful objects (connection ends) on two separate chains, each associated with a +light client of the other chain, which together facilitate cross-chain +sub-state verification and packet association (through channels). + +The main type is ConnectionEnd, which defines a stateful object on a +chain connected to another. +*/ +package connection diff --git a/modules/core/04-channel/doc.go b/modules/core/04-channel/doc.go new file mode 100644 index 00000000000..f5c537df089 --- /dev/null +++ b/modules/core/04-channel/doc.go @@ -0,0 +1,17 @@ +/* +Package channel implements the ICS 04 - Channel and Packet Semantics specification +(https://github.com/cosmos/ibc/tree/main/spec/core/ics-004-channel-and-packet-semantics). This +concrete implementation defines types and methods for safely creating two +stateful objects (channel ends) on two separate chains, each associated with a +particular connection. A channel serves as a conduit for packets passing between a +module on one chain and a module on another, ensuring that packets are executed +only once, delivered in the order in which they were sent (if necessary), +and delivered only to the corresponding module owning the other end of the +channel on the destination chain. + +The main types are Channel, which defines a stateful object on a +chain that allows for exactly-once packet delivery between specific modules +on separate blockchains, and Packet, which defines the data carried +across different chains through IBC. +*/ +package channel diff --git a/modules/core/05-port/doc.go b/modules/core/05-port/doc.go new file mode 100644 index 00000000000..0ff91c0fe47 --- /dev/null +++ b/modules/core/05-port/doc.go @@ -0,0 +1,7 @@ +/* +Package port implements the ICS 05 - Port Allocation specification +(https://github.com/cosmos/ibc/tree/main/spec/core/ics-005-port-allocation). This +concrete implementation defines types and methods with which modules can bind +to uniquely named ports allocated by the IBC handler. +*/ +package port diff --git a/modules/core/24-host/doc.go b/modules/core/24-host/doc.go index 4e5eaa556be..c7bf710c597 100644 --- a/modules/core/24-host/doc.go +++ b/modules/core/24-host/doc.go @@ -1,8 +1,8 @@ /* -24-host is an implementation of ICS24. +24-host is an implementation of ICS 24. -The storage path supported are defined in [ICS24](https://github.com/cosmos/ibc/blob/master/spec/core/ics-024-host-requirements#path-space). +The storage path supported are defined in ICS 24 (https://github.com/cosmos/ibc/blob/master/spec/core/ics-024-host-requirements#path-space). -Hostname validation is implemented as defined in [ICS 24](https://github.com/cosmos/ibc/tree/master/spec/core/ics-024-host-requirements). +Hostname validation is implemented as defined in ICS 24 (https://github.com/cosmos/ibc/tree/master/spec/core/ics-024-host-requirements). */ package host diff --git a/modules/core/keeper/keeper_test.go b/modules/core/keeper/keeper_test.go index cbd3fe30f7a..60dd960ccba 100644 --- a/modules/core/keeper/keeper_test.go +++ b/modules/core/keeper/keeper_test.go @@ -59,10 +59,10 @@ func (d MockStakingKeeper) UnbondingTime(ctx sdk.Context) time.Duration { // It verifies if ibckeeper.NewKeeper panic when any of the keepers passed in is empty. func (suite *KeeperTestSuite) TestNewKeeper() { var ( - stakingKeeper clienttypes.StakingKeeper - upgradeKeeper clienttypes.UpgradeKeeper - scopedKeeper capabilitykeeper.ScopedKeeper - newIBCKeeper = func() { + stakingKeeper clienttypes.StakingKeeper + upgradeKeeper clienttypes.UpgradeKeeper + scopedKeeper capabilitykeeper.ScopedKeeper + newIBCKeeperFn = func() { ibckeeper.NewKeeper( suite.chainA.GetSimApp().AppCodec(), suite.chainA.GetSimApp().GetKey(ibcexported.StoreKey), @@ -131,11 +131,11 @@ func (suite *KeeperTestSuite) TestNewKeeper() { if tc.expPass { suite.Require().NotPanics( - newIBCKeeper, + newIBCKeeperFn, ) } else { suite.Require().Panics( - newIBCKeeper, + newIBCKeeperFn, ) } }) diff --git a/modules/light-clients/06-solomachine/doc.go b/modules/light-clients/06-solomachine/doc.go index bbd5fb48493..c4d15dfdc76 100644 --- a/modules/light-clients/06-solomachine/doc.go +++ b/modules/light-clients/06-solomachine/doc.go @@ -1,7 +1,7 @@ /* -Package solomachine implements a concrete `ConsensusState`, `Header`, -`Misbehaviour` and `Equivocation` types for the Solo Machine light client. -This implementation is based off the ICS 06 specification: -https://github.com/cosmos/ibc/tree/master/spec/client/ics-006-solo-machine-client +Package solomachine implements a concrete ClientState, ConsensusState, +Header and Misbehaviour types for the Solo Machine light client. +This implementation is based off the ICS 06 specification +(https://github.com/cosmos/ibc/tree/master/spec/client/ics-006-solo-machine-client) */ package solomachine diff --git a/modules/light-clients/07-tendermint/doc.go b/modules/light-clients/07-tendermint/doc.go index 26aa430a82d..85f183b8d9d 100644 --- a/modules/light-clients/07-tendermint/doc.go +++ b/modules/light-clients/07-tendermint/doc.go @@ -1,5 +1,7 @@ /* -Package tendermint implements a concrete `ConsensusState`, `Header`, -`Misbehaviour` and `Equivocation` types for the Tendermint consensus light client. +Package tendermint implements a concrete ClientState, ConsensusState, +Header, Misbehaviour and types for the Tendermint consensus light client. +This implementation is based off the ICS 07 specification +(https://github.com/cosmos/ibc/tree/main/spec/client/ics-007-tendermint-client) */ package tendermint diff --git a/testing/simapp/params/doc.go b/testing/simapp/params/doc.go index 1c721342a9c..bef67c83b3d 100644 --- a/testing/simapp/params/doc.go +++ b/testing/simapp/params/doc.go @@ -13,7 +13,7 @@ file with the weights defined for each of the transaction operations: "op_weight_msg_delegate": 100, } -In the example above, the `MsgSend` has 60% chance to be simulated, while the -`MsgDelegate` will always be simulated. +In the example above, the MsgSend has 60% chance to be simulated, while the +MsgDelegate will always be simulated. */ package params From 1a204fed036f37d49fee052b067c8452224112e7 Mon Sep 17 00:00:00 2001 From: Marko Date: Wed, 1 Feb 2023 16:27:46 +0100 Subject: [PATCH 08/22] deps: Update to Cosmos SDK v0.47 rc-2 (#3095) Co-authored-by: Marko Baricevic Co-authored-by: Cian Hatton --- e2e/go.mod | 10 ++++------ e2e/go.sum | 19 ++++++++----------- go.mod | 10 ++++------ go.sum | 19 ++++++++----------- .../host/keeper/relay_test.go | 4 ++-- modules/apps/27-interchain-accounts/module.go | 4 ++-- .../simulation/params.go | 8 ++++---- modules/apps/29-fee/module.go | 4 ++-- modules/apps/transfer/module.go | 4 ++-- modules/apps/transfer/simulation/params.go | 8 ++++---- modules/core/module.go | 4 ++-- testing/simapp/utils.go | 3 ++- 12 files changed, 44 insertions(+), 53 deletions(-) diff --git a/e2e/go.mod b/e2e/go.mod index 66aac939a69..2cfda8e3f33 100644 --- a/e2e/go.mod +++ b/e2e/go.mod @@ -3,8 +3,8 @@ module github.com/cosmos/ibc-go/e2e go 1.19 require ( - github.com/cosmos/cosmos-sdk v0.47.0-rc1 - github.com/cosmos/gogoproto v1.4.3 + github.com/cosmos/cosmos-sdk v0.47.0-rc2 + github.com/cosmos/gogoproto v1.4.4 github.com/cosmos/ibc-go/v7 v7.0.0-20230120105519-ae96bf3d5ee9 github.com/cosmos/interchain-accounts v0.4.1-0.20230116203650-08d2a4529a5d github.com/docker/docker v20.10.19+incompatible @@ -41,7 +41,7 @@ require ( github.com/benbjohnson/clock v1.3.0 // indirect github.com/beorn7/perks v1.0.1 // indirect github.com/bgentry/go-netrc v0.0.0-20140422174119-9fd32a8b3d3d // indirect - github.com/bgentry/speakeasy v0.1.0 // indirect + github.com/bgentry/speakeasy v0.1.1-0.20220910012023-760eaf8b6816 // indirect github.com/btcsuite/btcd v0.22.3 // indirect github.com/btcsuite/btcd/btcec/v2 v2.3.2 // indirect github.com/cenkalti/backoff/v4 v4.1.3 // indirect @@ -56,7 +56,7 @@ require ( github.com/cosmos/go-bip39 v1.0.0 // indirect github.com/cosmos/gogogateway v1.2.0 // indirect github.com/cosmos/gorocksdb v1.2.0 // indirect - github.com/cosmos/iavl v0.19.4 // indirect + github.com/cosmos/iavl v0.19.5-rc.1 // indirect github.com/cosmos/ics23/go v0.9.1-0.20221207100636-b1abd8678aab // indirect github.com/cosmos/ledger-cosmos-go v0.12.1 // indirect github.com/cosmos/rosetta-sdk-go v0.9.0 // indirect @@ -177,8 +177,6 @@ require ( github.com/spf13/viper v1.15.0 // indirect github.com/subosito/gotenv v1.4.2 // indirect github.com/syndtr/goleveldb v1.0.1-0.20220614013038-64ee5596c38a // indirect - github.com/tendermint/btcd v0.1.1 // indirect - github.com/tendermint/crypto v0.0.0-20191022145703-50d29ede1e15 // indirect github.com/tendermint/go-amino v0.16.0 // indirect github.com/tendermint/tendermint v0.37.0-rc2 // indirect github.com/tendermint/tm-db v0.6.7 // indirect diff --git a/e2e/go.sum b/e2e/go.sum index 24a8e96c79c..0147e4233ab 100644 --- a/e2e/go.sum +++ b/e2e/go.sum @@ -122,8 +122,9 @@ github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM= github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6rlkpw= github.com/bgentry/go-netrc v0.0.0-20140422174119-9fd32a8b3d3d h1:xDfNPAt8lFiC1UJrqV3uuy861HCTo708pDMbjHHdCas= github.com/bgentry/go-netrc v0.0.0-20140422174119-9fd32a8b3d3d/go.mod h1:6QX/PXZ00z/TKoufEY6K/a0k6AhaJrQKdFe6OfVXsa4= -github.com/bgentry/speakeasy v0.1.0 h1:ByYyxL9InA1OWqxJqqp2A5pYHUrCiAL6K3J+LKSsQkY= github.com/bgentry/speakeasy v0.1.0/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kBD4zp0CCIs= +github.com/bgentry/speakeasy v0.1.1-0.20220910012023-760eaf8b6816 h1:41iFGWnSlI2gVpmOtVTJZNodLdLQLn/KsJqFvXwnd/s= +github.com/bgentry/speakeasy v0.1.1-0.20220910012023-760eaf8b6816/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kBD4zp0CCIs= github.com/btcsuite/btcd v0.22.3 h1:kYNaWFvOw6xvqP0vR20RP1Zq1DVMBxEO8QN5d1/EfNg= github.com/btcsuite/btcd v0.22.3/go.mod h1:wqgTSL29+50LRkmOVknEdmt8ZojIzhuWvgu/iptuN7Y= github.com/btcsuite/btcd/btcec/v2 v2.3.2 h1:5n0X6hX0Zk+6omWcihdYvdAlGf2DfasC0GMf7DClJ3U= @@ -182,20 +183,20 @@ github.com/cosmos/btcutil v1.0.5 h1:t+ZFcX77LpKtDBhjucvnOH8C2l2ioGsBNEQ3jef8xFk= github.com/cosmos/btcutil v1.0.5/go.mod h1:IyB7iuqZMJlthe2tkIFL33xPyzbFYP0XVdS8P5lUPis= github.com/cosmos/cosmos-proto v1.0.0-beta.1 h1:iDL5qh++NoXxG8hSy93FdYJut4XfgbShIocllGaXx/0= github.com/cosmos/cosmos-proto v1.0.0-beta.1/go.mod h1:8k2GNZghi5sDRFw/scPL8gMSowT1vDA+5ouxL8GjaUE= -github.com/cosmos/cosmos-sdk v0.47.0-rc1 h1:ptoLIOAqFGoqnZeqgec9KvC2JIZ6CVIyMHHjti9p6dQ= -github.com/cosmos/cosmos-sdk v0.47.0-rc1/go.mod h1:yWd503ULBJ71Zuv7GD0/dYJuyeg4LGWAvjeI4wK/dfY= +github.com/cosmos/cosmos-sdk v0.47.0-rc2 h1:BwQC41zQXG/pN9DdLaWzYJrC911St5lYOQIoW4Hf5wQ= +github.com/cosmos/cosmos-sdk v0.47.0-rc2/go.mod h1:e0ZEpY/nhVoXAkijdHPdFOJNOXCddfvyFrFLp2QmCCY= github.com/cosmos/go-bip39 v0.0.0-20180819234021-555e2067c45d/go.mod h1:tSxLoYXyBmiFeKpvmq4dzayMdCjCnu8uqmCysIGBT2Y= github.com/cosmos/go-bip39 v1.0.0 h1:pcomnQdrdH22njcAatO0yWojsUnCO3y2tNoV1cb6hHY= github.com/cosmos/go-bip39 v1.0.0/go.mod h1:RNJv0H/pOIVgxw6KS7QeX2a0Uo0aKUlfhZ4xuwvCdJw= github.com/cosmos/gogogateway v1.2.0 h1:Ae/OivNhp8DqBi/sh2A8a1D0y638GpL3tkmLQAiKxTE= github.com/cosmos/gogogateway v1.2.0/go.mod h1:iQpLkGWxYcnCdz5iAdLcRBSw3h7NXeOkZ4GUkT+tbFI= github.com/cosmos/gogoproto v1.4.2/go.mod h1:cLxOsn1ljAHSV527CHOtaIP91kK6cCrZETRBrkzItWU= -github.com/cosmos/gogoproto v1.4.3 h1:RP3yyVREh9snv/lsOvmsAPQt8f44LgL281X0IOIhhcI= -github.com/cosmos/gogoproto v1.4.3/go.mod h1:0hLIG5TR7IvV1fme1HCFKjfzW9X2x0Mo+RooWXCnOWU= +github.com/cosmos/gogoproto v1.4.4 h1:nVAsgLlAf5jeN0fV7hRlkZvf768zU+dy4pG+hxc2P34= +github.com/cosmos/gogoproto v1.4.4/go.mod h1:/yl6/nLwsZcZ2JY3OrqjRqvqCG9InUMcXRfRjQiF9DU= github.com/cosmos/gorocksdb v1.2.0 h1:d0l3jJG8M4hBouIZq0mDUHZ+zjOx044J3nGRskwTb4Y= github.com/cosmos/gorocksdb v1.2.0/go.mod h1:aaKvKItm514hKfNJpUJXnnOWeBnk2GL4+Qw9NHizILw= -github.com/cosmos/iavl v0.19.4 h1:t82sN+Y0WeqxDLJRSpNd8YFX5URIrT+p8n6oJbJ2Dok= -github.com/cosmos/iavl v0.19.4/go.mod h1:X9PKD3J0iFxdmgNLa7b2LYWdsGd90ToV5cAONApkEPw= +github.com/cosmos/iavl v0.19.5-rc.1 h1:4PjF2PdScyPbN1WbXpiQU21YtyonnrMU31xN74g8Rkg= +github.com/cosmos/iavl v0.19.5-rc.1/go.mod h1:X9PKD3J0iFxdmgNLa7b2LYWdsGd90ToV5cAONApkEPw= github.com/cosmos/ics23/go v0.9.1-0.20221207100636-b1abd8678aab h1:I9ialKTQo7248V827Bba4OuKPmk+FPzmTVHsLXaIJWw= github.com/cosmos/ics23/go v0.9.1-0.20221207100636-b1abd8678aab/go.mod h1:2CwqasX5dSD7Hbp/9b6lhK6BwoBDCBldx7gPKRukR60= github.com/cosmos/interchain-accounts v0.4.1-0.20230116203650-08d2a4529a5d h1:YR8OGEZKf0xveWZ2B/3+r9Q0dbtypXmwwAcolFNY8Fw= @@ -846,10 +847,6 @@ github.com/subosito/gotenv v1.4.2 h1:X1TuBLAMDFbaTAChgCBLu3DU3UPyELpnF2jjJ2cz/S8 github.com/subosito/gotenv v1.4.2/go.mod h1:ayKnFf/c6rvx/2iiLrJUk1e6plDbT3edrFNGqEflhK0= github.com/syndtr/goleveldb v1.0.1-0.20220614013038-64ee5596c38a h1:1ur3QoCqvE5fl+nylMaIr9PVV1w343YRDtsy+Rwu7XI= github.com/syndtr/goleveldb v1.0.1-0.20220614013038-64ee5596c38a/go.mod h1:RRCYJbIwD5jmqPI9XoAFR0OcDxqUctll6zUj/+B4S48= -github.com/tendermint/btcd v0.1.1 h1:0VcxPfflS2zZ3RiOAHkBiFUcPvbtRj5O7zHmcJWHV7s= -github.com/tendermint/btcd v0.1.1/go.mod h1:DC6/m53jtQzr/NFmMNEu0rxf18/ktVoVtMrnDD5pN+U= -github.com/tendermint/crypto v0.0.0-20191022145703-50d29ede1e15 h1:hqAk8riJvK4RMWx1aInLzndwxKalgi5rTqgfXxOxbEI= -github.com/tendermint/crypto v0.0.0-20191022145703-50d29ede1e15/go.mod h1:z4YtwM70uOnk8h0pjJYlj3zdYwi9l03By6iAIF5j/Pk= github.com/tendermint/go-amino v0.16.0 h1:GyhmgQKvqF82e2oZeuMSp9JTN0N09emoSZlb2lyGa2E= github.com/tendermint/go-amino v0.16.0/go.mod h1:TQU0M1i/ImAo+tYpZi73AU3V/dKeCoMC9Sphe2ZwGME= github.com/tendermint/tendermint v0.37.0-rc2 h1:2n1em+jfbhSv6QnBj8F6KHCpbIzZCB8KgcjidJUQNlY= diff --git a/go.mod b/go.mod index 0c1034b9956..692c949614c 100644 --- a/go.mod +++ b/go.mod @@ -9,8 +9,8 @@ require ( cosmossdk.io/tools/rosetta v0.2.0 github.com/armon/go-metrics v0.4.1 github.com/cosmos/cosmos-proto v1.0.0-beta.1 - github.com/cosmos/cosmos-sdk v0.47.0-rc1 - github.com/cosmos/gogoproto v1.4.3 + github.com/cosmos/cosmos-sdk v0.47.0-rc2 + github.com/cosmos/gogoproto v1.4.4 github.com/cosmos/ics23/go v0.9.1-0.20221207100636-b1abd8678aab github.com/golang/protobuf v1.5.2 github.com/gorilla/mux v1.8.0 @@ -44,7 +44,7 @@ require ( github.com/aws/aws-sdk-go v1.40.45 // indirect github.com/beorn7/perks v1.0.1 // indirect github.com/bgentry/go-netrc v0.0.0-20140422174119-9fd32a8b3d3d // indirect - github.com/bgentry/speakeasy v0.1.0 // indirect + github.com/bgentry/speakeasy v0.1.1-0.20220910012023-760eaf8b6816 // indirect github.com/btcsuite/btcd/btcec/v2 v2.3.2 // indirect github.com/cenkalti/backoff/v4 v4.1.3 // indirect github.com/cespare/xxhash v1.1.0 // indirect @@ -56,7 +56,7 @@ require ( github.com/cosmos/go-bip39 v1.0.0 // indirect github.com/cosmos/gogogateway v1.2.0 // indirect github.com/cosmos/gorocksdb v1.2.0 // indirect - github.com/cosmos/iavl v0.19.4 // indirect + github.com/cosmos/iavl v0.19.5-rc.1 // indirect github.com/cosmos/ledger-cosmos-go v0.12.1 // indirect github.com/cosmos/rosetta-sdk-go v0.9.0 // indirect github.com/creachadair/taskgroup v0.3.2 // indirect @@ -138,8 +138,6 @@ require ( github.com/spf13/pflag v1.0.5 // indirect github.com/subosito/gotenv v1.4.2 // indirect github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 // indirect - github.com/tendermint/btcd v0.1.1 // indirect - github.com/tendermint/crypto v0.0.0-20191022145703-50d29ede1e15 // indirect github.com/tendermint/go-amino v0.16.0 // indirect github.com/tidwall/btree v1.5.2 // indirect github.com/ulikunitz/xz v0.5.8 // indirect diff --git a/go.sum b/go.sum index a161820369d..4760fb04ae0 100644 --- a/go.sum +++ b/go.sum @@ -112,8 +112,9 @@ github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM= github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6rlkpw= github.com/bgentry/go-netrc v0.0.0-20140422174119-9fd32a8b3d3d h1:xDfNPAt8lFiC1UJrqV3uuy861HCTo708pDMbjHHdCas= github.com/bgentry/go-netrc v0.0.0-20140422174119-9fd32a8b3d3d/go.mod h1:6QX/PXZ00z/TKoufEY6K/a0k6AhaJrQKdFe6OfVXsa4= -github.com/bgentry/speakeasy v0.1.0 h1:ByYyxL9InA1OWqxJqqp2A5pYHUrCiAL6K3J+LKSsQkY= github.com/bgentry/speakeasy v0.1.0/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kBD4zp0CCIs= +github.com/bgentry/speakeasy v0.1.1-0.20220910012023-760eaf8b6816 h1:41iFGWnSlI2gVpmOtVTJZNodLdLQLn/KsJqFvXwnd/s= +github.com/bgentry/speakeasy v0.1.1-0.20220910012023-760eaf8b6816/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kBD4zp0CCIs= github.com/btcsuite/btcd/btcec/v2 v2.3.2 h1:5n0X6hX0Zk+6omWcihdYvdAlGf2DfasC0GMf7DClJ3U= github.com/btcsuite/btcd/btcec/v2 v2.3.2/go.mod h1:zYzJ8etWJQIv1Ogk7OzpWjowwOdXY1W/17j2MW85J04= github.com/btcsuite/btcd/btcutil v1.1.2 h1:XLMbX8JQEiwMcYft2EGi8zPUkoa0abKIU6/BJSRsjzQ= @@ -167,20 +168,20 @@ github.com/cosmos/btcutil v1.0.5 h1:t+ZFcX77LpKtDBhjucvnOH8C2l2ioGsBNEQ3jef8xFk= github.com/cosmos/btcutil v1.0.5/go.mod h1:IyB7iuqZMJlthe2tkIFL33xPyzbFYP0XVdS8P5lUPis= github.com/cosmos/cosmos-proto v1.0.0-beta.1 h1:iDL5qh++NoXxG8hSy93FdYJut4XfgbShIocllGaXx/0= github.com/cosmos/cosmos-proto v1.0.0-beta.1/go.mod h1:8k2GNZghi5sDRFw/scPL8gMSowT1vDA+5ouxL8GjaUE= -github.com/cosmos/cosmos-sdk v0.47.0-rc1 h1:ptoLIOAqFGoqnZeqgec9KvC2JIZ6CVIyMHHjti9p6dQ= -github.com/cosmos/cosmos-sdk v0.47.0-rc1/go.mod h1:yWd503ULBJ71Zuv7GD0/dYJuyeg4LGWAvjeI4wK/dfY= +github.com/cosmos/cosmos-sdk v0.47.0-rc2 h1:BwQC41zQXG/pN9DdLaWzYJrC911St5lYOQIoW4Hf5wQ= +github.com/cosmos/cosmos-sdk v0.47.0-rc2/go.mod h1:e0ZEpY/nhVoXAkijdHPdFOJNOXCddfvyFrFLp2QmCCY= github.com/cosmos/go-bip39 v0.0.0-20180819234021-555e2067c45d/go.mod h1:tSxLoYXyBmiFeKpvmq4dzayMdCjCnu8uqmCysIGBT2Y= github.com/cosmos/go-bip39 v1.0.0 h1:pcomnQdrdH22njcAatO0yWojsUnCO3y2tNoV1cb6hHY= github.com/cosmos/go-bip39 v1.0.0/go.mod h1:RNJv0H/pOIVgxw6KS7QeX2a0Uo0aKUlfhZ4xuwvCdJw= github.com/cosmos/gogogateway v1.2.0 h1:Ae/OivNhp8DqBi/sh2A8a1D0y638GpL3tkmLQAiKxTE= github.com/cosmos/gogogateway v1.2.0/go.mod h1:iQpLkGWxYcnCdz5iAdLcRBSw3h7NXeOkZ4GUkT+tbFI= github.com/cosmos/gogoproto v1.4.2/go.mod h1:cLxOsn1ljAHSV527CHOtaIP91kK6cCrZETRBrkzItWU= -github.com/cosmos/gogoproto v1.4.3 h1:RP3yyVREh9snv/lsOvmsAPQt8f44LgL281X0IOIhhcI= -github.com/cosmos/gogoproto v1.4.3/go.mod h1:0hLIG5TR7IvV1fme1HCFKjfzW9X2x0Mo+RooWXCnOWU= +github.com/cosmos/gogoproto v1.4.4 h1:nVAsgLlAf5jeN0fV7hRlkZvf768zU+dy4pG+hxc2P34= +github.com/cosmos/gogoproto v1.4.4/go.mod h1:/yl6/nLwsZcZ2JY3OrqjRqvqCG9InUMcXRfRjQiF9DU= github.com/cosmos/gorocksdb v1.2.0 h1:d0l3jJG8M4hBouIZq0mDUHZ+zjOx044J3nGRskwTb4Y= github.com/cosmos/gorocksdb v1.2.0/go.mod h1:aaKvKItm514hKfNJpUJXnnOWeBnk2GL4+Qw9NHizILw= -github.com/cosmos/iavl v0.19.4 h1:t82sN+Y0WeqxDLJRSpNd8YFX5URIrT+p8n6oJbJ2Dok= -github.com/cosmos/iavl v0.19.4/go.mod h1:X9PKD3J0iFxdmgNLa7b2LYWdsGd90ToV5cAONApkEPw= +github.com/cosmos/iavl v0.19.5-rc.1 h1:4PjF2PdScyPbN1WbXpiQU21YtyonnrMU31xN74g8Rkg= +github.com/cosmos/iavl v0.19.5-rc.1/go.mod h1:X9PKD3J0iFxdmgNLa7b2LYWdsGd90ToV5cAONApkEPw= github.com/cosmos/ics23/go v0.9.1-0.20221207100636-b1abd8678aab h1:I9ialKTQo7248V827Bba4OuKPmk+FPzmTVHsLXaIJWw= github.com/cosmos/ics23/go v0.9.1-0.20221207100636-b1abd8678aab/go.mod h1:2CwqasX5dSD7Hbp/9b6lhK6BwoBDCBldx7gPKRukR60= github.com/cosmos/ledger-cosmos-go v0.12.1 h1:sMBxza5p/rNK/06nBSNmsI/WDqI0pVJFVNihy1Y984w= @@ -749,10 +750,6 @@ github.com/subosito/gotenv v1.4.2 h1:X1TuBLAMDFbaTAChgCBLu3DU3UPyELpnF2jjJ2cz/S8 github.com/subosito/gotenv v1.4.2/go.mod h1:ayKnFf/c6rvx/2iiLrJUk1e6plDbT3edrFNGqEflhK0= github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 h1:epCh84lMvA70Z7CTTCmYQn2CKbY8j86K7/FAIr141uY= github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7/go.mod h1:q4W45IWZaF22tdD+VEXcAWRA037jwmWEB5VWYORlTpc= -github.com/tendermint/btcd v0.1.1 h1:0VcxPfflS2zZ3RiOAHkBiFUcPvbtRj5O7zHmcJWHV7s= -github.com/tendermint/btcd v0.1.1/go.mod h1:DC6/m53jtQzr/NFmMNEu0rxf18/ktVoVtMrnDD5pN+U= -github.com/tendermint/crypto v0.0.0-20191022145703-50d29ede1e15 h1:hqAk8riJvK4RMWx1aInLzndwxKalgi5rTqgfXxOxbEI= -github.com/tendermint/crypto v0.0.0-20191022145703-50d29ede1e15/go.mod h1:z4YtwM70uOnk8h0pjJYlj3zdYwi9l03By6iAIF5j/Pk= github.com/tendermint/go-amino v0.16.0 h1:GyhmgQKvqF82e2oZeuMSp9JTN0N09emoSZlb2lyGa2E= github.com/tendermint/go-amino v0.16.0/go.mod h1:TQU0M1i/ImAo+tYpZi73AU3V/dKeCoMC9Sphe2ZwGME= github.com/tendermint/tendermint v0.37.0-rc2 h1:2n1em+jfbhSv6QnBj8F6KHCpbIzZCB8KgcjidJUQNlY= diff --git a/modules/apps/27-interchain-accounts/host/keeper/relay_test.go b/modules/apps/27-interchain-accounts/host/keeper/relay_test.go index 0f2ac129287..0abc06b5abe 100644 --- a/modules/apps/27-interchain-accounts/host/keeper/relay_test.go +++ b/modules/apps/27-interchain-accounts/host/keeper/relay_test.go @@ -44,7 +44,7 @@ func (suite *KeeperTestSuite) TestOnRecvPacket() { proposalMsg, err := govv1.NewLegacyContent(testProposal, interchainAccountAddr) suite.Require().NoError(err) - proposal, err := govv1.NewProposal([]sdk.Msg{proposalMsg}, govtypes.DefaultStartingProposalID, "test proposal", suite.chainA.GetContext().BlockTime(), suite.chainA.GetContext().BlockTime(), "title", "Description", sdk.AccAddress(interchainAccountAddr)) + proposal, err := govv1.NewProposal([]sdk.Msg{proposalMsg}, govtypes.DefaultStartingProposalID, suite.chainA.GetContext().BlockTime(), suite.chainA.GetContext().BlockTime(), "test proposal", "title", "Description", sdk.AccAddress(interchainAccountAddr)) suite.Require().NoError(err) suite.chainB.GetSimApp().GovKeeper.SetProposal(suite.chainB.GetContext(), proposal) @@ -210,7 +210,7 @@ func (suite *KeeperTestSuite) TestOnRecvPacket() { proposalMsg, err := govv1.NewLegacyContent(testProposal, interchainAccountAddr) suite.Require().NoError(err) - proposal, err := govv1.NewProposal([]sdk.Msg{proposalMsg}, govtypes.DefaultStartingProposalID, "test proposal", suite.chainA.GetContext().BlockTime(), suite.chainA.GetContext().BlockTime(), "title", "description", sdk.AccAddress(interchainAccountAddr)) + proposal, err := govv1.NewProposal([]sdk.Msg{proposalMsg}, govtypes.DefaultStartingProposalID, suite.chainA.GetContext().BlockTime(), suite.chainA.GetContext().BlockTime(), "test proposal", "title", "description", sdk.AccAddress(interchainAccountAddr)) suite.Require().NoError(err) suite.chainB.GetSimApp().GovKeeper.SetProposal(suite.chainB.GetContext(), proposal) diff --git a/modules/apps/27-interchain-accounts/module.go b/modules/apps/27-interchain-accounts/module.go index 44a257e17fb..8befc9867c4 100644 --- a/modules/apps/27-interchain-accounts/module.go +++ b/modules/apps/27-interchain-accounts/module.go @@ -203,7 +203,7 @@ func (AppModule) GenerateGenesisState(simState *module.SimulationState) { } // ProposalContents doesn't return any content functions for governance proposals. -func (AppModule) ProposalContents(_ module.SimulationState) []simtypes.WeightedProposalContent { +func (AppModule) ProposalContents(_ module.SimulationState) []simtypes.WeightedProposalMsg { return nil } @@ -213,7 +213,7 @@ func (am AppModule) WeightedOperations(_ module.SimulationState) []simtypes.Weig } // RandomizedParams creates randomized ibc-transfer param changes for the simulator. -func (am AppModule) RandomizedParams(r *rand.Rand) []simtypes.ParamChange { +func (am AppModule) RandomizedParams(r *rand.Rand) []simtypes.LegacyParamChange { return simulation.ParamChanges(r, am.controllerKeeper, am.hostKeeper) } diff --git a/modules/apps/27-interchain-accounts/simulation/params.go b/modules/apps/27-interchain-accounts/simulation/params.go index 4b1fb019a33..13825a1f782 100644 --- a/modules/apps/27-interchain-accounts/simulation/params.go +++ b/modules/apps/27-interchain-accounts/simulation/params.go @@ -17,10 +17,10 @@ import ( // ParamChanges defines the parameters that can be modified by param change proposals // on the simulation -func ParamChanges(r *rand.Rand, controllerKeeper *controllerkeeper.Keeper, hostKeeper *hostkeeper.Keeper) []simtypes.ParamChange { - var paramChanges []simtypes.ParamChange +func ParamChanges(r *rand.Rand, controllerKeeper *controllerkeeper.Keeper, hostKeeper *hostkeeper.Keeper) []simtypes.LegacyParamChange { + var paramChanges []simtypes.LegacyParamChange if controllerKeeper != nil { - paramChanges = append(paramChanges, simulation.NewSimParamChange(controllertypes.SubModuleName, string(controllertypes.KeyControllerEnabled), + paramChanges = append(paramChanges, simulation.NewSimLegacyParamChange(controllertypes.SubModuleName, string(controllertypes.KeyControllerEnabled), func(r *rand.Rand) string { controllerEnabled := RandomEnabled(r) return fmt.Sprintf("%s", types.ModuleCdc.MustMarshalJSON(&gogotypes.BoolValue{Value: controllerEnabled})) //nolint:gosimple @@ -29,7 +29,7 @@ func ParamChanges(r *rand.Rand, controllerKeeper *controllerkeeper.Keeper, hostK } if hostKeeper != nil { - paramChanges = append(paramChanges, simulation.NewSimParamChange(hosttypes.SubModuleName, string(hosttypes.KeyHostEnabled), + paramChanges = append(paramChanges, simulation.NewSimLegacyParamChange(hosttypes.SubModuleName, string(hosttypes.KeyHostEnabled), func(r *rand.Rand) string { receiveEnabled := RandomEnabled(r) return fmt.Sprintf("%s", types.ModuleCdc.MustMarshalJSON(&gogotypes.BoolValue{Value: receiveEnabled})) //nolint:gosimple diff --git a/modules/apps/29-fee/module.go b/modules/apps/29-fee/module.go index b1bdedf0581..58a8b3955df 100644 --- a/modules/apps/29-fee/module.go +++ b/modules/apps/29-fee/module.go @@ -134,12 +134,12 @@ func (AppModule) GenerateGenesisState(_ *module.SimulationState) { } // ProposalContents doesn't return any content functions for governance proposals. -func (AppModule) ProposalContents(_ module.SimulationState) []simtypes.WeightedProposalContent { +func (AppModule) ProposalContents(_ module.SimulationState) []simtypes.WeightedProposalMsg { return nil } // RandomizedParams creates randomized ibc-29-fee param changes for the simulator. -func (AppModule) RandomizedParams(_ *rand.Rand) []simtypes.ParamChange { +func (AppModule) RandomizedParams(_ *rand.Rand) []simtypes.LegacyParamChange { return nil } diff --git a/modules/apps/transfer/module.go b/modules/apps/transfer/module.go index 67c56515401..210ec5f152c 100644 --- a/modules/apps/transfer/module.go +++ b/modules/apps/transfer/module.go @@ -146,12 +146,12 @@ func (AppModule) GenerateGenesisState(simState *module.SimulationState) { } // ProposalContents doesn't return any content functions for governance proposals. -func (AppModule) ProposalContents(_ module.SimulationState) []simtypes.WeightedProposalContent { +func (AppModule) ProposalContents(_ module.SimulationState) []simtypes.WeightedProposalMsg { return nil } // RandomizedParams creates randomized ibc-transfer param changes for the simulator. -func (AppModule) RandomizedParams(r *rand.Rand) []simtypes.ParamChange { +func (AppModule) RandomizedParams(r *rand.Rand) []simtypes.LegacyParamChange { return simulation.ParamChanges(r) } diff --git a/modules/apps/transfer/simulation/params.go b/modules/apps/transfer/simulation/params.go index 500bd3ece6a..d3d864db0c1 100644 --- a/modules/apps/transfer/simulation/params.go +++ b/modules/apps/transfer/simulation/params.go @@ -13,15 +13,15 @@ import ( // ParamChanges defines the parameters that can be modified by param change proposals // on the simulation -func ParamChanges(r *rand.Rand) []simtypes.ParamChange { - return []simtypes.ParamChange{ - simulation.NewSimParamChange(types.ModuleName, string(types.KeySendEnabled), +func ParamChanges(r *rand.Rand) []simtypes.LegacyParamChange { + return []simtypes.LegacyParamChange{ + simulation.NewSimLegacyParamChange(types.ModuleName, string(types.KeySendEnabled), func(r *rand.Rand) string { sendEnabled := RadomEnabled(r) return fmt.Sprintf("%s", types.ModuleCdc.MustMarshalJSON(&gogotypes.BoolValue{Value: sendEnabled})) //nolint:gosimple }, ), - simulation.NewSimParamChange(types.ModuleName, string(types.KeyReceiveEnabled), + simulation.NewSimLegacyParamChange(types.ModuleName, string(types.KeyReceiveEnabled), func(r *rand.Rand) string { receiveEnabled := RadomEnabled(r) return fmt.Sprintf("%s", types.ModuleCdc.MustMarshalJSON(&gogotypes.BoolValue{Value: receiveEnabled})) //nolint:gosimple diff --git a/modules/core/module.go b/modules/core/module.go index ee0799f64c2..872b61e0c3a 100644 --- a/modules/core/module.go +++ b/modules/core/module.go @@ -171,12 +171,12 @@ func (AppModule) GenerateGenesisState(simState *module.SimulationState) { } // ProposalContents doesn't return any content functions for governance proposals. -func (AppModule) ProposalContents(_ module.SimulationState) []simtypes.WeightedProposalContent { +func (AppModule) ProposalContents(_ module.SimulationState) []simtypes.WeightedProposalMsg { return nil } // RandomizedParams returns nil since IBC doesn't register parameter changes. -func (AppModule) RandomizedParams(_ *rand.Rand) []simtypes.ParamChange { +func (AppModule) RandomizedParams(_ *rand.Rand) []simtypes.LegacyParamChange { return nil } diff --git a/testing/simapp/utils.go b/testing/simapp/utils.go index 92fda85a524..313d334408a 100644 --- a/testing/simapp/utils.go +++ b/testing/simapp/utils.go @@ -65,7 +65,8 @@ func SimulationOperations(app App, cdc codec.JSONCodec, config simtypes.Config) } } - simState.Contents = app.SimulationManager().GetProposalContents(simState) + //nolint: staticcheck // SA1019: app.SimulationManager().GetProposalContents is deprecated: Use GetProposalMsgs instead. GetProposalContents returns each module's proposal content generator function with their default operation weight and key. + simState.LegacyProposalContents = app.SimulationManager().GetProposalContents(simState) return app.SimulationManager().WeightedOperations(simState) } From bb8a23b5c0d6c87195f6b47bc8986546430bc747 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 1 Feb 2023 15:37:34 +0000 Subject: [PATCH 09/22] build(deps): bump docker/build-push-action from 3.3.0 to 4.0.0 (#3090) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Bumps [docker/build-push-action](https://github.com/docker/build-push-action) from 3.3.0 to 4.0.0.
Release notes

Sourced from docker/build-push-action's releases.

v4.0.0

Warning

Buildx v0.10 enables support for a minimal SLSA Provenance attestation, which requires support for OCI-compliant multi-platform images. This may introduce issues with registry and runtime support (e.g. Google Cloud Run and AWS Lambda). You can optionally disable the default provenance attestation functionality using provenance: false.

Full Changelog: https://github.com/docker/build-push-action/compare/v3.3.1...v4.0.0

v3.3.1

Full Changelog: https://github.com/docker/build-push-action/compare/v3.3.0...v3.3.1

Commits
  • 3b5e802 Merge pull request #784 from crazy-max/enable-provenance
  • 02d3266 update generated content
  • f403daf revert disable provenance by default if not set
  • 1104d47 Merge pull request #781 from crazy-max/disable-provenance
  • 838bf90 update generated content
  • 337a09d disable provenance by default if not set
  • See full diff in compare view

[![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=docker/build-push-action&package-manager=github_actions&previous-version=3.3.0&new-version=4.0.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) ---
Dependabot commands and options
You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
--- .github/workflows/e2e-test-workflow-call.yml | 2 +- .github/workflows/release.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/e2e-test-workflow-call.yml b/.github/workflows/e2e-test-workflow-call.yml index 2122bab4ac0..07a1843fdc4 100644 --- a/.github/workflows/e2e-test-workflow-call.yml +++ b/.github/workflows/e2e-test-workflow-call.yml @@ -84,7 +84,7 @@ jobs: - name: Build and push Docker image if: ${{ inputs.build-and-push-docker-image }} - uses: docker/build-push-action@37abcedcc1da61a57767b7588cb9d03eb57e28b3 + uses: docker/build-push-action@3b5e8027fcad23fda98b2e3ac259d8d67585f671 with: context: . push: true diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 1b7ad3ff3fa..1487a58e44c 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -52,7 +52,7 @@ jobs: images: ${{ env.REGISTRY }}/cosmos/${{ env.IMAGE_NAME }} - name: Build and push Docker image - uses: docker/build-push-action@37abcedcc1da61a57767b7588cb9d03eb57e28b3 + uses: docker/build-push-action@3b5e8027fcad23fda98b2e3ac259d8d67585f671 with: context: . push: true From b69b8276d77e7b37633ad99643ef1912ec8f8175 Mon Sep 17 00:00:00 2001 From: Cian Hatton Date: Wed, 1 Feb 2023 16:41:44 +0000 Subject: [PATCH 10/22] Fix e2e memo test for broken versions (#3096) --- .github/workflows/e2e.yaml | 19 ++++++++++ e2e/README.md | 10 ++--- e2e/go.mod | 2 +- e2e/go.sum | 4 +- e2e/testconfig/testconfig.go | 2 +- .../core/03-connection/connection_test.go | 4 +- e2e/tests/core/client_test.go | 4 +- e2e/tests/interchain_accounts/base_test.go | 12 +++--- e2e/tests/interchain_accounts/gov_test.go | 8 ++-- e2e/tests/interchain_accounts/groups_test.go | 8 ++-- .../interchain_accounts/incentivized_test.go | 10 ++--- .../intertx_incentivized_test.go | 8 ++-- e2e/tests/interchain_accounts/intertx_test.go | 10 ++--- e2e/tests/transfer/base_test.go | 4 +- e2e/tests/transfer/incentivized_test.go | 4 +- e2e/tests/upgrades/upgrade_test.go | 10 ++--- e2e/testsuite/grpc_query.go | 4 +- e2e/testsuite/relayer.go | 8 ++-- e2e/testsuite/testsuite.go | 38 ++++++------------- e2e/testvalues/values.go | 2 +- 20 files changed, 88 insertions(+), 83 deletions(-) diff --git a/.github/workflows/e2e.yaml b/.github/workflows/e2e.yaml index 64a459b9415..9fe4b02cefd 100644 --- a/.github/workflows/e2e.yaml +++ b/.github/workflows/e2e.yaml @@ -35,10 +35,29 @@ jobs: echo "Using tag $tag" echo "simd-tag=$tag" >> $GITHUB_OUTPUT fi + + build-e2e: + if: ${{ !github.event.pull_request.head.repo.fork && github.actor != 'dependabot[bot]' }} + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - uses: actions/setup-go@v3 + with: + go-version: 1.19 + - name: Build e2e + run: | + cd e2e + test_dirs="$(ls -A tests)" + for td in $test_dirs + do + go test -c "./tests/${td}" + done + e2e: if: ${{ !github.event.pull_request.head.repo.fork && github.actor != 'dependabot[bot]' }} needs: - determine-image-tag + - build-e2e # don't attempt any tests unless the e2e code compiles successfully. uses: ./.github/workflows/e2e-test-workflow-call.yml secrets: inherit with: diff --git a/e2e/README.md b/e2e/README.md index 070b1773252..0ca688bd0fb 100644 --- a/e2e/README.md +++ b/e2e/README.md @@ -13,7 +13,7 @@ - [Arbitrary commands](#arbitrary-commands) - [IBC transfer](#ibc-transfer) 2. [Test design](#test-design) - - a. [ibctest](#ibctest) + - a. [interchaintest](#interchaintest) - b. [CI configuration](#ci-configuration) 3. [Github Workflows](#github-workflows) 4. [Running Compatibility Tests](#running-compatibility-tests) @@ -75,10 +75,10 @@ make e2e-test entrypoint=TestInterchainAccountsTestSuite test=TestMsgSubmitTx_Su ``` -> Note: sometimes it can be useful to make changes to [ibctest](https://github.com/strangelove-ventures/ibctest) when running tests locally. In order to do this, add the following line to +> Note: sometimes it can be useful to make changes to [ibctest](https://github.com/strangelove-ventures/interchaintest) when running tests locally. In order to do this, add the following line to e2e/go.mod -`replace github.com/strangelove-ventures/ibctest => ../ibctest` +`replace github.com/strangelove-ventures/interchaintest => ../ibctest` Or point it to any local checkout you have. @@ -207,9 +207,9 @@ t.Run("send IBC transfer", func(t *testing.T){ ## Test design -#### ibctest +#### interchaintest -These E2E tests use the [ibctest framework](https://github.com/strangelove-ventures/ibctest). This framework creates chains and relayers in containers and allows for arbitrary commands to be executed in the chain containers, +These E2E tests use the [interchaintest framework](https://github.com/strangelove-ventures/interchaintest). This framework creates chains and relayers in containers and allows for arbitrary commands to be executed in the chain containers, as well as allowing us to broadcast arbitrary messages which are signed on behalf of a user created in the test. diff --git a/e2e/go.mod b/e2e/go.mod index 2cfda8e3f33..77166203826 100644 --- a/e2e/go.mod +++ b/e2e/go.mod @@ -8,7 +8,7 @@ require ( github.com/cosmos/ibc-go/v7 v7.0.0-20230120105519-ae96bf3d5ee9 github.com/cosmos/interchain-accounts v0.4.1-0.20230116203650-08d2a4529a5d github.com/docker/docker v20.10.19+incompatible - github.com/strangelove-ventures/ibctest/v7 v7.0.0-20230124162348-0fcd87d2151a + github.com/strangelove-ventures/interchaintest/v7 v7.0.0-20230201060741-e0e4e0f9283b github.com/stretchr/testify v1.8.1 go.uber.org/zap v1.23.0 golang.org/x/mod v0.6.0 diff --git a/e2e/go.sum b/e2e/go.sum index 0147e4233ab..c0999c86e9e 100644 --- a/e2e/go.sum +++ b/e2e/go.sum @@ -822,8 +822,8 @@ github.com/spf13/viper v1.15.0 h1:js3yy885G8xwJa6iOISGFwd+qlUo5AvyXb7CiihdtiU= github.com/spf13/viper v1.15.0/go.mod h1:fFcTBJxvhhzSJiZy8n+PeW6t8l+KeT/uTARa0jHOQLA= github.com/strangelove-ventures/go-subkey v1.0.7 h1:cOP/Lajg3uxV/tvspu0m6+0Cu+DJgygkEAbx/s+f35I= github.com/strangelove-ventures/go-subkey v1.0.7/go.mod h1:E34izOIEm+sZ1YmYawYRquqBQWeZBjVB4pF7bMuhc1c= -github.com/strangelove-ventures/ibctest/v7 v7.0.0-20230124162348-0fcd87d2151a h1:I68lhxUi40elS4/4OAA9r71yQM4UpkRNFlfCxD43rUQ= -github.com/strangelove-ventures/ibctest/v7 v7.0.0-20230124162348-0fcd87d2151a/go.mod h1:hU36IqtAQslhbGcRqQCfZk52xkWwNAMujFxypvzS2Gg= +github.com/strangelove-ventures/interchaintest/v7 v7.0.0-20230201060741-e0e4e0f9283b h1:TPt4lyXM0XJUrgaO5ufBsAx9jbrNuwvSZvnIBL/5ui0= +github.com/strangelove-ventures/interchaintest/v7 v7.0.0-20230201060741-e0e4e0f9283b/go.mod h1:xABocejOFzpH8VR9Se92KE02IqR3cLhzGnl4SHV36Qw= github.com/streadway/amqp v0.0.0-20190404075320-75d898a42a94/go.mod h1:AZpEONHx3DKn8O/DFsRAY58/XVQiIPMTMB1SddzLXVw= github.com/streadway/amqp v0.0.0-20190827072141-edfb9018d271/go.mod h1:AZpEONHx3DKn8O/DFsRAY58/XVQiIPMTMB1SddzLXVw= github.com/streadway/handy v0.0.0-20190108123426-d5acb3125c2a/go.mod h1:qNTQ5P5JnDBl6z3cMAg/SywNDC5ABu5ApDIw6lUbRmI= diff --git a/e2e/testconfig/testconfig.go b/e2e/testconfig/testconfig.go index 995eed84c83..19e544fd618 100644 --- a/e2e/testconfig/testconfig.go +++ b/e2e/testconfig/testconfig.go @@ -12,7 +12,7 @@ import ( govv1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1" govv1beta1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1" gogoproto "github.com/cosmos/gogoproto/proto" - "github.com/strangelove-ventures/ibctest/v7/ibc" + "github.com/strangelove-ventures/interchaintest/v7/ibc" "github.com/cosmos/ibc-go/e2e/semverutil" "github.com/cosmos/ibc-go/e2e/testvalues" diff --git a/e2e/tests/core/03-connection/connection_test.go b/e2e/tests/core/03-connection/connection_test.go index 7c5d452fb06..1694bc2e0ce 100644 --- a/e2e/tests/core/03-connection/connection_test.go +++ b/e2e/tests/core/03-connection/connection_test.go @@ -9,8 +9,8 @@ import ( "time" paramsproposaltypes "github.com/cosmos/cosmos-sdk/x/params/types/proposal" - "github.com/strangelove-ventures/ibctest/v7/ibc" - test "github.com/strangelove-ventures/ibctest/v7/testutil" + "github.com/strangelove-ventures/interchaintest/v7/ibc" + test "github.com/strangelove-ventures/interchaintest/v7/testutil" "github.com/stretchr/testify/suite" "github.com/cosmos/ibc-go/e2e/testsuite" diff --git a/e2e/tests/core/client_test.go b/e2e/tests/core/client_test.go index a1facd0dd0a..03b1b9566cd 100644 --- a/e2e/tests/core/client_test.go +++ b/e2e/tests/core/client_test.go @@ -7,8 +7,8 @@ import ( "testing" "time" - "github.com/strangelove-ventures/ibctest/v7/ibc" - test "github.com/strangelove-ventures/ibctest/v7/testutil" + "github.com/strangelove-ventures/interchaintest/v7/ibc" + test "github.com/strangelove-ventures/interchaintest/v7/testutil" "github.com/stretchr/testify/suite" "github.com/cosmos/ibc-go/e2e/testsuite" diff --git a/e2e/tests/interchain_accounts/base_test.go b/e2e/tests/interchain_accounts/base_test.go index ac0acfdd817..53c5384be31 100644 --- a/e2e/tests/interchain_accounts/base_test.go +++ b/e2e/tests/interchain_accounts/base_test.go @@ -5,10 +5,10 @@ import ( "testing" "time" - "github.com/strangelove-ventures/ibctest/v7" - "github.com/strangelove-ventures/ibctest/v7/chain/cosmos" - "github.com/strangelove-ventures/ibctest/v7/ibc" - test "github.com/strangelove-ventures/ibctest/v7/testutil" + "github.com/strangelove-ventures/interchaintest/v7" + "github.com/strangelove-ventures/interchaintest/v7/chain/cosmos" + "github.com/strangelove-ventures/interchaintest/v7/ibc" + test "github.com/strangelove-ventures/interchaintest/v7/testutil" "github.com/stretchr/testify/suite" "golang.org/x/mod/semver" @@ -95,7 +95,7 @@ func (s *InterchainAccountsTestSuite) TestMsgSendTx_SuccessfulTransfer() { t.Run("interchain account executes a bank transfer on behalf of the corresponding owner account", func(t *testing.T) { t.Run("fund interchain account wallet", func(t *testing.T) { // fund the host account so it has some $$ to send - err := chainB.SendFunds(ctx, ibctest.FaucetAccountKeyName, ibc.WalletAmount{ + err := chainB.SendFunds(ctx, interchaintest.FaucetAccountKeyName, ibc.WalletAmount{ Address: hostAccount, Amount: testvalues.StartingTokenAmount, Denom: chainB.Config().Denom, @@ -293,7 +293,7 @@ func (s *InterchainAccountsTestSuite) TestMsgSubmitTx_SuccessfulTransfer_AfterRe t.Run("submit tx message with bank transfer message times out", func(t *testing.T) { t.Run("fund interchain account wallet", func(t *testing.T) { // fund the host account account so it has some $$ to send - err := chainB.SendFunds(ctx, ibctest.FaucetAccountKeyName, ibc.WalletAmount{ + err := chainB.SendFunds(ctx, interchaintest.FaucetAccountKeyName, ibc.WalletAmount{ Address: hostAccount, Amount: testvalues.StartingTokenAmount, Denom: chainB.Config().Denom, diff --git a/e2e/tests/interchain_accounts/gov_test.go b/e2e/tests/interchain_accounts/gov_test.go index 08da6cb046e..2f572c35596 100644 --- a/e2e/tests/interchain_accounts/gov_test.go +++ b/e2e/tests/interchain_accounts/gov_test.go @@ -10,9 +10,9 @@ import ( govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" "github.com/cosmos/gogoproto/proto" - "github.com/strangelove-ventures/ibctest/v7" - "github.com/strangelove-ventures/ibctest/v7/ibc" - test "github.com/strangelove-ventures/ibctest/v7/testutil" + "github.com/strangelove-ventures/interchaintest/v7" + "github.com/strangelove-ventures/interchaintest/v7/ibc" + test "github.com/strangelove-ventures/interchaintest/v7/testutil" "github.com/stretchr/testify/suite" "github.com/cosmos/ibc-go/e2e/testsuite" @@ -74,7 +74,7 @@ func (s *InterchainAccountsGovTestSuite) TestInterchainAccountsGovIntegration() t.Run("interchain account executes a bank transfer on behalf of the corresponding owner account", func(t *testing.T) { t.Run("fund interchain account wallet", func(t *testing.T) { // fund the host account, so it has some $$ to send - err := chainB.SendFunds(ctx, ibctest.FaucetAccountKeyName, ibc.WalletAmount{ + err := chainB.SendFunds(ctx, interchaintest.FaucetAccountKeyName, ibc.WalletAmount{ Address: interchainAccAddr, Amount: testvalues.StartingTokenAmount, Denom: chainB.Config().Denom, diff --git a/e2e/tests/interchain_accounts/groups_test.go b/e2e/tests/interchain_accounts/groups_test.go index 80ac49e3513..7e7ad72324d 100644 --- a/e2e/tests/interchain_accounts/groups_test.go +++ b/e2e/tests/interchain_accounts/groups_test.go @@ -9,9 +9,9 @@ import ( banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" grouptypes "github.com/cosmos/cosmos-sdk/x/group" "github.com/cosmos/gogoproto/proto" - ibctest "github.com/strangelove-ventures/ibctest/v7" - "github.com/strangelove-ventures/ibctest/v7/ibc" - test "github.com/strangelove-ventures/ibctest/v7/testutil" + interchaintest "github.com/strangelove-ventures/interchaintest/v7" + "github.com/strangelove-ventures/interchaintest/v7/ibc" + test "github.com/strangelove-ventures/interchaintest/v7/testutil" "github.com/stretchr/testify/suite" "github.com/cosmos/ibc-go/e2e/testsuite" @@ -148,7 +148,7 @@ func (s *InterchainAccountsGroupsTestSuite) TestInterchainAccountsGroupsIntegrat }) t.Run("fund interchain account wallet", func(t *testing.T) { - err := chainB.SendFunds(ctx, ibctest.FaucetAccountKeyName, ibc.WalletAmount{ + err := chainB.SendFunds(ctx, interchaintest.FaucetAccountKeyName, ibc.WalletAmount{ Address: interchainAccAddr, Amount: testvalues.StartingTokenAmount, Denom: chainB.Config().Denom, diff --git a/e2e/tests/interchain_accounts/incentivized_test.go b/e2e/tests/interchain_accounts/incentivized_test.go index 8675be1cbf1..e91f52eb439 100644 --- a/e2e/tests/interchain_accounts/incentivized_test.go +++ b/e2e/tests/interchain_accounts/incentivized_test.go @@ -8,10 +8,10 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" "github.com/cosmos/gogoproto/proto" - ibctest "github.com/strangelove-ventures/ibctest/v7" - "github.com/strangelove-ventures/ibctest/v7/chain/cosmos" - "github.com/strangelove-ventures/ibctest/v7/ibc" - test "github.com/strangelove-ventures/ibctest/v7/testutil" + interchaintest "github.com/strangelove-ventures/interchaintest/v7" + "github.com/strangelove-ventures/interchaintest/v7/chain/cosmos" + "github.com/strangelove-ventures/interchaintest/v7/ibc" + test "github.com/strangelove-ventures/interchaintest/v7/testutil" "github.com/stretchr/testify/suite" "github.com/cosmos/ibc-go/e2e/testconfig" @@ -107,7 +107,7 @@ func (s *IncentivizedInterchainAccountsTestSuite) TestMsgSendTx_SuccessfulBankSe t.Run("execute interchain account bank send through controller", func(t *testing.T) { t.Run("fund interchain account wallet on host chainB", func(t *testing.T) { // fund the interchain account so it has some $$ to send - err := chainB.SendFunds(ctx, ibctest.FaucetAccountKeyName, ibc.WalletAmount{ + err := chainB.SendFunds(ctx, interchaintest.FaucetAccountKeyName, ibc.WalletAmount{ Address: interchainAcc, Amount: testvalues.StartingTokenAmount, Denom: chainB.Config().Denom, diff --git a/e2e/tests/interchain_accounts/intertx_incentivized_test.go b/e2e/tests/interchain_accounts/intertx_incentivized_test.go index 9464844fdca..a76ae1a990c 100644 --- a/e2e/tests/interchain_accounts/intertx_incentivized_test.go +++ b/e2e/tests/interchain_accounts/intertx_incentivized_test.go @@ -7,9 +7,9 @@ import ( sdk "github.com/cosmos/cosmos-sdk/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" intertxtypes "github.com/cosmos/interchain-accounts/x/inter-tx/types" - "github.com/strangelove-ventures/ibctest/v7" - "github.com/strangelove-ventures/ibctest/v7/ibc" - test "github.com/strangelove-ventures/ibctest/v7/testutil" + "github.com/strangelove-ventures/interchaintest/v7" + "github.com/strangelove-ventures/interchaintest/v7/ibc" + test "github.com/strangelove-ventures/interchaintest/v7/testutil" "github.com/stretchr/testify/suite" "github.com/cosmos/ibc-go/e2e/testvalues" @@ -89,7 +89,7 @@ func (s *IncentivizedInterTxTestSuite) TestMsgSubmitTx_SuccessfulBankSend_Incent t.Run("execute interchain account bank send through controller", func(t *testing.T) { t.Run("fund interchain account wallet on host chainB", func(t *testing.T) { // fund the interchain account so it has some $$ to send - err := chainB.SendFunds(ctx, ibctest.FaucetAccountKeyName, ibc.WalletAmount{ + err := chainB.SendFunds(ctx, interchaintest.FaucetAccountKeyName, ibc.WalletAmount{ Address: interchainAcc, Amount: testvalues.StartingTokenAmount, Denom: chainB.Config().Denom, diff --git a/e2e/tests/interchain_accounts/intertx_test.go b/e2e/tests/interchain_accounts/intertx_test.go index 9d2942cc810..b70d539a55b 100644 --- a/e2e/tests/interchain_accounts/intertx_test.go +++ b/e2e/tests/interchain_accounts/intertx_test.go @@ -4,10 +4,10 @@ import ( "context" "testing" - "github.com/strangelove-ventures/ibctest/v7" - "github.com/strangelove-ventures/ibctest/v7/chain/cosmos" - "github.com/strangelove-ventures/ibctest/v7/ibc" - test "github.com/strangelove-ventures/ibctest/v7/testutil" + "github.com/strangelove-ventures/interchaintest/v7" + "github.com/strangelove-ventures/interchaintest/v7/chain/cosmos" + "github.com/strangelove-ventures/interchaintest/v7/ibc" + test "github.com/strangelove-ventures/interchaintest/v7/testutil" "github.com/stretchr/testify/suite" sdk "github.com/cosmos/cosmos-sdk/types" @@ -77,7 +77,7 @@ func (s *InterTxTestSuite) TestMsgSubmitTx_SuccessfulTransfer() { t.Run("interchain account executes a bank transfer on behalf of the corresponding owner account", func(t *testing.T) { t.Run("fund interchain account wallet", func(t *testing.T) { // fund the host account account so it has some $$ to send - err := chainB.SendFunds(ctx, ibctest.FaucetAccountKeyName, ibc.WalletAmount{ + err := chainB.SendFunds(ctx, interchaintest.FaucetAccountKeyName, ibc.WalletAmount{ Address: hostAccount, Amount: testvalues.StartingTokenAmount, Denom: chainB.Config().Denom, diff --git a/e2e/tests/transfer/base_test.go b/e2e/tests/transfer/base_test.go index 7c1a8be7051..d858bc04058 100644 --- a/e2e/tests/transfer/base_test.go +++ b/e2e/tests/transfer/base_test.go @@ -7,8 +7,8 @@ import ( "time" paramsproposaltypes "github.com/cosmos/cosmos-sdk/x/params/types/proposal" - "github.com/strangelove-ventures/ibctest/v7/ibc" - test "github.com/strangelove-ventures/ibctest/v7/testutil" + "github.com/strangelove-ventures/interchaintest/v7/ibc" + test "github.com/strangelove-ventures/interchaintest/v7/testutil" "github.com/stretchr/testify/suite" "github.com/cosmos/ibc-go/e2e/semverutil" diff --git a/e2e/tests/transfer/incentivized_test.go b/e2e/tests/transfer/incentivized_test.go index 85f15c2e18d..7da6e7b5c5d 100644 --- a/e2e/tests/transfer/incentivized_test.go +++ b/e2e/tests/transfer/incentivized_test.go @@ -6,8 +6,8 @@ import ( "time" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/strangelove-ventures/ibctest/v7/ibc" - test "github.com/strangelove-ventures/ibctest/v7/testutil" + "github.com/strangelove-ventures/interchaintest/v7/ibc" + test "github.com/strangelove-ventures/interchaintest/v7/testutil" "github.com/stretchr/testify/suite" "github.com/cosmos/ibc-go/e2e/testvalues" diff --git a/e2e/tests/upgrades/upgrade_test.go b/e2e/tests/upgrades/upgrade_test.go index 337a5e266af..4a84e69a308 100644 --- a/e2e/tests/upgrades/upgrade_test.go +++ b/e2e/tests/upgrades/upgrade_test.go @@ -12,10 +12,10 @@ import ( "github.com/cosmos/gogoproto/proto" v6upgrades "github.com/cosmos/interchain-accounts/app/upgrades/v6" intertxtypes "github.com/cosmos/interchain-accounts/x/inter-tx/types" - ibctest "github.com/strangelove-ventures/ibctest/v7" - "github.com/strangelove-ventures/ibctest/v7/chain/cosmos" - "github.com/strangelove-ventures/ibctest/v7/ibc" - test "github.com/strangelove-ventures/ibctest/v7/testutil" + interchaintest "github.com/strangelove-ventures/interchaintest/v7" + "github.com/strangelove-ventures/interchaintest/v7/chain/cosmos" + "github.com/strangelove-ventures/interchaintest/v7/ibc" + test "github.com/strangelove-ventures/interchaintest/v7/testutil" "github.com/stretchr/testify/suite" "golang.org/x/mod/semver" @@ -242,7 +242,7 @@ func (s *UpgradeTestSuite) TestV5ToV6ChainUpgrade() { t.Run("interchain account executes a bank transfer on behalf of the corresponding owner account", func(t *testing.T) { t.Run("fund interchain account wallet", func(t *testing.T) { // fund the host account account so it has some $$ to send - err := chainB.SendFunds(ctx, ibctest.FaucetAccountKeyName, ibc.WalletAmount{ + err := chainB.SendFunds(ctx, interchaintest.FaucetAccountKeyName, ibc.WalletAmount{ Address: hostAccount, Amount: testvalues.StartingTokenAmount, Denom: chainB.Config().Denom, diff --git a/e2e/testsuite/grpc_query.go b/e2e/testsuite/grpc_query.go index 5babe87970f..ff38ae0f09e 100644 --- a/e2e/testsuite/grpc_query.go +++ b/e2e/testsuite/grpc_query.go @@ -6,8 +6,8 @@ import ( govtypesv1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1" govtypesbeta1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1" intertxtypes "github.com/cosmos/interchain-accounts/x/inter-tx/types" - "github.com/strangelove-ventures/ibctest/v7/chain/cosmos" - "github.com/strangelove-ventures/ibctest/v7/ibc" + "github.com/strangelove-ventures/interchaintest/v7/chain/cosmos" + "github.com/strangelove-ventures/interchaintest/v7/ibc" controllertypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller/types" feetypes "github.com/cosmos/ibc-go/v7/modules/apps/29-fee/types" diff --git a/e2e/testsuite/relayer.go b/e2e/testsuite/relayer.go index 3728eac56bb..dcf20a15548 100644 --- a/e2e/testsuite/relayer.go +++ b/e2e/testsuite/relayer.go @@ -4,9 +4,9 @@ import ( "testing" dockerclient "github.com/docker/docker/client" - "github.com/strangelove-ventures/ibctest/v7" - "github.com/strangelove-ventures/ibctest/v7/ibc" - "github.com/strangelove-ventures/ibctest/v7/relayer" + interchaintest "github.com/strangelove-ventures/interchaintest/v7" + "github.com/strangelove-ventures/interchaintest/v7/ibc" + "github.com/strangelove-ventures/interchaintest/v7/relayer" "go.uber.org/zap" "github.com/cosmos/ibc-go/e2e/testconfig" @@ -23,7 +23,7 @@ func newCosmosRelayer(t *testing.T, tc testconfig.TestConfig, logger *zap.Logger customImageOption := relayer.CustomDockerImage(cosmosRelayerRepository, tc.RlyTag, cosmosRelayerUser) relayerProcessingOption := relayer.StartupFlags("-p", "events") // relayer processes via events - relayerFactory := ibctest.NewBuiltinRelayerFactory(ibc.CosmosRly, logger, customImageOption, relayerProcessingOption) + relayerFactory := interchaintest.NewBuiltinRelayerFactory(ibc.CosmosRly, logger, customImageOption, relayerProcessingOption) return relayerFactory.Build( t, dockerClient, network, diff --git a/e2e/testsuite/testsuite.go b/e2e/testsuite/testsuite.go index 42503349078..4d498e98aeb 100644 --- a/e2e/testsuite/testsuite.go +++ b/e2e/testsuite/testsuite.go @@ -20,11 +20,11 @@ import ( paramsproposaltypes "github.com/cosmos/cosmos-sdk/x/params/types/proposal" intertxtypes "github.com/cosmos/interchain-accounts/x/inter-tx/types" dockerclient "github.com/docker/docker/client" - "github.com/strangelove-ventures/ibctest/v7" - "github.com/strangelove-ventures/ibctest/v7/chain/cosmos" - "github.com/strangelove-ventures/ibctest/v7/ibc" - "github.com/strangelove-ventures/ibctest/v7/testreporter" - test "github.com/strangelove-ventures/ibctest/v7/testutil" + interchaintest "github.com/strangelove-ventures/interchaintest/v7" + "github.com/strangelove-ventures/interchaintest/v7/chain/cosmos" + "github.com/strangelove-ventures/interchaintest/v7/ibc" + "github.com/strangelove-ventures/interchaintest/v7/testreporter" + test "github.com/strangelove-ventures/interchaintest/v7/testutil" "github.com/stretchr/testify/suite" "go.uber.org/zap" "go.uber.org/zap/zaptest" @@ -131,11 +131,11 @@ func (s *E2ETestSuite) SetupChainsRelayerAndChannel(ctx context.Context, channel opt(&channelOptions) } - ic := ibctest.NewInterchain(). + ic := interchaintest.NewInterchain(). AddChain(chainA). AddChain(chainB). AddRelayer(r, "r"). - AddLink(ibctest.InterchainLink{ + AddLink(interchaintest.InterchainLink{ Chain1: chainA, Chain2: chainB, Relayer: r, @@ -144,7 +144,7 @@ func (s *E2ETestSuite) SetupChainsRelayerAndChannel(ctx context.Context, channel }) eRep := s.GetRelayerExecReporter() - s.Require().NoError(ic.Build(ctx, eRep, ibctest.InterchainBuildOptions{ + s.Require().NoError(ic.Build(ctx, eRep, interchaintest.InterchainBuildOptions{ TestName: s.T().Name(), Client: s.DockerClient, NetworkID: s.network, @@ -229,23 +229,9 @@ func (s *E2ETestSuite) GetChains(chainOpts ...testconfig.ChainOptionConfiguratio return path.chainA, path.chainB } -// TODO: remove this type once the broadcast user interface aligns with ibc.Wallet -type broadcastUser struct { - ibc.Wallet -} - -// FormattedAddressWithPrefix implement the broadcast user interface, the FormattedAddress -// function already includes the correct prefix. -func (b *broadcastUser) FormattedAddressWithPrefix(prefix string) string { - return b.FormattedAddress() -} - // BroadcastMessages broadcasts the provided messages to the given chain and signs them on behalf of the provided user. // Once the broadcast response is returned, we wait for a few blocks to be created on both chain A and chain B. func (s *E2ETestSuite) BroadcastMessages(ctx context.Context, chain *cosmos.CosmosChain, user ibc.Wallet, msgs ...sdk.Msg) (sdk.TxResponse, error) { - // wrap the user so it is a valid implementation of broadcast user. - b := broadcastUser{Wallet: user} - broadcaster := cosmos.NewBroadcaster(s.T(), chain) broadcaster.ConfigureClientContextOptions(func(clientContext client.Context) client.Context { @@ -259,7 +245,7 @@ func (s *E2ETestSuite) BroadcastMessages(ctx context.Context, chain *cosmos.Cosm return factory.WithGas(DefaultGasValue) }) - resp, err := cosmos.BroadcastTx(ctx, broadcaster, &b, msgs...) + resp, err := cosmos.BroadcastTx(ctx, broadcaster, user, msgs...) if err != nil { return sdk.TxResponse{}, err } @@ -349,13 +335,13 @@ func (s *E2ETestSuite) StopRelayer(ctx context.Context, relayer ibc.Relayer) { // CreateUserOnChainA creates a user with the given amount of funds on chain A. func (s *E2ETestSuite) CreateUserOnChainA(ctx context.Context, amount int64) ibc.Wallet { chainA, _ := s.GetChains() - return ibctest.GetAndFundTestUsers(s.T(), ctx, strings.ReplaceAll(s.T().Name(), " ", "-"), amount, chainA)[0] + return interchaintest.GetAndFundTestUsers(s.T(), ctx, strings.ReplaceAll(s.T().Name(), " ", "-"), amount, chainA)[0] } // CreateUserOnChainB creates a user with the given amount of funds on chain B. func (s *E2ETestSuite) CreateUserOnChainB(ctx context.Context, amount int64) ibc.Wallet { _, chainB := s.GetChains() - return ibctest.GetAndFundTestUsers(s.T(), ctx, strings.ReplaceAll(s.T().Name(), " ", "-"), amount, chainB)[0] + return interchaintest.GetAndFundTestUsers(s.T(), ctx, strings.ReplaceAll(s.T().Name(), " ", "-"), amount, chainB)[0] } // GetChainANativeBalance gets the balance of a given user on chain A. @@ -433,7 +419,7 @@ func (s *E2ETestSuite) AssertPacketRelayed(ctx context.Context, chain *cosmos.Co // createCosmosChains creates two separate chains in docker containers. // test and can be retrieved with GetChains. func (s *E2ETestSuite) createCosmosChains(chainOptions testconfig.ChainOptions) (*cosmos.CosmosChain, *cosmos.CosmosChain) { - client, network := ibctest.DockerSetup(s.T()) + client, network := interchaintest.DockerSetup(s.T()) s.logger = zap.NewExample() s.DockerClient = client diff --git a/e2e/testvalues/values.go b/e2e/testvalues/values.go index ead66b00351..86f788a1bd8 100644 --- a/e2e/testvalues/values.go +++ b/e2e/testvalues/values.go @@ -5,7 +5,7 @@ import ( "time" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/strangelove-ventures/ibctest/v7/ibc" + "github.com/strangelove-ventures/interchaintest/v7/ibc" feetypes "github.com/cosmos/ibc-go/v7/modules/apps/29-fee/types" ) From 6c008ea25d72c672949794dc4dba73a530d46391 Mon Sep 17 00:00:00 2001 From: Carlos Rodriguez Date: Thu, 2 Feb 2023 10:46:32 +0100 Subject: [PATCH 11/22] feat: Added authz support for ics20 (#3079) Co-authored-by: Damian Nolan Co-authored-by: Cian Hatton Co-authored-by: Charleen Fei Co-authored-by: Zaki Manian --- .github/workflows/e2e-manual-simd.yaml | 1 + docs/ibc/proto-docs.md | 54 ++ e2e/testconfig/testconfig.go | 8 + e2e/tests/transfer/authz_test.go | 329 +++++++++ e2e/testsuite/codec.go | 2 + e2e/testsuite/testsuite.go | 30 +- e2e/testvalues/values.go | 2 +- go.mod | 2 +- modules/apps/transfer/types/authz.pb.go | 695 ++++++++++++++++++ modules/apps/transfer/types/codec.go | 6 + modules/apps/transfer/types/errors.go | 1 + .../transfer/types/transfer_authorization.go | 127 ++++ .../types/transfer_authorization_test.go | 282 +++++++ .../types/{ack_test.go => types_test.go} | 11 + .../ibc/applications/transfer/v1/authz.proto | 31 + 15 files changed, 1578 insertions(+), 3 deletions(-) create mode 100644 e2e/tests/transfer/authz_test.go create mode 100644 modules/apps/transfer/types/authz.pb.go create mode 100644 modules/apps/transfer/types/transfer_authorization.go create mode 100644 modules/apps/transfer/types/transfer_authorization_test.go rename modules/apps/transfer/types/{ack_test.go => types_test.go} (59%) create mode 100644 proto/ibc/applications/transfer/v1/authz.proto diff --git a/.github/workflows/e2e-manual-simd.yaml b/.github/workflows/e2e-manual-simd.yaml index 55fb1e771c2..611ad78e9c6 100644 --- a/.github/workflows/e2e-manual-simd.yaml +++ b/.github/workflows/e2e-manual-simd.yaml @@ -17,6 +17,7 @@ on: - TestInterchainAccountsGroupsTestSuite - TestInterchainAccountsGovTestSuite - TestIncentivizedInterchainAccountsTestSuite + - TestAuthzTransferTestSuite chain-image: description: 'The image to use for chain A' required: true diff --git a/docs/ibc/proto-docs.md b/docs/ibc/proto-docs.md index 91154efa20b..5ec2d594cf0 100644 --- a/docs/ibc/proto-docs.md +++ b/docs/ibc/proto-docs.md @@ -154,6 +154,10 @@ - [Msg](#ibc.applications.transfer.v1.Msg) +- [ibc/applications/transfer/v2/authz.proto](#ibc/applications/transfer/v2/authz.proto) + - [PortChannelAmount](#ibc.applications.transfer.v2.PortChannelAmount) + - [TransferAuthorization](#ibc.applications.transfer.v2.TransferAuthorization) + - [ibc/applications/transfer/v2/packet.proto](#ibc/applications/transfer/v2/packet.proto) - [FungibleTokenPacketData](#ibc.applications.transfer.v2.FungibleTokenPacketData) @@ -2296,6 +2300,56 @@ Msg defines the ibc/transfer Msg service. + +

Top

+ +## ibc/applications/transfer/v2/authz.proto + + + + + +### PortChannelAmount + + + +| Field | Type | Label | Description | +| ----- | ---- | ----- | ----------- | +| `source_port` | [string](#string) | | the port on which the packet will be sent | +| `source_channel` | [string](#string) | | the channel by which the packet will be sent | +| `spend_limit` | [cosmos.base.v1beta1.Coin](#cosmos.base.v1beta1.Coin) | repeated | spend limitation on the channel | +| `allowed_addresses` | [string](#string) | repeated | | + + + + + + + + +### TransferAuthorization +TransferAuthorization allows the grantee to spend up to spend_limit coins from +the granter's account for ibc transfer on a specific channel + + +| Field | Type | Label | Description | +| ----- | ---- | ----- | ----------- | +| `allocations` | [PortChannelAmount](#ibc.applications.transfer.v2.PortChannelAmount) | repeated | port and channel amounts | + + + + + + + + + + + + + + +

Top

diff --git a/e2e/testconfig/testconfig.go b/e2e/testconfig/testconfig.go index 19e544fd618..fcd7e262caf 100644 --- a/e2e/testconfig/testconfig.go +++ b/e2e/testconfig/testconfig.go @@ -4,6 +4,7 @@ import ( "encoding/json" "fmt" "os" + "strings" "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" @@ -132,6 +133,13 @@ func GetChainBTag() string { return chainBTag } +// IsCI returns true if the tests are running in CI, false is returned +// if the tests are running locally. +// Note: github actions passes a CI env value of true by default to all runners. +func IsCI() bool { + return strings.ToLower(os.Getenv("CI")) == "true" +} + // ChainOptions stores chain configurations for the chains that will be // created for the tests. They can be modified by passing ChainOptionConfiguration // to E2ETestSuite.GetChains. diff --git a/e2e/tests/transfer/authz_test.go b/e2e/tests/transfer/authz_test.go new file mode 100644 index 00000000000..c70dfe0e834 --- /dev/null +++ b/e2e/tests/transfer/authz_test.go @@ -0,0 +1,329 @@ +package transfer + +import ( + "context" + "testing" + + codectypes "github.com/cosmos/cosmos-sdk/codec/types" + sdk "github.com/cosmos/cosmos-sdk/types" + sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" + "github.com/cosmos/cosmos-sdk/x/authz" + test "github.com/strangelove-ventures/interchaintest/v7/testutil" + "github.com/stretchr/testify/suite" + + "github.com/cosmos/ibc-go/e2e/testsuite" + "github.com/cosmos/ibc-go/e2e/testvalues" + transfertypes "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types" +) + +func TestAuthzTransferTestSuite(t *testing.T) { + suite.Run(t, new(AuthzTransferTestSuite)) +} + +type AuthzTransferTestSuite struct { + testsuite.E2ETestSuite +} + +func (suite *AuthzTransferTestSuite) TestAuthz_MsgTransfer_Succeeds() { + t := suite.T() + ctx := context.TODO() + + relayer, channelA := suite.SetupChainsRelayerAndChannel(ctx, transferChannelOptions()) + chainA, chainB := suite.GetChains() + + chainADenom := chainA.Config().Denom + + granterWallet := suite.CreateUserOnChainA(ctx, testvalues.StartingTokenAmount) + granterAddress := granterWallet.FormattedAddress() + + granteeWallet := suite.CreateUserOnChainA(ctx, testvalues.StartingTokenAmount) + granteeAddress := granteeWallet.FormattedAddress() + + receiverWallet := suite.CreateUserOnChainB(ctx, testvalues.StartingTokenAmount) + receiverWalletAddress := receiverWallet.FormattedAddress() + + t.Run("start relayer", func(t *testing.T) { + suite.StartRelayer(relayer) + }) + + // createMsgGrantFn initializes a TransferAuthorization and broadcasts a MsgGrant message. + createMsgGrantFn := func(t *testing.T) { + transferAuth := transfertypes.TransferAuthorization{ + Allocations: []transfertypes.Allocation{ + { + SourcePort: channelA.PortID, + SourceChannel: channelA.ChannelID, + SpendLimit: sdk.NewCoins(sdk.NewCoin(chainADenom, sdk.NewInt(testvalues.StartingTokenAmount))), + AllowList: []string{receiverWalletAddress}, + }, + }, + } + + authAny, err := codectypes.NewAnyWithValue(&transferAuth) + suite.Require().NoError(err) + + msgGrant := &authz.MsgGrant{ + Granter: granterAddress, + Grantee: granteeAddress, + Grant: authz.Grant{ + Authorization: authAny, + // no expiration + Expiration: nil, + }, + } + + resp, err := suite.BroadcastMessages(context.TODO(), chainA, granterWallet, msgGrant) + suite.AssertValidTxResponse(resp) + suite.Require().NoError(err) + } + + // verifyGrantFn returns a test function which asserts chainA has a grant authorization + // with the given spend limit. + verifyGrantFn := func(expectedLimit int64) func(t *testing.T) { + return func(t *testing.T) { + grantAuths, err := suite.QueryGranterGrants(ctx, chainA, granterAddress) + + suite.Require().NoError(err) + suite.Require().Len(grantAuths, 1) + grantAuthorization := grantAuths[0] + + transferAuth := suite.extractTransferAuthorizationFromGrantAuthorization(grantAuthorization) + expectedSpendLimit := sdk.NewCoins(sdk.NewCoin(chainADenom, sdk.NewInt(expectedLimit))) + suite.Require().Equal(expectedSpendLimit, transferAuth.Allocations[0].SpendLimit) + } + } + + t.Run("broadcast MsgGrant", createMsgGrantFn) + + t.Run("broadcast MsgExec for ibc MsgTransfer", func(t *testing.T) { + transferMsg := transfertypes.MsgTransfer{ + SourcePort: channelA.PortID, + SourceChannel: channelA.ChannelID, + Token: testvalues.DefaultTransferAmount(chainADenom), + Sender: granterAddress, + Receiver: receiverWalletAddress, + TimeoutHeight: suite.GetTimeoutHeight(ctx, chainB), + } + + transferAny, err := codectypes.NewAnyWithValue(&transferMsg) + suite.Require().NoError(err) + + msgExec := &authz.MsgExec{ + Grantee: granteeAddress, + Msgs: []*codectypes.Any{transferAny}, + } + + resp, err := suite.BroadcastMessages(context.TODO(), chainA, granteeWallet, msgExec) + suite.AssertValidTxResponse(resp) + suite.Require().NoError(err) + }) + + t.Run("verify granter wallet amount", func(t *testing.T) { + actualBalance, err := suite.GetChainANativeBalance(ctx, granterWallet) + suite.Require().NoError(err) + + expected := testvalues.StartingTokenAmount - testvalues.IBCTransferAmount + suite.Require().Equal(expected, actualBalance) + }) + + suite.Require().NoError(test.WaitForBlocks(context.TODO(), 10, chainB)) + + t.Run("verify receiver wallet amount", func(t *testing.T) { + chainBIBCToken := testsuite.GetIBCToken(chainADenom, channelA.Counterparty.PortID, channelA.Counterparty.ChannelID) + actualBalance, err := chainB.GetBalance(ctx, receiverWalletAddress, chainBIBCToken.IBCDenom()) + suite.Require().NoError(err) + suite.Require().Equal(testvalues.IBCTransferAmount, actualBalance) + }) + + t.Run("granter grant spend limit reduced", verifyGrantFn(testvalues.StartingTokenAmount-testvalues.IBCTransferAmount)) + + t.Run("re-initialize MsgGrant", createMsgGrantFn) + + t.Run("granter grant was reinitialized", verifyGrantFn(testvalues.StartingTokenAmount)) + + t.Run("revoke access", func(t *testing.T) { + msgRevoke := authz.MsgRevoke{ + Granter: granterAddress, + Grantee: granteeAddress, + MsgTypeUrl: transfertypes.TransferAuthorization{}.MsgTypeURL(), + } + + resp, err := suite.BroadcastMessages(context.TODO(), chainA, granterWallet, &msgRevoke) + suite.AssertValidTxResponse(resp) + suite.Require().NoError(err) + }) + + t.Run("exec unauthorized MsgTransfer", func(t *testing.T) { + transferMsg := transfertypes.MsgTransfer{ + SourcePort: channelA.PortID, + SourceChannel: channelA.ChannelID, + Token: testvalues.DefaultTransferAmount(chainADenom), + Sender: granterAddress, + Receiver: receiverWalletAddress, + TimeoutHeight: suite.GetTimeoutHeight(ctx, chainB), + } + + transferAny, err := codectypes.NewAnyWithValue(&transferMsg) + suite.Require().NoError(err) + + msgExec := &authz.MsgExec{ + Grantee: granteeAddress, + Msgs: []*codectypes.Any{transferAny}, + } + + resp, err := suite.BroadcastMessages(context.TODO(), chainA, granteeWallet, msgExec) + suite.Require().NotEqual(0, resp.Code) + suite.Require().Contains(resp.RawLog, authz.ErrNoAuthorizationFound.Error()) + suite.Require().NoError(err) + }) +} + +func (suite *AuthzTransferTestSuite) TestAuthz_InvalidTransferAuthorizations() { + t := suite.T() + ctx := context.TODO() + + relayer, channelA := suite.SetupChainsRelayerAndChannel(ctx, transferChannelOptions()) + chainA, chainB := suite.GetChains() + + chainADenom := chainA.Config().Denom + + granterWallet := suite.CreateUserOnChainA(ctx, testvalues.StartingTokenAmount) + granterAddress := granterWallet.FormattedAddress() + + granteeWallet := suite.CreateUserOnChainA(ctx, testvalues.StartingTokenAmount) + granteeAddress := granteeWallet.FormattedAddress() + + receiverWallet := suite.CreateUserOnChainB(ctx, testvalues.StartingTokenAmount) + receiverWalletAddress := receiverWallet.FormattedAddress() + + t.Run("start relayer", func(t *testing.T) { + suite.StartRelayer(relayer) + }) + + const spendLimit = 1000 + + t.Run("broadcast MsgGrant", func(t *testing.T) { + transferAuth := transfertypes.TransferAuthorization{ + Allocations: []transfertypes.Allocation{ + { + SourcePort: channelA.PortID, + SourceChannel: channelA.ChannelID, + SpendLimit: sdk.NewCoins(sdk.NewCoin(chainADenom, sdk.NewInt(spendLimit))), + AllowList: []string{receiverWalletAddress}, + }, + }, + } + + authAny, err := codectypes.NewAnyWithValue(&transferAuth) + suite.Require().NoError(err) + + msgGrant := &authz.MsgGrant{ + Granter: granterAddress, + Grantee: granteeAddress, + Grant: authz.Grant{ + Authorization: authAny, + // no expiration + Expiration: nil, + }, + } + + resp, err := suite.BroadcastMessages(context.TODO(), chainA, granterWallet, msgGrant) + suite.AssertValidTxResponse(resp) + suite.Require().NoError(err) + }) + + t.Run("exceed spend limit", func(t *testing.T) { + const invalidSpendAmount = spendLimit + 1 + + t.Run("broadcast MsgExec for ibc MsgTransfer", func(t *testing.T) { + transferMsg := transfertypes.MsgTransfer{ + SourcePort: channelA.PortID, + SourceChannel: channelA.ChannelID, + Token: sdk.Coin{Denom: chainADenom, Amount: sdk.NewInt(invalidSpendAmount)}, + Sender: granterAddress, + Receiver: receiverWalletAddress, + TimeoutHeight: suite.GetTimeoutHeight(ctx, chainB), + } + + transferAny, err := codectypes.NewAnyWithValue(&transferMsg) + suite.Require().NoError(err) + + msgExec := &authz.MsgExec{ + Grantee: granteeAddress, + Msgs: []*codectypes.Any{transferAny}, + } + + resp, err := suite.BroadcastMessages(context.TODO(), chainA, granteeWallet, msgExec) + suite.Require().NotEqual(0, resp.Code) + suite.Require().Contains(resp.RawLog, sdkerrors.ErrInsufficientFunds.Error()) + suite.Require().NoError(err) + }) + + t.Run("verify granter wallet amount", func(t *testing.T) { + actualBalance, err := suite.GetChainANativeBalance(ctx, granterWallet) + suite.Require().NoError(err) + suite.Require().Equal(testvalues.StartingTokenAmount, actualBalance) + }) + + t.Run("verify receiver wallet amount", func(t *testing.T) { + chainBIBCToken := testsuite.GetIBCToken(chainADenom, channelA.Counterparty.PortID, channelA.Counterparty.ChannelID) + actualBalance, err := chainB.GetBalance(ctx, receiverWalletAddress, chainBIBCToken.IBCDenom()) + suite.Require().NoError(err) + suite.Require().Equal(int64(0), actualBalance) + }) + + t.Run("granter grant spend limit unchanged", func(t *testing.T) { + grantAuths, err := suite.QueryGranterGrants(ctx, chainA, granterAddress) + + suite.Require().NoError(err) + suite.Require().Len(grantAuths, 1) + grantAuthorization := grantAuths[0] + + transferAuth := suite.extractTransferAuthorizationFromGrantAuthorization(grantAuthorization) + expectedSpendLimit := sdk.NewCoins(sdk.NewCoin(chainADenom, sdk.NewInt(spendLimit))) + suite.Require().Equal(expectedSpendLimit, transferAuth.Allocations[0].SpendLimit) + }) + }) + + t.Run("send funds to invalid address", func(t *testing.T) { + invalidWallet := suite.CreateUserOnChainB(ctx, testvalues.StartingTokenAmount) + invalidWalletAddress := invalidWallet.FormattedAddress() + + t.Run("broadcast MsgExec for ibc MsgTransfer", func(t *testing.T) { + transferMsg := transfertypes.MsgTransfer{ + SourcePort: channelA.PortID, + SourceChannel: channelA.ChannelID, + Token: sdk.Coin{Denom: chainADenom, Amount: sdk.NewInt(spendLimit)}, + Sender: granterAddress, + Receiver: invalidWalletAddress, + TimeoutHeight: suite.GetTimeoutHeight(ctx, chainB), + } + + transferAny, err := codectypes.NewAnyWithValue(&transferMsg) + suite.Require().NoError(err) + + msgExec := &authz.MsgExec{ + Grantee: granteeAddress, + Msgs: []*codectypes.Any{transferAny}, + } + + resp, err := suite.BroadcastMessages(context.TODO(), chainA, granteeWallet, msgExec) + suite.Require().NotEqual(0, resp.Code) + suite.Require().Contains(resp.RawLog, sdkerrors.ErrInvalidAddress.Error()) + suite.Require().NoError(err) + }) + }) +} + +// extractTransferAuthorizationFromGrantAuthorization extracts a TransferAuthorization from the given +// GrantAuthorization. +func (suite *AuthzTransferTestSuite) extractTransferAuthorizationFromGrantAuthorization(grantAuth *authz.GrantAuthorization) *transfertypes.TransferAuthorization { + cfg := testsuite.EncodingConfig() + var authorization authz.Authorization + err := cfg.InterfaceRegistry.UnpackAny(grantAuth.Authorization, &authorization) + suite.Require().NoError(err) + + transferAuth, ok := authorization.(*transfertypes.TransferAuthorization) + suite.Require().True(ok) + return transferAuth +} diff --git a/e2e/testsuite/codec.go b/e2e/testsuite/codec.go index a203078079c..db0fa340b6c 100644 --- a/e2e/testsuite/codec.go +++ b/e2e/testsuite/codec.go @@ -4,6 +4,7 @@ import ( "github.com/cosmos/cosmos-sdk/codec" sdkcodec "github.com/cosmos/cosmos-sdk/crypto/codec" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" + "github.com/cosmos/cosmos-sdk/x/authz" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" govv1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1" govv1beta1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1" @@ -38,6 +39,7 @@ func codecAndEncodingConfig() (*codec.ProtoCodec, simappparams.EncodingConfig) { sdkcodec.RegisterInterfaces(cfg.InterfaceRegistry) grouptypes.RegisterInterfaces(cfg.InterfaceRegistry) proposaltypes.RegisterInterfaces(cfg.InterfaceRegistry) + authz.RegisterInterfaces(cfg.InterfaceRegistry) transfertypes.RegisterInterfaces(cfg.InterfaceRegistry) clienttypes.RegisterInterfaces(cfg.InterfaceRegistry) diff --git a/e2e/testsuite/testsuite.go b/e2e/testsuite/testsuite.go index 4d498e98aeb..05fb56232ba 100644 --- a/e2e/testsuite/testsuite.go +++ b/e2e/testsuite/testsuite.go @@ -14,6 +14,7 @@ import ( signingtypes "github.com/cosmos/cosmos-sdk/types/tx/signing" authtx "github.com/cosmos/cosmos-sdk/x/auth/tx" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" + "github.com/cosmos/cosmos-sdk/x/authz" govtypesv1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1" govtypesv1beta1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1" grouptypes "github.com/cosmos/cosmos-sdk/x/group" @@ -84,6 +85,7 @@ type GRPCClients struct { GroupsQueryClient grouptypes.QueryClient ParamsQueryClient paramsproposaltypes.QueryClient AuthQueryClient authtypes.QueryClient + AuthZQueryClient authz.QueryClient } // path is a pairing of two chains which will be used in a test. @@ -393,6 +395,7 @@ func (s *E2ETestSuite) InitGRPCClients(chain *cosmos.CosmosChain) { GroupsQueryClient: grouptypes.NewQueryClient(grpcConn), ParamsQueryClient: paramsproposaltypes.NewQueryClient(grpcConn), AuthQueryClient: authtypes.NewQueryClient(grpcConn), + AuthZQueryClient: authz.NewQueryClient(grpcConn), } } @@ -427,7 +430,7 @@ func (s *E2ETestSuite) createCosmosChains(chainOptions testconfig.ChainOptions) logger := zaptest.NewLogger(s.T()) - numValidators, numFullNodes := 4, 1 + numValidators, numFullNodes := getValidatorsAndFullNodes() chainA := cosmos.NewCosmosChain(s.T().Name(), *chainOptions.ChainAConfig, numValidators, numFullNodes, logger) chainB := cosmos.NewCosmosChain(s.T().Name(), *chainOptions.ChainBConfig, numValidators, numFullNodes, logger) @@ -541,7 +544,32 @@ func (s *E2ETestSuite) QueryModuleAccountAddress(ctx context.Context, moduleName return moduleAccount.GetAddress(), nil } +// QueryGranterGrants returns all GrantAuthorizations for the given granterAddress. +func (s *E2ETestSuite) QueryGranterGrants(ctx context.Context, chain *cosmos.CosmosChain, granterAddress string) ([]*authz.GrantAuthorization, error) { + authzClient := s.GetChainGRCPClients(chain).AuthZQueryClient + queryRequest := &authz.QueryGranterGrantsRequest{ + Granter: granterAddress, + } + + grants, err := authzClient.GranterGrants(ctx, queryRequest) + if err != nil { + return nil, err + } + + return grants.Grants, nil +} + // GetIBCToken returns the denomination of the full token denom sent to the receiving channel func GetIBCToken(fullTokenDenom string, portID, channelID string) transfertypes.DenomTrace { return transfertypes.ParseDenomTrace(fmt.Sprintf("%s/%s/%s", portID, channelID, fullTokenDenom)) } + +// getValidatorsAndFullNodes returns the number of validators and full nodes respectively that should be used for +// the test. If the test is running in CI, more nodes are used, when running locally a single node is used to +// use less resources and allow the tests to run faster. +func getValidatorsAndFullNodes() (int, int) { + if testconfig.IsCI() { + return 4, 1 + } + return 1, 0 +} diff --git a/e2e/testvalues/values.go b/e2e/testvalues/values.go index 86f788a1bd8..c4c09e68781 100644 --- a/e2e/testvalues/values.go +++ b/e2e/testvalues/values.go @@ -41,5 +41,5 @@ func TendermintClientID(id int) string { } func SolomachineClientID(id int) string { - return fmt.Sprint("06-solomachine-%d", id) + return fmt.Sprintf("06-solomachine-%d", id) } diff --git a/go.mod b/go.mod index 692c949614c..24c60c0705c 100644 --- a/go.mod +++ b/go.mod @@ -22,6 +22,7 @@ require ( github.com/stretchr/testify v1.8.1 github.com/tendermint/tendermint v0.37.0-rc2 github.com/tendermint/tm-db v0.6.7 + golang.org/x/exp v0.0.0-20221019170559-20944726eadf google.golang.org/genproto v0.0.0-20221227171554-f9683d7f8bef google.golang.org/grpc v1.52.3 google.golang.org/protobuf v1.28.1 @@ -146,7 +147,6 @@ require ( go.etcd.io/bbolt v1.3.6 // indirect go.opencensus.io v0.24.0 // indirect golang.org/x/crypto v0.4.0 // indirect - golang.org/x/exp v0.0.0-20221019170559-20944726eadf // indirect golang.org/x/net v0.4.0 // indirect golang.org/x/oauth2 v0.0.0-20221014153046-6fdb5e3db783 // indirect golang.org/x/sys v0.3.0 // indirect diff --git a/modules/apps/transfer/types/authz.pb.go b/modules/apps/transfer/types/authz.pb.go new file mode 100644 index 00000000000..95f24eca332 --- /dev/null +++ b/modules/apps/transfer/types/authz.pb.go @@ -0,0 +1,695 @@ +// Code generated by protoc-gen-gogo. DO NOT EDIT. +// source: ibc/applications/transfer/v1/authz.proto + +package types + +import ( + fmt "fmt" + _ "github.com/cosmos/cosmos-proto" + github_com_cosmos_cosmos_sdk_types "github.com/cosmos/cosmos-sdk/types" + types "github.com/cosmos/cosmos-sdk/types" + _ "github.com/cosmos/gogoproto/gogoproto" + proto "github.com/cosmos/gogoproto/proto" + io "io" + math "math" + math_bits "math/bits" +) + +// Reference imports to suppress errors if they are not otherwise used. +var _ = proto.Marshal +var _ = fmt.Errorf +var _ = math.Inf + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the proto package it is being compiled against. +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package + +// Allocation defines the spend limit for a particular port and channel +type Allocation struct { + // the port on which the packet will be sent + SourcePort string `protobuf:"bytes,1,opt,name=source_port,json=sourcePort,proto3" json:"source_port,omitempty" yaml:"source_port"` + // the channel by which the packet will be sent + SourceChannel string `protobuf:"bytes,2,opt,name=source_channel,json=sourceChannel,proto3" json:"source_channel,omitempty" yaml:"source_channel"` + // spend limitation on the channel + SpendLimit github_com_cosmos_cosmos_sdk_types.Coins `protobuf:"bytes,3,rep,name=spend_limit,json=spendLimit,proto3,castrepeated=github.com/cosmos/cosmos-sdk/types.Coins" json:"spend_limit"` + // allow list of receivers, an empty allow list permits any receiver address + AllowList []string `protobuf:"bytes,4,rep,name=allow_list,json=allowList,proto3" json:"allow_list,omitempty"` +} + +func (m *Allocation) Reset() { *m = Allocation{} } +func (m *Allocation) String() string { return proto.CompactTextString(m) } +func (*Allocation) ProtoMessage() {} +func (*Allocation) Descriptor() ([]byte, []int) { + return fileDescriptor_b1a28b55d17325aa, []int{0} +} +func (m *Allocation) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *Allocation) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_Allocation.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 *Allocation) XXX_Merge(src proto.Message) { + xxx_messageInfo_Allocation.Merge(m, src) +} +func (m *Allocation) XXX_Size() int { + return m.Size() +} +func (m *Allocation) XXX_DiscardUnknown() { + xxx_messageInfo_Allocation.DiscardUnknown(m) +} + +var xxx_messageInfo_Allocation proto.InternalMessageInfo + +func (m *Allocation) GetSourcePort() string { + if m != nil { + return m.SourcePort + } + return "" +} + +func (m *Allocation) GetSourceChannel() string { + if m != nil { + return m.SourceChannel + } + return "" +} + +func (m *Allocation) GetSpendLimit() github_com_cosmos_cosmos_sdk_types.Coins { + if m != nil { + return m.SpendLimit + } + return nil +} + +func (m *Allocation) GetAllowList() []string { + if m != nil { + return m.AllowList + } + return nil +} + +// TransferAuthorization allows the grantee to spend up to spend_limit coins from +// the granter's account for ibc transfer on a specific channel +type TransferAuthorization struct { + // port and channel amounts + Allocations []Allocation `protobuf:"bytes,1,rep,name=allocations,proto3" json:"allocations"` +} + +func (m *TransferAuthorization) Reset() { *m = TransferAuthorization{} } +func (m *TransferAuthorization) String() string { return proto.CompactTextString(m) } +func (*TransferAuthorization) ProtoMessage() {} +func (*TransferAuthorization) Descriptor() ([]byte, []int) { + return fileDescriptor_b1a28b55d17325aa, []int{1} +} +func (m *TransferAuthorization) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *TransferAuthorization) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_TransferAuthorization.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 *TransferAuthorization) XXX_Merge(src proto.Message) { + xxx_messageInfo_TransferAuthorization.Merge(m, src) +} +func (m *TransferAuthorization) XXX_Size() int { + return m.Size() +} +func (m *TransferAuthorization) XXX_DiscardUnknown() { + xxx_messageInfo_TransferAuthorization.DiscardUnknown(m) +} + +var xxx_messageInfo_TransferAuthorization proto.InternalMessageInfo + +func (m *TransferAuthorization) GetAllocations() []Allocation { + if m != nil { + return m.Allocations + } + return nil +} + +func init() { + proto.RegisterType((*Allocation)(nil), "ibc.applications.transfer.v1.Allocation") + proto.RegisterType((*TransferAuthorization)(nil), "ibc.applications.transfer.v1.TransferAuthorization") +} + +func init() { + proto.RegisterFile("ibc/applications/transfer/v1/authz.proto", fileDescriptor_b1a28b55d17325aa) +} + +var fileDescriptor_b1a28b55d17325aa = []byte{ + // 435 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x7c, 0x52, 0x4d, 0x6e, 0xd3, 0x40, + 0x14, 0x8e, 0x9b, 0x0a, 0x29, 0x13, 0xc1, 0xc2, 0xa2, 0xc8, 0xa9, 0xc0, 0x89, 0xbc, 0x40, 0xde, + 0x64, 0x86, 0xc0, 0x22, 0x52, 0x57, 0x34, 0xdd, 0x76, 0x51, 0x2c, 0x56, 0x6c, 0xa2, 0xf1, 0x64, + 0xb0, 0x47, 0x8c, 0xfd, 0x2c, 0xcf, 0xd8, 0xa8, 0x3d, 0x05, 0x48, 0x9c, 0x82, 0x35, 0x87, 0xa8, + 0x58, 0x75, 0xc9, 0x2a, 0xa0, 0xe4, 0x06, 0x3d, 0x01, 0xf2, 0xcc, 0x14, 0x5c, 0x21, 0xb1, 0xb2, + 0xdf, 0xcf, 0xf7, 0xde, 0xf7, 0xbe, 0xf9, 0x50, 0x2c, 0x52, 0x46, 0x68, 0x55, 0x49, 0xc1, 0xa8, + 0x16, 0x50, 0x2a, 0xa2, 0x6b, 0x5a, 0xaa, 0xf7, 0xbc, 0x26, 0xed, 0x82, 0xd0, 0x46, 0xe7, 0x57, + 0xb8, 0xaa, 0x41, 0x83, 0xff, 0x54, 0xa4, 0x0c, 0xf7, 0x3b, 0xf1, 0x5d, 0x27, 0x6e, 0x17, 0xc7, + 0x13, 0x06, 0xaa, 0x00, 0xb5, 0x36, 0xbd, 0xc4, 0x06, 0x16, 0x78, 0xfc, 0x38, 0x83, 0x0c, 0x6c, + 0xbe, 0xfb, 0x73, 0xd9, 0xd0, 0xf6, 0x90, 0x94, 0x2a, 0x4e, 0xda, 0x45, 0xca, 0x35, 0x5d, 0x10, + 0x06, 0xa2, 0xb4, 0xf5, 0xe8, 0xcb, 0x01, 0x42, 0xa7, 0x52, 0x82, 0x5d, 0xe6, 0x2f, 0xd1, 0x58, + 0x41, 0x53, 0x33, 0xbe, 0xae, 0xa0, 0xd6, 0x81, 0x37, 0xf3, 0xe2, 0xd1, 0xea, 0xc9, 0xed, 0x76, + 0xea, 0x5f, 0xd2, 0x42, 0x9e, 0x44, 0xbd, 0x62, 0x94, 0x20, 0x1b, 0x5d, 0x40, 0xad, 0xfd, 0xd7, + 0xe8, 0x91, 0xab, 0xb1, 0x9c, 0x96, 0x25, 0x97, 0xc1, 0x81, 0xc1, 0x4e, 0x6e, 0xb7, 0xd3, 0xa3, + 0x7b, 0x58, 0x57, 0x8f, 0x92, 0x87, 0x36, 0x71, 0x66, 0x63, 0x5f, 0xa2, 0xb1, 0xaa, 0x78, 0xb9, + 0x59, 0x4b, 0x51, 0x08, 0x1d, 0x0c, 0x67, 0xc3, 0x78, 0xfc, 0x72, 0x82, 0xdd, 0x8d, 0x1d, 0x7f, + 0xec, 0xf8, 0xe3, 0x33, 0x10, 0xe5, 0xea, 0xc5, 0xf5, 0x76, 0x3a, 0xf8, 0xfa, 0x73, 0x1a, 0x67, + 0x42, 0xe7, 0x4d, 0x8a, 0x19, 0x14, 0x4e, 0x10, 0xf7, 0x99, 0xab, 0xcd, 0x07, 0xa2, 0x2f, 0x2b, + 0xae, 0x0c, 0x40, 0x25, 0xc8, 0xcc, 0x3f, 0xef, 0xc6, 0xfb, 0xcf, 0x10, 0xa2, 0x52, 0xc2, 0xc7, + 0xb5, 0x14, 0x4a, 0x07, 0x87, 0xb3, 0x61, 0x3c, 0x4a, 0x46, 0x26, 0x73, 0x2e, 0x94, 0x8e, 0x3e, + 0x7b, 0xe8, 0xe8, 0xad, 0xd3, 0xfd, 0xb4, 0xd1, 0x39, 0xd4, 0xe2, 0xca, 0x2a, 0x74, 0x81, 0xc6, + 0xf4, 0x8f, 0x5e, 0x2a, 0xf0, 0x0c, 0xcd, 0x18, 0xff, 0xef, 0xd5, 0xf0, 0x5f, 0x81, 0x57, 0x87, + 0x1d, 0xeb, 0xa4, 0x3f, 0xe2, 0xe4, 0xf9, 0xf7, 0x6f, 0xf3, 0xc8, 0x9d, 0x69, 0x9d, 0x70, 0x77, + 0xe7, 0xbd, 0xcd, 0xab, 0x37, 0xd7, 0xbb, 0xd0, 0xbb, 0xd9, 0x85, 0xde, 0xaf, 0x5d, 0xe8, 0x7d, + 0xda, 0x87, 0x83, 0x9b, 0x7d, 0x38, 0xf8, 0xb1, 0x0f, 0x07, 0xef, 0x96, 0xff, 0x4a, 0x20, 0x52, + 0x36, 0xcf, 0x80, 0xb4, 0x4b, 0x52, 0xc0, 0xa6, 0x91, 0x5c, 0x75, 0xee, 0xeb, 0xb9, 0xce, 0xe8, + 0x92, 0x3e, 0x30, 0x26, 0x78, 0xf5, 0x3b, 0x00, 0x00, 0xff, 0xff, 0x61, 0xe8, 0x65, 0x9c, 0x9f, + 0x02, 0x00, 0x00, +} + +func (m *Allocation) 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 *Allocation) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *Allocation) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if len(m.AllowList) > 0 { + for iNdEx := len(m.AllowList) - 1; iNdEx >= 0; iNdEx-- { + i -= len(m.AllowList[iNdEx]) + copy(dAtA[i:], m.AllowList[iNdEx]) + i = encodeVarintAuthz(dAtA, i, uint64(len(m.AllowList[iNdEx]))) + i-- + dAtA[i] = 0x22 + } + } + if len(m.SpendLimit) > 0 { + for iNdEx := len(m.SpendLimit) - 1; iNdEx >= 0; iNdEx-- { + { + size, err := m.SpendLimit[iNdEx].MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintAuthz(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x1a + } + } + if len(m.SourceChannel) > 0 { + i -= len(m.SourceChannel) + copy(dAtA[i:], m.SourceChannel) + i = encodeVarintAuthz(dAtA, i, uint64(len(m.SourceChannel))) + i-- + dAtA[i] = 0x12 + } + if len(m.SourcePort) > 0 { + i -= len(m.SourcePort) + copy(dAtA[i:], m.SourcePort) + i = encodeVarintAuthz(dAtA, i, uint64(len(m.SourcePort))) + i-- + dAtA[i] = 0xa + } + return len(dAtA) - i, nil +} + +func (m *TransferAuthorization) 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 *TransferAuthorization) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *TransferAuthorization) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if len(m.Allocations) > 0 { + for iNdEx := len(m.Allocations) - 1; iNdEx >= 0; iNdEx-- { + { + size, err := m.Allocations[iNdEx].MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintAuthz(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0xa + } + } + return len(dAtA) - i, nil +} + +func encodeVarintAuthz(dAtA []byte, offset int, v uint64) int { + offset -= sovAuthz(v) + base := offset + for v >= 1<<7 { + dAtA[offset] = uint8(v&0x7f | 0x80) + v >>= 7 + offset++ + } + dAtA[offset] = uint8(v) + return base +} +func (m *Allocation) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = len(m.SourcePort) + if l > 0 { + n += 1 + l + sovAuthz(uint64(l)) + } + l = len(m.SourceChannel) + if l > 0 { + n += 1 + l + sovAuthz(uint64(l)) + } + if len(m.SpendLimit) > 0 { + for _, e := range m.SpendLimit { + l = e.Size() + n += 1 + l + sovAuthz(uint64(l)) + } + } + if len(m.AllowList) > 0 { + for _, s := range m.AllowList { + l = len(s) + n += 1 + l + sovAuthz(uint64(l)) + } + } + return n +} + +func (m *TransferAuthorization) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + if len(m.Allocations) > 0 { + for _, e := range m.Allocations { + l = e.Size() + n += 1 + l + sovAuthz(uint64(l)) + } + } + return n +} + +func sovAuthz(x uint64) (n int) { + return (math_bits.Len64(x|1) + 6) / 7 +} +func sozAuthz(x uint64) (n int) { + return sovAuthz(uint64((x << 1) ^ uint64((int64(x) >> 63)))) +} +func (m *Allocation) 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 ErrIntOverflowAuthz + } + 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: Allocation: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: Allocation: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field SourcePort", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowAuthz + } + 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 ErrInvalidLengthAuthz + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthAuthz + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.SourcePort = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field SourceChannel", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowAuthz + } + 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 ErrInvalidLengthAuthz + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthAuthz + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.SourceChannel = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field SpendLimit", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowAuthz + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthAuthz + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthAuthz + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.SpendLimit = append(m.SpendLimit, types.Coin{}) + if err := m.SpendLimit[len(m.SpendLimit)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field AllowList", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowAuthz + } + 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 ErrInvalidLengthAuthz + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthAuthz + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.AllowList = append(m.AllowList, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipAuthz(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthAuthz + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *TransferAuthorization) 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 ErrIntOverflowAuthz + } + 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: TransferAuthorization: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: TransferAuthorization: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Allocations", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowAuthz + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthAuthz + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthAuthz + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Allocations = append(m.Allocations, Allocation{}) + if err := m.Allocations[len(m.Allocations)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipAuthz(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthAuthz + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func skipAuthz(dAtA []byte) (n int, err error) { + l := len(dAtA) + iNdEx := 0 + depth := 0 + for iNdEx < l { + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowAuthz + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + wireType := int(wire & 0x7) + switch wireType { + case 0: + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowAuthz + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + iNdEx++ + if dAtA[iNdEx-1] < 0x80 { + break + } + } + case 1: + iNdEx += 8 + case 2: + var length int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowAuthz + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + length |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if length < 0 { + return 0, ErrInvalidLengthAuthz + } + iNdEx += length + case 3: + depth++ + case 4: + if depth == 0 { + return 0, ErrUnexpectedEndOfGroupAuthz + } + depth-- + case 5: + iNdEx += 4 + default: + return 0, fmt.Errorf("proto: illegal wireType %d", wireType) + } + if iNdEx < 0 { + return 0, ErrInvalidLengthAuthz + } + if depth == 0 { + return iNdEx, nil + } + } + return 0, io.ErrUnexpectedEOF +} + +var ( + ErrInvalidLengthAuthz = fmt.Errorf("proto: negative length found during unmarshaling") + ErrIntOverflowAuthz = fmt.Errorf("proto: integer overflow") + ErrUnexpectedEndOfGroupAuthz = fmt.Errorf("proto: unexpected end of group") +) diff --git a/modules/apps/transfer/types/codec.go b/modules/apps/transfer/types/codec.go index f1fcf135f50..92ed91ef58a 100644 --- a/modules/apps/transfer/types/codec.go +++ b/modules/apps/transfer/types/codec.go @@ -3,6 +3,7 @@ package types import ( "bytes" + "github.com/cosmos/cosmos-sdk/x/authz" "github.com/cosmos/gogoproto/jsonpb" "github.com/cosmos/gogoproto/proto" @@ -23,6 +24,11 @@ func RegisterLegacyAminoCodec(cdc *codec.LegacyAmino) { func RegisterInterfaces(registry codectypes.InterfaceRegistry) { registry.RegisterImplementations((*sdk.Msg)(nil), &MsgTransfer{}) + registry.RegisterImplementations( + (*authz.Authorization)(nil), + &TransferAuthorization{}, + ) + msgservice.RegisterMsgServiceDesc(registry, &_Msg_serviceDesc) } diff --git a/modules/apps/transfer/types/errors.go b/modules/apps/transfer/types/errors.go index 0f0cb7c42a4..d4f85cf4fa7 100644 --- a/modules/apps/transfer/types/errors.go +++ b/modules/apps/transfer/types/errors.go @@ -14,4 +14,5 @@ var ( ErrSendDisabled = sdkerrors.Register(ModuleName, 7, "fungible token transfers from this chain are disabled") ErrReceiveDisabled = sdkerrors.Register(ModuleName, 8, "fungible token transfers to this chain are disabled") ErrMaxTransferChannels = sdkerrors.Register(ModuleName, 9, "max transfer channels") + ErrInvalidAuthorization = sdkerrors.Register(ModuleName, 10, "invalid transfer authorization") ) diff --git a/modules/apps/transfer/types/transfer_authorization.go b/modules/apps/transfer/types/transfer_authorization.go new file mode 100644 index 00000000000..fed33b0a909 --- /dev/null +++ b/modules/apps/transfer/types/transfer_authorization.go @@ -0,0 +1,127 @@ +package types + +import ( + sdk "github.com/cosmos/cosmos-sdk/types" + sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" + "github.com/cosmos/cosmos-sdk/x/authz" + + channeltypes "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" + host "github.com/cosmos/ibc-go/v7/modules/core/24-host" +) + +const gasCostPerIteration = uint64(10) + +var _ authz.Authorization = &TransferAuthorization{} + +// NewTransferAuthorization creates a new TransferAuthorization object. +func NewTransferAuthorization(allocations ...Allocation) *TransferAuthorization { + return &TransferAuthorization{ + Allocations: allocations, + } +} + +// MsgTypeURL implements Authorization.MsgTypeURL. +func (a TransferAuthorization) MsgTypeURL() string { + return sdk.MsgTypeURL(&MsgTransfer{}) +} + +// Accept implements Authorization.Accept. +func (a TransferAuthorization) Accept(ctx sdk.Context, msg sdk.Msg) (authz.AcceptResponse, error) { + msgTransfer, ok := msg.(*MsgTransfer) + if !ok { + return authz.AcceptResponse{}, sdkerrors.Wrap(sdkerrors.ErrInvalidType, "type mismatch") + } + + for index, allocation := range a.Allocations { + if allocation.SourceChannel == msgTransfer.SourceChannel && allocation.SourcePort == msgTransfer.SourcePort { + limitLeft, isNegative := allocation.SpendLimit.SafeSub(msgTransfer.Token) + if isNegative { + return authz.AcceptResponse{}, sdkerrors.Wrapf(sdkerrors.ErrInsufficientFunds, "requested amount is more than spend limit") + } + + if !isAllowedAddress(ctx, msgTransfer.Receiver, allocation.AllowList) { + return authz.AcceptResponse{}, sdkerrors.Wrapf(sdkerrors.ErrInvalidAddress, "not allowed address for transfer") + } + + if limitLeft.IsZero() { + a.Allocations = append(a.Allocations[:index], a.Allocations[index+1:]...) + if len(a.Allocations) == 0 { + return authz.AcceptResponse{Accept: true, Delete: true}, nil + } + return authz.AcceptResponse{Accept: true, Delete: false, Updated: &TransferAuthorization{ + Allocations: a.Allocations, + }}, nil + } + a.Allocations[index] = Allocation{ + SourcePort: allocation.SourcePort, + SourceChannel: allocation.SourceChannel, + SpendLimit: limitLeft, + AllowList: allocation.AllowList, + } + + return authz.AcceptResponse{Accept: true, Delete: false, Updated: &TransferAuthorization{ + Allocations: a.Allocations, + }}, nil + } + } + return authz.AcceptResponse{}, sdkerrors.Wrapf(sdkerrors.ErrNotFound, "requested port and channel allocation does not exist") +} + +// ValidateBasic implements Authorization.ValidateBasic. +func (a TransferAuthorization) ValidateBasic() error { + if len(a.Allocations) == 0 { + return sdkerrors.Wrap(ErrInvalidAuthorization, "allocations cannot be empty") + } + + foundChannels := make(map[string]bool, 0) + + for _, allocation := range a.Allocations { + if _, found := foundChannels[allocation.SourceChannel]; found { + return sdkerrors.Wrapf(channeltypes.ErrInvalidChannel, "duplicate source channel ID: %s", allocation.SourceChannel) + } + + foundChannels[allocation.SourceChannel] = true + + if allocation.SpendLimit == nil { + return sdkerrors.Wrap(sdkerrors.ErrInvalidCoins, "spend limit cannot be nil") + } + + if err := allocation.SpendLimit.Validate(); err != nil { + return sdkerrors.Wrapf(sdkerrors.ErrInvalidCoins, err.Error()) + } + + if err := host.PortIdentifierValidator(allocation.SourcePort); err != nil { + return sdkerrors.Wrap(err, "invalid source port ID") + } + + if err := host.ChannelIdentifierValidator(allocation.SourceChannel); err != nil { + return sdkerrors.Wrap(err, "invalid source channel ID") + } + + found := make(map[string]bool, 0) + for i := 0; i < len(allocation.AllowList); i++ { + if found[allocation.AllowList[i]] { + return sdkerrors.Wrapf(ErrInvalidAuthorization, "duplicate entry in allow list %s") + } + found[allocation.AllowList[i]] = true + } + } + + return nil +} + +// isAllowedAddress returns a boolean indicating if the receiver address is valid for transfer. +// gasCostPerIteration gas is consumed for each iteration. +func isAllowedAddress(ctx sdk.Context, receiver string, allowedAddrs []string) bool { + if len(allowedAddrs) == 0 { + return true + } + + for _, addr := range allowedAddrs { + ctx.GasMeter().ConsumeGas(gasCostPerIteration, "transfer authorization") + if addr == receiver { + return true + } + } + return false +} diff --git a/modules/apps/transfer/types/transfer_authorization_test.go b/modules/apps/transfer/types/transfer_authorization_test.go new file mode 100644 index 00000000000..f0f7f3ab0b9 --- /dev/null +++ b/modules/apps/transfer/types/transfer_authorization_test.go @@ -0,0 +1,282 @@ +package types_test + +import ( + sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/cosmos/cosmos-sdk/x/authz" + + "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types" + ibctesting "github.com/cosmos/ibc-go/v7/testing" + "github.com/cosmos/ibc-go/v7/testing/mock" +) + +func (suite *TypesTestSuite) TestTransferAuthorizationAccept() { + var ( + msgTransfer types.MsgTransfer + transferAuthz types.TransferAuthorization + ) + + testCases := []struct { + name string + malleate func() + assertResult func(res authz.AcceptResponse, err error) + }{ + { + "success", + func() {}, + func(res authz.AcceptResponse, err error) { + suite.Require().NoError(err) + + suite.Require().True(res.Accept) + suite.Require().True(res.Delete) + suite.Require().Nil(res.Updated) + }, + }, + { + "success: with spend limit updated", + func() { + msgTransfer.Token = sdk.NewCoin(sdk.DefaultBondDenom, sdk.NewInt(50)) + }, + func(res authz.AcceptResponse, err error) { + suite.Require().NoError(err) + + suite.Require().True(res.Accept) + suite.Require().False(res.Delete) + + updatedAuthz, ok := res.Updated.(*types.TransferAuthorization) + suite.Require().True(ok) + + isEqual := updatedAuthz.Allocations[0].SpendLimit.IsEqual(sdk.NewCoins(sdk.NewCoin(sdk.DefaultBondDenom, sdk.NewInt(50)))) + suite.Require().True(isEqual) + }, + }, + { + "success: with empty allow list", + func() { + transferAuthz.Allocations[0].AllowList = []string{} + }, + func(res authz.AcceptResponse, err error) { + suite.Require().NoError(err) + + suite.Require().True(res.Accept) + suite.Require().True(res.Delete) + suite.Require().Nil(res.Updated) + }, + }, + { + "success: with multiple allocations", + func() { + alloc := types.Allocation{ + SourcePort: ibctesting.MockPort, + SourceChannel: "channel-9", + SpendLimit: ibctesting.TestCoins, + } + + transferAuthz.Allocations = append(transferAuthz.Allocations, alloc) + }, + func(res authz.AcceptResponse, err error) { + suite.Require().NoError(err) + + suite.Require().True(res.Accept) + suite.Require().False(res.Delete) + + updatedAuthz, ok := res.Updated.(*types.TransferAuthorization) + suite.Require().True(ok) + + // assert spent spendlimit is removed from the list + suite.Require().Len(updatedAuthz.Allocations, 1) + }, + }, + { + "no spend limit set for MsgTransfer port/channel", + func() { + msgTransfer.SourcePort = ibctesting.MockPort + msgTransfer.SourceChannel = "channel-9" + }, + func(res authz.AcceptResponse, err error) { + suite.Require().Error(err) + }, + }, + { + "requested transfer amount is more than the spend limit", + func() { + msgTransfer.Token = sdk.NewCoin(sdk.DefaultBondDenom, sdk.NewInt(1000)) + }, + func(res authz.AcceptResponse, err error) { + suite.Require().Error(err) + }, + }, + { + "receiver address not permitted via allow list", + func() { + msgTransfer.Receiver = suite.chainB.SenderAccount.GetAddress().String() + }, + func(res authz.AcceptResponse, err error) { + suite.Require().Error(err) + }, + }, + } + + for _, tc := range testCases { + suite.Run(tc.name, func() { + suite.SetupTest() + + path := NewTransferPath(suite.chainA, suite.chainB) + suite.coordinator.Setup(path) + + transferAuthz = types.TransferAuthorization{ + Allocations: []types.Allocation{ + { + SourcePort: path.EndpointA.ChannelConfig.PortID, + SourceChannel: path.EndpointA.ChannelID, + SpendLimit: ibctesting.TestCoins, + AllowList: []string{ibctesting.TestAccAddress}, + }, + }, + } + + msgTransfer = types.MsgTransfer{ + SourcePort: path.EndpointA.ChannelConfig.PortID, + SourceChannel: path.EndpointA.ChannelID, + Token: ibctesting.TestCoin, + Sender: suite.chainA.SenderAccount.GetAddress().String(), + Receiver: ibctesting.TestAccAddress, + TimeoutHeight: suite.chainB.GetTimeoutHeight(), + } + + tc.malleate() + + res, err := transferAuthz.Accept(suite.chainA.GetContext(), &msgTransfer) + tc.assertResult(res, err) + }) + } +} + +func (suite *TypesTestSuite) TestTransferAuthorizationMsgTypeURL() { + var transferAuthz types.TransferAuthorization + suite.Require().Equal(sdk.MsgTypeURL(&types.MsgTransfer{}), transferAuthz.MsgTypeURL(), "invalid type url for transfer authorization") +} + +func (suite *TypesTestSuite) TestTransferAuthorizationValidateBasic() { + var transferAuthz types.TransferAuthorization + + testCases := []struct { + name string + malleate func() + expPass bool + }{ + { + "success", + func() {}, + true, + }, + { + "success: empty allow list", + func() { + transferAuthz.Allocations[0].AllowList = []string{} + }, + true, + }, + { + "success: with multiple allocations", + func() { + allocation := types.Allocation{ + SourcePort: types.PortID, + SourceChannel: "channel-1", + SpendLimit: sdk.NewCoins(sdk.NewCoin(sdk.DefaultBondDenom, sdk.NewInt(100))), + AllowList: []string{}, + } + + transferAuthz.Allocations = append(transferAuthz.Allocations, allocation) + }, + true, + }, + { + "empty allocations", + func() { + transferAuthz = types.TransferAuthorization{Allocations: []types.Allocation{}} + }, + false, + }, + { + "nil allocations", + func() { + transferAuthz = types.TransferAuthorization{} + }, + false, + }, + { + "nil spend limit coins", + func() { + transferAuthz.Allocations[0].SpendLimit = nil + }, + false, + }, + { + "invalid spend limit coins", + func() { + transferAuthz.Allocations[0].SpendLimit = sdk.Coins{sdk.Coin{Denom: ""}} + }, + false, + }, + { + "duplicate entry in allow list", + func() { + transferAuthz.Allocations[0].AllowList = []string{ibctesting.TestAccAddress, ibctesting.TestAccAddress} + }, + false, + }, + { + "invalid port identifier", + func() { + transferAuthz.Allocations[0].SourcePort = "" + }, + false, + }, + { + "invalid channel identifier", + func() { + transferAuthz.Allocations[0].SourceChannel = "" + }, + false, + }, + { + name: "duplicate channel ID", + malleate: func() { + allocation := types.Allocation{ + SourcePort: mock.PortID, + SourceChannel: transferAuthz.Allocations[0].SourceChannel, + SpendLimit: sdk.NewCoins(sdk.NewCoin(sdk.DefaultBondDenom, sdk.NewInt(100))), + AllowList: []string{ibctesting.TestAccAddress}, + } + + transferAuthz.Allocations = append(transferAuthz.Allocations, allocation) + }, + expPass: false, + }, + } + + for _, tc := range testCases { + suite.Run(tc.name, func() { + transferAuthz = types.TransferAuthorization{ + Allocations: []types.Allocation{ + { + SourcePort: mock.PortID, + SourceChannel: ibctesting.FirstChannelID, + SpendLimit: sdk.NewCoins(sdk.NewCoin(sdk.DefaultBondDenom, sdk.NewInt(100))), + AllowList: []string{ibctesting.TestAccAddress}, + }, + }, + } + + tc.malleate() + + err := transferAuthz.ValidateBasic() + + if tc.expPass { + suite.Require().NoError(err) + } else { + suite.Require().Error(err) + } + }) + } +} diff --git a/modules/apps/transfer/types/ack_test.go b/modules/apps/transfer/types/types_test.go similarity index 59% rename from modules/apps/transfer/types/ack_test.go rename to modules/apps/transfer/types/types_test.go index 1516f334e7e..86069b1a887 100644 --- a/modules/apps/transfer/types/ack_test.go +++ b/modules/apps/transfer/types/types_test.go @@ -5,6 +5,7 @@ import ( "github.com/stretchr/testify/suite" + "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types" ibctesting "github.com/cosmos/ibc-go/v7/testing" ) @@ -24,6 +25,16 @@ func (suite *TypesTestSuite) SetupTest() { suite.chainB = suite.coordinator.GetChain(ibctesting.GetChainID(2)) } +func NewTransferPath(chainA, chainB *ibctesting.TestChain) *ibctesting.Path { + path := ibctesting.NewPath(chainA, chainB) + path.EndpointA.ChannelConfig.PortID = types.PortID + path.EndpointB.ChannelConfig.PortID = types.PortID + path.EndpointA.ChannelConfig.Version = types.Version + path.EndpointB.ChannelConfig.Version = types.Version + + return path +} + func TestTypesTestSuite(t *testing.T) { suite.Run(t, new(TypesTestSuite)) } diff --git a/proto/ibc/applications/transfer/v1/authz.proto b/proto/ibc/applications/transfer/v1/authz.proto new file mode 100644 index 00000000000..8b27ac9cf7d --- /dev/null +++ b/proto/ibc/applications/transfer/v1/authz.proto @@ -0,0 +1,31 @@ +syntax = "proto3"; + +package ibc.applications.transfer.v1; + +option go_package = "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types"; + +import "cosmos_proto/cosmos.proto"; +import "gogoproto/gogo.proto"; +import "cosmos/base/v1beta1/coin.proto"; + +// Allocation defines the spend limit for a particular port and channel +message Allocation { + // the port on which the packet will be sent + string source_port = 1 [(gogoproto.moretags) = "yaml:\"source_port\""]; + // the channel by which the packet will be sent + string source_channel = 2 [(gogoproto.moretags) = "yaml:\"source_channel\""]; + // spend limitation on the channel + repeated cosmos.base.v1beta1.Coin spend_limit = 3 + [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"]; + // allow list of receivers, an empty allow list permits any receiver address + repeated string allow_list = 4; +} + +// TransferAuthorization allows the grantee to spend up to spend_limit coins from +// the granter's account for ibc transfer on a specific channel +message TransferAuthorization { + option (cosmos_proto.implements_interface) = "cosmos.authz.v1beta1.Authorization"; + + // port and channel amounts + repeated Allocation allocations = 1 [(gogoproto.nullable) = false]; +} From 65f7038f1b3c041cc39c25af91b786277548967d Mon Sep 17 00:00:00 2001 From: Cian Hatton Date: Thu, 2 Feb 2023 11:58:54 +0000 Subject: [PATCH 12/22] Fix Compatibility Tests using govv1beta1 GenesisStates (#3052) --- .../release-v4.3.x/transfer-chain-a.json | 2 +- .../release-v4.3.x/transfer-chain-b.json | 2 +- .../transfer-authz-chain-a.json | 15 ++ .github/workflows/release.yml | 2 +- e2e/semverutil/semver.go | 13 ++ e2e/testconfig/testconfig.go | 129 ++++++++++++------ e2e/testsuite/testsuite.go | 11 ++ 7 files changed, 129 insertions(+), 45 deletions(-) create mode 100644 .github/compatibility-test-matrices/release-v7.0.x/transfer-authz-chain-a.json diff --git a/.github/compatibility-test-matrices/release-v4.3.x/transfer-chain-a.json b/.github/compatibility-test-matrices/release-v4.3.x/transfer-chain-a.json index f4eaf8dff12..d800d545f2d 100644 --- a/.github/compatibility-test-matrices/release-v4.3.x/transfer-chain-a.json +++ b/.github/compatibility-test-matrices/release-v4.3.x/transfer-chain-a.json @@ -1,6 +1,6 @@ { "chain-a": ["release-v4.3.x"], - "chain-b": ["release-v4.3.x", "v6.1.0", "v5.2.0", "4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-b": ["release-v4.3.x", "v6.1.0", "v5.2.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], "entrypoint": ["TestTransferTestSuite"], "test": [ "TestMsgTransfer_Succeeds_Nonincentivized", diff --git a/.github/compatibility-test-matrices/release-v4.3.x/transfer-chain-b.json b/.github/compatibility-test-matrices/release-v4.3.x/transfer-chain-b.json index 3f1931c21bc..b74bdca5249 100644 --- a/.github/compatibility-test-matrices/release-v4.3.x/transfer-chain-b.json +++ b/.github/compatibility-test-matrices/release-v4.3.x/transfer-chain-b.json @@ -1,5 +1,5 @@ { - "chain-a": ["release-v4.3.x", "v6.1.0", "v5.2.0", "4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-a": ["release-v4.3.x", "v6.1.0", "v5.2.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], "chain-b": ["release-v4.3.x"], "entrypoint": ["TestTransferTestSuite"], "test": [ diff --git a/.github/compatibility-test-matrices/release-v7.0.x/transfer-authz-chain-a.json b/.github/compatibility-test-matrices/release-v7.0.x/transfer-authz-chain-a.json new file mode 100644 index 00000000000..7fca8e7535f --- /dev/null +++ b/.github/compatibility-test-matrices/release-v7.0.x/transfer-authz-chain-a.json @@ -0,0 +1,15 @@ +{ + "chain-a": ["release-v7.0.x"], + "chain-b": ["release-v7.0.x", "v6.1.0", "v5.2.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "entrypoint": ["TestTransferTestSuite"], + "test": [ + "TestMsgTransfer_Succeeds_Nonincentivized", + "TestMsgTransfer_Fails_InvalidAddress", + "TestMsgTransfer_Timeout_Nonincentivized", + "TestMsgTransfer_WithMemo", + "TestSendEnabledParam", + "TestReceiveEnabledParam" + ], + "chain-binary": ["simd"], + "chain-image": ["ghcr.io/cosmos/ibc-go-simd"] +} diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 1487a58e44c..c87e3bca3ee 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -58,4 +58,4 @@ jobs: push: true tags: ${{ steps.meta.outputs.tags }} build-args: | - IBC_GO_VERSION="${{ github.ref_name }}" + IBC_GO_VERSION=${{ github.ref_name }} diff --git a/e2e/semverutil/semver.go b/e2e/semverutil/semver.go index c630a1b2dad..a210289bad4 100644 --- a/e2e/semverutil/semver.go +++ b/e2e/semverutil/semver.go @@ -1,6 +1,8 @@ package semverutil import ( + "strings" + "golang.org/x/mod/semver" ) @@ -16,6 +18,17 @@ type FeatureReleases struct { // This is true if the version is greater than or equal to the major version it was released in // or is greater than or equal to the list of minor releases it was included in. func (fr FeatureReleases) IsSupported(versionStr string) bool { + + // in our compatibility tests, our images are in the format of "release-v1.0.x". We want to actually look at + // the "1.0.x" part but we also need this to be a valid version. We can change it to "1.0.0" + // TODO: change the way we provide the ibc-go version. This should be done in a more flexible way such + // as docker labels/metadata instead of the tag, as this will only work for our versioning scheme. + const releasePrefix = "release-" + if strings.HasPrefix(versionStr, releasePrefix) { + versionStr = versionStr[len(releasePrefix):] + versionStr = strings.ReplaceAll(versionStr, "x", "0") + } + // assume any non-semantic version formatted version supports the feature // this will be useful during development of the e2e test with the new feature if !semver.IsValid(versionStr) { diff --git a/e2e/testconfig/testconfig.go b/e2e/testconfig/testconfig.go index fcd7e262caf..6c96c5942ba 100644 --- a/e2e/testconfig/testconfig.go +++ b/e2e/testconfig/testconfig.go @@ -9,11 +9,13 @@ import ( "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module/testutil" + genutiltypes "github.com/cosmos/cosmos-sdk/x/genutil/types" govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" govv1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1" govv1beta1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1" - gogoproto "github.com/cosmos/gogoproto/proto" "github.com/strangelove-ventures/interchaintest/v7/ibc" + tmjson "github.com/tendermint/tendermint/libs/json" + tmtypes "github.com/tendermint/tendermint/types" "github.com/cosmos/ibc-go/e2e/semverutil" "github.com/cosmos/ibc-go/e2e/testvalues" @@ -165,6 +167,7 @@ func DefaultChainOptions() ChainOptions { // newDefaultSimappConfig creates an ibc configuration for simd. func newDefaultSimappConfig(cc ChainConfig, name, chainID, denom string) ibc.ChainConfig { + return ibc.ChainConfig{ Type: "cosmos", Name: name, @@ -183,33 +186,66 @@ func newDefaultSimappConfig(cc ChainConfig, name, chainID, denom string) ibc.Cha GasAdjustment: 1.3, TrustingPeriod: "508h", NoHostMount: false, - ModifyGenesis: defaultModifyGenesis(), + ModifyGenesis: getGenesisModificationFunction(cc), } } +// getGenesisModificationFunction returns a genesis modification function that handles the GenesisState type +// correctly depending on if the govv1beta1 gov module is used or if govv1 is being used. +func getGenesisModificationFunction(cc ChainConfig) func(ibc.ChainConfig, []byte) ([]byte, error) { + version := cc.Tag + + if govGenesisFeatureReleases.IsSupported(version) { + return defaultGovv1ModifyGenesis() + } + + return defaultGovv1Beta1ModifyGenesis() +} + // govGenesisFeatureReleases represents the releases the governance module genesis // was upgraded from v1beta1 to v1. var govGenesisFeatureReleases = semverutil.FeatureReleases{ MajorVersion: "v7", } -// defaultModifyGenesis will only modify governance params to ensure the voting period and minimum deposit +// defaultGovv1ModifyGenesis will only modify governance params to ensure the voting period and minimum deposit // are functional for e2e testing purposes. -// Note: this function intentionally does not use the type defined here https://github.com/tendermint/tendermint/blob/v0.37.0-rc2/types/genesis.go#L38-L46 -// and uses a map[string]interface{} instead. -// This approach prevents the field block.TimeIotaMs from being lost which happened when using the GenesisDoc type from tendermint version v0.37.0. -// ibctest performs the following steps when creating the genesis.json file for chains. -// - 1. Let the chain binary create its own genesis file. -// - 2. Apply any provided functions to modify the bytes of the file. -// - 3. Overwrite the file with the new contents. -// This is a problem because when the tendermint types change, marshalling into the type will cause us to lose -// values if the types have changed in between the version of the chain in the test and the version of tendermint -// imported by the e2e tests. -// By using a raw map[string]interface{} we preserve the values unknown to the e2e tests and can still change -// the values we care about. -// TODO: handle these genesis modifications in a way which is type safe and does not require us to rely on -// map[string]interface{} -func defaultModifyGenesis() func(ibc.ChainConfig, []byte) ([]byte, error) { +func defaultGovv1ModifyGenesis() func(ibc.ChainConfig, []byte) ([]byte, error) { + return func(chainConfig ibc.ChainConfig, genbz []byte) ([]byte, error) { + genDoc, err := tmtypes.GenesisDocFromJSON(genbz) + if err != nil { + return nil, fmt.Errorf("failed to unmarshal genesis bytes into genesis doc: %w", err) + } + + var appState genutiltypes.AppMap + if err := json.Unmarshal(genDoc.AppState, &appState); err != nil { + return nil, fmt.Errorf("failed to unmarshal genesis bytes into app state: %w", err) + } + + govGenBz, err := modifyGovAppState(chainConfig, appState[govtypes.ModuleName]) + if err != nil { + return nil, err + } + + appState[govtypes.ModuleName] = govGenBz + + genDoc.AppState, err = json.Marshal(appState) + if err != nil { + return nil, err + } + + bz, err := tmjson.MarshalIndent(genDoc, "", " ") + if err != nil { + return nil, err + } + + return bz, nil + } +} + +// defaultGovv1Beta1ModifyGenesis will only modify governance params to ensure the voting period and minimum deposit +// // are functional for e2e testing purposes. +func defaultGovv1Beta1ModifyGenesis() func(ibc.ChainConfig, []byte) ([]byte, error) { const appStateKey = "app_state" return func(chainConfig ibc.ChainConfig, genbz []byte) ([]byte, error) { genesisDocMap := map[string]interface{}{} @@ -228,7 +264,7 @@ func defaultModifyGenesis() func(ibc.ChainConfig, []byte) ([]byte, error) { return nil, fmt.Errorf("failed to extract gov genesis bytes: %s", err) } - govModuleGenesisBytes, err := modifyGovAppState(chainConfig, govModuleBytes) + govModuleGenesisBytes, err := modifyGovv1Beta1AppState(chainConfig, govModuleBytes) if err != nil { return nil, err } @@ -251,41 +287,50 @@ func defaultModifyGenesis() func(ibc.ChainConfig, []byte) ([]byte, error) { } } -// modifyGovAppState takes the existing gov app state and marshals it to either a govv1 GenesisState -// or a govv1beta1 GenesisState depending on the simapp version. +// modifyGovAppState takes the existing gov app state and marshals it to a govv1 GenesisState. func modifyGovAppState(chainConfig ibc.ChainConfig, govAppState []byte) ([]byte, error) { cfg := testutil.MakeTestEncodingConfig() cdc := codec.NewProtoCodec(cfg.InterfaceRegistry) govv1.RegisterInterfaces(cfg.InterfaceRegistry) - govv1beta1.RegisterInterfaces(cfg.InterfaceRegistry) - shouldUseGovV1 := govGenesisFeatureReleases.IsSupported(chainConfig.Images[0].Version) - - var govGenesisState gogoproto.Message - if shouldUseGovV1 { - govGenesisState = &govv1.GenesisState{} - } else { - govGenesisState = &govv1beta1.GenesisState{} - } + govGenesisState := &govv1.GenesisState{} if err := cdc.UnmarshalJSON(govAppState, govGenesisState); err != nil { return nil, fmt.Errorf("failed to unmarshal genesis bytes into gov genesis state: %w", err) } - switch v := govGenesisState.(type) { - case *govv1.GenesisState: - if v.Params == nil { - v.Params = &govv1.Params{} - } - // set correct minimum deposit using configured denom - v.Params.MinDeposit = sdk.NewCoins(sdk.NewCoin(chainConfig.Denom, govv1beta1.DefaultMinDepositTokens)) - vp := testvalues.VotingPeriod - v.Params.VotingPeriod = &vp - case *govv1beta1.GenesisState: - v.DepositParams.MinDeposit = sdk.NewCoins(sdk.NewCoin(chainConfig.Denom, govv1beta1.DefaultMinDepositTokens)) - v.VotingParams.VotingPeriod = testvalues.VotingPeriod + if govGenesisState.Params == nil { + govGenesisState.Params = &govv1.Params{} + } + + govGenesisState.Params.MinDeposit = sdk.NewCoins(sdk.NewCoin(chainConfig.Denom, govv1beta1.DefaultMinDepositTokens)) + vp := testvalues.VotingPeriod + govGenesisState.Params.VotingPeriod = &vp + + govGenBz, err := cdc.MarshalJSON(govGenesisState) + if err != nil { + return nil, fmt.Errorf("failed to marshal gov genesis state: %w", err) } + + return govGenBz, nil +} + +// modifyGovv1Beta1AppState takes the existing gov app state and marshals it to a govv1beta1 GenesisState. +func modifyGovv1Beta1AppState(chainConfig ibc.ChainConfig, govAppState []byte) ([]byte, error) { + cfg := testutil.MakeTestEncodingConfig() + + cdc := codec.NewProtoCodec(cfg.InterfaceRegistry) + govv1beta1.RegisterInterfaces(cfg.InterfaceRegistry) + + govGenesisState := &govv1beta1.GenesisState{} + if err := cdc.UnmarshalJSON(govAppState, govGenesisState); err != nil { + return nil, fmt.Errorf("failed to unmarshal genesis bytes into govv1beta1 genesis state: %w", err) + } + + govGenesisState.DepositParams.MinDeposit = sdk.NewCoins(sdk.NewCoin(chainConfig.Denom, govv1beta1.DefaultMinDepositTokens)) + govGenesisState.VotingParams.VotingPeriod = testvalues.VotingPeriod + govGenBz, err := cdc.MarshalJSON(govGenesisState) if err != nil { return nil, fmt.Errorf("failed to marshal gov genesis state: %w", err) diff --git a/e2e/testsuite/testsuite.go b/e2e/testsuite/testsuite.go index 05fb56232ba..23558bae5e4 100644 --- a/e2e/testsuite/testsuite.go +++ b/e2e/testsuite/testsuite.go @@ -32,6 +32,7 @@ import ( "google.golang.org/grpc" "google.golang.org/grpc/credentials/insecure" + "github.com/cosmos/ibc-go/e2e/semverutil" "github.com/cosmos/ibc-go/e2e/testconfig" "github.com/cosmos/ibc-go/e2e/testvalues" controllertypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller/types" @@ -496,6 +497,11 @@ func (s *E2ETestSuite) ExecuteGovProposal(ctx context.Context, chain *cosmos.Cos s.Require().Equal(govtypesv1beta1.StatusPassed, proposal.Status) } +// govv1ProposalTitleAndSummary represents the releases that support the new title and summary fields. +var govv1ProposalTitleAndSummary = semverutil.FeatureReleases{ + MajorVersion: "v7", +} + // ExecuteGovProposalV1 submits a governance proposal using the provided user and message and uses all validators // to vote yes on the proposal. It ensures the proposal successfully passes. func (s *E2ETestSuite) ExecuteGovProposalV1(ctx context.Context, msg sdk.Msg, chain *cosmos.CosmosChain, user ibc.Wallet, proposalID uint64) { @@ -506,6 +512,11 @@ func (s *E2ETestSuite) ExecuteGovProposalV1(ctx context.Context, msg sdk.Msg, ch msgSubmitProposal, err := govtypesv1.NewMsgSubmitProposal(msgs, sdk.NewCoins(sdk.NewCoin(chain.Config().Denom, govtypesv1.DefaultMinDepositTokens)), sender.String(), "", fmt.Sprintf("e2e gov proposal: %d", proposalID), fmt.Sprintf("executing gov proposal %d", proposalID)) s.Require().NoError(err) + if !govv1ProposalTitleAndSummary.IsSupported(chain.Nodes()[0].Image.Version) { + msgSubmitProposal.Title = "" + msgSubmitProposal.Summary = "" + } + resp, err := s.BroadcastMessages(ctx, chain, user, msgSubmitProposal) s.AssertValidTxResponse(resp) s.Require().NoError(err) From 143ad693df183ae06c62c8260800e771c5c23aca Mon Sep 17 00:00:00 2001 From: Carlos Rodriguez Date: Thu, 2 Feb 2023 13:51:34 +0100 Subject: [PATCH 13/22] chores: post v4.3.0 release chores (#3080) ## Description closes: #XXXX ### Commit Message / Changelog Entry ```bash type: commit message ``` see the [guidelines](https://github.com/cosmos/ibc-go/blob/main/CONTRIBUTING.md#commit-messages) for commit messages. (view raw markdown for examples) --- Before we can merge this PR, please make sure that all the following items have been checked off. If any of the checklist items are not applicable, please leave them but write a little note why. - [x] Targeted PR against correct branch (see [CONTRIBUTING.md](https://github.com/cosmos/ibc-go/blob/master/CONTRIBUTING.md#pr-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/building-modules/10-structure.md) and [Go style guide](../docs/dev/go-style-guide.md). - [ ] Wrote unit and integration [tests](https://github.com/cosmos/ibc-go/blob/master/CONTRIBUTING.md#testing). - [ ] Updated relevant documentation (`docs/`) or specification (`x//spec/`). - [ ] Added relevant `godoc` [comments](https://blog.golang.org/godoc-documenting-go-code). - [ ] Provide a [commit message](https://github.com/cosmos/ibc-go/blob/main/CONTRIBUTING.md#commit-messages) to be used for the changelog entry in the PR description for review. - [x] Re-reviewed `Files changed` in the Github PR explorer. - [ ] Review `Codecov Report` in the comment section below once CI passes. --- .../release-v4.3.x/incentivized-transfer-chain-a.json | 2 +- .../release-v4.3.x/incentivized-transfer-chain-b.json | 2 +- .../release-v4.3.x/transfer-chain-a.json | 2 +- .../release-v4.3.x/transfer-chain-b.json | 2 +- .../release-v5.2.x/incentivized-transfer-chain-a.json | 2 +- .../release-v5.2.x/incentivized-transfer-chain-b.json | 2 +- .../release-v5.2.x/transfer-chain-a.json | 2 +- .../release-v5.2.x/transfer-chain-b.json | 2 +- .../release-v6.1.x/client-chain-a.json | 2 +- .../release-v6.1.x/client-chain-b.json | 2 +- .../release-v6.1.x/connection-chain-a.json | 2 +- .../release-v6.1.x/connection-chain-b.json | 2 +- .../release-v6.1.x/incentivized-transfer-chain-a.json | 2 +- .../release-v6.1.x/incentivized-transfer-chain-b.json | 2 +- .../release-v6.1.x/transfer-chain-a.json | 2 +- .../release-v6.1.x/transfer-chain-b.json | 2 +- .../release-v7.0.x/client-chain-a.json | 2 +- .../release-v7.0.x/client-chain-b.json | 2 +- .../release-v7.0.x/connection-chain-a.json | 2 +- .../release-v7.0.x/connection-chain-b.json | 2 +- .../release-v7.0.x/incentivized-transfer-chain-a.json | 2 +- .../release-v7.0.x/incentivized-transfer-chain-b.json | 2 +- .../release-v7.0.x/transfer-chain-a.json | 2 +- .../release-v7.0.x/transfer-chain-b.json | 2 +- .github/workflows/e2e-manual-icad.yaml | 4 ++-- .github/workflows/e2e-manual-simd.yaml | 2 ++ .github/workflows/e2e-upgrade.yaml | 4 ++-- RELEASES.md | 2 ++ docs/.vuepress/config.js | 4 ++++ docs/versions | 1 + 30 files changed, 37 insertions(+), 28 deletions(-) diff --git a/.github/compatibility-test-matrices/release-v4.3.x/incentivized-transfer-chain-a.json b/.github/compatibility-test-matrices/release-v4.3.x/incentivized-transfer-chain-a.json index 71f343b2fd1..73a3e68d158 100644 --- a/.github/compatibility-test-matrices/release-v4.3.x/incentivized-transfer-chain-a.json +++ b/.github/compatibility-test-matrices/release-v4.3.x/incentivized-transfer-chain-a.json @@ -1,6 +1,6 @@ { "chain-a": ["release-v4.3.x"], - "chain-b": ["release-v4.3.x", "v6.1.0", "v5.2.0", "4.2.0", "v4.1.1"], + "chain-b": ["release-v4.3.x", "v6.1.0", "v5.2.0", "v4.3.0", "4.2.0", "v4.1.1"], "entrypoint": ["TestIncentivizedTransferTestSuite"], "test": [ "TestMsgPayPacketFee_AsyncSingleSender_Succeeds", diff --git a/.github/compatibility-test-matrices/release-v4.3.x/incentivized-transfer-chain-b.json b/.github/compatibility-test-matrices/release-v4.3.x/incentivized-transfer-chain-b.json index 14b57689f6c..abfbefab1f4 100644 --- a/.github/compatibility-test-matrices/release-v4.3.x/incentivized-transfer-chain-b.json +++ b/.github/compatibility-test-matrices/release-v4.3.x/incentivized-transfer-chain-b.json @@ -1,5 +1,5 @@ { - "chain-a": ["release-v4.3.x", "v6.1.0", "v5.2.0", "4.2.0", "v4.1.1"], + "chain-a": ["release-v4.3.x", "v6.1.0", "v5.2.0", "v4.3.0", "4.2.0", "v4.1.1"], "chain-b": ["release-v4.3.x"], "entrypoint": ["TestIncentivizedTransferTestSuite"], "test": [ diff --git a/.github/compatibility-test-matrices/release-v4.3.x/transfer-chain-a.json b/.github/compatibility-test-matrices/release-v4.3.x/transfer-chain-a.json index d800d545f2d..fb40d4651df 100644 --- a/.github/compatibility-test-matrices/release-v4.3.x/transfer-chain-a.json +++ b/.github/compatibility-test-matrices/release-v4.3.x/transfer-chain-a.json @@ -1,6 +1,6 @@ { "chain-a": ["release-v4.3.x"], - "chain-b": ["release-v4.3.x", "v6.1.0", "v5.2.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-b": ["release-v4.3.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], "entrypoint": ["TestTransferTestSuite"], "test": [ "TestMsgTransfer_Succeeds_Nonincentivized", diff --git a/.github/compatibility-test-matrices/release-v4.3.x/transfer-chain-b.json b/.github/compatibility-test-matrices/release-v4.3.x/transfer-chain-b.json index b74bdca5249..4252267109a 100644 --- a/.github/compatibility-test-matrices/release-v4.3.x/transfer-chain-b.json +++ b/.github/compatibility-test-matrices/release-v4.3.x/transfer-chain-b.json @@ -1,5 +1,5 @@ { - "chain-a": ["release-v4.3.x", "v6.1.0", "v5.2.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-a": ["release-v4.3.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], "chain-b": ["release-v4.3.x"], "entrypoint": ["TestTransferTestSuite"], "test": [ diff --git a/.github/compatibility-test-matrices/release-v5.2.x/incentivized-transfer-chain-a.json b/.github/compatibility-test-matrices/release-v5.2.x/incentivized-transfer-chain-a.json index 5886e152f50..d806b02dcb9 100644 --- a/.github/compatibility-test-matrices/release-v5.2.x/incentivized-transfer-chain-a.json +++ b/.github/compatibility-test-matrices/release-v5.2.x/incentivized-transfer-chain-a.json @@ -1,6 +1,6 @@ { "chain-a": ["release-v5.2.x"], - "chain-b": ["release-v5.2.x", "v6.1.0", "v5.2.0", "v4.2.0", "v4.1.1"], + "chain-b": ["release-v5.2.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1"], "entrypoint": ["TestIncentivizedTransferTestSuite"], "test": [ "TestMsgPayPacketFee_AsyncSingleSender_Succeeds", diff --git a/.github/compatibility-test-matrices/release-v5.2.x/incentivized-transfer-chain-b.json b/.github/compatibility-test-matrices/release-v5.2.x/incentivized-transfer-chain-b.json index aa9511f2661..b76f42d1ce3 100644 --- a/.github/compatibility-test-matrices/release-v5.2.x/incentivized-transfer-chain-b.json +++ b/.github/compatibility-test-matrices/release-v5.2.x/incentivized-transfer-chain-b.json @@ -1,5 +1,5 @@ { - "chain-a": ["release-v5.2.x", "v6.1.0", "v5.2.0", "v4.2.0", "v4.1.1"], + "chain-a": ["release-v5.2.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1"], "chain-b": ["release-v5.2.x"], "entrypoint": ["TestIncentivizedTransferTestSuite"], "test": [ diff --git a/.github/compatibility-test-matrices/release-v5.2.x/transfer-chain-a.json b/.github/compatibility-test-matrices/release-v5.2.x/transfer-chain-a.json index 7c6216963c1..859206ad37c 100644 --- a/.github/compatibility-test-matrices/release-v5.2.x/transfer-chain-a.json +++ b/.github/compatibility-test-matrices/release-v5.2.x/transfer-chain-a.json @@ -1,6 +1,6 @@ { "chain-a": ["release-v5.2.x"], - "chain-b": ["release-v5.2.x", "v6.1.0", "v5.2.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-b": ["release-v5.2.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], "entrypoint": ["TestTransferTestSuite"], "test": [ "TestMsgTransfer_Succeeds_Nonincentivized", diff --git a/.github/compatibility-test-matrices/release-v5.2.x/transfer-chain-b.json b/.github/compatibility-test-matrices/release-v5.2.x/transfer-chain-b.json index 1df85382946..85174edf434 100644 --- a/.github/compatibility-test-matrices/release-v5.2.x/transfer-chain-b.json +++ b/.github/compatibility-test-matrices/release-v5.2.x/transfer-chain-b.json @@ -1,5 +1,5 @@ { - "chain-a": ["release-v5.2.x", "v6.1.0", "v5.2.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-a": ["release-v5.2.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], "chain-b": ["release-v5.2.x"], "entrypoint": ["TestTransferTestSuite"], "test": [ diff --git a/.github/compatibility-test-matrices/release-v6.1.x/client-chain-a.json b/.github/compatibility-test-matrices/release-v6.1.x/client-chain-a.json index b52636636f5..588df03bb4e 100644 --- a/.github/compatibility-test-matrices/release-v6.1.x/client-chain-a.json +++ b/.github/compatibility-test-matrices/release-v6.1.x/client-chain-a.json @@ -1,6 +1,6 @@ { "chain-a": ["release-v6.1.x"], - "chain-b": ["release-v6.1.x", "v6.1.0", "v5.2.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-b": ["release-v6.1.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], "entrypoint": ["TestClientTestSuite"], "test": [ "TestClientUpdateProposal_Succeeds" diff --git a/.github/compatibility-test-matrices/release-v6.1.x/client-chain-b.json b/.github/compatibility-test-matrices/release-v6.1.x/client-chain-b.json index 3b9c1f7fd3d..243414733b8 100644 --- a/.github/compatibility-test-matrices/release-v6.1.x/client-chain-b.json +++ b/.github/compatibility-test-matrices/release-v6.1.x/client-chain-b.json @@ -1,5 +1,5 @@ { - "chain-a": ["release-v6.1.x", "v6.1.0", "v5.2.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-a": ["release-v6.1.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], "chain-b": ["release-v6.1.x"], "entrypoint": ["TestClientTestSuite"], "test": [ diff --git a/.github/compatibility-test-matrices/release-v6.1.x/connection-chain-a.json b/.github/compatibility-test-matrices/release-v6.1.x/connection-chain-a.json index e9353318f38..4b7860fdd35 100644 --- a/.github/compatibility-test-matrices/release-v6.1.x/connection-chain-a.json +++ b/.github/compatibility-test-matrices/release-v6.1.x/connection-chain-a.json @@ -1,6 +1,6 @@ { "chain-a": ["release-v6.1.x"], - "chain-b": ["release-v6.1.x", "v6.1.0", "v5.2.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-b": ["release-v6.1.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], "entrypoint": ["TestConnectionTestSuite"], "test": [ "TestMaxExpectedTimePerBlockParam" diff --git a/.github/compatibility-test-matrices/release-v6.1.x/connection-chain-b.json b/.github/compatibility-test-matrices/release-v6.1.x/connection-chain-b.json index cfe618ab531..0e5d24f34a4 100644 --- a/.github/compatibility-test-matrices/release-v6.1.x/connection-chain-b.json +++ b/.github/compatibility-test-matrices/release-v6.1.x/connection-chain-b.json @@ -1,5 +1,5 @@ { - "chain-a": ["release-v6.1.x", "v6.1.0", "v5.2.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-a": ["release-v6.1.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], "chain-b": ["release-v6.1.x"], "entrypoint": ["TestConnectionTestSuite"], "test": [ diff --git a/.github/compatibility-test-matrices/release-v6.1.x/incentivized-transfer-chain-a.json b/.github/compatibility-test-matrices/release-v6.1.x/incentivized-transfer-chain-a.json index ade93b16d79..9d1b592eabb 100644 --- a/.github/compatibility-test-matrices/release-v6.1.x/incentivized-transfer-chain-a.json +++ b/.github/compatibility-test-matrices/release-v6.1.x/incentivized-transfer-chain-a.json @@ -1,6 +1,6 @@ { "chain-a": ["release-v6.1.x"], - "chain-b": ["release-v6.1.x", "v6.1.0", "v5.2.0", "v4.2.0", "v4.1.1"], + "chain-b": ["release-v6.1.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1"], "entrypoint": ["TestIncentivizedTransferTestSuite"], "test": [ "TestMsgPayPacketFee_AsyncSingleSender_Succeeds", diff --git a/.github/compatibility-test-matrices/release-v6.1.x/incentivized-transfer-chain-b.json b/.github/compatibility-test-matrices/release-v6.1.x/incentivized-transfer-chain-b.json index 1cd7f43ca14..46da1bf7ec4 100644 --- a/.github/compatibility-test-matrices/release-v6.1.x/incentivized-transfer-chain-b.json +++ b/.github/compatibility-test-matrices/release-v6.1.x/incentivized-transfer-chain-b.json @@ -1,5 +1,5 @@ { - "chain-a": ["release-v6.1.x", "v6.1.0", "v5.2.0", "v4.2.0", "v4.1.1"], + "chain-a": ["release-v6.1.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1"], "chain-b": ["release-v6.1.x"], "entrypoint": ["TestIncentivizedTransferTestSuite"], "test": [ diff --git a/.github/compatibility-test-matrices/release-v6.1.x/transfer-chain-a.json b/.github/compatibility-test-matrices/release-v6.1.x/transfer-chain-a.json index 3e6ca88ad0f..426a0bb4a01 100644 --- a/.github/compatibility-test-matrices/release-v6.1.x/transfer-chain-a.json +++ b/.github/compatibility-test-matrices/release-v6.1.x/transfer-chain-a.json @@ -1,6 +1,6 @@ { "chain-a": ["release-v6.1.x"], - "chain-b": ["release-v6.1.x", "v6.1.0", "v5.2.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-b": ["release-v6.1.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], "entrypoint": ["TestTransferTestSuite"], "test": [ "TestMsgTransfer_Succeeds_Nonincentivized", diff --git a/.github/compatibility-test-matrices/release-v6.1.x/transfer-chain-b.json b/.github/compatibility-test-matrices/release-v6.1.x/transfer-chain-b.json index 53f06c63621..c8468f1158b 100644 --- a/.github/compatibility-test-matrices/release-v6.1.x/transfer-chain-b.json +++ b/.github/compatibility-test-matrices/release-v6.1.x/transfer-chain-b.json @@ -1,5 +1,5 @@ { - "chain-a": ["release-v6.1.x", "v6.1.0", "v5.2.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-a": ["release-v6.1.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], "chain-b": ["release-v6.1.x"], "entrypoint": ["TestTransferTestSuite"], "test": [ diff --git a/.github/compatibility-test-matrices/release-v7.0.x/client-chain-a.json b/.github/compatibility-test-matrices/release-v7.0.x/client-chain-a.json index e207796c9c2..547b8981c90 100644 --- a/.github/compatibility-test-matrices/release-v7.0.x/client-chain-a.json +++ b/.github/compatibility-test-matrices/release-v7.0.x/client-chain-a.json @@ -1,6 +1,6 @@ { "chain-a": ["release-v7.0.x"], - "chain-b": ["release-v7.0.x", "v6.1.0", "v5.2.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-b": ["release-v7.0.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], "entrypoint": ["TestClientTestSuite"], "test": [ "TestClientUpdateProposal_Succeeds" diff --git a/.github/compatibility-test-matrices/release-v7.0.x/client-chain-b.json b/.github/compatibility-test-matrices/release-v7.0.x/client-chain-b.json index 0cd48752fff..d8599b534ff 100644 --- a/.github/compatibility-test-matrices/release-v7.0.x/client-chain-b.json +++ b/.github/compatibility-test-matrices/release-v7.0.x/client-chain-b.json @@ -1,5 +1,5 @@ { - "chain-a": ["release-v7.0.x", "v6.1.0", "v5.2.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-a": ["release-v7.0.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], "chain-b": ["release-v7.0.x"], "entrypoint": ["TestClientTestSuite"], "test": [ diff --git a/.github/compatibility-test-matrices/release-v7.0.x/connection-chain-a.json b/.github/compatibility-test-matrices/release-v7.0.x/connection-chain-a.json index de28a533905..58df9c3d20a 100644 --- a/.github/compatibility-test-matrices/release-v7.0.x/connection-chain-a.json +++ b/.github/compatibility-test-matrices/release-v7.0.x/connection-chain-a.json @@ -1,6 +1,6 @@ { "chain-a": ["release-v7.0.x"], - "chain-b": ["release-v7.0.x", "v6.1.0", "v5.2.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-b": ["release-v7.0.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], "entrypoint": ["TestConnectionTestSuite"], "test": [ "TestMaxExpectedTimePerBlockParam" diff --git a/.github/compatibility-test-matrices/release-v7.0.x/connection-chain-b.json b/.github/compatibility-test-matrices/release-v7.0.x/connection-chain-b.json index f2bc2d213d9..11666658f37 100644 --- a/.github/compatibility-test-matrices/release-v7.0.x/connection-chain-b.json +++ b/.github/compatibility-test-matrices/release-v7.0.x/connection-chain-b.json @@ -1,5 +1,5 @@ { - "chain-a": ["release-v7.0.x", "v6.1.0", "v5.2.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-a": ["release-v7.0.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], "chain-b": ["release-v7.0.x"], "entrypoint": ["TestConnectionTestSuite"], "test": [ diff --git a/.github/compatibility-test-matrices/release-v7.0.x/incentivized-transfer-chain-a.json b/.github/compatibility-test-matrices/release-v7.0.x/incentivized-transfer-chain-a.json index 13379d3f928..b82b2c52dc7 100644 --- a/.github/compatibility-test-matrices/release-v7.0.x/incentivized-transfer-chain-a.json +++ b/.github/compatibility-test-matrices/release-v7.0.x/incentivized-transfer-chain-a.json @@ -1,6 +1,6 @@ { "chain-a": ["release-v7.0.x"], - "chain-b": ["release-v7.0.x", "v6.1.0", "v5.2.0", "v4.2.0", "v4.1.1"], + "chain-b": ["release-v7.0.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1"], "entrypoint": ["TestIncentivizedTransferTestSuite"], "test": [ "TestMsgPayPacketFee_AsyncSingleSender_Succeeds", diff --git a/.github/compatibility-test-matrices/release-v7.0.x/incentivized-transfer-chain-b.json b/.github/compatibility-test-matrices/release-v7.0.x/incentivized-transfer-chain-b.json index 26731342c7c..ea2956300e3 100644 --- a/.github/compatibility-test-matrices/release-v7.0.x/incentivized-transfer-chain-b.json +++ b/.github/compatibility-test-matrices/release-v7.0.x/incentivized-transfer-chain-b.json @@ -1,5 +1,5 @@ { - "chain-a": ["release-v7.0.x", "v6.1.0", "v5.2.0", "v4.2.0", "v4.1.1"], + "chain-a": ["release-v7.0.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1"], "chain-b": ["release-v7.0.x"], "entrypoint": ["TestIncentivizedTransferTestSuite"], "test": [ diff --git a/.github/compatibility-test-matrices/release-v7.0.x/transfer-chain-a.json b/.github/compatibility-test-matrices/release-v7.0.x/transfer-chain-a.json index 7fca8e7535f..b0513db66ba 100644 --- a/.github/compatibility-test-matrices/release-v7.0.x/transfer-chain-a.json +++ b/.github/compatibility-test-matrices/release-v7.0.x/transfer-chain-a.json @@ -1,6 +1,6 @@ { "chain-a": ["release-v7.0.x"], - "chain-b": ["release-v7.0.x", "v6.1.0", "v5.2.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-b": ["release-v7.0.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], "entrypoint": ["TestTransferTestSuite"], "test": [ "TestMsgTransfer_Succeeds_Nonincentivized", diff --git a/.github/compatibility-test-matrices/release-v7.0.x/transfer-chain-b.json b/.github/compatibility-test-matrices/release-v7.0.x/transfer-chain-b.json index d515ef3a05e..d091ffe1a4f 100644 --- a/.github/compatibility-test-matrices/release-v7.0.x/transfer-chain-b.json +++ b/.github/compatibility-test-matrices/release-v7.0.x/transfer-chain-b.json @@ -1,5 +1,5 @@ { - "chain-a": ["release-v7.0.x", "v6.1.0", "v5.2.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-a": ["release-v7.0.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], "chain-b": ["release-v7.0.x"], "entrypoint": ["TestTransferTestSuite"], "test": [ diff --git a/.github/workflows/e2e-manual-icad.yaml b/.github/workflows/e2e-manual-icad.yaml index dfb980c494f..b960cd51541 100644 --- a/.github/workflows/e2e-manual-icad.yaml +++ b/.github/workflows/e2e-manual-icad.yaml @@ -27,7 +27,7 @@ on: - master - v0.4.3 - v0.3.6 - - v0.2.5 + - v0.2.6 - v0.1.7 chain-b-tag: default: master @@ -38,7 +38,7 @@ on: - master - v0.4.3 - v0.3.6 - - v0.2.5 + - v0.2.6 - v0.1.7 relayer-tag: description: 'The tag to use for the relayer' diff --git a/.github/workflows/e2e-manual-simd.yaml b/.github/workflows/e2e-manual-simd.yaml index 611ad78e9c6..989a58b5a0d 100644 --- a/.github/workflows/e2e-manual-simd.yaml +++ b/.github/workflows/e2e-manual-simd.yaml @@ -37,6 +37,7 @@ on: - main - v6.1.0 - v5.2.0 + - v4.3.0 - v4.2.0 - v4.1.1 - v3.4.0 @@ -56,6 +57,7 @@ on: - main - v6.1.0 - v5.2.0 + - v4.3.0 - v4.2.0 - v4.1.1 - v3.4.0 diff --git a/.github/workflows/e2e-upgrade.yaml b/.github/workflows/e2e-upgrade.yaml index bfcd2db0e66..89d27e50924 100644 --- a/.github/workflows/e2e-upgrade.yaml +++ b/.github/workflows/e2e-upgrade.yaml @@ -10,8 +10,8 @@ jobs: include: - test: TestV4ToV5ChainUpgrade chain-image: ghcr.io/cosmos/ibc-go-simd - chain-a-tag: v4.2.0 - chain-b-tag: v4.2.0 + chain-a-tag: v4.3.0 + chain-b-tag: v4.3.0 chain-upgrade-tag: v5.1.0 - test: TestV5ToV6ChainUpgrade chain-image: ghcr.io/cosmos/ibc-go-icad diff --git a/RELEASES.md b/RELEASES.md index 8618bd78b34..ee57b7fa8ec 100644 --- a/RELEASES.md +++ b/RELEASES.md @@ -71,6 +71,7 @@ Only the following major release series have a stable release status: |`v3.4.x`|March 15, 2023| |`v4.1.x`|August 12, 2023| |`v4.2.x`|August 12, 2023| +|`v4.3.x`|August 12, 2023| |`v5.2.x`|September 28, 2023| |`v6.1.x`|December 09, 2023| @@ -109,6 +110,7 @@ Versions of Golang, Cosmos SDK and Tendermint used by ibc-go in the currently ac | 1.18 | v3.4.0 | v0.45.10 | v0.34.22 | | 1.18 | v4.1.1 | v0.45.10 | v0.34.22 | | 1.18 | v4.2.0 | v0.45.10 | v0.34.22 | +| 1.18 | v4.3.0 | v0.45.12 | v0.34.24 | | 1.18 | v5.2.0 | v0.46.7 | v0.34.24 | | 1.18 | v6.1.0 | v0.46.7 | v0.34.24 | diff --git a/docs/.vuepress/config.js b/docs/.vuepress/config.js index 2e9e95352d3..6acecc932fe 100644 --- a/docs/.vuepress/config.js +++ b/docs/.vuepress/config.js @@ -140,6 +140,10 @@ module.exports = { label: "v4.2.0", key: "v4.2.0", }, + { + label: "v4.3.0", + key: "v4.3.0", + }, { label: "v5.0.0", key: "v5.0.0", diff --git a/docs/versions b/docs/versions index cf6b9285616..265e01a0bfe 100644 --- a/docs/versions +++ b/docs/versions @@ -3,6 +3,7 @@ release/v6.0.x v6.0.0 release/v5.2.x v5.2.0 release/v5.1.x v5.1.0 release/v5.0.x v5.0.0 +release/v4.3.x v4.3.0 release/v4.2.x v4.2.0 release/v4.1.x v4.1.0 release/v4.0.x v4.0.0 From 1da651e5e117872499e3558c2a92f887369ae262 Mon Sep 17 00:00:00 2001 From: Cian Hatton Date: Fri, 3 Feb 2023 11:52:12 +0000 Subject: [PATCH 14/22] Add transfer authz tests to workflow (#3102) --- .../release-v7.0.x/transfer-authz-chain-a.json | 12 ++++-------- .github/workflows/e2e-compatibility.yaml | 9 +++++++++ .github/workflows/release.yml | 2 +- 3 files changed, 14 insertions(+), 9 deletions(-) diff --git a/.github/compatibility-test-matrices/release-v7.0.x/transfer-authz-chain-a.json b/.github/compatibility-test-matrices/release-v7.0.x/transfer-authz-chain-a.json index 7fca8e7535f..23ac0a9ed1b 100644 --- a/.github/compatibility-test-matrices/release-v7.0.x/transfer-authz-chain-a.json +++ b/.github/compatibility-test-matrices/release-v7.0.x/transfer-authz-chain-a.json @@ -1,14 +1,10 @@ { "chain-a": ["release-v7.0.x"], - "chain-b": ["release-v7.0.x", "v6.1.0", "v5.2.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], - "entrypoint": ["TestTransferTestSuite"], + "chain-b": ["release-v7.0.x"], + "entrypoint": ["TestAuthzTransferTestSuite"], "test": [ - "TestMsgTransfer_Succeeds_Nonincentivized", - "TestMsgTransfer_Fails_InvalidAddress", - "TestMsgTransfer_Timeout_Nonincentivized", - "TestMsgTransfer_WithMemo", - "TestSendEnabledParam", - "TestReceiveEnabledParam" + "TestAuthz_MsgTransfer_Succeeds", + "TestAuthz_InvalidTransferAuthorizations" ], "chain-binary": ["simd"], "chain-image": ["ghcr.io/cosmos/ibc-go-simd"] diff --git a/.github/workflows/e2e-compatibility.yaml b/.github/workflows/e2e-compatibility.yaml index 3b87973655c..2327bc97ff3 100644 --- a/.github/workflows/e2e-compatibility.yaml +++ b/.github/workflows/e2e-compatibility.yaml @@ -96,6 +96,15 @@ jobs: test-file-directory: "${{ needs.determine-test-directory.outputs.test-directory }}" test-suite: "transfer-chain-b" + transfer-authz-chain-a: + needs: + - build-release-images + - determine-test-directory + uses: ./.github/workflows/e2e-compatibility-workflow-call.yaml + with: + test-file-directory: "${{ needs.determine-test-directory.outputs.test-directory }}" + test-suite: "transfer-authz-chain-a" + connection-chain-a: needs: - build-release-images diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index c87e3bca3ee..f775032c128 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -21,7 +21,7 @@ jobs: - uses: actions/setup-go@v3 with: - go-version: '1.18' + go-version: '1.19' - name: Release uses: goreleaser/goreleaser-action@v4 From ceb9464ced75d4c64b3a71abf6ceab4a50e908be Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 3 Feb 2023 12:52:59 +0100 Subject: [PATCH 15/22] build(deps): bump bufbuild/buf-setup-action from 1.12.0 to 1.13.0 (#3075) Bumps [bufbuild/buf-setup-action](https://github.com/bufbuild/buf-setup-action) from 1.12.0 to 1.13.0. - [Release notes](https://github.com/bufbuild/buf-setup-action/releases) - [Commits](https://github.com/bufbuild/buf-setup-action/compare/v1.12.0...v1.13.0) --- updated-dependencies: - dependency-name: bufbuild/buf-setup-action dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Damian Nolan --- .github/workflows/proto-registry.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/proto-registry.yml b/.github/workflows/proto-registry.yml index 7374bdda6c8..7a0c527d771 100644 --- a/.github/workflows/proto-registry.yml +++ b/.github/workflows/proto-registry.yml @@ -13,7 +13,7 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - - uses: bufbuild/buf-setup-action@v1.12.0 + - uses: bufbuild/buf-setup-action@v1.13.0 - uses: bufbuild/buf-push-action@v1 with: input: "proto" From 26075efcc53ab5a3da5314933419cb16e823c3bd Mon Sep 17 00:00:00 2001 From: Damian Nolan Date: Tue, 7 Feb 2023 15:32:26 +0100 Subject: [PATCH 16/22] set light client module names (#3113) * set light client module names * go mod tidy --- e2e/go.mod | 2 +- go.mod | 2 +- modules/light-clients/06-solomachine/keys.go | 2 +- modules/light-clients/07-tendermint/keys.go | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/e2e/go.mod b/e2e/go.mod index 77166203826..77c45c44b43 100644 --- a/e2e/go.mod +++ b/e2e/go.mod @@ -10,6 +10,7 @@ require ( github.com/docker/docker v20.10.19+incompatible github.com/strangelove-ventures/interchaintest/v7 v7.0.0-20230201060741-e0e4e0f9283b github.com/stretchr/testify v1.8.1 + github.com/tendermint/tendermint v0.37.0-rc2 go.uber.org/zap v1.23.0 golang.org/x/mod v0.6.0 google.golang.org/grpc v1.52.3 @@ -178,7 +179,6 @@ require ( github.com/subosito/gotenv v1.4.2 // indirect github.com/syndtr/goleveldb v1.0.1-0.20220614013038-64ee5596c38a // indirect github.com/tendermint/go-amino v0.16.0 // indirect - github.com/tendermint/tendermint v0.37.0-rc2 // indirect github.com/tendermint/tm-db v0.6.7 // indirect github.com/tidwall/btree v1.5.2 // indirect github.com/ulikunitz/xz v0.5.8 // indirect diff --git a/go.mod b/go.mod index 24c60c0705c..692c949614c 100644 --- a/go.mod +++ b/go.mod @@ -22,7 +22,6 @@ require ( github.com/stretchr/testify v1.8.1 github.com/tendermint/tendermint v0.37.0-rc2 github.com/tendermint/tm-db v0.6.7 - golang.org/x/exp v0.0.0-20221019170559-20944726eadf google.golang.org/genproto v0.0.0-20221227171554-f9683d7f8bef google.golang.org/grpc v1.52.3 google.golang.org/protobuf v1.28.1 @@ -147,6 +146,7 @@ require ( go.etcd.io/bbolt v1.3.6 // indirect go.opencensus.io v0.24.0 // indirect golang.org/x/crypto v0.4.0 // indirect + golang.org/x/exp v0.0.0-20221019170559-20944726eadf // indirect golang.org/x/net v0.4.0 // indirect golang.org/x/oauth2 v0.0.0-20221014153046-6fdb5e3db783 // indirect golang.org/x/sys v0.3.0 // indirect diff --git a/modules/light-clients/06-solomachine/keys.go b/modules/light-clients/06-solomachine/keys.go index 2254ad60119..cbb665d6fe3 100644 --- a/modules/light-clients/06-solomachine/keys.go +++ b/modules/light-clients/06-solomachine/keys.go @@ -1,5 +1,5 @@ package solomachine const ( - ModuleName = "solo machine" + ModuleName = "06-solomachine" ) diff --git a/modules/light-clients/07-tendermint/keys.go b/modules/light-clients/07-tendermint/keys.go index e2e31b377fb..bc2fd02dec1 100644 --- a/modules/light-clients/07-tendermint/keys.go +++ b/modules/light-clients/07-tendermint/keys.go @@ -1,5 +1,5 @@ package tendermint const ( - ModuleName = "tendermint-client" + ModuleName = "07-tendermint" ) From 6ecf7b6df8abc7709634ee1c9b66ac694ea6af0e Mon Sep 17 00:00:00 2001 From: Damian Nolan Date: Tue, 7 Feb 2023 17:41:07 +0100 Subject: [PATCH 17/22] imp: adding channelID to `MsgChannelOpenTryResponse` (#3117) --- modules/core/04-channel/types/tx.pb.go | 218 +++++++++++++++---------- modules/core/keeper/msg_server.go | 3 +- proto/ibc/core/channel/v1/tx.proto | 3 +- 3 files changed, 139 insertions(+), 85 deletions(-) diff --git a/modules/core/04-channel/types/tx.pb.go b/modules/core/04-channel/types/tx.pb.go index ec23399a695..cd1d8fdb256 100644 --- a/modules/core/04-channel/types/tx.pb.go +++ b/modules/core/04-channel/types/tx.pb.go @@ -205,7 +205,8 @@ var xxx_messageInfo_MsgChannelOpenTry proto.InternalMessageInfo // MsgChannelOpenTryResponse defines the Msg/ChannelOpenTry response type. type MsgChannelOpenTryResponse struct { - Version string `protobuf:"bytes,1,opt,name=version,proto3" json:"version,omitempty"` + Version string `protobuf:"bytes,1,opt,name=version,proto3" json:"version,omitempty"` + ChannelId string `protobuf:"bytes,2,opt,name=channel_id,json=channelId,proto3" json:"channel_id,omitempty" yaml:"channel_id"` } func (m *MsgChannelOpenTryResponse) Reset() { *m = MsgChannelOpenTryResponse{} } @@ -248,6 +249,13 @@ func (m *MsgChannelOpenTryResponse) GetVersion() string { return "" } +func (m *MsgChannelOpenTryResponse) GetChannelId() string { + if m != nil { + return m.ChannelId + } + return "" +} + // MsgChannelOpenAck defines a msg sent by a Relayer to Chain A to acknowledge // the change of channel state to TRYOPEN on Chain B. type MsgChannelOpenAck struct { @@ -917,88 +925,89 @@ func init() { func init() { proto.RegisterFile("ibc/core/channel/v1/tx.proto", fileDescriptor_bc4637e0ac3fc7b7) } var fileDescriptor_bc4637e0ac3fc7b7 = []byte{ - // 1294 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xcc, 0x58, 0x5f, 0x6f, 0xda, 0x56, - 0x14, 0xc7, 0x40, 0x21, 0x39, 0x74, 0x09, 0x31, 0x49, 0x4a, 0x4c, 0x82, 0x99, 0x1f, 0x9a, 0x28, - 0x53, 0xa0, 0x49, 0x5b, 0x55, 0x8d, 0x26, 0x4d, 0x81, 0x51, 0x2d, 0xda, 0x92, 0x20, 0x43, 0x26, - 0x2d, 0x9b, 0x86, 0xc0, 0xdc, 0x12, 0x0b, 0xb0, 0x99, 0x6d, 0x68, 0xf9, 0x06, 0x55, 0x9e, 0xfa, - 0x5c, 0x29, 0x52, 0xa7, 0x3d, 0x4d, 0x7b, 0xe8, 0x3e, 0x46, 0x1f, 0xfb, 0xb6, 0x6a, 0x0f, 0x68, - 0x4a, 0x5e, 0xf6, 0xcc, 0x27, 0x98, 0x7c, 0x7d, 0x6d, 0x0c, 0xd8, 0x8a, 0xd3, 0x26, 0xe9, 0xde, - 0x7c, 0xef, 0xf9, 0xdd, 0x73, 0xce, 0xfd, 0x9d, 0xdf, 0xfd, 0x67, 0x58, 0x16, 0xab, 0x42, 0x46, - 0x90, 0x15, 0x94, 0x11, 0x8e, 0x2b, 0x92, 0x84, 0x9a, 0x99, 0xee, 0x66, 0x46, 0x7b, 0x9e, 0x6e, - 0x2b, 0xb2, 0x26, 0xd3, 0x31, 0xb1, 0x2a, 0xa4, 0x75, 0x6b, 0x9a, 0x58, 0xd3, 0xdd, 0x4d, 0x66, - 0xbe, 0x2e, 0xd7, 0x65, 0x6c, 0xcf, 0xe8, 0x5f, 0x06, 0x94, 0x61, 0x87, 0x8e, 0x9a, 0x22, 0x92, - 0x34, 0xdd, 0x8f, 0xf1, 0x45, 0x00, 0x9f, 0x3b, 0x45, 0x32, 0xdd, 0x62, 0x08, 0xf7, 0x2b, 0x05, - 0xf4, 0x9e, 0x5a, 0xcf, 0x19, 0x9d, 0x07, 0x6d, 0x24, 0xed, 0x4a, 0xa2, 0x46, 0x7f, 0x01, 0xe1, - 0xb6, 0xac, 0x68, 0x65, 0xb1, 0x16, 0xa7, 0x52, 0xd4, 0xda, 0x74, 0x96, 0x1e, 0xf4, 0xd9, 0x99, - 0x5e, 0xa5, 0xd5, 0xdc, 0xe6, 0x88, 0x81, 0xe3, 0x43, 0xfa, 0xd7, 0x6e, 0x8d, 0xfe, 0x12, 0xc2, - 0xc4, 0x69, 0xdc, 0x9f, 0xa2, 0xd6, 0x22, 0x5b, 0xcb, 0x69, 0x87, 0x49, 0xa4, 0x49, 0x8c, 0x6c, - 0xf0, 0x6d, 0x9f, 0xf5, 0xf1, 0xe6, 0x10, 0x7a, 0x11, 0x42, 0xaa, 0x58, 0x97, 0x90, 0x12, 0x0f, - 0xe8, 0x91, 0x78, 0xd2, 0xda, 0x9e, 0x7a, 0xf1, 0x9a, 0xf5, 0xfd, 0xfb, 0x9a, 0xf5, 0x71, 0x4d, - 0x60, 0x26, 0x53, 0xe4, 0x91, 0xda, 0x96, 0x25, 0x15, 0xd1, 0x0f, 0x00, 0x88, 0xab, 0x61, 0xb6, - 0x0b, 0x83, 0x3e, 0x3b, 0x67, 0x64, 0x3b, 0xb4, 0x71, 0xfc, 0x34, 0x69, 0xec, 0xd6, 0xe8, 0x38, - 0x84, 0xbb, 0x48, 0x51, 0x45, 0x59, 0xc2, 0x39, 0x4f, 0xf3, 0x66, 0x93, 0x7b, 0x1f, 0x80, 0xb9, - 0xd1, 0x70, 0x25, 0xa5, 0x77, 0x39, 0x42, 0x0a, 0x10, 0x6b, 0x2b, 0xa8, 0x2b, 0xca, 0x1d, 0xb5, - 0x6c, 0xcb, 0x0d, 0x07, 0xca, 0xa6, 0x06, 0x7d, 0x96, 0x21, 0x03, 0x27, 0x41, 0x5c, 0x9c, 0xe2, - 0xe7, 0xcc, 0xfe, 0x9c, 0x95, 0xae, 0x8d, 0xe2, 0xc0, 0xe5, 0x29, 0xe6, 0x61, 0x5e, 0x90, 0x3b, - 0x92, 0x86, 0x94, 0x76, 0x45, 0xd1, 0x7a, 0x65, 0x73, 0xe6, 0x41, 0x9c, 0x10, 0x3b, 0xe8, 0xb3, - 0x09, 0x42, 0x96, 0x03, 0x8a, 0xe3, 0x63, 0xf6, 0xee, 0xef, 0x8d, 0x5e, 0x9d, 0xf6, 0xb6, 0x22, - 0xcb, 0x4f, 0xcb, 0xa2, 0x24, 0x6a, 0xf1, 0x5b, 0x29, 0x6a, 0xed, 0xb6, 0x9d, 0xf6, 0xa1, 0x8d, - 0xe3, 0xa7, 0x71, 0x03, 0xeb, 0xea, 0x08, 0x6e, 0x1b, 0x96, 0x63, 0x24, 0xd6, 0x8f, 0xb5, 0x78, - 0x08, 0x4f, 0x86, 0xb1, 0x4d, 0xc6, 0xd0, 0x6f, 0x77, 0x33, 0xfd, 0x0d, 0x46, 0x64, 0x13, 0xfa, - 0x54, 0x06, 0x7d, 0x36, 0x66, 0xf7, 0x6b, 0x8c, 0xe6, 0xf8, 0x08, 0x6e, 0x1a, 0x48, 0x9b, 0x90, - 0xc2, 0x2e, 0x42, 0x7a, 0x08, 0x4b, 0x13, 0x95, 0xb5, 0x74, 0x64, 0x53, 0x04, 0x35, 0xaa, 0x88, - 0xbf, 0x26, 0x14, 0xb1, 0x23, 0x34, 0x2e, 0xa7, 0x88, 0x51, 0x91, 0xfa, 0x3d, 0x8a, 0xf4, 0x08, - 0xee, 0x8c, 0x54, 0xc4, 0xe6, 0x02, 0xaf, 0x95, 0x2c, 0x37, 0xe8, 0xb3, 0x49, 0x87, 0xd2, 0xd9, - 0xfd, 0x2d, 0xd8, 0x2d, 0x43, 0x45, 0x5d, 0x87, 0x26, 0x36, 0xc1, 0x28, 0x75, 0x59, 0x53, 0x7a, - 0x44, 0x12, 0xf3, 0x83, 0x3e, 0x1b, 0xb5, 0x97, 0x4e, 0x53, 0x7a, 0x1c, 0x3f, 0x85, 0xbf, 0xf5, - 0x75, 0xf5, 0x69, 0x05, 0x91, 0x18, 0x17, 0xc4, 0x8e, 0xd0, 0x30, 0x05, 0xc1, 0xfd, 0xe1, 0x87, - 0x85, 0x51, 0x6b, 0x4e, 0x96, 0x9e, 0x8a, 0x4a, 0xeb, 0x26, 0x4a, 0x6f, 0x51, 0x59, 0x11, 0x1a, - 0xb8, 0xd8, 0x0e, 0x54, 0x56, 0x84, 0x86, 0x49, 0xa5, 0x2e, 0xc8, 0x71, 0x2a, 0x83, 0xd7, 0x42, - 0xe5, 0x2d, 0x17, 0x2a, 0x59, 0x58, 0x71, 0x24, 0xcb, 0xa2, 0xf3, 0x15, 0x05, 0xb1, 0x21, 0x22, - 0xd7, 0x94, 0x55, 0x74, 0xf9, 0xa3, 0xe6, 0xc3, 0xc8, 0xbc, 0xf8, 0x88, 0x59, 0x81, 0x84, 0x43, - 0x6e, 0x56, 0xee, 0x6f, 0xfc, 0xb0, 0x38, 0x66, 0xbf, 0x41, 0x2d, 0x8c, 0x6e, 0xb5, 0x81, 0x0f, - 0xdc, 0x6a, 0x6f, 0x56, 0x0e, 0x29, 0x48, 0x3a, 0x13, 0x66, 0x71, 0xfa, 0xd2, 0x0f, 0x9f, 0xed, - 0xa9, 0x75, 0x1e, 0x09, 0xdd, 0x42, 0x45, 0x68, 0x20, 0x8d, 0x7e, 0x0c, 0xa1, 0x36, 0xfe, 0xc2, - 0x4c, 0x46, 0xb6, 0x12, 0x8e, 0x67, 0x9c, 0x01, 0x26, 0x47, 0x1c, 0x19, 0x40, 0x3f, 0x81, 0xa8, - 0x91, 0xae, 0x20, 0xb7, 0x5a, 0xa2, 0xd6, 0x42, 0x92, 0x86, 0xe9, 0xbd, 0x9d, 0x4d, 0x0c, 0xfa, - 0xec, 0x1d, 0xfb, 0x84, 0x86, 0x08, 0x8e, 0x9f, 0xc5, 0x5d, 0x39, 0xab, 0x67, 0x82, 0xb4, 0xc0, - 0xb5, 0x90, 0x16, 0x74, 0x21, 0xed, 0x67, 0xbc, 0xe1, 0x0c, 0x19, 0xb1, 0xce, 0xa6, 0xaf, 0x20, - 0xa4, 0x20, 0xb5, 0xd3, 0x34, 0x98, 0x99, 0xd9, 0x5a, 0x75, 0x64, 0xc6, 0x84, 0xf3, 0x18, 0x5a, - 0xea, 0xb5, 0x11, 0x4f, 0x86, 0x6d, 0x07, 0xf5, 0x18, 0xdc, 0xdf, 0x7e, 0x80, 0x3d, 0xb5, 0x5e, - 0x12, 0x5b, 0x48, 0xee, 0x5c, 0x0d, 0xdf, 0x1d, 0x49, 0x41, 0x02, 0x12, 0xbb, 0xa8, 0xe6, 0xc6, - 0xf7, 0x10, 0x61, 0xf2, 0x7d, 0x68, 0xf5, 0x5c, 0x2b, 0xdf, 0xdf, 0x02, 0x2d, 0xa1, 0xe7, 0x5a, - 0x59, 0x45, 0xbf, 0x74, 0x90, 0x24, 0xa0, 0xb2, 0x82, 0x84, 0x2e, 0xe6, 0x3e, 0x98, 0x5d, 0x19, - 0xf4, 0xd9, 0x25, 0xc3, 0xc3, 0x24, 0x86, 0xe3, 0xa3, 0x7a, 0x67, 0x91, 0xf4, 0xe9, 0xf5, 0xf0, - 0xa0, 0xf8, 0x1f, 0xf1, 0x45, 0x9a, 0x70, 0x7b, 0xd5, 0x95, 0x7b, 0x65, 0x5c, 0x41, 0x88, 0xf7, - 0x03, 0x09, 0xaf, 0xa8, 0xff, 0x43, 0x01, 0x1f, 0x41, 0x84, 0x2c, 0x2b, 0x3d, 0x23, 0xb2, 0x39, - 0x2d, 0x0e, 0xfa, 0x2c, 0x3d, 0xb2, 0xe6, 0x74, 0x23, 0xc7, 0x1b, 0xdb, 0x98, 0x91, 0xfb, 0x75, - 0x6e, 0x4f, 0xce, 0x95, 0xbf, 0xf5, 0xb1, 0x95, 0x0f, 0xb9, 0x54, 0xbe, 0x8a, 0x6f, 0x11, 0xa3, - 0xb5, 0xb9, 0x6a, 0x01, 0xfc, 0xe9, 0xc7, 0xf2, 0xda, 0x11, 0x1a, 0x92, 0xfc, 0xac, 0x89, 0x6a, - 0x75, 0x84, 0xf7, 0xab, 0x8f, 0x50, 0xc0, 0x1a, 0xcc, 0x56, 0x46, 0xbd, 0x19, 0x02, 0xe0, 0xc7, - 0xbb, 0x87, 0x35, 0xd6, 0x07, 0xd6, 0xdc, 0x6a, 0x8c, 0x8d, 0x66, 0x8d, 0x77, 0xf4, 0xc6, 0x27, - 0x3e, 0x82, 0x04, 0xfc, 0x6c, 0x1c, 0x63, 0xec, 0x8a, 0xeb, 0xb2, 0xfe, 0x3b, 0x05, 0xf4, 0x24, - 0x88, 0x7e, 0x08, 0x29, 0x3e, 0x5f, 0x2c, 0x1c, 0xec, 0x17, 0xf3, 0x65, 0x3e, 0x5f, 0x3c, 0xfc, - 0xae, 0x54, 0x2e, 0xfd, 0x50, 0xc8, 0x97, 0x0f, 0xf7, 0x8b, 0x85, 0x7c, 0x6e, 0xf7, 0xc9, 0x6e, - 0xfe, 0xeb, 0xa8, 0x8f, 0x99, 0x3d, 0x39, 0x4d, 0x45, 0x6c, 0x5d, 0xf4, 0x2a, 0x2c, 0x39, 0x0e, - 0xdb, 0x3f, 0x38, 0x28, 0x44, 0x29, 0x66, 0xea, 0xe4, 0x34, 0x15, 0xd4, 0xbf, 0xe9, 0x0d, 0x58, - 0x76, 0x04, 0x16, 0x0f, 0x73, 0xb9, 0x7c, 0xb1, 0x18, 0xf5, 0x33, 0x91, 0x93, 0xd3, 0x54, 0x98, - 0x34, 0x99, 0xe0, 0x8b, 0xdf, 0x92, 0xbe, 0xad, 0x37, 0x53, 0x10, 0xd8, 0x53, 0xeb, 0x74, 0x03, - 0x66, 0xc7, 0xdf, 0xfb, 0xce, 0xb3, 0x9f, 0x7c, 0x75, 0x33, 0x19, 0x8f, 0x40, 0x8b, 0xe7, 0x63, - 0x98, 0x19, 0x7b, 0x4a, 0xdf, 0xf5, 0xe0, 0xa2, 0xa4, 0xf4, 0x98, 0xb4, 0x37, 0x9c, 0x4b, 0x24, - 0xfd, 0x46, 0xec, 0x25, 0xd2, 0x8e, 0xd0, 0xf0, 0x14, 0xc9, 0xf6, 0x32, 0xa0, 0x35, 0xa0, 0x1d, - 0x5e, 0x05, 0xeb, 0x1e, 0xbc, 0x10, 0x2c, 0xb3, 0xe5, 0x1d, 0x6b, 0x45, 0x95, 0x20, 0x3a, 0x71, - 0x79, 0x5e, 0xbb, 0xc0, 0x8f, 0x85, 0x64, 0xee, 0x79, 0x45, 0x5a, 0xf1, 0x9e, 0x41, 0xcc, 0xf1, - 0xc2, 0xeb, 0xc5, 0x91, 0x39, 0xcf, 0xfb, 0x97, 0x00, 0x5b, 0x81, 0x7f, 0x02, 0xb0, 0xdd, 0x0a, - 0x39, 0x37, 0x17, 0x43, 0x0c, 0xb3, 0x7e, 0x31, 0xc6, 0xf2, 0x5e, 0x84, 0xb0, 0x79, 0x01, 0x62, - 0xdd, 0x86, 0x11, 0x00, 0xb3, 0x7a, 0x01, 0xc0, 0xae, 0xbd, 0xb1, 0xb3, 0xf9, 0xee, 0x05, 0x43, - 0x09, 0xce, 0x5d, 0x7b, 0x2e, 0xe7, 0x49, 0x03, 0x66, 0xc7, 0x0f, 0x01, 0xd7, 0x2c, 0xc7, 0x80, - 0xee, 0x8b, 0xd7, 0x65, 0x93, 0xcc, 0x16, 0xdf, 0x9e, 0x25, 0xa9, 0x77, 0x67, 0x49, 0xea, 0x9f, - 0xb3, 0x24, 0xf5, 0xf2, 0x3c, 0xe9, 0x7b, 0x77, 0x9e, 0xf4, 0xbd, 0x3f, 0x4f, 0xfa, 0x8e, 0x1e, - 0xd7, 0x45, 0xed, 0xb8, 0x53, 0x4d, 0x0b, 0x72, 0x2b, 0x23, 0xc8, 0x6a, 0x4b, 0x56, 0x33, 0x62, - 0x55, 0xd8, 0xa8, 0xcb, 0x99, 0xee, 0xa3, 0x4c, 0x4b, 0xae, 0x75, 0x9a, 0x48, 0x35, 0x7e, 0x3d, - 0xde, 0x7b, 0xb0, 0x61, 0xfe, 0x7d, 0xd4, 0x7a, 0x6d, 0xa4, 0x56, 0x43, 0xf8, 0xcf, 0xe3, 0xfd, - 0xff, 0x02, 0x00, 0x00, 0xff, 0xff, 0xa3, 0xcf, 0x11, 0xf4, 0x08, 0x15, 0x00, 0x00, + // 1300 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xcc, 0x58, 0xdf, 0x6f, 0xda, 0xd6, + 0x17, 0xc7, 0x40, 0x21, 0x39, 0xf4, 0x9b, 0x10, 0x93, 0xa4, 0xc4, 0x24, 0x98, 0xaf, 0x1f, 0x9a, + 0x28, 0x53, 0xa0, 0x49, 0x3b, 0x55, 0x8d, 0x26, 0x4d, 0x81, 0x51, 0x2d, 0xda, 0x92, 0x20, 0x43, + 0x26, 0x2d, 0x9b, 0x86, 0xc0, 0xdc, 0x12, 0x0b, 0xb0, 0x99, 0x6d, 0x68, 0xf9, 0x0f, 0xaa, 0x3c, + 0xf5, 0xb9, 0x52, 0xa4, 0x4e, 0x7b, 0x9a, 0xf6, 0xd0, 0xfd, 0x19, 0x7d, 0xec, 0xdb, 0xaa, 0x3d, + 0xa0, 0x29, 0x79, 0xd9, 0x33, 0x7f, 0xc1, 0xe4, 0xeb, 0x6b, 0x63, 0xc0, 0x56, 0x9c, 0x34, 0x49, + 0xf7, 0x76, 0xef, 0x3d, 0x9f, 0x7b, 0xce, 0xb9, 0x9f, 0xf3, 0xb9, 0x3f, 0x6c, 0x58, 0x16, 0xab, + 0x42, 0x46, 0x90, 0x15, 0x94, 0x11, 0x8e, 0x2b, 0x92, 0x84, 0x9a, 0x99, 0xee, 0x66, 0x46, 0x7b, + 0x91, 0x6e, 0x2b, 0xb2, 0x26, 0xd3, 0x31, 0xb1, 0x2a, 0xa4, 0x75, 0x6b, 0x9a, 0x58, 0xd3, 0xdd, + 0x4d, 0x66, 0xbe, 0x2e, 0xd7, 0x65, 0x6c, 0xcf, 0xe8, 0x2d, 0x03, 0xca, 0xb0, 0x43, 0x47, 0x4d, + 0x11, 0x49, 0x9a, 0xee, 0xc7, 0x68, 0x11, 0xc0, 0xff, 0x9d, 0x22, 0x99, 0x6e, 0x31, 0x84, 0xfb, + 0x85, 0x02, 0x7a, 0x4f, 0xad, 0xe7, 0x8c, 0xc1, 0x83, 0x36, 0x92, 0x76, 0x25, 0x51, 0xa3, 0x3f, + 0x83, 0x70, 0x5b, 0x56, 0xb4, 0xb2, 0x58, 0x8b, 0x53, 0x29, 0x6a, 0x6d, 0x3a, 0x4b, 0x0f, 0xfa, + 0xec, 0x4c, 0xaf, 0xd2, 0x6a, 0x6e, 0x73, 0xc4, 0xc0, 0xf1, 0x21, 0xbd, 0xb5, 0x5b, 0xa3, 0xbf, + 0x80, 0x30, 0x71, 0x1a, 0xf7, 0xa7, 0xa8, 0xb5, 0xc8, 0xd6, 0x72, 0xda, 0x61, 0x11, 0x69, 0x12, + 0x23, 0x1b, 0x7c, 0xd7, 0x67, 0x7d, 0xbc, 0x39, 0x85, 0x5e, 0x84, 0x90, 0x2a, 0xd6, 0x25, 0xa4, + 0xc4, 0x03, 0x7a, 0x24, 0x9e, 0xf4, 0xb6, 0xa7, 0x5e, 0xbe, 0x61, 0x7d, 0xff, 0xbc, 0x61, 0x7d, + 0x5c, 0x13, 0x98, 0xc9, 0x14, 0x79, 0xa4, 0xb6, 0x65, 0x49, 0x45, 0xf4, 0x23, 0x00, 0xe2, 0x6a, + 0x98, 0xed, 0xc2, 0xa0, 0xcf, 0xce, 0x19, 0xd9, 0x0e, 0x6d, 0x1c, 0x3f, 0x4d, 0x3a, 0xbb, 0x35, + 0x3a, 0x0e, 0xe1, 0x2e, 0x52, 0x54, 0x51, 0x96, 0x70, 0xce, 0xd3, 0xbc, 0xd9, 0xe5, 0x3e, 0x04, + 0x60, 0x6e, 0x34, 0x5c, 0x49, 0xe9, 0x5d, 0x8e, 0x90, 0x02, 0xc4, 0xda, 0x0a, 0xea, 0x8a, 0x72, + 0x47, 0x2d, 0xdb, 0x72, 0xc3, 0x81, 0xb2, 0xa9, 0x41, 0x9f, 0x65, 0xc8, 0xc4, 0x49, 0x10, 0x17, + 0xa7, 0xf8, 0x39, 0x73, 0x3c, 0x67, 0xa5, 0x6b, 0xa3, 0x38, 0x70, 0x79, 0x8a, 0x79, 0x98, 0x17, + 0xe4, 0x8e, 0xa4, 0x21, 0xa5, 0x5d, 0x51, 0xb4, 0x5e, 0xd9, 0x5c, 0x79, 0x10, 0x27, 0xc4, 0x0e, + 0xfa, 0x6c, 0x82, 0x90, 0xe5, 0x80, 0xe2, 0xf8, 0x98, 0x7d, 0xf8, 0x3b, 0x63, 0x54, 0xa7, 0xbd, + 0xad, 0xc8, 0xf2, 0xb3, 0xb2, 0x28, 0x89, 0x5a, 0xfc, 0x4e, 0x8a, 0x5a, 0xbb, 0x6b, 0xa7, 0x7d, + 0x68, 0xe3, 0xf8, 0x69, 0xdc, 0xc1, 0xba, 0x3a, 0x82, 0xbb, 0x86, 0xe5, 0x18, 0x89, 0xf5, 0x63, + 0x2d, 0x1e, 0xc2, 0x8b, 0x61, 0x6c, 0x8b, 0x31, 0xf4, 0xdb, 0xdd, 0x4c, 0x7f, 0x8d, 0x11, 0xd9, + 0x84, 0xbe, 0x94, 0x41, 0x9f, 0x8d, 0xd9, 0xfd, 0x1a, 0xb3, 0x39, 0x3e, 0x82, 0xbb, 0x06, 0xd2, + 0x26, 0xa4, 0xb0, 0x8b, 0x90, 0x1a, 0xb0, 0x34, 0x51, 0x59, 0x4b, 0x47, 0x36, 0x45, 0x50, 0x23, + 0x8a, 0x18, 0x53, 0x98, 0xdf, 0x9b, 0xc2, 0xb8, 0x3f, 0x27, 0x74, 0xb4, 0x23, 0x34, 0x2e, 0xa7, + 0xa3, 0x2b, 0x05, 0xa6, 0x8f, 0xe0, 0xde, 0x48, 0x1d, 0x6d, 0x2e, 0xf0, 0x0e, 0xcb, 0x72, 0x83, + 0x3e, 0x9b, 0x74, 0x28, 0xb8, 0xdd, 0xdf, 0x82, 0xdd, 0x32, 0xd4, 0xe1, 0x4d, 0x28, 0x69, 0x13, + 0x0c, 0x81, 0x94, 0x35, 0xa5, 0x47, 0x84, 0x34, 0x3f, 0xe8, 0xb3, 0x51, 0x7b, 0xc1, 0x35, 0xa5, + 0xc7, 0xf1, 0x53, 0xb8, 0xad, 0xef, 0xc6, 0x4f, 0x2b, 0xa3, 0xc4, 0xb8, 0x8c, 0x76, 0x84, 0x86, + 0x29, 0x23, 0xee, 0x77, 0x3f, 0x2c, 0x8c, 0x5a, 0x73, 0xb2, 0xf4, 0x4c, 0x54, 0x5a, 0xb7, 0x51, + 0x7a, 0x8b, 0xca, 0x8a, 0xd0, 0xc0, 0xc5, 0x76, 0xa0, 0xb2, 0x22, 0x34, 0x4c, 0x2a, 0x75, 0x41, + 0x8e, 0x53, 0x19, 0xbc, 0x11, 0x2a, 0xef, 0xb8, 0x50, 0xc9, 0xc2, 0x8a, 0x23, 0x59, 0x16, 0x9d, + 0xaf, 0x29, 0x88, 0x0d, 0x11, 0xb9, 0xa6, 0xac, 0xa2, 0xcb, 0x5f, 0x50, 0x57, 0x23, 0xf3, 0xe2, + 0x8b, 0x69, 0x05, 0x12, 0x0e, 0xb9, 0x59, 0xb9, 0xbf, 0xf5, 0xc3, 0xe2, 0x98, 0xfd, 0x16, 0xb5, + 0x30, 0x7a, 0x40, 0x07, 0xae, 0x78, 0x40, 0xdf, 0xae, 0x1c, 0x52, 0x90, 0x74, 0x26, 0xcc, 0xe2, + 0xf4, 0x95, 0x1f, 0xfe, 0xb7, 0xa7, 0xd6, 0x79, 0x24, 0x74, 0x0b, 0x15, 0xa1, 0x81, 0x34, 0xfa, + 0x09, 0x84, 0xda, 0xb8, 0x85, 0x99, 0x8c, 0x6c, 0x25, 0x1c, 0x6f, 0x46, 0x03, 0x4c, 0x2e, 0x46, + 0x32, 0x81, 0x7e, 0x0a, 0x51, 0x23, 0x5d, 0x41, 0x6e, 0xb5, 0x44, 0xad, 0x85, 0x24, 0x0d, 0xd3, + 0x7b, 0x37, 0x9b, 0x18, 0xf4, 0xd9, 0x7b, 0xf6, 0x05, 0x0d, 0x11, 0x1c, 0x3f, 0x8b, 0x87, 0x72, + 0xd6, 0xc8, 0x04, 0x69, 0x81, 0x1b, 0x21, 0x2d, 0xe8, 0x42, 0xda, 0x4f, 0xf8, 0xc0, 0x19, 0x32, + 0x62, 0xdd, 0x68, 0x5f, 0x42, 0x48, 0x41, 0x6a, 0xa7, 0x69, 0x30, 0x33, 0xb3, 0xb5, 0xea, 0xc8, + 0x8c, 0x09, 0xe7, 0x31, 0xb4, 0xd4, 0x6b, 0x23, 0x9e, 0x4c, 0xdb, 0x0e, 0xea, 0x31, 0xb8, 0xbf, + 0xfc, 0x00, 0x7b, 0x6a, 0xbd, 0x24, 0xb6, 0x90, 0xdc, 0xb9, 0x1e, 0xbe, 0x3b, 0x92, 0x82, 0x04, + 0x24, 0x76, 0x51, 0xcd, 0x8d, 0xef, 0x21, 0xc2, 0xe4, 0xfb, 0xd0, 0x1a, 0xb9, 0x51, 0xbe, 0xbf, + 0x01, 0x5a, 0x42, 0x2f, 0xb4, 0xb2, 0x8a, 0x7e, 0xee, 0x20, 0x49, 0x40, 0x65, 0x05, 0x09, 0x5d, + 0xcc, 0x7d, 0x30, 0xbb, 0x32, 0xe8, 0xb3, 0x4b, 0x86, 0x87, 0x49, 0x0c, 0xc7, 0x47, 0xf5, 0xc1, + 0x22, 0x19, 0xd3, 0xeb, 0xe1, 0x41, 0xf1, 0x3f, 0xe0, 0xe7, 0x37, 0xe1, 0xf6, 0xba, 0x2b, 0xf7, + 0xda, 0x78, 0x82, 0x10, 0xef, 0x07, 0x12, 0xde, 0x51, 0xff, 0x85, 0x02, 0x3e, 0x86, 0x08, 0xd9, + 0x56, 0x7a, 0x46, 0xe4, 0x70, 0x5a, 0x1c, 0xf4, 0x59, 0x7a, 0x64, 0xcf, 0xe9, 0x46, 0x8e, 0x37, + 0x8e, 0x31, 0x23, 0xf7, 0x9b, 0x3c, 0x9e, 0x9c, 0x2b, 0x7f, 0xe7, 0x63, 0x2b, 0x1f, 0x72, 0xa9, + 0x7c, 0x15, 0xbf, 0x22, 0x46, 0x6b, 0x73, 0xdd, 0x02, 0xf8, 0xc3, 0x8f, 0xe5, 0xb5, 0x23, 0x34, + 0x24, 0xf9, 0x79, 0x13, 0xd5, 0xea, 0x08, 0x9f, 0x57, 0x1f, 0xa1, 0x80, 0x35, 0x98, 0xad, 0x8c, + 0x7a, 0x33, 0x04, 0xc0, 0x8f, 0x0f, 0x0f, 0x6b, 0xac, 0x4f, 0xac, 0xb9, 0xd5, 0x18, 0x1b, 0xcd, + 0x1a, 0xef, 0xe8, 0x9d, 0x4f, 0x7c, 0x05, 0x09, 0xf8, 0x63, 0x73, 0x8c, 0xb1, 0x6b, 0xae, 0xcb, + 0xfa, 0x6f, 0x14, 0xd0, 0x93, 0x20, 0xfa, 0x73, 0x48, 0xf1, 0xf9, 0x62, 0xe1, 0x60, 0xbf, 0x98, + 0x2f, 0xf3, 0xf9, 0xe2, 0xe1, 0xb7, 0xa5, 0x72, 0xe9, 0xfb, 0x42, 0xbe, 0x7c, 0xb8, 0x5f, 0x2c, + 0xe4, 0x73, 0xbb, 0x4f, 0x77, 0xf3, 0x5f, 0x45, 0x7d, 0xcc, 0xec, 0xc9, 0x69, 0x2a, 0x62, 0x1b, + 0xa2, 0x57, 0x61, 0xc9, 0x71, 0xda, 0xfe, 0xc1, 0x41, 0x21, 0x4a, 0x31, 0x53, 0x27, 0xa7, 0xa9, + 0xa0, 0xde, 0xa6, 0x37, 0x60, 0xd9, 0x11, 0x58, 0x3c, 0xcc, 0xe5, 0xf2, 0xc5, 0x62, 0xd4, 0xcf, + 0x44, 0x4e, 0x4e, 0x53, 0x61, 0xd2, 0x65, 0x82, 0x2f, 0x7f, 0x4d, 0xfa, 0xb6, 0xde, 0x4e, 0x41, + 0x60, 0x4f, 0xad, 0xd3, 0x0d, 0x98, 0x1d, 0xff, 0x4b, 0xe0, 0xbc, 0xfa, 0xc9, 0x6f, 0x75, 0x26, + 0xe3, 0x11, 0x68, 0xf1, 0x7c, 0x0c, 0x33, 0x63, 0x1f, 0xe0, 0xf7, 0x3d, 0xb8, 0x28, 0x29, 0x3d, + 0x26, 0xed, 0x0d, 0xe7, 0x12, 0x49, 0x7f, 0x11, 0x7b, 0x89, 0xb4, 0x23, 0x34, 0x3c, 0x45, 0xb2, + 0x7d, 0x19, 0xd0, 0x1a, 0xd0, 0x0e, 0x5f, 0x05, 0xeb, 0x1e, 0xbc, 0x10, 0x2c, 0xb3, 0xe5, 0x1d, + 0x6b, 0x45, 0x95, 0x20, 0x3a, 0xf1, 0x78, 0x5e, 0xbb, 0xc0, 0x8f, 0x85, 0x64, 0x1e, 0x78, 0x45, + 0x5a, 0xf1, 0x9e, 0x43, 0xcc, 0xf1, 0xc1, 0xeb, 0xc5, 0x91, 0xb9, 0xce, 0x87, 0x97, 0x00, 0x5b, + 0x81, 0x7f, 0x04, 0xb0, 0xbd, 0x0a, 0x39, 0x37, 0x17, 0x43, 0x0c, 0xb3, 0x7e, 0x31, 0xc6, 0xf2, + 0x5e, 0x84, 0xb0, 0xf9, 0x00, 0x62, 0xdd, 0xa6, 0x11, 0x00, 0xb3, 0x7a, 0x01, 0xc0, 0xae, 0xbd, + 0xb1, 0xbb, 0xf9, 0xfe, 0x05, 0x53, 0x09, 0xce, 0x5d, 0x7b, 0x2e, 0xf7, 0x49, 0x03, 0x66, 0xc7, + 0x2f, 0x01, 0xd7, 0x2c, 0xc7, 0x80, 0xee, 0x9b, 0xd7, 0xe5, 0x90, 0xcc, 0x16, 0xdf, 0x9d, 0x25, + 0xa9, 0xf7, 0x67, 0x49, 0xea, 0xef, 0xb3, 0x24, 0xf5, 0xea, 0x3c, 0xe9, 0x7b, 0x7f, 0x9e, 0xf4, + 0x7d, 0x38, 0x4f, 0xfa, 0x8e, 0x9e, 0xd4, 0x45, 0xed, 0xb8, 0x53, 0x4d, 0x0b, 0x72, 0x2b, 0x23, + 0xc8, 0x6a, 0x4b, 0x56, 0x33, 0x62, 0x55, 0xd8, 0xa8, 0xcb, 0x99, 0xee, 0xe3, 0x4c, 0x4b, 0xae, + 0x75, 0x9a, 0x48, 0x35, 0x7e, 0x58, 0x3e, 0x78, 0xb4, 0x61, 0xfe, 0xb3, 0xd4, 0x7a, 0x6d, 0xa4, + 0x56, 0x43, 0xf8, 0x7f, 0xe5, 0xc3, 0x7f, 0x03, 0x00, 0x00, 0xff, 0xff, 0x02, 0xf0, 0xc5, 0x4c, + 0x3e, 0x15, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -1609,6 +1618,13 @@ func (m *MsgChannelOpenTryResponse) MarshalToSizedBuffer(dAtA []byte) (int, erro _ = i var l int _ = l + if len(m.ChannelId) > 0 { + i -= len(m.ChannelId) + copy(dAtA[i:], m.ChannelId) + i = encodeVarintTx(dAtA, i, uint64(len(m.ChannelId))) + i-- + dAtA[i] = 0x12 + } if len(m.Version) > 0 { i -= len(m.Version) copy(dAtA[i:], m.Version) @@ -2406,6 +2422,10 @@ func (m *MsgChannelOpenTryResponse) Size() (n int) { if l > 0 { n += 1 + l + sovTx(uint64(l)) } + l = len(m.ChannelId) + if l > 0 { + n += 1 + l + sovTx(uint64(l)) + } return n } @@ -3307,6 +3327,38 @@ func (m *MsgChannelOpenTryResponse) Unmarshal(dAtA []byte) error { } m.Version = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ChannelId", 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.ChannelId = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) diff --git a/modules/core/keeper/msg_server.go b/modules/core/keeper/msg_server.go index 460edb08643..1fd8ec8dcdb 100644 --- a/modules/core/keeper/msg_server.go +++ b/modules/core/keeper/msg_server.go @@ -250,7 +250,8 @@ func (k Keeper) ChannelOpenTry(goCtx context.Context, msg *channeltypes.MsgChann ctx.Logger().Info("channel open try callback succeeded", "channel-id", channelID, "port-id", msg.PortId, "version", version) return &channeltypes.MsgChannelOpenTryResponse{ - Version: version, + ChannelId: channelID, + Version: version, }, nil } diff --git a/proto/ibc/core/channel/v1/tx.proto b/proto/ibc/core/channel/v1/tx.proto index 0cc55fbaad6..a67a375559b 100644 --- a/proto/ibc/core/channel/v1/tx.proto +++ b/proto/ibc/core/channel/v1/tx.proto @@ -92,7 +92,8 @@ message MsgChannelOpenTry { // MsgChannelOpenTryResponse defines the Msg/ChannelOpenTry response type. message MsgChannelOpenTryResponse { - string version = 1; + string version = 1; + string channel_id = 2 [(gogoproto.moretags) = "yaml:\"channel_id\""]; } // MsgChannelOpenAck defines a msg sent by a Relayer to Chain A to acknowledge From 4601ab0e3df3938831c6ec567cc875017bbd2cee Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 7 Feb 2023 22:16:58 +0100 Subject: [PATCH 18/22] build(deps): bump bufbuild/buf-setup-action from 1.13.0 to 1.13.1 (#3108) Bumps [bufbuild/buf-setup-action](https://github.com/bufbuild/buf-setup-action) from 1.13.0 to 1.13.1. - [Release notes](https://github.com/bufbuild/buf-setup-action/releases) - [Commits](https://github.com/bufbuild/buf-setup-action/compare/v1.13.0...v1.13.1) --- updated-dependencies: - dependency-name: bufbuild/buf-setup-action dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Carlos Rodriguez --- .github/workflows/proto-registry.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/proto-registry.yml b/.github/workflows/proto-registry.yml index 7a0c527d771..766c619beae 100644 --- a/.github/workflows/proto-registry.yml +++ b/.github/workflows/proto-registry.yml @@ -13,7 +13,7 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - - uses: bufbuild/buf-setup-action@v1.13.0 + - uses: bufbuild/buf-setup-action@v1.13.1 - uses: bufbuild/buf-push-action@v1 with: input: "proto" From 5fc42fdc9377205742be23c4fa5250760b5a972a Mon Sep 17 00:00:00 2001 From: Damian Nolan Date: Wed, 8 Feb 2023 11:46:28 +0100 Subject: [PATCH 19/22] attempting to silence deprecation warnings on golangci lint (#3125) --- .golangci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.golangci.yml b/.golangci.yml index 15f140f2025..76204d5471c 100644 --- a/.golangci.yml +++ b/.golangci.yml @@ -29,7 +29,7 @@ linters: issues: exclude-rules: - - text: "SA1019: suite.chainA.GetSimApp().ICAControllerKeeper.SendTx is deprecated: this is a legacy API that is only intended to function correctly in workflows where an underlying application has been set. Prior to to v6.x.x of ibc-go, the controller module was only functional as middleware, with authentication performed by the underlying application. For a full summary of the changes in v6.x.x, please see ADR009. This API will be removed in later releases." + - text: "SA1019:" linters: - staticcheck - text: "Use of weak random number generator" From 045f083259194c2717d9fd1797cb6c61d2389642 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 8 Feb 2023 11:47:18 +0100 Subject: [PATCH 20/22] build(deps): bump cosmossdk.io/math from 1.0.0-beta.4 to 1.0.0-beta.6 (#3112) * build(deps): bump cosmossdk.io/math from 1.0.0-beta.4 to 1.0.0-beta.6 Bumps [cosmossdk.io/math](https://github.com/cosmos/cosmos-sdk) from 1.0.0-beta.4 to 1.0.0-beta.6. - [Release notes](https://github.com/cosmos/cosmos-sdk/releases) - [Changelog](https://github.com/cosmos/cosmos-sdk/blob/main/CHANGELOG.md) - [Commits](https://github.com/cosmos/cosmos-sdk/compare/math/v1.0.0-beta.4...math/v1.0.0-beta.6) --- updated-dependencies: - dependency-name: cosmossdk.io/math dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] * go mod tidy e2e --------- Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Carlos Rodriguez --- e2e/go.mod | 4 ++-- e2e/go.sum | 10 +++++----- go.mod | 4 ++-- go.sum | 10 +++++----- 4 files changed, 14 insertions(+), 14 deletions(-) diff --git a/e2e/go.mod b/e2e/go.mod index 77c45c44b43..dd2fde3c8cb 100644 --- a/e2e/go.mod +++ b/e2e/go.mod @@ -26,7 +26,7 @@ require ( cosmossdk.io/core v0.3.2 // indirect cosmossdk.io/depinject v1.0.0-alpha.3 // indirect cosmossdk.io/errors v1.0.0-beta.7 // indirect - cosmossdk.io/math v1.0.0-beta.4 // indirect + cosmossdk.io/math v1.0.0-beta.6 // indirect cosmossdk.io/tools/rosetta v0.2.0 // indirect filippo.io/edwards25519 v1.0.0-rc.1 // indirect github.com/99designs/go-keychain v0.0.0-20191008050251-8e49817e8af4 // indirect @@ -190,7 +190,7 @@ require ( go.uber.org/atomic v1.10.0 // indirect go.uber.org/multierr v1.8.0 // indirect golang.org/x/crypto v0.4.0 // indirect - golang.org/x/exp v0.0.0-20221019170559-20944726eadf // indirect + golang.org/x/exp v0.0.0-20221205204356-47842c84f3db // indirect golang.org/x/net v0.4.0 // indirect golang.org/x/oauth2 v0.0.0-20221014153046-6fdb5e3db783 // indirect golang.org/x/sync v0.1.0 // indirect diff --git a/e2e/go.sum b/e2e/go.sum index c0999c86e9e..f9de1e5f0ed 100644 --- a/e2e/go.sum +++ b/e2e/go.sum @@ -54,8 +54,8 @@ cosmossdk.io/depinject v1.0.0-alpha.3 h1:6evFIgj//Y3w09bqOUOzEpFj5tsxBqdc5CfkO7z cosmossdk.io/depinject v1.0.0-alpha.3/go.mod h1:eRbcdQ7MRpIPEM5YUJh8k97nxHpYbc3sMUnEtt8HPWU= cosmossdk.io/errors v1.0.0-beta.7 h1:gypHW76pTQGVnHKo6QBkb4yFOJjC+sUGRc5Al3Odj1w= cosmossdk.io/errors v1.0.0-beta.7/go.mod h1:mz6FQMJRku4bY7aqS/Gwfcmr/ue91roMEKAmDUDpBfE= -cosmossdk.io/math v1.0.0-beta.4 h1:JtKedVLGzA0vv84xjYmZ75RKG35Kf2WwcFu8IjRkIIw= -cosmossdk.io/math v1.0.0-beta.4/go.mod h1:An0MllWJY6PxibUpnwGk8jOm+a/qIxlKmL5Zyp9NnaM= +cosmossdk.io/math v1.0.0-beta.6 h1:WF29SiFYNde5eYvqO2kdOM9nYbDb44j3YW5B8M1m9KE= +cosmossdk.io/math v1.0.0-beta.6/go.mod h1:gUVtWwIzfSXqcOT+lBVz2jyjfua8DoBdzRsIyaUAT/8= cosmossdk.io/tools/rosetta v0.2.0 h1:Ae499UiZ9yPNCXvjOBO/R9I1pksCJfxoqWauEZgA/gs= cosmossdk.io/tools/rosetta v0.2.0/go.mod h1:3mn8QuE2wLUdTi77/gbDXdFqXZdBdiBJhgAWUTSXPv8= dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU= @@ -551,7 +551,7 @@ github.com/konsorten/go-windows-terminal-sequences v1.0.3/go.mod h1:T0+1ngSBFLxv github.com/kr/fs v0.1.0/go.mod h1:FFnZGqtBN9Gxj7eW1uZ42v5BccTP0vu6NEaFoC2HwRg= github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515/go.mod h1:+0opPa2QZZtGFBFZlji/RkVcI2GknAs/DXo4wKdlNEc= github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo= -github.com/kr/pretty v0.3.0 h1:WgNl7dwNpEZ6jJ9k1snq4pZsg7DOEN8hP9Xw0Tsjwk0= +github.com/kr/pretty v0.3.1 h1:flRD4NNwYAUpkphVc1HcthR4KEIFJ65n8Mw5qdRn3LE= github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ= github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI= github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY= @@ -939,8 +939,8 @@ golang.org/x/exp v0.0.0-20200119233911-0405dc783f0a/go.mod h1:2RIsYlXP63K8oxa1u0 golang.org/x/exp v0.0.0-20200207192155-f17229e696bd/go.mod h1:J/WKrq2StrnmMY6+EHIKF9dgMWnmCNThgcyBT1FY9mM= golang.org/x/exp v0.0.0-20200224162631-6cc2880d07d6/go.mod h1:3jZMyOhIsHpP37uCMkUooju7aAi5cS1Q23tOzKc+0MU= golang.org/x/exp v0.0.0-20200331195152-e8c3332aa8e5/go.mod h1:4M0jN8W1tt0AVLNr8HDosyJCDCDuyL9N9+3m7wDWgKw= -golang.org/x/exp v0.0.0-20221019170559-20944726eadf h1:nFVjjKDgNY37+ZSYCJmtYf7tOlfQswHqplG2eosjOMg= -golang.org/x/exp v0.0.0-20221019170559-20944726eadf/go.mod h1:cyybsKvd6eL0RnXn6p/Grxp8F5bW7iYuBgsNCOHpMYE= +golang.org/x/exp v0.0.0-20221205204356-47842c84f3db h1:D/cFflL63o2KSLJIwjlcIt8PR064j/xsmdEJL/YvY/o= +golang.org/x/exp v0.0.0-20221205204356-47842c84f3db/go.mod h1:CxIveKay+FTh1D0yPZemJVgC/95VzuuOLq5Qi4xnoYc= golang.org/x/image v0.0.0-20190227222117-0694c2d4d067/go.mod h1:kZ7UVZpmo3dzQBMxlp+ypCbDeSB+sBbTgSJuh5dn5js= golang.org/x/image v0.0.0-20190802002840-cff245a6509b/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0= golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE= diff --git a/go.mod b/go.mod index 692c949614c..e2816277c93 100644 --- a/go.mod +++ b/go.mod @@ -4,7 +4,7 @@ module github.com/cosmos/ibc-go/v7 require ( cosmossdk.io/errors v1.0.0-beta.7 - cosmossdk.io/math v1.0.0-beta.4 + cosmossdk.io/math v1.0.0-beta.6 cosmossdk.io/simapp v0.0.0-20221216140705-ee8890cf30e7 cosmossdk.io/tools/rosetta v0.2.0 github.com/armon/go-metrics v0.4.1 @@ -146,7 +146,7 @@ require ( go.etcd.io/bbolt v1.3.6 // indirect go.opencensus.io v0.24.0 // indirect golang.org/x/crypto v0.4.0 // indirect - golang.org/x/exp v0.0.0-20221019170559-20944726eadf // indirect + golang.org/x/exp v0.0.0-20221205204356-47842c84f3db // indirect golang.org/x/net v0.4.0 // indirect golang.org/x/oauth2 v0.0.0-20221014153046-6fdb5e3db783 // indirect golang.org/x/sys v0.3.0 // indirect diff --git a/go.sum b/go.sum index 4760fb04ae0..fa4c9c3a3be 100644 --- a/go.sum +++ b/go.sum @@ -54,8 +54,8 @@ cosmossdk.io/depinject v1.0.0-alpha.3 h1:6evFIgj//Y3w09bqOUOzEpFj5tsxBqdc5CfkO7z cosmossdk.io/depinject v1.0.0-alpha.3/go.mod h1:eRbcdQ7MRpIPEM5YUJh8k97nxHpYbc3sMUnEtt8HPWU= cosmossdk.io/errors v1.0.0-beta.7 h1:gypHW76pTQGVnHKo6QBkb4yFOJjC+sUGRc5Al3Odj1w= cosmossdk.io/errors v1.0.0-beta.7/go.mod h1:mz6FQMJRku4bY7aqS/Gwfcmr/ue91roMEKAmDUDpBfE= -cosmossdk.io/math v1.0.0-beta.4 h1:JtKedVLGzA0vv84xjYmZ75RKG35Kf2WwcFu8IjRkIIw= -cosmossdk.io/math v1.0.0-beta.4/go.mod h1:An0MllWJY6PxibUpnwGk8jOm+a/qIxlKmL5Zyp9NnaM= +cosmossdk.io/math v1.0.0-beta.6 h1:WF29SiFYNde5eYvqO2kdOM9nYbDb44j3YW5B8M1m9KE= +cosmossdk.io/math v1.0.0-beta.6/go.mod h1:gUVtWwIzfSXqcOT+lBVz2jyjfua8DoBdzRsIyaUAT/8= cosmossdk.io/simapp v0.0.0-20221216140705-ee8890cf30e7 h1:8uwZLyQ6NMZNT0janUI86Q4vF1sIIquSUsijmOkgmp8= cosmossdk.io/simapp v0.0.0-20221216140705-ee8890cf30e7/go.mod h1:zvJ3aFHDzqQ6NvkCcCHyolr5Wh2BJ9Rg4qVcN1T6Re0= cosmossdk.io/tools/rosetta v0.2.0 h1:Ae499UiZ9yPNCXvjOBO/R9I1pksCJfxoqWauEZgA/gs= @@ -512,7 +512,7 @@ github.com/konsorten/go-windows-terminal-sequences v1.0.3/go.mod h1:T0+1ngSBFLxv github.com/kr/fs v0.1.0/go.mod h1:FFnZGqtBN9Gxj7eW1uZ42v5BccTP0vu6NEaFoC2HwRg= github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515/go.mod h1:+0opPa2QZZtGFBFZlji/RkVcI2GknAs/DXo4wKdlNEc= github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo= -github.com/kr/pretty v0.3.0 h1:WgNl7dwNpEZ6jJ9k1snq4pZsg7DOEN8hP9Xw0Tsjwk0= +github.com/kr/pretty v0.3.1 h1:flRD4NNwYAUpkphVc1HcthR4KEIFJ65n8Mw5qdRn3LE= github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ= github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI= github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY= @@ -829,8 +829,8 @@ golang.org/x/exp v0.0.0-20200119233911-0405dc783f0a/go.mod h1:2RIsYlXP63K8oxa1u0 golang.org/x/exp v0.0.0-20200207192155-f17229e696bd/go.mod h1:J/WKrq2StrnmMY6+EHIKF9dgMWnmCNThgcyBT1FY9mM= golang.org/x/exp v0.0.0-20200224162631-6cc2880d07d6/go.mod h1:3jZMyOhIsHpP37uCMkUooju7aAi5cS1Q23tOzKc+0MU= golang.org/x/exp v0.0.0-20200331195152-e8c3332aa8e5/go.mod h1:4M0jN8W1tt0AVLNr8HDosyJCDCDuyL9N9+3m7wDWgKw= -golang.org/x/exp v0.0.0-20221019170559-20944726eadf h1:nFVjjKDgNY37+ZSYCJmtYf7tOlfQswHqplG2eosjOMg= -golang.org/x/exp v0.0.0-20221019170559-20944726eadf/go.mod h1:cyybsKvd6eL0RnXn6p/Grxp8F5bW7iYuBgsNCOHpMYE= +golang.org/x/exp v0.0.0-20221205204356-47842c84f3db h1:D/cFflL63o2KSLJIwjlcIt8PR064j/xsmdEJL/YvY/o= +golang.org/x/exp v0.0.0-20221205204356-47842c84f3db/go.mod h1:CxIveKay+FTh1D0yPZemJVgC/95VzuuOLq5Qi4xnoYc= golang.org/x/image v0.0.0-20190227222117-0694c2d4d067/go.mod h1:kZ7UVZpmo3dzQBMxlp+ypCbDeSB+sBbTgSJuh5dn5js= golang.org/x/image v0.0.0-20190802002840-cff245a6509b/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0= golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE= From d86918d64b8a128b9688ad17625176483a7fb070 Mon Sep 17 00:00:00 2001 From: Carlos Rodriguez Date: Wed, 8 Feb 2023 14:35:39 +0100 Subject: [PATCH 21/22] fix docker build for forks (#3126) --- .github/workflows/e2e-fork.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/e2e-fork.yml b/.github/workflows/e2e-fork.yml index b559110257c..1f3f691c9ae 100644 --- a/.github/workflows/e2e-fork.yml +++ b/.github/workflows/e2e-fork.yml @@ -40,7 +40,7 @@ jobs: steps: - uses: actions/checkout@v3 - name: Docker Build - run: docker build . -t "${CHAIN_IMAGE}:${CHAIN_A_TAG}" + run: docker build . -t "${CHAIN_IMAGE}:${CHAIN_A_TAG}" --build-arg IBC_GO_VERSION=latest - name: Setup Go uses: actions/setup-go@v3 with: From cb41315bd29522bed86a3fd0e383eb9c7263a1e0 Mon Sep 17 00:00:00 2001 From: Carlos Rodriguez Date: Wed, 8 Feb 2023 21:55:47 +0100 Subject: [PATCH 22/22] v2 is EoL (#3121) --- .../main/client-chain-a.json | 2 +- .../main/client-chain-b.json | 2 +- .../main/connection-chain-a.json | 2 +- .../main/connection-chain-b.json | 2 +- .../main/transfer-chain-a.json | 2 +- .../main/transfer-chain-b.json | 2 +- .../release-v2.5.x/transfer-chain-a.json | 15 --------------- .../release-v2.5.x/transfer-chain-b.json | 15 --------------- .../release-v3.4.x/transfer-chain-a.json | 2 +- .../release-v3.4.x/transfer-chain-b.json | 2 +- .../release-v4.2.x/transfer-chain-a.json | 2 +- .../release-v4.2.x/transfer-chain-b.json | 2 +- .../release-v4.3.x/transfer-chain-a.json | 2 +- .../release-v4.3.x/transfer-chain-b.json | 2 +- .../release-v5.2.x/transfer-chain-a.json | 2 +- .../release-v5.2.x/transfer-chain-b.json | 2 +- .../release-v6.1.x/client-chain-a.json | 2 +- .../release-v6.1.x/client-chain-b.json | 2 +- .../release-v6.1.x/connection-chain-a.json | 2 +- .../release-v6.1.x/connection-chain-b.json | 2 +- .../release-v6.1.x/transfer-chain-a.json | 2 +- .../release-v6.1.x/transfer-chain-b.json | 2 +- .../release-v7.0.x/client-chain-a.json | 2 +- .../release-v7.0.x/client-chain-b.json | 2 +- .../release-v7.0.x/connection-chain-a.json | 2 +- .../release-v7.0.x/connection-chain-b.json | 2 +- .../release-v7.0.x/transfer-chain-a.json | 2 +- .../release-v7.0.x/transfer-chain-b.json | 2 +- .../unreleased/client.json | 4 ++-- .../unreleased/connection.json | 4 ++-- .../unreleased/transfer.json | 4 ++-- .github/mergify.yml | 16 ---------------- .github/workflows/e2e-compatibility.yaml | 2 -- .github/workflows/e2e-manual-simd.yaml | 4 ---- README.md | 2 +- RELEASES.md | 4 ---- 36 files changed, 33 insertions(+), 89 deletions(-) delete mode 100644 .github/compatibility-test-matrices/release-v2.5.x/transfer-chain-a.json delete mode 100644 .github/compatibility-test-matrices/release-v2.5.x/transfer-chain-b.json diff --git a/.github/compatibility-test-matrices/main/client-chain-a.json b/.github/compatibility-test-matrices/main/client-chain-a.json index 7bec03195cd..e81ee2903aa 100644 --- a/.github/compatibility-test-matrices/main/client-chain-a.json +++ b/.github/compatibility-test-matrices/main/client-chain-a.json @@ -1,6 +1,6 @@ { "chain-a": ["main"], - "chain-b": ["main", "v5.1.0", "v5.0.1", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-b": ["main", "v5.1.0", "v5.0.1", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1"], "entrypoint": ["TestClientTestSuite"], "test": [ "TestClientUpdateProposal_Succeeds" diff --git a/.github/compatibility-test-matrices/main/client-chain-b.json b/.github/compatibility-test-matrices/main/client-chain-b.json index ec7a3539054..99ae0cc9334 100644 --- a/.github/compatibility-test-matrices/main/client-chain-b.json +++ b/.github/compatibility-test-matrices/main/client-chain-b.json @@ -1,5 +1,5 @@ { - "chain-a": ["main", "v5.1.0", "v5.0.1", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-a": ["main", "v5.1.0", "v5.0.1", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1"], "chain-b": ["main"], "entrypoint": ["TestClientTestSuite"], "test": [ diff --git a/.github/compatibility-test-matrices/main/connection-chain-a.json b/.github/compatibility-test-matrices/main/connection-chain-a.json index b0da913249c..387d8f64bd3 100644 --- a/.github/compatibility-test-matrices/main/connection-chain-a.json +++ b/.github/compatibility-test-matrices/main/connection-chain-a.json @@ -1,6 +1,6 @@ { "chain-a": ["main"], - "chain-b": ["main", "v5.1.0", "v5.0.1", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-b": ["main", "v5.1.0", "v5.0.1", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1"], "entrypoint": ["TestConnectionTestSuite"], "test": [ "TestMaxExpectedTimePerBlockParam" diff --git a/.github/compatibility-test-matrices/main/connection-chain-b.json b/.github/compatibility-test-matrices/main/connection-chain-b.json index d90e3559677..eeaa6760227 100644 --- a/.github/compatibility-test-matrices/main/connection-chain-b.json +++ b/.github/compatibility-test-matrices/main/connection-chain-b.json @@ -1,5 +1,5 @@ { - "chain-a": ["main", "v5.1.0", "v5.0.1", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-a": ["main", "v5.1.0", "v5.0.1", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1"], "chain-b": ["main"], "entrypoint": ["TestConnectionTestSuite"], "test": [ diff --git a/.github/compatibility-test-matrices/main/transfer-chain-a.json b/.github/compatibility-test-matrices/main/transfer-chain-a.json index 99b607e12da..7365e7c3520 100644 --- a/.github/compatibility-test-matrices/main/transfer-chain-a.json +++ b/.github/compatibility-test-matrices/main/transfer-chain-a.json @@ -1,6 +1,6 @@ { "chain-a": ["main"], - "chain-b": ["main", "v5.1.0", "v5.0.1", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-b": ["main", "v5.1.0", "v5.0.1", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1"], "entrypoint": ["TestTransferTestSuite"], "test": [ "TestMsgTransfer_Succeeds_Nonincentivized", diff --git a/.github/compatibility-test-matrices/main/transfer-chain-b.json b/.github/compatibility-test-matrices/main/transfer-chain-b.json index d64f0be8ffe..4f55bb7c396 100644 --- a/.github/compatibility-test-matrices/main/transfer-chain-b.json +++ b/.github/compatibility-test-matrices/main/transfer-chain-b.json @@ -1,5 +1,5 @@ { - "chain-a": ["main", "v5.1.0", "v5.0.1", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-a": ["main", "v5.1.0", "v5.0.1", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1"], "chain-b": ["main"], "entrypoint": ["TestTransferTestSuite"], "test": [ diff --git a/.github/compatibility-test-matrices/release-v2.5.x/transfer-chain-a.json b/.github/compatibility-test-matrices/release-v2.5.x/transfer-chain-a.json deleted file mode 100644 index 9970abaaea9..00000000000 --- a/.github/compatibility-test-matrices/release-v2.5.x/transfer-chain-a.json +++ /dev/null @@ -1,15 +0,0 @@ -{ - "chain-a": ["release-v2.5.x"], - "chain-b": ["release-v2.5.x", "v6.1.0", "v5.2.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], - "entrypoint": ["TestTransferTestSuite"], - "test": [ - "TestMsgTransfer_Succeeds_Nonincentivized", - "TestMsgTransfer_Fails_InvalidAddress", - "TestMsgTransfer_Timeout_Nonincentivized", - "TestMsgTransfer_WithMemo", - "TestSendEnabledParam", - "TestReceiveEnabledParam" - ], - "chain-binary": ["simd"], - "chain-image": ["ghcr.io/cosmos/ibc-go-simd"] -} diff --git a/.github/compatibility-test-matrices/release-v2.5.x/transfer-chain-b.json b/.github/compatibility-test-matrices/release-v2.5.x/transfer-chain-b.json deleted file mode 100644 index 865bfe80b7e..00000000000 --- a/.github/compatibility-test-matrices/release-v2.5.x/transfer-chain-b.json +++ /dev/null @@ -1,15 +0,0 @@ -{ - "chain-a": ["release-v2.5.x", "v6.1.0", "v5.2.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], - "chain-b": ["release-v2.5.x"], - "entrypoint": ["TestTransferTestSuite"], - "test": [ - "TestMsgTransfer_Succeeds_Nonincentivized", - "TestMsgTransfer_Fails_InvalidAddress", - "TestMsgTransfer_Timeout_Nonincentivized", - "TestMsgTransfer_WithMemo", - "TestSendEnabledParam", - "TestReceiveEnabledParam" - ], - "chain-binary": ["simd"], - "chain-image": ["ghcr.io/cosmos/ibc-go-simd"] -} diff --git a/.github/compatibility-test-matrices/release-v3.4.x/transfer-chain-a.json b/.github/compatibility-test-matrices/release-v3.4.x/transfer-chain-a.json index 33df3af70bc..eb5c233c70a 100644 --- a/.github/compatibility-test-matrices/release-v3.4.x/transfer-chain-a.json +++ b/.github/compatibility-test-matrices/release-v3.4.x/transfer-chain-a.json @@ -1,6 +1,6 @@ { "chain-a": ["release-v3.4.x"], - "chain-b": ["release-v3.4.x", "v6.1.0", "v5.2.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-b": ["release-v3.4.x", "v6.1.0", "v5.2.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1"], "entrypoint": ["TestTransferTestSuite"], "test": [ "TestMsgTransfer_Succeeds_Nonincentivized", diff --git a/.github/compatibility-test-matrices/release-v3.4.x/transfer-chain-b.json b/.github/compatibility-test-matrices/release-v3.4.x/transfer-chain-b.json index 678edbd03c4..eebe7b3cade 100644 --- a/.github/compatibility-test-matrices/release-v3.4.x/transfer-chain-b.json +++ b/.github/compatibility-test-matrices/release-v3.4.x/transfer-chain-b.json @@ -1,5 +1,5 @@ { - "chain-a": ["release-v3.4.x", "v6.1.0", "v5.2.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-a": ["release-v3.4.x", "v6.1.0", "v5.2.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1"], "chain-b": ["release-v3.4.x"], "entrypoint": ["TestTransferTestSuite"], "test": [ diff --git a/.github/compatibility-test-matrices/release-v4.2.x/transfer-chain-a.json b/.github/compatibility-test-matrices/release-v4.2.x/transfer-chain-a.json index 14c23c1e8cc..81781ecfb32 100644 --- a/.github/compatibility-test-matrices/release-v4.2.x/transfer-chain-a.json +++ b/.github/compatibility-test-matrices/release-v4.2.x/transfer-chain-a.json @@ -1,6 +1,6 @@ { "chain-a": ["release-v4.2.x"], - "chain-b": ["release-v4.2.x", "v6.1.0", "v5.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-b": ["release-v4.2.x", "v6.1.0", "v5.2.0", "v4.1.1", "v3.4.0", "v3.3.1"], "entrypoint": ["TestTransferTestSuite"], "test": [ "TestMsgTransfer_Succeeds_Nonincentivized", diff --git a/.github/compatibility-test-matrices/release-v4.2.x/transfer-chain-b.json b/.github/compatibility-test-matrices/release-v4.2.x/transfer-chain-b.json index 53507e47ce5..6f648cafa07 100644 --- a/.github/compatibility-test-matrices/release-v4.2.x/transfer-chain-b.json +++ b/.github/compatibility-test-matrices/release-v4.2.x/transfer-chain-b.json @@ -1,5 +1,5 @@ { - "chain-a": ["release-v4.2.x", "v6.1.0", "v5.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-a": ["release-v4.2.x", "v6.1.0", "v5.2.0", "v4.1.1", "v3.4.0", "v3.3.1"], "chain-b": ["release-v4.2.x"], "entrypoint": ["TestTransferTestSuite"], "test": [ diff --git a/.github/compatibility-test-matrices/release-v4.3.x/transfer-chain-a.json b/.github/compatibility-test-matrices/release-v4.3.x/transfer-chain-a.json index fb40d4651df..5bff3259c40 100644 --- a/.github/compatibility-test-matrices/release-v4.3.x/transfer-chain-a.json +++ b/.github/compatibility-test-matrices/release-v4.3.x/transfer-chain-a.json @@ -1,6 +1,6 @@ { "chain-a": ["release-v4.3.x"], - "chain-b": ["release-v4.3.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-b": ["release-v4.3.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1"], "entrypoint": ["TestTransferTestSuite"], "test": [ "TestMsgTransfer_Succeeds_Nonincentivized", diff --git a/.github/compatibility-test-matrices/release-v4.3.x/transfer-chain-b.json b/.github/compatibility-test-matrices/release-v4.3.x/transfer-chain-b.json index 4252267109a..cdfe5fa0720 100644 --- a/.github/compatibility-test-matrices/release-v4.3.x/transfer-chain-b.json +++ b/.github/compatibility-test-matrices/release-v4.3.x/transfer-chain-b.json @@ -1,5 +1,5 @@ { - "chain-a": ["release-v4.3.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-a": ["release-v4.3.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1"], "chain-b": ["release-v4.3.x"], "entrypoint": ["TestTransferTestSuite"], "test": [ diff --git a/.github/compatibility-test-matrices/release-v5.2.x/transfer-chain-a.json b/.github/compatibility-test-matrices/release-v5.2.x/transfer-chain-a.json index 859206ad37c..b6664525f78 100644 --- a/.github/compatibility-test-matrices/release-v5.2.x/transfer-chain-a.json +++ b/.github/compatibility-test-matrices/release-v5.2.x/transfer-chain-a.json @@ -1,6 +1,6 @@ { "chain-a": ["release-v5.2.x"], - "chain-b": ["release-v5.2.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-b": ["release-v5.2.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1"], "entrypoint": ["TestTransferTestSuite"], "test": [ "TestMsgTransfer_Succeeds_Nonincentivized", diff --git a/.github/compatibility-test-matrices/release-v5.2.x/transfer-chain-b.json b/.github/compatibility-test-matrices/release-v5.2.x/transfer-chain-b.json index 85174edf434..6ad261308a3 100644 --- a/.github/compatibility-test-matrices/release-v5.2.x/transfer-chain-b.json +++ b/.github/compatibility-test-matrices/release-v5.2.x/transfer-chain-b.json @@ -1,5 +1,5 @@ { - "chain-a": ["release-v5.2.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-a": ["release-v5.2.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1"], "chain-b": ["release-v5.2.x"], "entrypoint": ["TestTransferTestSuite"], "test": [ diff --git a/.github/compatibility-test-matrices/release-v6.1.x/client-chain-a.json b/.github/compatibility-test-matrices/release-v6.1.x/client-chain-a.json index 588df03bb4e..c7b8300ac61 100644 --- a/.github/compatibility-test-matrices/release-v6.1.x/client-chain-a.json +++ b/.github/compatibility-test-matrices/release-v6.1.x/client-chain-a.json @@ -1,6 +1,6 @@ { "chain-a": ["release-v6.1.x"], - "chain-b": ["release-v6.1.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-b": ["release-v6.1.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1"], "entrypoint": ["TestClientTestSuite"], "test": [ "TestClientUpdateProposal_Succeeds" diff --git a/.github/compatibility-test-matrices/release-v6.1.x/client-chain-b.json b/.github/compatibility-test-matrices/release-v6.1.x/client-chain-b.json index 243414733b8..cf63fea5827 100644 --- a/.github/compatibility-test-matrices/release-v6.1.x/client-chain-b.json +++ b/.github/compatibility-test-matrices/release-v6.1.x/client-chain-b.json @@ -1,5 +1,5 @@ { - "chain-a": ["release-v6.1.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-a": ["release-v6.1.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1"], "chain-b": ["release-v6.1.x"], "entrypoint": ["TestClientTestSuite"], "test": [ diff --git a/.github/compatibility-test-matrices/release-v6.1.x/connection-chain-a.json b/.github/compatibility-test-matrices/release-v6.1.x/connection-chain-a.json index 4b7860fdd35..c17274eb080 100644 --- a/.github/compatibility-test-matrices/release-v6.1.x/connection-chain-a.json +++ b/.github/compatibility-test-matrices/release-v6.1.x/connection-chain-a.json @@ -1,6 +1,6 @@ { "chain-a": ["release-v6.1.x"], - "chain-b": ["release-v6.1.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-b": ["release-v6.1.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1"], "entrypoint": ["TestConnectionTestSuite"], "test": [ "TestMaxExpectedTimePerBlockParam" diff --git a/.github/compatibility-test-matrices/release-v6.1.x/connection-chain-b.json b/.github/compatibility-test-matrices/release-v6.1.x/connection-chain-b.json index 0e5d24f34a4..d5c3fa115cf 100644 --- a/.github/compatibility-test-matrices/release-v6.1.x/connection-chain-b.json +++ b/.github/compatibility-test-matrices/release-v6.1.x/connection-chain-b.json @@ -1,5 +1,5 @@ { - "chain-a": ["release-v6.1.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-a": ["release-v6.1.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1"], "chain-b": ["release-v6.1.x"], "entrypoint": ["TestConnectionTestSuite"], "test": [ diff --git a/.github/compatibility-test-matrices/release-v6.1.x/transfer-chain-a.json b/.github/compatibility-test-matrices/release-v6.1.x/transfer-chain-a.json index 426a0bb4a01..f6b298ae76f 100644 --- a/.github/compatibility-test-matrices/release-v6.1.x/transfer-chain-a.json +++ b/.github/compatibility-test-matrices/release-v6.1.x/transfer-chain-a.json @@ -1,6 +1,6 @@ { "chain-a": ["release-v6.1.x"], - "chain-b": ["release-v6.1.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-b": ["release-v6.1.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1"], "entrypoint": ["TestTransferTestSuite"], "test": [ "TestMsgTransfer_Succeeds_Nonincentivized", diff --git a/.github/compatibility-test-matrices/release-v6.1.x/transfer-chain-b.json b/.github/compatibility-test-matrices/release-v6.1.x/transfer-chain-b.json index c8468f1158b..5b47f108d4c 100644 --- a/.github/compatibility-test-matrices/release-v6.1.x/transfer-chain-b.json +++ b/.github/compatibility-test-matrices/release-v6.1.x/transfer-chain-b.json @@ -1,5 +1,5 @@ { - "chain-a": ["release-v6.1.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-a": ["release-v6.1.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1"], "chain-b": ["release-v6.1.x"], "entrypoint": ["TestTransferTestSuite"], "test": [ diff --git a/.github/compatibility-test-matrices/release-v7.0.x/client-chain-a.json b/.github/compatibility-test-matrices/release-v7.0.x/client-chain-a.json index 547b8981c90..220d46f6918 100644 --- a/.github/compatibility-test-matrices/release-v7.0.x/client-chain-a.json +++ b/.github/compatibility-test-matrices/release-v7.0.x/client-chain-a.json @@ -1,6 +1,6 @@ { "chain-a": ["release-v7.0.x"], - "chain-b": ["release-v7.0.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-b": ["release-v7.0.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1"], "entrypoint": ["TestClientTestSuite"], "test": [ "TestClientUpdateProposal_Succeeds" diff --git a/.github/compatibility-test-matrices/release-v7.0.x/client-chain-b.json b/.github/compatibility-test-matrices/release-v7.0.x/client-chain-b.json index d8599b534ff..7e2e4f5b72f 100644 --- a/.github/compatibility-test-matrices/release-v7.0.x/client-chain-b.json +++ b/.github/compatibility-test-matrices/release-v7.0.x/client-chain-b.json @@ -1,5 +1,5 @@ { - "chain-a": ["release-v7.0.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-a": ["release-v7.0.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1"], "chain-b": ["release-v7.0.x"], "entrypoint": ["TestClientTestSuite"], "test": [ diff --git a/.github/compatibility-test-matrices/release-v7.0.x/connection-chain-a.json b/.github/compatibility-test-matrices/release-v7.0.x/connection-chain-a.json index 58df9c3d20a..0795cb738ee 100644 --- a/.github/compatibility-test-matrices/release-v7.0.x/connection-chain-a.json +++ b/.github/compatibility-test-matrices/release-v7.0.x/connection-chain-a.json @@ -1,6 +1,6 @@ { "chain-a": ["release-v7.0.x"], - "chain-b": ["release-v7.0.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-b": ["release-v7.0.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1"], "entrypoint": ["TestConnectionTestSuite"], "test": [ "TestMaxExpectedTimePerBlockParam" diff --git a/.github/compatibility-test-matrices/release-v7.0.x/connection-chain-b.json b/.github/compatibility-test-matrices/release-v7.0.x/connection-chain-b.json index 11666658f37..2679fefcab9 100644 --- a/.github/compatibility-test-matrices/release-v7.0.x/connection-chain-b.json +++ b/.github/compatibility-test-matrices/release-v7.0.x/connection-chain-b.json @@ -1,5 +1,5 @@ { - "chain-a": ["release-v7.0.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-a": ["release-v7.0.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1"], "chain-b": ["release-v7.0.x"], "entrypoint": ["TestConnectionTestSuite"], "test": [ diff --git a/.github/compatibility-test-matrices/release-v7.0.x/transfer-chain-a.json b/.github/compatibility-test-matrices/release-v7.0.x/transfer-chain-a.json index b0513db66ba..130351158d7 100644 --- a/.github/compatibility-test-matrices/release-v7.0.x/transfer-chain-a.json +++ b/.github/compatibility-test-matrices/release-v7.0.x/transfer-chain-a.json @@ -1,6 +1,6 @@ { "chain-a": ["release-v7.0.x"], - "chain-b": ["release-v7.0.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-b": ["release-v7.0.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1"], "entrypoint": ["TestTransferTestSuite"], "test": [ "TestMsgTransfer_Succeeds_Nonincentivized", diff --git a/.github/compatibility-test-matrices/release-v7.0.x/transfer-chain-b.json b/.github/compatibility-test-matrices/release-v7.0.x/transfer-chain-b.json index d091ffe1a4f..8135f305972 100644 --- a/.github/compatibility-test-matrices/release-v7.0.x/transfer-chain-b.json +++ b/.github/compatibility-test-matrices/release-v7.0.x/transfer-chain-b.json @@ -1,5 +1,5 @@ { - "chain-a": ["release-v7.0.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1", "v2.5.0", "v2.4.2"], + "chain-a": ["release-v7.0.x", "v6.1.0", "v5.2.0", "v4.3.0", "v4.2.0", "v4.1.1", "v3.4.0", "v3.3.1"], "chain-b": ["release-v7.0.x"], "entrypoint": ["TestTransferTestSuite"], "test": [ diff --git a/.github/compatibility-test-matrices/unreleased/client.json b/.github/compatibility-test-matrices/unreleased/client.json index 21a81d67007..69e861c63f4 100644 --- a/.github/compatibility-test-matrices/unreleased/client.json +++ b/.github/compatibility-test-matrices/unreleased/client.json @@ -1,6 +1,6 @@ { - "chain-a": ["release-v7.0.x", "release-v6.1.x", "release-v5.2.x", "release-v4.3.x", "release-v4.2.x", "release-v3.4.x", "release-v2.5.x"], - "chain-b": ["release-v7.0.x", "release-v6.1.x", "release-v5.2.x", "release-v4.3.x", "release-v4.2.x", "release-v3.4.x", "release-v2.5.x"], + "chain-a": ["release-v7.0.x", "release-v6.1.x", "release-v5.2.x", "release-v4.3.x", "release-v4.2.x", "release-v3.4.x"], + "chain-b": ["release-v7.0.x", "release-v6.1.x", "release-v5.2.x", "release-v4.3.x", "release-v4.2.x", "release-v3.4.x"], "entrypoint": ["TestClientTestSuite"], "test": [ "TestClientUpdateProposal_Succeeds" diff --git a/.github/compatibility-test-matrices/unreleased/connection.json b/.github/compatibility-test-matrices/unreleased/connection.json index ebccc155f58..96cea6c543e 100644 --- a/.github/compatibility-test-matrices/unreleased/connection.json +++ b/.github/compatibility-test-matrices/unreleased/connection.json @@ -1,6 +1,6 @@ { - "chain-a": ["release-v7.0.x", "release-v6.1.x", "release-v5.2.x", "release-v4.3.x", "release-v4.2.x", "release-v3.4.x", "release-v2.5.x"], - "chain-b": ["release-v7.0.x", "release-v6.1.x", "release-v5.2.x", "release-v4.3.x", "release-v4.2.x", "release-v3.4.x", "release-v2.5.x"], + "chain-a": ["release-v7.0.x", "release-v6.1.x", "release-v5.2.x", "release-v4.3.x", "release-v4.2.x", "release-v3.4.x"], + "chain-b": ["release-v7.0.x", "release-v6.1.x", "release-v5.2.x", "release-v4.3.x", "release-v4.2.x", "release-v3.4.x"], "entrypoint": ["TestConnectionTestSuite"], "test": [ "TestMaxExpectedTimePerBlockParam" diff --git a/.github/compatibility-test-matrices/unreleased/transfer.json b/.github/compatibility-test-matrices/unreleased/transfer.json index 0cf689975cd..a76939e784d 100644 --- a/.github/compatibility-test-matrices/unreleased/transfer.json +++ b/.github/compatibility-test-matrices/unreleased/transfer.json @@ -1,6 +1,6 @@ { - "chain-a": ["release-v7.0.x", "release-v6.1.x", "release-v5.2.x", "release-v4.2.x", "release-v3.4.x", "release-v2.5.x"], - "chain-b": ["release-v7.0.x", "release-v6.1.x", "release-v5.2.x", "release-v4.2.x", "release-v3.4.x", "release-v2.5.x"], + "chain-a": ["release-v7.0.x", "release-v6.1.x", "release-v5.2.x", "release-v4.2.x", "release-v3.4.x"], + "chain-b": ["release-v7.0.x", "release-v6.1.x", "release-v5.2.x", "release-v4.2.x", "release-v3.4.x"], "entrypoint": ["TestTransferTestSuite"], "test": [ "TestMsgTransfer_Succeeds_Nonincentivized", diff --git a/.github/mergify.yml b/.github/mergify.yml index 983ea60625e..8ff9b606452 100644 --- a/.github/mergify.yml +++ b/.github/mergify.yml @@ -18,22 +18,6 @@ pull_request_rules: commit_message_template: | {{ title }} (#{{ number }}) {{ body }} - - name: backport patches to v2.4.x branch - conditions: - - base=main - - label=backport-to-v2.4.x - actions: - backport: - branches: - - release/v2.4.x - - name: backport patches to v2.5.x branch - conditions: - - base=main - - label=backport-to-v2.5.x - actions: - backport: - branches: - - release/v2.5.x - name: backport patches to v3.3.x branch conditions: - base=main diff --git a/.github/workflows/e2e-compatibility.yaml b/.github/workflows/e2e-compatibility.yaml index 2327bc97ff3..76c755a6265 100644 --- a/.github/workflows/e2e-compatibility.yaml +++ b/.github/workflows/e2e-compatibility.yaml @@ -7,7 +7,6 @@ on: required: true type: choice options: - - release/v2.5.x - release/v3.4.x - release/v4.2.x - release/v4.3.x @@ -45,7 +44,6 @@ jobs: strategy: matrix: release-branch: - - release/v2.5.x - release/v3.4.x - release/v4.2.x - release/v4.3.x diff --git a/.github/workflows/e2e-manual-simd.yaml b/.github/workflows/e2e-manual-simd.yaml index 989a58b5a0d..3d8b1e02a50 100644 --- a/.github/workflows/e2e-manual-simd.yaml +++ b/.github/workflows/e2e-manual-simd.yaml @@ -42,8 +42,6 @@ on: - v4.1.1 - v3.4.0 - v3.3.1 - - v2.5.0 - - v2.4.2 chain-a-tag-override: description: 'Specify an arbitrary tag for chain A' required: false @@ -62,8 +60,6 @@ on: - v4.1.1 - v3.4.0 - v3.3.1 - - v2.5.0 - - v2.4.2 chain-b-tag-override: description: 'Specify an arbitrary tag for chain B' required: false diff --git a/README.md b/README.md index 51de14ad8a7..baae7884fb1 100644 --- a/README.md +++ b/README.md @@ -51,7 +51,7 @@ For the latest information on the progress of the work or the decisions made tha ## Releases -The release lines currently supported are v2, v3, v4, v5 and v6. +The release lines currently supported are v3, v4, v5 and v6. Please refer to the [Stable Release Policy section of RELEASES.md](https://github.com/cosmos/ibc-go/blob/main/RELEASES.md#stable-release-policy) for more details. diff --git a/RELEASES.md b/RELEASES.md index ee57b7fa8ec..28684dee16e 100644 --- a/RELEASES.md +++ b/RELEASES.md @@ -65,8 +65,6 @@ Only the following major release series have a stable release status: |Release|End of Life Date| |-------|----------------| -|`v2.4.x`|February 01, 2023| -|`v2.5.x`|February 01, 2023| |`v3.3.x`|March 15, 2023| |`v3.4.x`|March 15, 2023| |`v4.1.x`|August 12, 2023| @@ -104,8 +102,6 @@ Versions of Golang, Cosmos SDK and Tendermint used by ibc-go in the currently ac | Go | ibc-go | Cosmos SDK | Tendermint | |----|--------|------------|------------| -| 1.18 | v2.4.2 | v0.45.10 | v0.34.22 | -| 1.18 | v2.5.0 | v0.45.10 | v0.34.22 | | 1.18 | v3.3.1 | v0.45.10 | v0.34.22 | | 1.18 | v3.4.0 | v0.45.10 | v0.34.22 | | 1.18 | v4.1.1 | v0.45.10 | v0.34.22 |