From 64279437b71239687b4db82612a1091b9840338a Mon Sep 17 00:00:00 2001 From: Jim Fasarakis-Hilliard Date: Tue, 20 Jun 2023 12:44:47 +0300 Subject: [PATCH 1/7] Add NewMsgUpdateParams for host. (#3850) * Add NewMsgUpdateParams for host. --- .../host/keeper/msg_server_test.go | 25 +++------ .../27-interchain-accounts/host/types/msgs.go | 8 +++ .../host/types/msgs_test.go | 53 ++++++------------- 3 files changed, 30 insertions(+), 56 deletions(-) diff --git a/modules/apps/27-interchain-accounts/host/keeper/msg_server_test.go b/modules/apps/27-interchain-accounts/host/keeper/msg_server_test.go index 9bebd157ef7..ab9cce28a97 100644 --- a/modules/apps/27-interchain-accounts/host/keeper/msg_server_test.go +++ b/modules/apps/27-interchain-accounts/host/keeper/msg_server_test.go @@ -6,27 +6,19 @@ import ( ) func (suite *KeeperTestSuite) TestUpdateParams() { - msg := types.MsgUpdateParams{} - testCases := []struct { - name string - malleate func(authority string) - expPass bool + name string + msg *types.MsgUpdateParams + expPass bool }{ { "success", - func(authority string) { - msg.Authority = authority - msg.Params = types.DefaultParams() - }, + types.NewMsgUpdateParams(suite.chainA.GetSimApp().ICAHostKeeper.GetAuthority(), types.DefaultParams()), true, }, { "invalid authority address", - func(authority string) { - msg.Authority = "authority" - msg.Params = types.DefaultParams() - }, + types.NewMsgUpdateParams("authority", types.DefaultParams()), false, }, } @@ -37,12 +29,9 @@ func (suite *KeeperTestSuite) TestUpdateParams() { suite.Run(tc.name, func() { suite.SetupTest() - ICAHostKeeper := &suite.chainA.GetSimApp().ICAHostKeeper - tc.malleate(ICAHostKeeper.GetAuthority()) // malleate mutates test data - ctx := suite.chainA.GetContext() - msgServer := keeper.NewMsgServerImpl(ICAHostKeeper) - res, err := msgServer.UpdateParams(ctx, &msg) + msgServer := keeper.NewMsgServerImpl(&suite.chainA.GetSimApp().ICAHostKeeper) + res, err := msgServer.UpdateParams(ctx, tc.msg) if tc.expPass { suite.Require().NoError(err) diff --git a/modules/apps/27-interchain-accounts/host/types/msgs.go b/modules/apps/27-interchain-accounts/host/types/msgs.go index 67dc6566c19..2af6d52a050 100644 --- a/modules/apps/27-interchain-accounts/host/types/msgs.go +++ b/modules/apps/27-interchain-accounts/host/types/msgs.go @@ -9,6 +9,14 @@ import ( var _ sdk.Msg = (*MsgUpdateParams)(nil) +// NewMsgUpdateParams creates a new MsgUpdateParams instance +func NewMsgUpdateParams(authority string, params Params) *MsgUpdateParams { + return &MsgUpdateParams{ + Authority: authority, + Params: params, + } +} + // ValidateBasic implements sdk.Msg func (msg MsgUpdateParams) ValidateBasic() error { _, err := sdk.AccAddressFromBech32(msg.Authority) diff --git a/modules/apps/27-interchain-accounts/host/types/msgs_test.go b/modules/apps/27-interchain-accounts/host/types/msgs_test.go index 1156c364083..24d817d3a9f 100644 --- a/modules/apps/27-interchain-accounts/host/types/msgs_test.go +++ b/modules/apps/27-interchain-accounts/host/types/msgs_test.go @@ -11,57 +11,37 @@ import ( ) func TestMsgUpdateParamsValidateBasic(t *testing.T) { - var msg *types.MsgUpdateParams - testCases := []struct { - name string - malleate func() - expPass bool + name string + msg *types.MsgUpdateParams + expPass bool }{ { "success: valid authority address", - func() { - msg = &types.MsgUpdateParams{ - Authority: ibctesting.TestAccAddress, - Params: types.DefaultParams(), - } - }, + types.NewMsgUpdateParams(sdk.AccAddress(ibctesting.TestAccAddress).String(), types.DefaultParams()), true, }, { "failure: invalid authority address", - func() { - msg = &types.MsgUpdateParams{ - Authority: "authority", - } - }, + types.NewMsgUpdateParams("authority", types.DefaultParams()), false, }, { "failure: invalid allowed message", - func() { - msg = &types.MsgUpdateParams{ - Authority: ibctesting.TestAccAddress, - Params: types.Params{ - AllowMessages: []string{""}, - }, - } - }, + types.NewMsgUpdateParams("authority", types.Params{ + AllowMessages: []string{""}, + }), false, }, } for _, tc := range testCases { - t.Run(tc.name, func(t *testing.T) { - tc.malleate() - - err := msg.ValidateBasic() - if tc.expPass { - require.NoError(t, err) - } else { - require.Error(t, err) - } - }) + err := tc.msg.ValidateBasic() + if tc.expPass { + require.NoError(t, err) + } else { + require.Error(t, err) + } } } @@ -76,10 +56,7 @@ func TestMsgUpdateParamsGetSigners(t *testing.T) { } for _, tc := range testCases { - msg := types.MsgUpdateParams{ - Authority: tc.address.String(), - Params: types.DefaultParams(), - } + msg := types.NewMsgUpdateParams(tc.address.String(), types.DefaultParams()) if tc.expPass { require.Equal(t, []sdk.AccAddress{tc.address}, msg.GetSigners()) } else { From 2e44243cf2c2002403cce687256ddc8fcdfbc74b Mon Sep 17 00:00:00 2001 From: Charly Date: Tue, 20 Jun 2023 13:20:57 +0200 Subject: [PATCH 2/7] chore: script to automate updates of compatibility test configs for new releases (#3541) Add a script to automate the adding/removing/replacing of versions in the json compatibility files. --------- Co-authored-by: DimitrisJim --- scripts/update_compatibility_tests.py | 191 ++++++++++++++++++++++++++ 1 file changed, 191 insertions(+) create mode 100755 scripts/update_compatibility_tests.py diff --git a/scripts/update_compatibility_tests.py b/scripts/update_compatibility_tests.py new file mode 100755 index 00000000000..99dded3181f --- /dev/null +++ b/scripts/update_compatibility_tests.py @@ -0,0 +1,191 @@ +#!/usr/bin/python3 +""" +The following script takes care of adding new/removing versions or +replacing a version in the compatibility-test-matrices JSON files. + +To use this script, you'll need to have Python 3.9+ installed. + +Invocation: + +By default, the script assumes that adding a new version is the desired operation. +Furthermore, it assumes that the compatibility-test-matrices directory is located +in the .github directory and the script is invoked from the root of the repository. + +If any of the above is not true, you can use the '--type' and '--directory' flags +to specify the operation and the directory respectively. + +Typically, an invocation would look like: + + scripts/update_compatibility_tests.py --recent_version v4.3.0 --new_version v4.4.0 + +The three operations currently added are: + + - ADD: Add a new version to the JSON files. Requires both '--recent_version' and + '--new_version' options to be set. + - REPLACE: Replace an existing version with a new one. Requires both '--recent_version' + and '--new_version' options to be set. + - REMOVE: Remove an existing version from the JSON files. Requires only the + '--recent_version' options to be set. + +For more information, use the '--help' flag to see the available options. +""" +import argparse +import os +import json +import enum +from collections import defaultdict +from typing import Tuple, Generator, Optional, Dict, List, Any + +# Directory to operate in +DIRECTORY: str = ".github/compatibility-test-matrices" +# JSON keys to search in. +KEYS: Tuple[str, str] = ("chain-a", "chain-b") +# Toggle if required. Indent = 2 matches our current formatting. +DUMP_ARGS: Dict[Any, Any] = { + "indent": 2, + "sort_keys": False, + "ensure_ascii": False, +} +# Suggestions for recent and new versions. +SUGGESTION: str = "for example, v4.3.0 or 4.3.0" +# Supported Operations. +Operation = enum.Enum("Operation", ["ADD", "REMOVE", "REPLACE"]) + + +def find_json_files( + directory: str, ignores: Tuple[str] = (".",) +) -> Generator[str, None, None]: + """Find JSON files in a directory. By default, ignore hidden directories.""" + for root, dirs, files in os.walk(directory): + dirs[:] = (d for d in dirs if not d.startswith(ignores)) + for file_ in files: + if file_.endswith(".json"): + yield os.path.join(root, file_) + + +def has_release_version(json_file: Any, keys: Tuple[str, str], version: str) -> bool: + """Check if the json file has the version in question.""" + rows = (json_file[key] for key in keys) + return any(version in row for row in rows) + + +def sorter(key: str) -> str: + """Since 'main' < 'vX.X.X' and we want to have 'main' as the first entry + in the list, we return a version that is considerably large. If ibc-go + reaches this version I'll wear my dunce hat and go sit in the corner. + """ + return "v99999.9.9" if key == "main" else key + + +def update_version(json_file: Any, keys: Tuple[str, str], args: argparse.Namespace): + """Update the versions as required in the json file.""" + recent, new, op = args.recent, args.new, args.type + for row in (json_file[key] for key in keys): + if recent not in row: + continue + if op == Operation.ADD: + row.append(new) + row.sort(key=sorter, reverse=True) + else: + index = row.index(recent) + if op == Operation.REPLACE: + row[index] = new + elif op == Operation.REMOVE: + del row[index] + + +def version_input(prompt: str, version: Optional[str]) -> str: + """Input version if not supplied, make it start with a 'v' if it doesn't.""" + if version is None: + version = input(prompt) + return version if version.startswith(("v", "V")) else f"v{version}" + + +def require_version(args: argparse.Namespace): + """Allow non-required version in argparse but request it if not provided.""" + args.recent = version_input(f"Recent version ({SUGGESTION}): ", args.recent) + if args.type == Operation.REMOVE: + return + args.new = version_input(f"New version ({SUGGESTION}): ", args.new) + + +def parse_args() -> argparse.Namespace: + """Parse command line arguments.""" + parser = argparse.ArgumentParser(description="Update JSON files.") + parser.add_argument( + "--type", + choices=[Operation.ADD.name, Operation.REPLACE.name, Operation.REMOVE.name], + default=Operation.ADD, + help="Type of version update: add a version, replace one or remove one.", + ) + parser.add_argument( + "--directory", + default=DIRECTORY, + help="Directory path where JSON files are located", + ) + parser.add_argument( + "--recent_version", + dest="recent", + help=f"Recent version to search in JSON files ({SUGGESTION})", + ) + parser.add_argument( + "--new_version", + dest="new", + help=f"New version to add in JSON files ({SUGGESTION})", + ) + parser.add_argument( + "--verbose", + "-v", + action="store_true", + help="Allow for verbose output", + default=False, + ) + + args = parser.parse_args() + require_version(args) + return args + + +def print_logs(logs: Dict[str, List[str]], verbose: bool): + """Print the logs. Verbosity controls if each individual + file is printed or not. + """ + updated, skipped = logs["updated"], logs["skipped"] + if updated: + if verbose: + print("Updated files:", *updated, sep="\n - ") + else: + print("No files were updated.") + if skipped: + if verbose: + print("The following files were skipped:", *skipped, sep="\n - ") + else: + print("No files skipped.") + + +def main(args: argparse.Namespace): + """ Main driver function.""" + # Hold logs for 'updated' and 'skipped' files. + logs = defaultdict(list) + + # Go through each file and operate on it, if applicable. + for file_ in find_json_files(args.directory): + with open(file_, "r+") as fp: + json_file = json.load(fp) + if not has_release_version(json_file, KEYS, args.recent): + logs["skipped"].append( + f"Version '{args.recent}' not found in '{file_}'" + ) + continue + update_version(json_file, KEYS, args) + fp.seek(0) + json.dump(json_file, fp, **DUMP_ARGS) + logs["updated"].append(f"Updated '{file_}'") + + # Print logs collected. + print_logs(logs, args.verbose) + + +if __name__ == "__main__": + args = parse_args() + main(args) From 255c5e2b6e1788df8b99c8488d14b3e1f7f0c070 Mon Sep 17 00:00:00 2001 From: Carlos Rodriguez Date: Tue, 20 Jun 2023 20:32:25 +0200 Subject: [PATCH 3/7] chore: add deprecated option to `MsgSubmitMisbehaviour` (#3893) --- modules/core/02-client/types/tx.pb.go | 96 ++++++++++++++------------- proto/ibc/core/client/v1/tx.proto | 9 +-- 2 files changed, 54 insertions(+), 51 deletions(-) diff --git a/modules/core/02-client/types/tx.pb.go b/modules/core/02-client/types/tx.pb.go index 93658401e3b..76a8cb9721a 100644 --- a/modules/core/02-client/types/tx.pb.go +++ b/modules/core/02-client/types/tx.pb.go @@ -282,14 +282,16 @@ var xxx_messageInfo_MsgUpgradeClientResponse proto.InternalMessageInfo // MsgSubmitMisbehaviour defines an sdk.Msg type that submits Evidence for // light client misbehaviour. -// Warning: DEPRECATED +// This message has been deprecated. Use MsgUpdateClient instead. +// +// Deprecated: Do not use. type MsgSubmitMisbehaviour struct { // client unique identifier - ClientId string `protobuf:"bytes,1,opt,name=client_id,json=clientId,proto3" json:"client_id,omitempty"` // Deprecated: Do not use. + ClientId string `protobuf:"bytes,1,opt,name=client_id,json=clientId,proto3" json:"client_id,omitempty"` // misbehaviour used for freezing the light client - Misbehaviour *types.Any `protobuf:"bytes,2,opt,name=misbehaviour,proto3" json:"misbehaviour,omitempty"` // Deprecated: Do not use. + Misbehaviour *types.Any `protobuf:"bytes,2,opt,name=misbehaviour,proto3" json:"misbehaviour,omitempty"` // signer address - Signer string `protobuf:"bytes,3,opt,name=signer,proto3" json:"signer,omitempty"` // Deprecated: Do not use. + Signer string `protobuf:"bytes,3,opt,name=signer,proto3" json:"signer,omitempty"` } func (m *MsgSubmitMisbehaviour) Reset() { *m = MsgSubmitMisbehaviour{} } @@ -473,49 +475,49 @@ func init() { func init() { proto.RegisterFile("ibc/core/client/v1/tx.proto", fileDescriptor_cb5dc4651eb49a04) } var fileDescriptor_cb5dc4651eb49a04 = []byte{ - // 667 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x95, 0xbf, 0x53, 0xd4, 0x40, - 0x14, 0xc7, 0x93, 0x03, 0x6e, 0xbc, 0xe5, 0x00, 0x67, 0x45, 0x39, 0x82, 0x24, 0x0c, 0x5a, 0x20, - 0x4a, 0x02, 0x58, 0xc0, 0xa0, 0x16, 0x40, 0x65, 0x71, 0x33, 0x4e, 0x18, 0x1b, 0x1b, 0x4c, 0x72, - 0xcb, 0x92, 0x19, 0x92, 0xcd, 0x64, 0x93, 0x1b, 0xaf, 0x73, 0xac, 0x2c, 0xb5, 0xb3, 0xa4, 0xb3, - 0xa5, 0xf2, 0x6f, 0xc0, 0x8e, 0xd2, 0xca, 0x71, 0xee, 0x0a, 0xfc, 0x33, 0x9c, 0xec, 0xee, 0xe5, - 0x92, 0xdc, 0x0f, 0x4e, 0xed, 0x92, 0x7d, 0x9f, 0xb7, 0xdf, 0xef, 0x7b, 0x79, 0x9b, 0x05, 0x4b, - 0xae, 0xed, 0x18, 0x0e, 0x09, 0x91, 0xe1, 0x9c, 0xb9, 0xc8, 0x8f, 0x8c, 0xe6, 0x96, 0x11, 0xbd, - 0xd3, 0x83, 0x90, 0x44, 0x04, 0x42, 0xd7, 0x76, 0xf4, 0x24, 0xa8, 0xf3, 0xa0, 0xde, 0xdc, 0x52, - 0x16, 0x1c, 0x42, 0x3d, 0x42, 0x0d, 0x8f, 0xe2, 0x84, 0xf5, 0x28, 0xe6, 0xb0, 0x32, 0x8f, 0x09, - 0x26, 0xec, 0xd1, 0x48, 0x9e, 0xc4, 0xea, 0x22, 0x26, 0x04, 0x9f, 0x21, 0x83, 0xbd, 0xd9, 0xf1, - 0x89, 0x61, 0xf9, 0x2d, 0x11, 0xd2, 0x06, 0x48, 0x0b, 0x1d, 0x06, 0xac, 0x7e, 0x93, 0xc1, 0x5c, - 0x9d, 0xe2, 0xc3, 0x10, 0x59, 0x11, 0x3a, 0x64, 0x11, 0xb8, 0x03, 0xaa, 0x9c, 0x39, 0xa6, 0x91, - 0x15, 0xa1, 0x9a, 0xbc, 0x22, 0xaf, 0x4d, 0x6f, 0xcf, 0xeb, 0x5c, 0x46, 0xef, 0xca, 0xe8, 0xfb, - 0x7e, 0xcb, 0x9c, 0xe6, 0xe4, 0x51, 0x02, 0xc2, 0x17, 0x60, 0xce, 0x21, 0x3e, 0x45, 0x3e, 0x8d, - 0xa9, 0xc8, 0x2d, 0x8d, 0xc8, 0x9d, 0x4d, 0x61, 0x9e, 0x7e, 0x0f, 0x94, 0xa9, 0x8b, 0x7d, 0x14, - 0xd6, 0x26, 0x56, 0xe4, 0xb5, 0x8a, 0x29, 0xde, 0xf6, 0xee, 0x7c, 0x3c, 0xd7, 0xa4, 0xdf, 0xe7, - 0x9a, 0xf4, 0xe1, 0xfa, 0x62, 0x5d, 0x2c, 0xae, 0x2e, 0x82, 0x85, 0x82, 0x6f, 0x13, 0xd1, 0x20, - 0xd9, 0x70, 0xf5, 0x0b, 0xaf, 0xe9, 0x75, 0xd0, 0xe8, 0xd5, 0xb4, 0x04, 0x2a, 0xa2, 0x26, 0xb7, - 0xc1, 0x0a, 0xaa, 0x98, 0xb7, 0xf8, 0xc2, 0xcb, 0x06, 0x7c, 0x06, 0x66, 0x45, 0xd0, 0x43, 0x94, - 0x5a, 0x78, 0xb4, 0xed, 0x19, 0xce, 0xd6, 0x39, 0xfa, 0x2f, 0xae, 0xb3, 0xce, 0x52, 0xd7, 0xdf, - 0x4b, 0xe0, 0x36, 0x8b, 0xe1, 0xd0, 0x6a, 0x8c, 0x65, 0xbb, 0xf8, 0x9d, 0x4a, 0xff, 0xf1, 0x9d, - 0x26, 0xfe, 0xe2, 0x3b, 0x6d, 0x82, 0xf9, 0x20, 0x24, 0xe4, 0xe4, 0x38, 0xe6, 0x5e, 0x8f, 0xf9, - 0xde, 0xb5, 0xc9, 0x15, 0x79, 0xad, 0x6a, 0x42, 0x16, 0xcb, 0x97, 0xb1, 0x0f, 0x96, 0x0b, 0x19, - 0x05, 0xf9, 0x29, 0x96, 0xaa, 0xe4, 0x52, 0x87, 0x0d, 0x47, 0xf9, 0xe6, 0x36, 0x2b, 0xa0, 0x56, - 0x6c, 0x65, 0xda, 0xe7, 0xaf, 0x32, 0xb8, 0x5b, 0xa7, 0xf8, 0x28, 0xb6, 0x3d, 0x37, 0xaa, 0xbb, - 0xd4, 0x46, 0xa7, 0x56, 0xd3, 0x25, 0x71, 0x08, 0xb5, 0xbe, 0x66, 0x1f, 0x94, 0x6a, 0x72, 0xa6, - 0xe1, 0xcf, 0x41, 0xd5, 0xcb, 0x24, 0x8c, 0x6a, 0x38, 0xcb, 0xcc, 0xd1, 0x50, 0xc9, 0x0f, 0x0a, - 0x23, 0x46, 0x56, 0xa1, 0x81, 0xe5, 0x81, 0x46, 0xd3, 0x52, 0x5a, 0x99, 0x39, 0x7f, 0x65, 0x85, - 0x96, 0x47, 0xe1, 0x7d, 0x50, 0xb1, 0xe2, 0xe8, 0x94, 0x84, 0x6e, 0xd4, 0x12, 0x03, 0xd3, 0x5b, - 0x80, 0xbb, 0xa0, 0x1c, 0x30, 0x4e, 0x58, 0x57, 0xf4, 0xfe, 0xbf, 0x8f, 0xce, 0x77, 0x3a, 0x98, - 0xbc, 0xfc, 0xa9, 0x49, 0xa6, 0xe0, 0xf7, 0x66, 0x13, 0x63, 0xbd, 0x9d, 0x72, 0x83, 0xcc, 0x13, - 0xba, 0xae, 0xb6, 0x3f, 0x4f, 0x82, 0x89, 0x3a, 0xc5, 0xf0, 0x2d, 0xa8, 0xe6, 0x7e, 0x2b, 0x0f, - 0x06, 0x89, 0x15, 0xce, 0xb0, 0xf2, 0x78, 0x0c, 0xa8, 0xab, 0x94, 0x28, 0xe4, 0x0e, 0xf9, 0x30, - 0x85, 0x2c, 0x34, 0x54, 0x61, 0xd0, 0xa1, 0x84, 0x0e, 0x98, 0xc9, 0x4f, 0xf2, 0xc3, 0xa1, 0xd9, - 0x19, 0x4a, 0x79, 0x32, 0x0e, 0x95, 0x8a, 0x84, 0x00, 0x0e, 0x98, 0xc6, 0x47, 0x43, 0xf6, 0xe8, - 0x47, 0x95, 0xad, 0xb1, 0xd1, 0x54, 0xf3, 0x04, 0xc0, 0x6c, 0xc1, 0x62, 0x7a, 0x46, 0x37, 0x90, - 0x43, 0x37, 0x34, 0x30, 0x3f, 0x0c, 0xca, 0xd4, 0xfb, 0xeb, 0x8b, 0x75, 0xf9, 0xc0, 0xbc, 0x6c, - 0xab, 0xf2, 0x55, 0x5b, 0x95, 0x7f, 0xb5, 0x55, 0xf9, 0x53, 0x47, 0x95, 0xae, 0x3a, 0xaa, 0xf4, - 0xa3, 0xa3, 0x4a, 0x6f, 0x76, 0xb1, 0x1b, 0x9d, 0xc6, 0xb6, 0xee, 0x10, 0xcf, 0x10, 0xd7, 0x9e, - 0x6b, 0x3b, 0x1b, 0x98, 0x18, 0xcd, 0x1d, 0xc3, 0x23, 0x8d, 0xf8, 0x0c, 0x51, 0x7e, 0x83, 0x6d, - 0x6e, 0x6f, 0x88, 0x4b, 0x2c, 0x6a, 0x05, 0x88, 0xda, 0x65, 0x76, 0xde, 0x9e, 0xfe, 0x09, 0x00, - 0x00, 0xff, 0xff, 0xe6, 0x7c, 0xe1, 0x7d, 0x5f, 0x07, 0x00, 0x00, + // 660 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x95, 0xbf, 0x6f, 0xd3, 0x40, + 0x14, 0xc7, 0xed, 0xfe, 0x88, 0xc8, 0x35, 0x6d, 0xd1, 0xd1, 0xd2, 0xd4, 0xa5, 0x4e, 0x15, 0x18, + 0x4a, 0xa1, 0x76, 0x5b, 0x86, 0x56, 0x45, 0x0c, 0x6d, 0x27, 0x86, 0x48, 0xc8, 0x15, 0x0b, 0x4b, + 0xb1, 0x9d, 0xcb, 0xc5, 0x52, 0xec, 0xb3, 0x7c, 0x76, 0x44, 0x36, 0xc4, 0xc4, 0x08, 0x1b, 0x0b, + 0x52, 0xff, 0x84, 0x4e, 0xfc, 0x0d, 0x65, 0xeb, 0xc8, 0x84, 0x50, 0x32, 0x94, 0x3f, 0x03, 0xd9, + 0x77, 0x71, 0x6c, 0xd7, 0x4e, 0x03, 0x6c, 0xf6, 0xbd, 0xcf, 0xbb, 0xef, 0xf7, 0x3d, 0xbf, 0xf3, + 0x81, 0x35, 0xcb, 0x30, 0x55, 0x93, 0x78, 0x48, 0x35, 0x3b, 0x16, 0x72, 0x7c, 0xb5, 0xbb, 0xab, + 0xfa, 0xef, 0x14, 0xd7, 0x23, 0x3e, 0x81, 0xd0, 0x32, 0x4c, 0x25, 0x0c, 0x2a, 0x2c, 0xa8, 0x74, + 0x77, 0xa5, 0x15, 0x93, 0x50, 0x9b, 0x50, 0xd5, 0xa6, 0x38, 0x64, 0x6d, 0x8a, 0x19, 0x2c, 0x2d, + 0x61, 0x82, 0x49, 0xf4, 0xa8, 0x86, 0x4f, 0x7c, 0x75, 0x15, 0x13, 0x82, 0x3b, 0x48, 0x8d, 0xde, + 0x8c, 0xa0, 0xa5, 0xea, 0x4e, 0x8f, 0x87, 0x6a, 0x39, 0xd2, 0x5c, 0x27, 0x02, 0xea, 0xdf, 0x44, + 0xb0, 0xd8, 0xa0, 0xf8, 0xc4, 0x43, 0xba, 0x8f, 0x4e, 0xa2, 0x08, 0xdc, 0x07, 0x15, 0xc6, 0x9c, + 0x51, 0x5f, 0xf7, 0x51, 0x55, 0xdc, 0x10, 0x37, 0xe7, 0xf6, 0x96, 0x14, 0x26, 0xa3, 0x0c, 0x65, + 0x94, 0x23, 0xa7, 0xa7, 0xcd, 0x31, 0xf2, 0x34, 0x04, 0xe1, 0x0b, 0xb0, 0x68, 0x12, 0x87, 0x22, + 0x87, 0x06, 0x94, 0xe7, 0x4e, 0x8d, 0xc9, 0x5d, 0x88, 0x61, 0x96, 0x7e, 0x1f, 0x94, 0xa8, 0x85, + 0x1d, 0xe4, 0x55, 0xa7, 0x37, 0xc4, 0xcd, 0xb2, 0xc6, 0xdf, 0x0e, 0xef, 0x7d, 0x3c, 0xaf, 0x09, + 0xbf, 0xcf, 0x6b, 0xc2, 0x87, 0xeb, 0x8b, 0x2d, 0xbe, 0x58, 0x5f, 0x05, 0x2b, 0x19, 0xdf, 0x1a, + 0xa2, 0x6e, 0xb8, 0x61, 0xfd, 0x0b, 0xab, 0xe9, 0xb5, 0xdb, 0x1c, 0xd5, 0xb4, 0x06, 0xca, 0xbc, + 0x26, 0xab, 0x19, 0x15, 0x54, 0xd6, 0xee, 0xb0, 0x85, 0x97, 0x4d, 0xf8, 0x1c, 0x2c, 0xf0, 0xa0, + 0x8d, 0x28, 0xd5, 0xf1, 0x78, 0xdb, 0xf3, 0x8c, 0x6d, 0x30, 0xf4, 0x5f, 0x5c, 0x27, 0x9d, 0xc5, + 0xae, 0xbf, 0x4f, 0x81, 0xbb, 0x51, 0x0c, 0x7b, 0x7a, 0x73, 0x22, 0xdb, 0xd9, 0xef, 0x34, 0xf5, + 0x1f, 0xdf, 0x69, 0xfa, 0x2f, 0xbe, 0xd3, 0x0e, 0x58, 0x72, 0x3d, 0x42, 0x5a, 0x67, 0x01, 0xf3, + 0x7a, 0xc6, 0xf6, 0xae, 0xce, 0x6c, 0x88, 0x9b, 0x15, 0x0d, 0x46, 0xb1, 0x74, 0x19, 0x47, 0x60, + 0x3d, 0x93, 0x91, 0x91, 0x9f, 0x8d, 0x52, 0xa5, 0x54, 0x6a, 0xd1, 0x70, 0x94, 0x6e, 0x6f, 0xb3, + 0x04, 0xaa, 0xd9, 0x56, 0xc6, 0x7d, 0xfe, 0x2a, 0x82, 0xe5, 0x06, 0xc5, 0xa7, 0x81, 0x61, 0x5b, + 0x7e, 0xc3, 0xa2, 0x06, 0x6a, 0xeb, 0x5d, 0x8b, 0x04, 0xde, 0xf8, 0x66, 0x1f, 0x80, 0x8a, 0x9d, + 0x80, 0xc7, 0x36, 0x3b, 0x45, 0x16, 0x0e, 0xc8, 0x72, 0x8e, 0xf3, 0xaa, 0x58, 0xaf, 0x81, 0xf5, + 0x5c, 0x7b, 0x71, 0x01, 0xbd, 0xc4, 0x74, 0xbf, 0xd2, 0x3d, 0xdd, 0xa6, 0xf0, 0x01, 0x28, 0xeb, + 0x81, 0xdf, 0x26, 0x9e, 0xe5, 0xf7, 0xb8, 0xf3, 0xd1, 0x02, 0x3c, 0x00, 0x25, 0x37, 0xe2, 0xb8, + 0x69, 0x49, 0xb9, 0xf9, 0xcf, 0x51, 0xd8, 0x4e, 0xc7, 0x33, 0x97, 0x3f, 0x6b, 0x82, 0xc6, 0xf9, + 0xc3, 0x85, 0xd0, 0xda, 0x68, 0xa7, 0xd4, 0xf8, 0xb2, 0x84, 0xa1, 0xab, 0xbd, 0xcf, 0x33, 0x60, + 0xba, 0x41, 0x31, 0x7c, 0x0b, 0x2a, 0xa9, 0x9f, 0xc9, 0xc3, 0x3c, 0xb1, 0xcc, 0xc9, 0x95, 0x9e, + 0x4c, 0x00, 0x0d, 0x95, 0x42, 0x85, 0xd4, 0xd1, 0x2e, 0x52, 0x48, 0x42, 0x85, 0x0a, 0x79, 0x47, + 0x11, 0x9a, 0x60, 0x3e, 0x3d, 0xbf, 0x8f, 0x0a, 0xb3, 0x13, 0x94, 0xf4, 0x74, 0x12, 0x2a, 0x16, + 0xf1, 0x00, 0xcc, 0x99, 0xc1, 0xc7, 0x05, 0x7b, 0xdc, 0x44, 0xa5, 0xdd, 0x89, 0xd1, 0x58, 0xb3, + 0x05, 0x60, 0xb2, 0x60, 0x3e, 0x3d, 0xe3, 0x1b, 0xc8, 0xa0, 0x5b, 0x1a, 0x98, 0x1e, 0x06, 0x69, + 0xf6, 0xfd, 0xf5, 0xc5, 0x96, 0x78, 0xac, 0x5d, 0xf6, 0x65, 0xf1, 0xaa, 0x2f, 0x8b, 0xbf, 0xfa, + 0xb2, 0xf8, 0x69, 0x20, 0x0b, 0x57, 0x03, 0x59, 0xf8, 0x31, 0x90, 0x85, 0x37, 0x07, 0xd8, 0xf2, + 0xdb, 0x81, 0xa1, 0x98, 0xc4, 0x56, 0xf9, 0x65, 0x67, 0x19, 0xe6, 0x36, 0x26, 0x6a, 0x77, 0x5f, + 0xb5, 0x49, 0x33, 0xe8, 0x20, 0xca, 0xee, 0xad, 0x9d, 0xbd, 0x6d, 0x7e, 0x75, 0xf9, 0x3d, 0x17, + 0x51, 0xa3, 0x14, 0x9d, 0xb4, 0x67, 0x7f, 0x02, 0x00, 0x00, 0xff, 0xff, 0x44, 0x4f, 0xa6, 0x1c, + 0x55, 0x07, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. diff --git a/proto/ibc/core/client/v1/tx.proto b/proto/ibc/core/client/v1/tx.proto index ad0622518e2..7d37fd590d3 100644 --- a/proto/ibc/core/client/v1/tx.proto +++ b/proto/ibc/core/client/v1/tx.proto @@ -95,19 +95,20 @@ message MsgUpgradeClientResponse {} // MsgSubmitMisbehaviour defines an sdk.Msg type that submits Evidence for // light client misbehaviour. -// Warning: DEPRECATED +// This message has been deprecated. Use MsgUpdateClient instead. message MsgSubmitMisbehaviour { + option deprecated = true; option (cosmos.msg.v1.signer) = "signer"; option (gogoproto.equal) = false; option (gogoproto.goproto_getters) = false; // client unique identifier - string client_id = 1 [deprecated = true]; + string client_id = 1; // misbehaviour used for freezing the light client - google.protobuf.Any misbehaviour = 2 [deprecated = true]; + google.protobuf.Any misbehaviour = 2; // signer address - string signer = 3 [deprecated = true]; + string signer = 3; } // MsgSubmitMisbehaviourResponse defines the Msg/SubmitMisbehaviour response From 782f43a5311da1ad05fe5f9fc1ebf6dc8899c1a7 Mon Sep 17 00:00:00 2001 From: Jim Fasarakis-Hilliard Date: Tue, 20 Jun 2023 21:48:06 +0300 Subject: [PATCH 4/7] chore: add e2e test for changing controller params. (#3872) --- e2e/tests/interchain_accounts/params_test.go | 90 ++++++++++++++++++++ 1 file changed, 90 insertions(+) create mode 100644 e2e/tests/interchain_accounts/params_test.go diff --git a/e2e/tests/interchain_accounts/params_test.go b/e2e/tests/interchain_accounts/params_test.go new file mode 100644 index 00000000000..7f33a2523d9 --- /dev/null +++ b/e2e/tests/interchain_accounts/params_test.go @@ -0,0 +1,90 @@ +package interchain_accounts + +import ( + "context" + "testing" + + govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" + paramsproposaltypes "github.com/cosmos/cosmos-sdk/x/params/types/proposal" + "github.com/strangelove-ventures/interchaintest/v7/ibc" + "github.com/stretchr/testify/suite" + + "github.com/cosmos/ibc-go/e2e/testsuite" + "github.com/cosmos/ibc-go/e2e/testvalues" + controllertypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller/types" + icatypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/types" + ibctesting "github.com/cosmos/ibc-go/v7/testing" +) + +func TestInterchainAccountsParamsTestSuite(t *testing.T) { + suite.Run(t, new(InterchainAccountsParamsTestSuite)) +} + +type InterchainAccountsParamsTestSuite struct { + testsuite.E2ETestSuite +} + +// QueryControllerParams queries the params for the controller +func (s *InterchainAccountsParamsTestSuite) QueryControllerParams(ctx context.Context, chain ibc.Chain) controllertypes.Params { + queryClient := s.GetChainGRCPClients(chain).ICAControllerQueryClient + res, err := queryClient.Params(ctx, &controllertypes.QueryParamsRequest{}) + s.Require().NoError(err) + + return *res.Params +} + +// TestControllerEnabledParam tests that changing the ControllerEnabled param works as expected +func (s *InterchainAccountsParamsTestSuite) TestControllerEnabledParam() { + t := s.T() + ctx := context.TODO() + + // setup relayers and connection-0 between two chains + // channel-0 is a transfer channel but it will not be used in this test case + _, _ = s.SetupChainsRelayerAndChannel(ctx) + chainA, _ := s.GetChains() + chainAVersion := chainA.Config().Images[0].Version + + // setup controller account on chainA + controllerAccount := s.CreateUserOnChainA(ctx, testvalues.StartingTokenAmount) + controllerAddress := controllerAccount.FormattedAddress() + + t.Run("ensure the controller is enabled", func(t *testing.T) { + params := s.QueryControllerParams(ctx, chainA) + s.Require().True(params.ControllerEnabled) + }) + + t.Run("disable the controller", func(t *testing.T) { + if testvalues.SelfParamsFeatureReleases.IsSupported(chainAVersion) { + authority, err := s.QueryModuleAccountAddress(ctx, govtypes.ModuleName, chainA) + s.Require().NoError(err) + s.Require().NotNil(authority) + + msg := controllertypes.MsgUpdateParams{ + Authority: authority.String(), + Params: controllertypes.NewParams(false), + } + s.ExecuteGovProposalV1(ctx, &msg, chainA, controllerAccount, 1) + } else { + changes := []paramsproposaltypes.ParamChange{ + paramsproposaltypes.NewParamChange(controllertypes.StoreKey, string(controllertypes.KeyControllerEnabled), "false"), + } + + proposal := paramsproposaltypes.NewParameterChangeProposal(ibctesting.Title, ibctesting.Description, changes) + s.ExecuteGovProposal(ctx, chainA, controllerAccount, proposal) + } + }) + + t.Run("ensure controller is disabled", func(t *testing.T) { + params := s.QueryControllerParams(ctx, chainA) + s.Require().False(params.ControllerEnabled) + }) + + t.Run("ensure that broadcasting a MsgRegisterInterchainAccount fails", func(t *testing.T) { + // explicitly set the version string because we don't want to use incentivized channels. + version := icatypes.NewDefaultMetadataString(ibctesting.FirstConnectionID, ibctesting.FirstConnectionID) + msgRegisterAccount := controllertypes.NewMsgRegisterInterchainAccount(ibctesting.FirstConnectionID, controllerAddress, version) + + txResp := s.BroadcastMessages(ctx, chainA, controllerAccount, msgRegisterAccount) + s.AssertTxFailure(txResp, controllertypes.ErrControllerSubModuleDisabled) + }) +} From 487d73cbcd7610e4378b2c66e7de7249804bacd5 Mon Sep 17 00:00:00 2001 From: Jacob Gadikian Date: Wed, 21 Jun 2023 03:20:14 +0800 Subject: [PATCH 5/7] buf mod update (#3885) Co-authored-by: Carlos Rodriguez --- proto/buf.lock | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/proto/buf.lock b/proto/buf.lock index 373656974b8..7906031c41a 100644 --- a/proto/buf.lock +++ b/proto/buf.lock @@ -5,19 +5,24 @@ deps: owner: cosmos repository: cosmos-proto commit: 1935555c206d4afb9e94615dfd0fad31 + digest: shake256:c74d91a3ac7ae07d579e90eee33abf9b29664047ac8816500cf22c081fec0d72d62c89ce0bebafc1f6fec7aa5315be72606717740ca95007248425102c365377 - remote: buf.build owner: cosmos repository: cosmos-sdk commit: 954f7b05f38440fc8250134b15adec47 + digest: shake256:2ab4404fd04a7d1d52df0e2d0f2d477a3d83ffd88d876957bf3fedfd702c8e52833d65b3ce1d89a3c5adf2aab512616b0e4f51d8463f07eda9a8a3317ee3ac54 - remote: buf.build owner: cosmos repository: gogo-proto commit: 34d970b699f84aa382f3c29773a60836 + digest: shake256:3d3bee5229ba579e7d19ffe6e140986a228b48a8c7fe74348f308537ab95e9135210e81812489d42cd8941d33ff71f11583174ccc5972e86e6112924b6ce9f04 - remote: buf.build owner: cosmos repository: ics23 commit: 55085f7c710a45f58fa09947208eb70b + digest: shake256:9bf0bc495b5a11c88d163d39ef521bc4b00bc1374a05758c91d82821bdc61f09e8c2c51dda8452529bf80137f34d852561eacbe9550a59015d51cecb0dacb628 - remote: buf.build owner: googleapis repository: googleapis commit: 8d7204855ec14631a499bd7393ce1970 + digest: shake256:40bf4112960cad01281930beed85829910768e32e80e986791596853eccd42c0cbd9d96690b918f658020d2d427e16f8b6514e2ac7f4a10306fd32e77be44329 From 39adb01a33009ecd95e4ad22379640717832585b Mon Sep 17 00:00:00 2001 From: Jacob Gadikian Date: Wed, 21 Jun 2023 03:37:57 +0800 Subject: [PATCH 6/7] linting: use gci to sort imports (#3887) * gci with custom order * sort with custom order * correct ordering * update go style guide --------- Co-authored-by: Carlos Rodriguez --- .golangci.yml | 22 ++++++++++++++----- docs/dev/go-style-guide.md | 6 ++++- internal/collections/collections_test.go | 3 ++- .../controller/client/cli/query.go | 3 ++- .../controller/client/cli/tx.go | 3 ++- .../controller/ibc_middleware.go | 1 + .../controller/ibc_middleware_test.go | 5 +++-- .../controller/keeper/account.go | 1 + .../controller/keeper/grpc_query.go | 3 ++- .../controller/keeper/handshake.go | 3 ++- .../controller/keeper/handshake_test.go | 1 - .../controller/keeper/keeper.go | 4 +++- .../controller/keeper/migrations.go | 1 + .../controller/keeper/msg_server.go | 1 + .../controller/keeper/msg_server_test.go | 4 +++- .../controller/keeper/relay.go | 3 ++- .../controller/keeper/relay_test.go | 5 +++-- .../controller/migrations/v6/migrations.go | 2 +- .../migrations/v6/migrations_test.go | 5 +++-- .../controller/types/msgs.go | 1 + .../controller/types/msgs_test.go | 5 +++-- .../host/client/cli/cli.go | 3 ++- .../host/client/cli/query.go | 6 +++-- .../host/client/cli/tx.go | 5 +++-- .../host/client/cli/tx_test.go | 3 ++- .../27-interchain-accounts/host/ibc_module.go | 3 ++- .../host/ibc_module_test.go | 8 ++++--- .../host/keeper/account.go | 1 + .../host/keeper/handshake.go | 3 ++- .../host/keeper/handshake_test.go | 3 ++- .../host/keeper/keeper.go | 5 +++-- .../host/keeper/migrations.go | 1 + .../host/keeper/msg_server.go | 1 + .../host/keeper/relay.go | 4 +++- .../host/keeper/relay_test.go | 4 +++- .../27-interchain-accounts/host/types/msgs.go | 1 + .../host/types/msgs_test.go | 3 ++- modules/apps/27-interchain-accounts/module.go | 8 ++++--- .../27-interchain-accounts/module_test.go | 8 ++++--- .../simulation/decoder_test.go | 3 ++- .../simulation/genesis_test.go | 4 +++- .../27-interchain-accounts/types/account.go | 4 +++- .../types/account_test.go | 3 ++- .../27-interchain-accounts/types/codec.go | 4 +++- .../types/codec_test.go | 4 +++- .../types/expected_keepers.go | 2 +- .../27-interchain-accounts/types/metadata.go | 1 + .../27-interchain-accounts/types/packet.go | 1 + modules/apps/29-fee/client/cli/query.go | 3 ++- modules/apps/29-fee/client/cli/tx.go | 3 ++- modules/apps/29-fee/ibc_middleware.go | 3 ++- modules/apps/29-fee/ibc_middleware_test.go | 3 ++- modules/apps/29-fee/ica_test.go | 4 +++- modules/apps/29-fee/keeper/escrow.go | 1 + modules/apps/29-fee/keeper/escrow_test.go | 4 +++- modules/apps/29-fee/keeper/events_test.go | 4 +++- modules/apps/29-fee/keeper/grpc_query.go | 6 +++-- modules/apps/29-fee/keeper/grpc_query_test.go | 4 +++- modules/apps/29-fee/keeper/keeper.go | 5 +++-- modules/apps/29-fee/keeper/keeper_test.go | 4 +++- modules/apps/29-fee/keeper/msg_server.go | 1 + modules/apps/29-fee/keeper/msg_server_test.go | 2 +- modules/apps/29-fee/keeper/relay.go | 3 ++- modules/apps/29-fee/module.go | 8 ++++--- modules/apps/29-fee/types/expected_keepers.go | 2 +- modules/apps/29-fee/types/fee.go | 1 + modules/apps/29-fee/types/fee_test.go | 7 ++++-- modules/apps/29-fee/types/genesis.go | 1 + modules/apps/29-fee/types/genesis_test.go | 6 +++-- modules/apps/29-fee/types/msgs.go | 1 + modules/apps/29-fee/types/msgs_test.go | 6 +++-- modules/apps/transfer/client/cli/cli.go | 3 ++- modules/apps/transfer/client/cli/query.go | 3 ++- modules/apps/transfer/client/cli/tx.go | 3 ++- modules/apps/transfer/ibc_module.go | 3 ++- modules/apps/transfer/ibc_module_test.go | 1 - modules/apps/transfer/keeper/genesis_test.go | 1 + modules/apps/transfer/keeper/grpc_query.go | 6 +++-- .../apps/transfer/keeper/grpc_query_test.go | 1 + .../apps/transfer/keeper/invariants_test.go | 1 + modules/apps/transfer/keeper/keeper.go | 8 ++++--- modules/apps/transfer/keeper/keeper_test.go | 4 +++- .../apps/transfer/keeper/mbt_relay_test.go | 4 +++- .../apps/transfer/keeper/migrations_test.go | 1 + modules/apps/transfer/keeper/msg_server.go | 1 + .../apps/transfer/keeper/msg_server_test.go | 3 ++- modules/apps/transfer/keeper/relay.go | 4 +++- modules/apps/transfer/keeper/relay_test.go | 1 + modules/apps/transfer/module.go | 8 ++++--- .../apps/transfer/simulation/decoder_test.go | 3 ++- .../apps/transfer/simulation/genesis_test.go | 4 +++- modules/apps/transfer/transfer_test.go | 4 +++- modules/apps/transfer/types/codec.go | 2 +- modules/apps/transfer/types/coin.go | 1 + .../apps/transfer/types/expected_keepers.go | 2 +- modules/apps/transfer/types/msgs.go | 1 + modules/apps/transfer/types/msgs_test.go | 4 +++- modules/apps/transfer/types/packet.go | 1 + modules/apps/transfer/types/trace.go | 4 +++- .../transfer/types/transfer_authorization.go | 1 + .../types/transfer_authorization_test.go | 2 ++ modules/core/02-client/abci_test.go | 8 ++++--- modules/core/02-client/client/cli/cli.go | 3 ++- modules/core/02-client/client/cli/query.go | 3 ++- modules/core/02-client/client/cli/tx.go | 3 ++- modules/core/02-client/client/utils/utils.go | 4 +++- modules/core/02-client/keeper/client.go | 4 +++- modules/core/02-client/keeper/grpc_query.go | 6 +++-- modules/core/02-client/keeper/keeper.go | 6 +++-- modules/core/02-client/keeper/keeper_test.go | 12 ++++++---- modules/core/02-client/keeper/proposal.go | 4 +++- .../core/02-client/migrations/v7/genesis.go | 1 + modules/core/02-client/migrations/v7/store.go | 1 + .../02-client/migrations/v7/store_test.go | 3 ++- modules/core/02-client/proposal_handler.go | 1 + .../core/02-client/proposal_handler_test.go | 1 + .../core/02-client/simulation/decoder_test.go | 3 ++- modules/core/02-client/types/client.go | 4 +++- modules/core/02-client/types/codec.go | 4 +++- modules/core/02-client/types/height.go | 1 + modules/core/02-client/types/msgs.go | 1 + modules/core/02-client/types/msgs_test.go | 3 ++- modules/core/02-client/types/proposal.go | 1 + .../core/03-connection/client/cli/query.go | 3 ++- .../core/03-connection/client/utils/utils.go | 1 + .../core/03-connection/keeper/grpc_query.go | 6 +++-- .../core/03-connection/keeper/handshake.go | 1 + modules/core/03-connection/keeper/keeper.go | 4 +++- modules/core/03-connection/keeper/verify.go | 1 + .../03-connection/simulation/decoder_test.go | 3 ++- modules/core/03-connection/types/msgs.go | 1 + modules/core/03-connection/types/msgs_test.go | 12 +++++----- modules/core/04-channel/client/cli/cli.go | 3 ++- modules/core/04-channel/client/cli/query.go | 3 ++- modules/core/04-channel/client/utils/utils.go | 1 + modules/core/04-channel/keeper/grpc_query.go | 6 +++-- modules/core/04-channel/keeper/handshake.go | 3 ++- .../core/04-channel/keeper/handshake_test.go | 1 - modules/core/04-channel/keeper/keeper.go | 7 +++--- modules/core/04-channel/keeper/packet.go | 3 ++- modules/core/04-channel/keeper/packet_test.go | 2 +- modules/core/04-channel/keeper/timeout.go | 3 ++- .../core/04-channel/keeper/timeout_test.go | 2 +- .../04-channel/simulation/decoder_test.go | 3 ++- .../core/04-channel/types/acknowledgement.go | 1 + .../04-channel/types/acknowledgement_test.go | 4 +++- .../core/04-channel/types/expected_keepers.go | 2 +- modules/core/04-channel/types/msgs.go | 1 + modules/core/04-channel/types/msgs_test.go | 10 +++++---- modules/core/04-channel/types/packet.go | 1 + modules/core/04-channel/types/packet_test.go | 3 ++- modules/core/05-port/keeper/keeper.go | 5 +++-- modules/core/05-port/keeper/keeper_test.go | 6 +++-- modules/core/05-port/types/module.go | 2 +- .../23-commitment/types/commitment_test.go | 8 ++++--- modules/core/23-commitment/types/merkle.go | 6 +++-- .../core/23-commitment/types/merkle_test.go | 3 ++- modules/core/23-commitment/types/utils.go | 4 +++- .../core/23-commitment/types/utils_test.go | 3 ++- modules/core/ante/ante_test.go | 3 ++- modules/core/client/cli/cli.go | 3 ++- modules/core/client/query.go | 3 ++- modules/core/exported/client.go | 3 ++- modules/core/exported/expected_keepers.go | 1 + modules/core/genesis_test.go | 6 +++-- modules/core/keeper/keeper.go | 2 +- modules/core/keeper/keeper_test.go | 5 +++-- modules/core/keeper/msg_server.go | 4 +++- modules/core/migrations/v7/genesis_test.go | 3 ++- modules/core/module.go | 8 ++++--- modules/core/simulation/decoder_test.go | 3 ++- modules/core/simulation/genesis_test.go | 4 +++- .../06-solomachine/client_state.go | 1 + modules/light-clients/06-solomachine/codec.go | 1 + .../06-solomachine/consensus_state.go | 1 + .../light-clients/06-solomachine/header.go | 1 + .../06-solomachine/misbehaviour_handle.go | 4 ++-- .../light-clients/06-solomachine/module.go | 5 +++-- modules/light-clients/06-solomachine/proof.go | 1 + .../06-solomachine/proposal_handle.go | 1 + .../06-solomachine/solomachine_test.go | 5 +++-- .../light-clients/06-solomachine/update.go | 1 + .../07-tendermint/client_state.go | 9 +++++--- .../07-tendermint/client_state_test.go | 3 ++- .../07-tendermint/consensus_state.go | 1 + modules/light-clients/07-tendermint/header.go | 1 + .../migrations/expected_keepers.go | 3 ++- .../07-tendermint/migrations/migrations.go | 1 + .../07-tendermint/misbehaviour.go | 1 + .../07-tendermint/misbehaviour_handle.go | 4 +++- modules/light-clients/07-tendermint/module.go | 5 +++-- .../07-tendermint/proposal_handle.go | 1 + .../07-tendermint/tendermint_test.go | 8 ++++--- modules/light-clients/07-tendermint/update.go | 6 +++-- .../07-tendermint/update_test.go | 3 ++- .../light-clients/07-tendermint/upgrade.go | 1 + .../09-localhost/client_state.go | 1 + testing/app.go | 17 ++++++++------ testing/chain.go | 19 +++++++++------- testing/chain_test.go | 4 +++- testing/coordinator.go | 3 ++- testing/endpoint.go | 3 ++- testing/events.go | 3 ++- testing/mock/ibc_app.go | 2 +- testing/mock/ibc_module.go | 2 +- testing/mock/mock.go | 10 +++++---- testing/mock/privval.go | 7 +++--- testing/mock/privval_test.go | 3 ++- testing/simapp/ante_handler.go | 1 + testing/simapp/app.go | 21 ++++++++++-------- testing/simapp/export.go | 3 ++- testing/simapp/genesis_account_test.go | 6 +++-- testing/simapp/sim_bench_test.go | 3 ++- testing/simapp/sim_test.go | 14 +++++++----- testing/simapp/simd/cmd/cmd_test.go | 3 ++- testing/simapp/simd/cmd/root.go | 16 ++++++++------ testing/simapp/state.go | 6 +++-- testing/simapp/test_helpers.go | 15 ++++++++----- testing/simapp/upgrades/upgrades.go | 2 +- testing/simapp/utils.go | 3 ++- testing/simapp/utils_test.go | 3 ++- testing/solomachine.go | 4 +++- testing/utils.go | 3 ++- testing/values.go | 1 + 224 files changed, 570 insertions(+), 274 deletions(-) diff --git a/.golangci.yml b/.golangci.yml index 4a0022ce9df..71e76f042a9 100644 --- a/.golangci.yml +++ b/.golangci.yml @@ -9,6 +9,7 @@ linters: - dogsled - exportloopref - errcheck + - gci - goconst - gocritic - gofumpt @@ -29,27 +30,38 @@ linters: issues: exclude-rules: - - text: "unused-parameter" + - text: 'unused-parameter' linters: - revive - - text: "SA1019:" + - text: 'SA1019:' linters: - staticcheck - - text: "Use of weak random number generator" + - text: 'Use of weak random number generator' linters: - gosec - - text: "ST1003:" + - text: 'ST1003:' linters: - stylecheck # FIXME: Disabled until golangci-lint updates stylecheck with this fix: # https://github.com/dominikh/go-tools/issues/389 - - text: "ST1016:" + - text: 'ST1016:' linters: - stylecheck max-issues-per-linter: 10000 max-same-issues: 10000 linters-settings: + gci: + sections: + - standard # Standard section: captures all standard packages. + - default # Default section: contains all imports that could not be matched to another section type. + - blank # blank imports + - dot # dot imports + - prefix(cosmossdk.io) + - prefix(github.com/cosmos/cosmos-sdk) + - prefix(github.com/cometbft/cometbft) + - prefix(github.com/cosmos/ibc-go) + custom-order: true dogsled: max-blank-identifiers: 3 maligned: diff --git a/docs/dev/go-style-guide.md b/docs/dev/go-style-guide.md index 7cf50598000..7301e49edfa 100644 --- a/docs/dev/go-style-guide.md +++ b/docs/dev/go-style-guide.md @@ -69,7 +69,7 @@ type middleware struct { ## Importing libraries - Use [goimports](https://godoc.org/golang.org/x/tools/cmd/goimports). -- Separate imports into blocks: one for the standard lib, one for external libs and one for application libs. For example: +- Separate imports into blocks. For example: ```go import ( @@ -79,6 +79,8 @@ import ( // external library imports "github.com/stretchr/testify/require" + + // Cosmos-SDK imports abci "github.com/cometbft/cometbft/abci/types" // ibc-go library imports @@ -86,6 +88,8 @@ import ( ) ``` +Run `make lint-fix` to get the imports ordered and grouped automatically. + ## Dependencies - Dependencies should be pinned by a release tag, or specific commit, to avoid breaking `go get` when external dependencies are updated. diff --git a/internal/collections/collections_test.go b/internal/collections/collections_test.go index faf16fa6bc3..9fb3664c372 100644 --- a/internal/collections/collections_test.go +++ b/internal/collections/collections_test.go @@ -3,8 +3,9 @@ package collections_test import ( "testing" - "github.com/cosmos/ibc-go/v7/internal/collections" "github.com/stretchr/testify/require" + + "github.com/cosmos/ibc-go/v7/internal/collections" ) func TestContainsString(t *testing.T) { diff --git a/modules/apps/27-interchain-accounts/controller/client/cli/query.go b/modules/apps/27-interchain-accounts/controller/client/cli/query.go index ca71a96652a..4a18fcd05fa 100644 --- a/modules/apps/27-interchain-accounts/controller/client/cli/query.go +++ b/modules/apps/27-interchain-accounts/controller/client/cli/query.go @@ -3,10 +3,11 @@ package cli import ( "fmt" + "github.com/spf13/cobra" + "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cosmos/cosmos-sdk/version" - "github.com/spf13/cobra" "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller/types" ) diff --git a/modules/apps/27-interchain-accounts/controller/client/cli/tx.go b/modules/apps/27-interchain-accounts/controller/client/cli/tx.go index 44094f7b152..232d22b07c9 100644 --- a/modules/apps/27-interchain-accounts/controller/client/cli/tx.go +++ b/modules/apps/27-interchain-accounts/controller/client/cli/tx.go @@ -5,11 +5,12 @@ import ( "os" "strings" + "github.com/spf13/cobra" + "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cosmos/cosmos-sdk/client/tx" "github.com/cosmos/cosmos-sdk/codec" - "github.com/spf13/cobra" "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller/types" icatypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/types" diff --git a/modules/apps/27-interchain-accounts/controller/ibc_middleware.go b/modules/apps/27-interchain-accounts/controller/ibc_middleware.go index 3e767a24614..1338b3f252f 100644 --- a/modules/apps/27-interchain-accounts/controller/ibc_middleware.go +++ b/modules/apps/27-interchain-accounts/controller/ibc_middleware.go @@ -2,6 +2,7 @@ package controller import ( errorsmod "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" diff --git a/modules/apps/27-interchain-accounts/controller/ibc_middleware_test.go b/modules/apps/27-interchain-accounts/controller/ibc_middleware_test.go index 663a72b6dcc..cf049e3ae50 100644 --- a/modules/apps/27-interchain-accounts/controller/ibc_middleware_test.go +++ b/modules/apps/27-interchain-accounts/controller/ibc_middleware_test.go @@ -4,10 +4,11 @@ import ( "fmt" "testing" - sdk "github.com/cosmos/cosmos-sdk/types" - capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" "github.com/stretchr/testify/suite" + sdk "github.com/cosmos/cosmos-sdk/types" + + capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller" controllerkeeper "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller/keeper" "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller/types" diff --git a/modules/apps/27-interchain-accounts/controller/keeper/account.go b/modules/apps/27-interchain-accounts/controller/keeper/account.go index 189f5c6e903..9ce0f5211a6 100644 --- a/modules/apps/27-interchain-accounts/controller/keeper/account.go +++ b/modules/apps/27-interchain-accounts/controller/keeper/account.go @@ -2,6 +2,7 @@ package keeper import ( errorsmod "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" diff --git a/modules/apps/27-interchain-accounts/controller/keeper/grpc_query.go b/modules/apps/27-interchain-accounts/controller/keeper/grpc_query.go index 78e0f37446e..2b983546c61 100644 --- a/modules/apps/27-interchain-accounts/controller/keeper/grpc_query.go +++ b/modules/apps/27-interchain-accounts/controller/keeper/grpc_query.go @@ -3,10 +3,11 @@ package keeper import ( "context" - sdk "github.com/cosmos/cosmos-sdk/types" "google.golang.org/grpc/codes" "google.golang.org/grpc/status" + sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller/types" icatypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/types" ) diff --git a/modules/apps/27-interchain-accounts/controller/keeper/handshake.go b/modules/apps/27-interchain-accounts/controller/keeper/handshake.go index 04b8b97b6df..1bc75623f71 100644 --- a/modules/apps/27-interchain-accounts/controller/keeper/handshake.go +++ b/modules/apps/27-interchain-accounts/controller/keeper/handshake.go @@ -5,9 +5,10 @@ import ( "strings" errorsmod "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" - capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" + capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" icatypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/types" channeltypes "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" ) diff --git a/modules/apps/27-interchain-accounts/controller/keeper/handshake_test.go b/modules/apps/27-interchain-accounts/controller/keeper/handshake_test.go index 9e29dc0a93c..1f3929154f7 100644 --- a/modules/apps/27-interchain-accounts/controller/keeper/handshake_test.go +++ b/modules/apps/27-interchain-accounts/controller/keeper/handshake_test.go @@ -2,7 +2,6 @@ package keeper_test import ( capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" - icatypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/types" channeltypes "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" host "github.com/cosmos/ibc-go/v7/modules/core/24-host" diff --git a/modules/apps/27-interchain-accounts/controller/keeper/keeper.go b/modules/apps/27-interchain-accounts/controller/keeper/keeper.go index 8b2d6aad48e..9aa172a6f15 100644 --- a/modules/apps/27-interchain-accounts/controller/keeper/keeper.go +++ b/modules/apps/27-interchain-accounts/controller/keeper/keeper.go @@ -6,12 +6,14 @@ import ( "strings" errorsmod "cosmossdk.io/errors" - "github.com/cometbft/cometbft/libs/log" + "github.com/cosmos/cosmos-sdk/codec" storetypes "github.com/cosmos/cosmos-sdk/store/types" sdk "github.com/cosmos/cosmos-sdk/types" paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" + "github.com/cometbft/cometbft/libs/log" + capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller/types" genesistypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/genesis/types" diff --git a/modules/apps/27-interchain-accounts/controller/keeper/migrations.go b/modules/apps/27-interchain-accounts/controller/keeper/migrations.go index 1c1323a6d07..896bd3575cb 100644 --- a/modules/apps/27-interchain-accounts/controller/keeper/migrations.go +++ b/modules/apps/27-interchain-accounts/controller/keeper/migrations.go @@ -4,6 +4,7 @@ import ( "fmt" errorsmod "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" diff --git a/modules/apps/27-interchain-accounts/controller/keeper/msg_server.go b/modules/apps/27-interchain-accounts/controller/keeper/msg_server.go index d1bbc7205ff..df22e40b34b 100644 --- a/modules/apps/27-interchain-accounts/controller/keeper/msg_server.go +++ b/modules/apps/27-interchain-accounts/controller/keeper/msg_server.go @@ -4,6 +4,7 @@ import ( "context" errorsmod "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller/types" diff --git a/modules/apps/27-interchain-accounts/controller/keeper/msg_server_test.go b/modules/apps/27-interchain-accounts/controller/keeper/msg_server_test.go index f929a74a55a..ef55faef863 100644 --- a/modules/apps/27-interchain-accounts/controller/keeper/msg_server_test.go +++ b/modules/apps/27-interchain-accounts/controller/keeper/msg_server_test.go @@ -3,10 +3,12 @@ package keeper_test import ( "time" + "github.com/cosmos/gogoproto/proto" + sdkmath "cosmossdk.io/math" + sdk "github.com/cosmos/cosmos-sdk/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" - "github.com/cosmos/gogoproto/proto" "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller/keeper" "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller/types" diff --git a/modules/apps/27-interchain-accounts/controller/keeper/relay.go b/modules/apps/27-interchain-accounts/controller/keeper/relay.go index 9ebe2ed85f8..412d2cb2f0c 100644 --- a/modules/apps/27-interchain-accounts/controller/keeper/relay.go +++ b/modules/apps/27-interchain-accounts/controller/keeper/relay.go @@ -2,9 +2,10 @@ package keeper import ( errorsmod "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" - capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" + capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" icatypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/types" clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" channeltypes "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" diff --git a/modules/apps/27-interchain-accounts/controller/keeper/relay_test.go b/modules/apps/27-interchain-accounts/controller/keeper/relay_test.go index d5deeb41d19..c363643a484 100644 --- a/modules/apps/27-interchain-accounts/controller/keeper/relay_test.go +++ b/modules/apps/27-interchain-accounts/controller/keeper/relay_test.go @@ -1,11 +1,12 @@ package keeper_test import ( + "github.com/cosmos/gogoproto/proto" + sdkmath "cosmossdk.io/math" - sdk "github.com/cosmos/cosmos-sdk/types" + sdk "github.com/cosmos/cosmos-sdk/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" - "github.com/cosmos/gogoproto/proto" icatypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/types" clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" diff --git a/modules/apps/27-interchain-accounts/controller/migrations/v6/migrations.go b/modules/apps/27-interchain-accounts/controller/migrations/v6/migrations.go index 96a5d76fa91..0208c97eb49 100644 --- a/modules/apps/27-interchain-accounts/controller/migrations/v6/migrations.go +++ b/modules/apps/27-interchain-accounts/controller/migrations/v6/migrations.go @@ -5,9 +5,9 @@ import ( "github.com/cosmos/cosmos-sdk/store/prefix" storetypes "github.com/cosmos/cosmos-sdk/store/types" sdk "github.com/cosmos/cosmos-sdk/types" + capabilitykeeper "github.com/cosmos/ibc-go/modules/capability/keeper" capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" - controllertypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller/types" ibcexported "github.com/cosmos/ibc-go/v7/modules/core/exported" ) diff --git a/modules/apps/27-interchain-accounts/controller/migrations/v6/migrations_test.go b/modules/apps/27-interchain-accounts/controller/migrations/v6/migrations_test.go index 872d1a24039..c079459c0aa 100644 --- a/modules/apps/27-interchain-accounts/controller/migrations/v6/migrations_test.go +++ b/modules/apps/27-interchain-accounts/controller/migrations/v6/migrations_test.go @@ -3,10 +3,11 @@ package v6_test import ( "testing" - sdk "github.com/cosmos/cosmos-sdk/types" - capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" "github.com/stretchr/testify/suite" + sdk "github.com/cosmos/cosmos-sdk/types" + + capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" v6 "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller/migrations/v6" "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller/types" icatypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/types" diff --git a/modules/apps/27-interchain-accounts/controller/types/msgs.go b/modules/apps/27-interchain-accounts/controller/types/msgs.go index 39f55c96078..545bec0a15a 100644 --- a/modules/apps/27-interchain-accounts/controller/types/msgs.go +++ b/modules/apps/27-interchain-accounts/controller/types/msgs.go @@ -4,6 +4,7 @@ import ( "strings" errorsmod "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" icatypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/types" diff --git a/modules/apps/27-interchain-accounts/controller/types/msgs_test.go b/modules/apps/27-interchain-accounts/controller/types/msgs_test.go index b843494d115..2a84109fad0 100644 --- a/modules/apps/27-interchain-accounts/controller/types/msgs_test.go +++ b/modules/apps/27-interchain-accounts/controller/types/msgs_test.go @@ -3,11 +3,12 @@ package types_test import ( "testing" - sdk "github.com/cosmos/cosmos-sdk/types" - banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" "github.com/cosmos/gogoproto/proto" "github.com/stretchr/testify/require" + sdk "github.com/cosmos/cosmos-sdk/types" + banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" + "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller/types" icatypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/types" feetypes "github.com/cosmos/ibc-go/v7/modules/apps/29-fee/types" diff --git a/modules/apps/27-interchain-accounts/host/client/cli/cli.go b/modules/apps/27-interchain-accounts/host/client/cli/cli.go index 23d2dc2e83a..1eceb6159a4 100644 --- a/modules/apps/27-interchain-accounts/host/client/cli/cli.go +++ b/modules/apps/27-interchain-accounts/host/client/cli/cli.go @@ -1,8 +1,9 @@ package cli import ( - "github.com/cosmos/cosmos-sdk/client" "github.com/spf13/cobra" + + "github.com/cosmos/cosmos-sdk/client" ) // GetQueryCmd returns the query commands for the ICA host submodule diff --git a/modules/apps/27-interchain-accounts/host/client/cli/query.go b/modules/apps/27-interchain-accounts/host/client/cli/query.go index 327f51538fc..36e928fe795 100644 --- a/modules/apps/27-interchain-accounts/host/client/cli/query.go +++ b/modules/apps/27-interchain-accounts/host/client/cli/query.go @@ -4,13 +4,15 @@ import ( "fmt" "strconv" - abci "github.com/cometbft/cometbft/abci/types" + "github.com/spf13/cobra" + "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/version" "github.com/cosmos/cosmos-sdk/x/auth/tx" - "github.com/spf13/cobra" + + abci "github.com/cometbft/cometbft/abci/types" "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/host/types" icatypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/types" diff --git a/modules/apps/27-interchain-accounts/host/client/cli/tx.go b/modules/apps/27-interchain-accounts/host/client/cli/tx.go index 8d74f1ce66c..159dff22449 100644 --- a/modules/apps/27-interchain-accounts/host/client/cli/tx.go +++ b/modules/apps/27-interchain-accounts/host/client/cli/tx.go @@ -4,12 +4,13 @@ import ( "encoding/json" "fmt" + "github.com/cosmos/gogoproto/proto" + "github.com/spf13/cobra" + "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/version" - "github.com/cosmos/gogoproto/proto" - "github.com/spf13/cobra" icatypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/types" ) diff --git a/modules/apps/27-interchain-accounts/host/client/cli/tx_test.go b/modules/apps/27-interchain-accounts/host/client/cli/tx_test.go index c5d8d56e1dd..a1ca3e0f547 100644 --- a/modules/apps/27-interchain-accounts/host/client/cli/tx_test.go +++ b/modules/apps/27-interchain-accounts/host/client/cli/tx_test.go @@ -4,12 +4,13 @@ import ( "fmt" "testing" + "github.com/stretchr/testify/require" + "github.com/cosmos/cosmos-sdk/codec" codectypes "github.com/cosmos/cosmos-sdk/codec/types" sdk "github.com/cosmos/cosmos-sdk/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" - "github.com/stretchr/testify/require" icatypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/types" ) diff --git a/modules/apps/27-interchain-accounts/host/ibc_module.go b/modules/apps/27-interchain-accounts/host/ibc_module.go index 5ec6b5f78b2..012130c2efc 100644 --- a/modules/apps/27-interchain-accounts/host/ibc_module.go +++ b/modules/apps/27-interchain-accounts/host/ibc_module.go @@ -4,9 +4,10 @@ import ( "fmt" errorsmod "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" - capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" + capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/host/keeper" "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/host/types" icatypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/types" diff --git a/modules/apps/27-interchain-accounts/host/ibc_module_test.go b/modules/apps/27-interchain-accounts/host/ibc_module_test.go index 4428d453f59..373bdbc7226 100644 --- a/modules/apps/27-interchain-accounts/host/ibc_module_test.go +++ b/modules/apps/27-interchain-accounts/host/ibc_module_test.go @@ -4,14 +4,16 @@ import ( "fmt" "testing" + "github.com/cosmos/gogoproto/proto" + "github.com/stretchr/testify/suite" + sdkmath "cosmossdk.io/math" + codectypes "github.com/cosmos/cosmos-sdk/codec/types" sdk "github.com/cosmos/cosmos-sdk/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" - "github.com/cosmos/gogoproto/proto" - capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" - "github.com/stretchr/testify/suite" + capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/host/types" icatypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/types" feetypes "github.com/cosmos/ibc-go/v7/modules/apps/29-fee/types" diff --git a/modules/apps/27-interchain-accounts/host/keeper/account.go b/modules/apps/27-interchain-accounts/host/keeper/account.go index 3b02d3c7cae..e7fd35fb236 100644 --- a/modules/apps/27-interchain-accounts/host/keeper/account.go +++ b/modules/apps/27-interchain-accounts/host/keeper/account.go @@ -2,6 +2,7 @@ package keeper import ( errorsmod "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" diff --git a/modules/apps/27-interchain-accounts/host/keeper/handshake.go b/modules/apps/27-interchain-accounts/host/keeper/handshake.go index c82a826efa5..8d43071ac2a 100644 --- a/modules/apps/27-interchain-accounts/host/keeper/handshake.go +++ b/modules/apps/27-interchain-accounts/host/keeper/handshake.go @@ -4,9 +4,10 @@ import ( "fmt" errorsmod "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" - capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" + capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" icatypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/types" channeltypes "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" host "github.com/cosmos/ibc-go/v7/modules/core/24-host" diff --git a/modules/apps/27-interchain-accounts/host/keeper/handshake_test.go b/modules/apps/27-interchain-accounts/host/keeper/handshake_test.go index 7f31c3bcb31..034550a7d50 100644 --- a/modules/apps/27-interchain-accounts/host/keeper/handshake_test.go +++ b/modules/apps/27-interchain-accounts/host/keeper/handshake_test.go @@ -2,10 +2,11 @@ package keeper_test import ( sdkmath "cosmossdk.io/math" + sdk "github.com/cosmos/cosmos-sdk/types" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" - capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" + capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" hosttypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/host/types" icatypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/types" channeltypes "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" diff --git a/modules/apps/27-interchain-accounts/host/keeper/keeper.go b/modules/apps/27-interchain-accounts/host/keeper/keeper.go index c8f806486d6..1dd233aa76b 100644 --- a/modules/apps/27-interchain-accounts/host/keeper/keeper.go +++ b/modules/apps/27-interchain-accounts/host/keeper/keeper.go @@ -4,13 +4,14 @@ import ( "fmt" "strings" - "github.com/cometbft/cometbft/libs/log" "github.com/cosmos/cosmos-sdk/codec" storetypes "github.com/cosmos/cosmos-sdk/store/types" sdk "github.com/cosmos/cosmos-sdk/types" paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" - capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" + "github.com/cometbft/cometbft/libs/log" + + capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" genesistypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/genesis/types" "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/host/types" icatypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/types" diff --git a/modules/apps/27-interchain-accounts/host/keeper/migrations.go b/modules/apps/27-interchain-accounts/host/keeper/migrations.go index 558af284c49..d1d5a129e3d 100644 --- a/modules/apps/27-interchain-accounts/host/keeper/migrations.go +++ b/modules/apps/27-interchain-accounts/host/keeper/migrations.go @@ -2,6 +2,7 @@ package keeper import ( sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/host/types" ) diff --git a/modules/apps/27-interchain-accounts/host/keeper/msg_server.go b/modules/apps/27-interchain-accounts/host/keeper/msg_server.go index 388f78c744a..e9bebdf7193 100644 --- a/modules/apps/27-interchain-accounts/host/keeper/msg_server.go +++ b/modules/apps/27-interchain-accounts/host/keeper/msg_server.go @@ -4,6 +4,7 @@ import ( "context" errorsmod "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/host/types" diff --git a/modules/apps/27-interchain-accounts/host/keeper/relay.go b/modules/apps/27-interchain-accounts/host/keeper/relay.go index aa61d7004b7..2f0037558ea 100644 --- a/modules/apps/27-interchain-accounts/host/keeper/relay.go +++ b/modules/apps/27-interchain-accounts/host/keeper/relay.go @@ -1,10 +1,12 @@ package keeper import ( + "github.com/cosmos/gogoproto/proto" + errorsmod "cosmossdk.io/errors" + codectypes "github.com/cosmos/cosmos-sdk/codec/types" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/cosmos/gogoproto/proto" "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/host/types" icatypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/types" 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 7f0f298c452..034263f1039 100644 --- a/modules/apps/27-interchain-accounts/host/keeper/relay_test.go +++ b/modules/apps/27-interchain-accounts/host/keeper/relay_test.go @@ -1,7 +1,10 @@ package keeper_test import ( + "github.com/cosmos/gogoproto/proto" + sdkmath "cosmossdk.io/math" + codectypes "github.com/cosmos/cosmos-sdk/codec/types" sdk "github.com/cosmos/cosmos-sdk/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" @@ -9,7 +12,6 @@ import ( govv1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1" govtypes "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" - "github.com/cosmos/gogoproto/proto" "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/host/types" icatypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/types" diff --git a/modules/apps/27-interchain-accounts/host/types/msgs.go b/modules/apps/27-interchain-accounts/host/types/msgs.go index 2af6d52a050..0c851060c44 100644 --- a/modules/apps/27-interchain-accounts/host/types/msgs.go +++ b/modules/apps/27-interchain-accounts/host/types/msgs.go @@ -2,6 +2,7 @@ package types import ( errorsmod "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" ibcerrors "github.com/cosmos/ibc-go/v7/modules/core/errors" diff --git a/modules/apps/27-interchain-accounts/host/types/msgs_test.go b/modules/apps/27-interchain-accounts/host/types/msgs_test.go index 24d817d3a9f..2cfda22f526 100644 --- a/modules/apps/27-interchain-accounts/host/types/msgs_test.go +++ b/modules/apps/27-interchain-accounts/host/types/msgs_test.go @@ -3,9 +3,10 @@ package types_test import ( "testing" - sdk "github.com/cosmos/cosmos-sdk/types" "github.com/stretchr/testify/require" + sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/host/types" ibctesting "github.com/cosmos/ibc-go/v7/testing" ) diff --git a/modules/apps/27-interchain-accounts/module.go b/modules/apps/27-interchain-accounts/module.go index d5fc60b3da8..31e58cfbcb8 100644 --- a/modules/apps/27-interchain-accounts/module.go +++ b/modules/apps/27-interchain-accounts/module.go @@ -5,15 +5,17 @@ import ( "encoding/json" "fmt" - abci "github.com/cometbft/cometbft/abci/types" + "github.com/grpc-ecosystem/grpc-gateway/runtime" + "github.com/spf13/cobra" + "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/codec" codectypes "github.com/cosmos/cosmos-sdk/codec/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" simtypes "github.com/cosmos/cosmos-sdk/types/simulation" - "github.com/grpc-ecosystem/grpc-gateway/runtime" - "github.com/spf13/cobra" + + abci "github.com/cometbft/cometbft/abci/types" "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/client/cli" controllerkeeper "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller/keeper" diff --git a/modules/apps/27-interchain-accounts/module_test.go b/modules/apps/27-interchain-accounts/module_test.go index 461091b996d..7e9c6688df2 100644 --- a/modules/apps/27-interchain-accounts/module_test.go +++ b/modules/apps/27-interchain-accounts/module_test.go @@ -3,12 +3,14 @@ package ica_test import ( "testing" + "github.com/stretchr/testify/suite" + + "github.com/cosmos/cosmos-sdk/baseapp" + simtestutil "github.com/cosmos/cosmos-sdk/testutil/sims" + dbm "github.com/cometbft/cometbft-db" "github.com/cometbft/cometbft/libs/log" tmproto "github.com/cometbft/cometbft/proto/tendermint/types" - "github.com/cosmos/cosmos-sdk/baseapp" - simtestutil "github.com/cosmos/cosmos-sdk/testutil/sims" - "github.com/stretchr/testify/suite" ica "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts" controllertypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller/types" diff --git a/modules/apps/27-interchain-accounts/simulation/decoder_test.go b/modules/apps/27-interchain-accounts/simulation/decoder_test.go index 81e899b620e..ae54a74c00c 100644 --- a/modules/apps/27-interchain-accounts/simulation/decoder_test.go +++ b/modules/apps/27-interchain-accounts/simulation/decoder_test.go @@ -4,9 +4,10 @@ import ( "fmt" "testing" - "github.com/cosmos/cosmos-sdk/types/kv" "github.com/stretchr/testify/require" + "github.com/cosmos/cosmos-sdk/types/kv" + "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/simulation" "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/types" ibctesting "github.com/cosmos/ibc-go/v7/testing" diff --git a/modules/apps/27-interchain-accounts/simulation/genesis_test.go b/modules/apps/27-interchain-accounts/simulation/genesis_test.go index ac38cc936c4..5072865e22c 100644 --- a/modules/apps/27-interchain-accounts/simulation/genesis_test.go +++ b/modules/apps/27-interchain-accounts/simulation/genesis_test.go @@ -5,13 +5,15 @@ import ( "math/rand" "testing" + "github.com/stretchr/testify/require" + sdkmath "cosmossdk.io/math" + "github.com/cosmos/cosmos-sdk/codec" codectypes "github.com/cosmos/cosmos-sdk/codec/types" cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" "github.com/cosmos/cosmos-sdk/types/module" simtypes "github.com/cosmos/cosmos-sdk/types/simulation" - "github.com/stretchr/testify/require" genesistypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/genesis/types" "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/simulation" diff --git a/modules/apps/27-interchain-accounts/types/account.go b/modules/apps/27-interchain-accounts/types/account.go index 472b509818c..5fc1466e52d 100644 --- a/modules/apps/27-interchain-accounts/types/account.go +++ b/modules/apps/27-interchain-accounts/types/account.go @@ -5,12 +5,14 @@ import ( "regexp" "strings" + yaml "gopkg.in/yaml.v2" + errorsmod "cosmossdk.io/errors" + crypto "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" sdkaddress "github.com/cosmos/cosmos-sdk/types/address" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" - yaml "gopkg.in/yaml.v2" ) var ( diff --git a/modules/apps/27-interchain-accounts/types/account_test.go b/modules/apps/27-interchain-accounts/types/account_test.go index 8acef7e33a9..50eadc8aad3 100644 --- a/modules/apps/27-interchain-accounts/types/account_test.go +++ b/modules/apps/27-interchain-accounts/types/account_test.go @@ -5,10 +5,11 @@ import ( "fmt" "testing" + "github.com/stretchr/testify/suite" + "github.com/cosmos/cosmos-sdk/crypto/keys/secp256k1" sdk "github.com/cosmos/cosmos-sdk/types" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" - "github.com/stretchr/testify/suite" "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/types" ibctesting "github.com/cosmos/ibc-go/v7/testing" diff --git a/modules/apps/27-interchain-accounts/types/codec.go b/modules/apps/27-interchain-accounts/types/codec.go index b0ba7b8902b..4456173c79a 100644 --- a/modules/apps/27-interchain-accounts/types/codec.go +++ b/modules/apps/27-interchain-accounts/types/codec.go @@ -1,12 +1,14 @@ package types import ( + "github.com/cosmos/gogoproto/proto" + errorsmod "cosmossdk.io/errors" + "github.com/cosmos/cosmos-sdk/codec" codectypes "github.com/cosmos/cosmos-sdk/codec/types" sdk "github.com/cosmos/cosmos-sdk/types" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" - "github.com/cosmos/gogoproto/proto" ) // ModuleCdc references the global interchain accounts module codec. Note, the codec diff --git a/modules/apps/27-interchain-accounts/types/codec_test.go b/modules/apps/27-interchain-accounts/types/codec_test.go index 08db0f6d0e7..33616d38790 100644 --- a/modules/apps/27-interchain-accounts/types/codec_test.go +++ b/modules/apps/27-interchain-accounts/types/codec_test.go @@ -1,12 +1,14 @@ package types_test import ( + "github.com/cosmos/gogoproto/proto" + sdkmath "cosmossdk.io/math" + "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" govtypes "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1" - "github.com/cosmos/gogoproto/proto" "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/types" "github.com/cosmos/ibc-go/v7/testing/simapp" diff --git a/modules/apps/27-interchain-accounts/types/expected_keepers.go b/modules/apps/27-interchain-accounts/types/expected_keepers.go index 08547816778..d923d61c603 100644 --- a/modules/apps/27-interchain-accounts/types/expected_keepers.go +++ b/modules/apps/27-interchain-accounts/types/expected_keepers.go @@ -3,8 +3,8 @@ package types import ( sdk "github.com/cosmos/cosmos-sdk/types" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" - capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" + capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" channeltypes "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" ibcexported "github.com/cosmos/ibc-go/v7/modules/core/exported" ) diff --git a/modules/apps/27-interchain-accounts/types/metadata.go b/modules/apps/27-interchain-accounts/types/metadata.go index ee986a006f9..6cf6a27688f 100644 --- a/modules/apps/27-interchain-accounts/types/metadata.go +++ b/modules/apps/27-interchain-accounts/types/metadata.go @@ -2,6 +2,7 @@ package types import ( errorsmod "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" connectiontypes "github.com/cosmos/ibc-go/v7/modules/core/03-connection/types" diff --git a/modules/apps/27-interchain-accounts/types/packet.go b/modules/apps/27-interchain-accounts/types/packet.go index f7d1c6648be..213497f6ac6 100644 --- a/modules/apps/27-interchain-accounts/types/packet.go +++ b/modules/apps/27-interchain-accounts/types/packet.go @@ -4,6 +4,7 @@ import ( "time" errorsmod "cosmossdk.io/errors" + codectypes "github.com/cosmos/cosmos-sdk/codec/types" sdk "github.com/cosmos/cosmos-sdk/types" ) diff --git a/modules/apps/29-fee/client/cli/query.go b/modules/apps/29-fee/client/cli/query.go index 5c57386668d..e836ac113fe 100644 --- a/modules/apps/29-fee/client/cli/query.go +++ b/modules/apps/29-fee/client/cli/query.go @@ -4,11 +4,12 @@ import ( "fmt" "strconv" + "github.com/spf13/cobra" + "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/version" - "github.com/spf13/cobra" "github.com/cosmos/ibc-go/v7/modules/apps/29-fee/types" channeltypes "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" diff --git a/modules/apps/29-fee/client/cli/tx.go b/modules/apps/29-fee/client/cli/tx.go index 40d0f5e5c1c..21ffae00f9a 100644 --- a/modules/apps/29-fee/client/cli/tx.go +++ b/modules/apps/29-fee/client/cli/tx.go @@ -5,12 +5,13 @@ import ( "strconv" "strings" + "github.com/spf13/cobra" + "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cosmos/cosmos-sdk/client/tx" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/version" - "github.com/spf13/cobra" "github.com/cosmos/ibc-go/v7/modules/apps/29-fee/types" channeltypes "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" diff --git a/modules/apps/29-fee/ibc_middleware.go b/modules/apps/29-fee/ibc_middleware.go index 1938fd6381a..5b260ad7be9 100644 --- a/modules/apps/29-fee/ibc_middleware.go +++ b/modules/apps/29-fee/ibc_middleware.go @@ -4,9 +4,10 @@ import ( "strings" errorsmod "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" - capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" + capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" "github.com/cosmos/ibc-go/v7/modules/apps/29-fee/keeper" "github.com/cosmos/ibc-go/v7/modules/apps/29-fee/types" clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" diff --git a/modules/apps/29-fee/ibc_middleware_test.go b/modules/apps/29-fee/ibc_middleware_test.go index 11302063364..ee1d0ed228a 100644 --- a/modules/apps/29-fee/ibc_middleware_test.go +++ b/modules/apps/29-fee/ibc_middleware_test.go @@ -4,9 +4,10 @@ import ( "fmt" sdkmath "cosmossdk.io/math" + sdk "github.com/cosmos/cosmos-sdk/types" - capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" + capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" fee "github.com/cosmos/ibc-go/v7/modules/apps/29-fee" "github.com/cosmos/ibc-go/v7/modules/apps/29-fee/types" transfertypes "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types" diff --git a/modules/apps/29-fee/ica_test.go b/modules/apps/29-fee/ica_test.go index 396e25cb00a..451c54b8b73 100644 --- a/modules/apps/29-fee/ica_test.go +++ b/modules/apps/29-fee/ica_test.go @@ -1,11 +1,13 @@ package fee_test import ( + "github.com/cosmos/gogoproto/proto" + sdkmath "cosmossdk.io/math" + sdk "github.com/cosmos/cosmos-sdk/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" - "github.com/cosmos/gogoproto/proto" icahosttypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/host/types" icatypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/types" diff --git a/modules/apps/29-fee/keeper/escrow.go b/modules/apps/29-fee/keeper/escrow.go index 8f3f8bd417f..9f9310272cd 100644 --- a/modules/apps/29-fee/keeper/escrow.go +++ b/modules/apps/29-fee/keeper/escrow.go @@ -5,6 +5,7 @@ import ( "fmt" errorsmod "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/ibc-go/v7/modules/apps/29-fee/types" diff --git a/modules/apps/29-fee/keeper/escrow_test.go b/modules/apps/29-fee/keeper/escrow_test.go index 71a1f9e5a44..fee65c5af9c 100644 --- a/modules/apps/29-fee/keeper/escrow_test.go +++ b/modules/apps/29-fee/keeper/escrow_test.go @@ -2,9 +2,11 @@ package keeper_test import ( sdkmath "cosmossdk.io/math" - "github.com/cometbft/cometbft/crypto/secp256k1" + sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/cometbft/cometbft/crypto/secp256k1" + "github.com/cosmos/ibc-go/v7/modules/apps/29-fee/types" transfertypes "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types" channeltypes "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" diff --git a/modules/apps/29-fee/keeper/events_test.go b/modules/apps/29-fee/keeper/events_test.go index 7c8b917f49e..2cd5b265b6d 100644 --- a/modules/apps/29-fee/keeper/events_test.go +++ b/modules/apps/29-fee/keeper/events_test.go @@ -2,9 +2,11 @@ package keeper_test import ( sdkmath "cosmossdk.io/math" - abcitypes "github.com/cometbft/cometbft/abci/types" + sdk "github.com/cosmos/cosmos-sdk/types" + abcitypes "github.com/cometbft/cometbft/abci/types" + "github.com/cosmos/ibc-go/v7/modules/apps/29-fee/types" transfertypes "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types" clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" diff --git a/modules/apps/29-fee/keeper/grpc_query.go b/modules/apps/29-fee/keeper/grpc_query.go index 1f007bbfb8c..6c7122e28c3 100644 --- a/modules/apps/29-fee/keeper/grpc_query.go +++ b/modules/apps/29-fee/keeper/grpc_query.go @@ -3,12 +3,14 @@ package keeper import ( "context" + "google.golang.org/grpc/codes" + "google.golang.org/grpc/status" + errorsmod "cosmossdk.io/errors" + "github.com/cosmos/cosmos-sdk/store/prefix" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/query" - "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" "github.com/cosmos/ibc-go/v7/modules/apps/29-fee/types" ) diff --git a/modules/apps/29-fee/keeper/grpc_query_test.go b/modules/apps/29-fee/keeper/grpc_query_test.go index 707980d9bb2..65f880fddb8 100644 --- a/modules/apps/29-fee/keeper/grpc_query_test.go +++ b/modules/apps/29-fee/keeper/grpc_query_test.go @@ -4,10 +4,12 @@ import ( "fmt" sdkmath "cosmossdk.io/math" - "github.com/cometbft/cometbft/crypto/secp256k1" + sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/query" + "github.com/cometbft/cometbft/crypto/secp256k1" + "github.com/cosmos/ibc-go/v7/modules/apps/29-fee/types" channeltypes "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" ibctesting "github.com/cosmos/ibc-go/v7/testing" diff --git a/modules/apps/29-fee/keeper/keeper.go b/modules/apps/29-fee/keeper/keeper.go index 99801bd6999..cfa353530b0 100644 --- a/modules/apps/29-fee/keeper/keeper.go +++ b/modules/apps/29-fee/keeper/keeper.go @@ -1,12 +1,13 @@ package keeper import ( - "github.com/cometbft/cometbft/libs/log" "github.com/cosmos/cosmos-sdk/codec" storetypes "github.com/cosmos/cosmos-sdk/store/types" sdk "github.com/cosmos/cosmos-sdk/types" - capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" + "github.com/cometbft/cometbft/libs/log" + + capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" "github.com/cosmos/ibc-go/v7/modules/apps/29-fee/types" channeltypes "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" porttypes "github.com/cosmos/ibc-go/v7/modules/core/05-port/types" diff --git a/modules/apps/29-fee/keeper/keeper_test.go b/modules/apps/29-fee/keeper/keeper_test.go index d82f09eea5e..f2265afe695 100644 --- a/modules/apps/29-fee/keeper/keeper_test.go +++ b/modules/apps/29-fee/keeper/keeper_test.go @@ -4,9 +4,11 @@ import ( "fmt" "testing" + "github.com/stretchr/testify/suite" + sdkmath "cosmossdk.io/math" + sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/stretchr/testify/suite" "github.com/cosmos/ibc-go/v7/modules/apps/29-fee/types" channeltypes "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" diff --git a/modules/apps/29-fee/keeper/msg_server.go b/modules/apps/29-fee/keeper/msg_server.go index 511c0e5aed7..12dd50506cf 100644 --- a/modules/apps/29-fee/keeper/msg_server.go +++ b/modules/apps/29-fee/keeper/msg_server.go @@ -4,6 +4,7 @@ import ( "context" errorsmod "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/ibc-go/v7/modules/apps/29-fee/types" diff --git a/modules/apps/29-fee/keeper/msg_server_test.go b/modules/apps/29-fee/keeper/msg_server_test.go index 40a24c5225d..fc7420144be 100644 --- a/modules/apps/29-fee/keeper/msg_server_test.go +++ b/modules/apps/29-fee/keeper/msg_server_test.go @@ -2,8 +2,8 @@ package keeper_test import ( sdkmath "cosmossdk.io/math" - sdk "github.com/cosmos/cosmos-sdk/types" + sdk "github.com/cosmos/cosmos-sdk/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" "github.com/cosmos/ibc-go/v7/modules/apps/29-fee/types" diff --git a/modules/apps/29-fee/keeper/relay.go b/modules/apps/29-fee/keeper/relay.go index 625901450a4..a5328703d7c 100644 --- a/modules/apps/29-fee/keeper/relay.go +++ b/modules/apps/29-fee/keeper/relay.go @@ -4,9 +4,10 @@ import ( "fmt" errorsmod "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" - capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" + capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" "github.com/cosmos/ibc-go/v7/modules/apps/29-fee/types" clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" channeltypes "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" diff --git a/modules/apps/29-fee/module.go b/modules/apps/29-fee/module.go index 988276073e9..e2981cd97f6 100644 --- a/modules/apps/29-fee/module.go +++ b/modules/apps/29-fee/module.go @@ -5,15 +5,17 @@ import ( "encoding/json" "fmt" - abci "github.com/cometbft/cometbft/abci/types" + "github.com/grpc-ecosystem/grpc-gateway/runtime" + "github.com/spf13/cobra" + "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/codec" codectypes "github.com/cosmos/cosmos-sdk/codec/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" simtypes "github.com/cosmos/cosmos-sdk/types/simulation" - "github.com/grpc-ecosystem/grpc-gateway/runtime" - "github.com/spf13/cobra" + + abci "github.com/cometbft/cometbft/abci/types" "github.com/cosmos/ibc-go/v7/modules/apps/29-fee/client/cli" "github.com/cosmos/ibc-go/v7/modules/apps/29-fee/keeper" diff --git a/modules/apps/29-fee/types/expected_keepers.go b/modules/apps/29-fee/types/expected_keepers.go index c9a82e62608..68ea270b72a 100644 --- a/modules/apps/29-fee/types/expected_keepers.go +++ b/modules/apps/29-fee/types/expected_keepers.go @@ -3,8 +3,8 @@ package types import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/x/auth/types" - capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" + capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" channeltypes "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" ) diff --git a/modules/apps/29-fee/types/fee.go b/modules/apps/29-fee/types/fee.go index 7081540ccb4..103a8a47046 100644 --- a/modules/apps/29-fee/types/fee.go +++ b/modules/apps/29-fee/types/fee.go @@ -4,6 +4,7 @@ import ( "strings" errorsmod "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" channeltypes "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" diff --git a/modules/apps/29-fee/types/fee_test.go b/modules/apps/29-fee/types/fee_test.go index 0ff42efb41a..a17b42693b5 100644 --- a/modules/apps/29-fee/types/fee_test.go +++ b/modules/apps/29-fee/types/fee_test.go @@ -3,10 +3,13 @@ package types_test import ( "testing" + "github.com/stretchr/testify/require" + sdkmath "cosmossdk.io/math" - "github.com/cometbft/cometbft/crypto/secp256k1" + sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/stretchr/testify/require" + + "github.com/cometbft/cometbft/crypto/secp256k1" "github.com/cosmos/ibc-go/v7/modules/apps/29-fee/types" ) diff --git a/modules/apps/29-fee/types/genesis.go b/modules/apps/29-fee/types/genesis.go index 69dc5e38178..b6d2143e28a 100644 --- a/modules/apps/29-fee/types/genesis.go +++ b/modules/apps/29-fee/types/genesis.go @@ -4,6 +4,7 @@ import ( "strings" errorsmod "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" host "github.com/cosmos/ibc-go/v7/modules/core/24-host" diff --git a/modules/apps/29-fee/types/genesis_test.go b/modules/apps/29-fee/types/genesis_test.go index 6ecde68c3a6..082efe4dd3e 100644 --- a/modules/apps/29-fee/types/genesis_test.go +++ b/modules/apps/29-fee/types/genesis_test.go @@ -3,10 +3,12 @@ package types_test import ( "testing" - "github.com/cometbft/cometbft/crypto/secp256k1" - sdk "github.com/cosmos/cosmos-sdk/types" "github.com/stretchr/testify/require" + sdk "github.com/cosmos/cosmos-sdk/types" + + "github.com/cometbft/cometbft/crypto/secp256k1" + "github.com/cosmos/ibc-go/v7/modules/apps/29-fee/types" channeltypes "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" ibctesting "github.com/cosmos/ibc-go/v7/testing" diff --git a/modules/apps/29-fee/types/msgs.go b/modules/apps/29-fee/types/msgs.go index c66c6ba7aa6..cf39b7fdd73 100644 --- a/modules/apps/29-fee/types/msgs.go +++ b/modules/apps/29-fee/types/msgs.go @@ -4,6 +4,7 @@ import ( "strings" errorsmod "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" channeltypes "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" diff --git a/modules/apps/29-fee/types/msgs_test.go b/modules/apps/29-fee/types/msgs_test.go index e20984e228b..fee8c236522 100644 --- a/modules/apps/29-fee/types/msgs_test.go +++ b/modules/apps/29-fee/types/msgs_test.go @@ -3,10 +3,12 @@ package types_test import ( "testing" - "github.com/cometbft/cometbft/crypto/secp256k1" - sdk "github.com/cosmos/cosmos-sdk/types" "github.com/stretchr/testify/require" + sdk "github.com/cosmos/cosmos-sdk/types" + + "github.com/cometbft/cometbft/crypto/secp256k1" + "github.com/cosmos/ibc-go/v7/modules/apps/29-fee/types" channeltypes "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" ibctesting "github.com/cosmos/ibc-go/v7/testing" diff --git a/modules/apps/transfer/client/cli/cli.go b/modules/apps/transfer/client/cli/cli.go index 8412c331fc8..a0fe3564b60 100644 --- a/modules/apps/transfer/client/cli/cli.go +++ b/modules/apps/transfer/client/cli/cli.go @@ -1,8 +1,9 @@ package cli import ( - "github.com/cosmos/cosmos-sdk/client" "github.com/spf13/cobra" + + "github.com/cosmos/cosmos-sdk/client" ) // GetQueryCmd returns the query commands for IBC connections diff --git a/modules/apps/transfer/client/cli/query.go b/modules/apps/transfer/client/cli/query.go index 8ebab138c66..c81e6ee921d 100644 --- a/modules/apps/transfer/client/cli/query.go +++ b/modules/apps/transfer/client/cli/query.go @@ -3,10 +3,11 @@ package cli import ( "fmt" + "github.com/spf13/cobra" + "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cosmos/cosmos-sdk/version" - "github.com/spf13/cobra" "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types" ) diff --git a/modules/apps/transfer/client/cli/tx.go b/modules/apps/transfer/client/cli/tx.go index c9024f03886..acd80760f88 100644 --- a/modules/apps/transfer/client/cli/tx.go +++ b/modules/apps/transfer/client/cli/tx.go @@ -6,12 +6,13 @@ import ( "strings" "time" + "github.com/spf13/cobra" + "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cosmos/cosmos-sdk/client/tx" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/version" - "github.com/spf13/cobra" "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types" clientutils "github.com/cosmos/ibc-go/v7/modules/core/02-client/client/utils" diff --git a/modules/apps/transfer/ibc_module.go b/modules/apps/transfer/ibc_module.go index 1d5afed8935..41fdd604926 100644 --- a/modules/apps/transfer/ibc_module.go +++ b/modules/apps/transfer/ibc_module.go @@ -6,9 +6,10 @@ import ( "strings" errorsmod "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" - capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" + capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" "github.com/cosmos/ibc-go/v7/modules/apps/transfer/keeper" "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types" channeltypes "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" diff --git a/modules/apps/transfer/ibc_module_test.go b/modules/apps/transfer/ibc_module_test.go index e62f7b421b7..4988d52b0af 100644 --- a/modules/apps/transfer/ibc_module_test.go +++ b/modules/apps/transfer/ibc_module_test.go @@ -4,7 +4,6 @@ import ( "math" capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" - "github.com/cosmos/ibc-go/v7/modules/apps/transfer" "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types" channeltypes "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" diff --git a/modules/apps/transfer/keeper/genesis_test.go b/modules/apps/transfer/keeper/genesis_test.go index 8b8aac62c67..b2e42d367ba 100644 --- a/modules/apps/transfer/keeper/genesis_test.go +++ b/modules/apps/transfer/keeper/genesis_test.go @@ -4,6 +4,7 @@ import ( "fmt" sdkmath "cosmossdk.io/math" + sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types" diff --git a/modules/apps/transfer/keeper/grpc_query.go b/modules/apps/transfer/keeper/grpc_query.go index 87648d2f9dc..f33db868d35 100644 --- a/modules/apps/transfer/keeper/grpc_query.go +++ b/modules/apps/transfer/keeper/grpc_query.go @@ -5,12 +5,14 @@ import ( "fmt" "strings" + "google.golang.org/grpc/codes" + "google.golang.org/grpc/status" + errorsmod "cosmossdk.io/errors" + "github.com/cosmos/cosmos-sdk/store/prefix" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/query" - "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types" ) diff --git a/modules/apps/transfer/keeper/grpc_query_test.go b/modules/apps/transfer/keeper/grpc_query_test.go index ae741a9b714..8df7babc69c 100644 --- a/modules/apps/transfer/keeper/grpc_query_test.go +++ b/modules/apps/transfer/keeper/grpc_query_test.go @@ -4,6 +4,7 @@ import ( "fmt" sdkmath "cosmossdk.io/math" + sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/query" diff --git a/modules/apps/transfer/keeper/invariants_test.go b/modules/apps/transfer/keeper/invariants_test.go index 28c2f9f0e2d..dd459db6de2 100644 --- a/modules/apps/transfer/keeper/invariants_test.go +++ b/modules/apps/transfer/keeper/invariants_test.go @@ -2,6 +2,7 @@ package keeper_test import ( sdkmath "cosmossdk.io/math" + sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/ibc-go/v7/modules/apps/transfer/keeper" diff --git a/modules/apps/transfer/keeper/keeper.go b/modules/apps/transfer/keeper/keeper.go index 4e5760cbf5b..be5ccd148ed 100644 --- a/modules/apps/transfer/keeper/keeper.go +++ b/modules/apps/transfer/keeper/keeper.go @@ -5,15 +5,17 @@ import ( "strings" sdkmath "cosmossdk.io/math" - tmbytes "github.com/cometbft/cometbft/libs/bytes" - "github.com/cometbft/cometbft/libs/log" + "github.com/cosmos/cosmos-sdk/codec" "github.com/cosmos/cosmos-sdk/store/prefix" storetypes "github.com/cosmos/cosmos-sdk/store/types" sdk "github.com/cosmos/cosmos-sdk/types" paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" - capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" + tmbytes "github.com/cometbft/cometbft/libs/bytes" + "github.com/cometbft/cometbft/libs/log" + + capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types" porttypes "github.com/cosmos/ibc-go/v7/modules/core/05-port/types" host "github.com/cosmos/ibc-go/v7/modules/core/24-host" diff --git a/modules/apps/transfer/keeper/keeper_test.go b/modules/apps/transfer/keeper/keeper_test.go index fc469b06c75..ead002a72c2 100644 --- a/modules/apps/transfer/keeper/keeper_test.go +++ b/modules/apps/transfer/keeper/keeper_test.go @@ -4,12 +4,14 @@ import ( "fmt" "testing" + "github.com/stretchr/testify/suite" + sdkmath "cosmossdk.io/math" + "github.com/cosmos/cosmos-sdk/baseapp" "github.com/cosmos/cosmos-sdk/codec" storetypes "github.com/cosmos/cosmos-sdk/store/types" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/stretchr/testify/suite" "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types" ibctesting "github.com/cosmos/ibc-go/v7/testing" diff --git a/modules/apps/transfer/keeper/mbt_relay_test.go b/modules/apps/transfer/keeper/mbt_relay_test.go index 80a99eada08..aad7366dcca 100644 --- a/modules/apps/transfer/keeper/mbt_relay_test.go +++ b/modules/apps/transfer/keeper/mbt_relay_test.go @@ -13,9 +13,11 @@ import ( errorsmod "cosmossdk.io/errors" sdkmath "cosmossdk.io/math" - "github.com/cometbft/cometbft/crypto" + sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/cometbft/cometbft/crypto" + "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types" clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" channeltypes "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" diff --git a/modules/apps/transfer/keeper/migrations_test.go b/modules/apps/transfer/keeper/migrations_test.go index 577fe8d2ba6..9548052c437 100644 --- a/modules/apps/transfer/keeper/migrations_test.go +++ b/modules/apps/transfer/keeper/migrations_test.go @@ -4,6 +4,7 @@ import ( "fmt" sdkmath "cosmossdk.io/math" + sdk "github.com/cosmos/cosmos-sdk/types" banktestutil "github.com/cosmos/cosmos-sdk/x/bank/testutil" diff --git a/modules/apps/transfer/keeper/msg_server.go b/modules/apps/transfer/keeper/msg_server.go index f930c929b42..41961e57261 100644 --- a/modules/apps/transfer/keeper/msg_server.go +++ b/modules/apps/transfer/keeper/msg_server.go @@ -4,6 +4,7 @@ import ( "context" errorsmod "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types" diff --git a/modules/apps/transfer/keeper/msg_server_test.go b/modules/apps/transfer/keeper/msg_server_test.go index 73c94bc0ca3..552d43be0d4 100644 --- a/modules/apps/transfer/keeper/msg_server_test.go +++ b/modules/apps/transfer/keeper/msg_server_test.go @@ -2,11 +2,12 @@ package keeper_test import ( sdkmath "cosmossdk.io/math" + sdk "github.com/cosmos/cosmos-sdk/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" - ibctesting "github.com/cosmos/ibc-go/v7/testing" "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types" + ibctesting "github.com/cosmos/ibc-go/v7/testing" ) // TestMsgTransfer tests Transfer rpc handler diff --git a/modules/apps/transfer/keeper/relay.go b/modules/apps/transfer/keeper/relay.go index 0bef4fa81f9..f6abdd61bd2 100644 --- a/modules/apps/transfer/keeper/relay.go +++ b/modules/apps/transfer/keeper/relay.go @@ -4,9 +4,11 @@ import ( "fmt" "strings" + metrics "github.com/armon/go-metrics" + errorsmod "cosmossdk.io/errors" sdkmath "cosmossdk.io/math" - metrics "github.com/armon/go-metrics" + "github.com/cosmos/cosmos-sdk/telemetry" sdk "github.com/cosmos/cosmos-sdk/types" diff --git a/modules/apps/transfer/keeper/relay_test.go b/modules/apps/transfer/keeper/relay_test.go index 57f594d4711..6d723cd107c 100644 --- a/modules/apps/transfer/keeper/relay_test.go +++ b/modules/apps/transfer/keeper/relay_test.go @@ -4,6 +4,7 @@ import ( "fmt" sdkmath "cosmossdk.io/math" + sdk "github.com/cosmos/cosmos-sdk/types" banktestutil "github.com/cosmos/cosmos-sdk/x/bank/testutil" diff --git a/modules/apps/transfer/module.go b/modules/apps/transfer/module.go index 43359bf9681..8d84ff0311b 100644 --- a/modules/apps/transfer/module.go +++ b/modules/apps/transfer/module.go @@ -5,15 +5,17 @@ import ( "encoding/json" "fmt" - abci "github.com/cometbft/cometbft/abci/types" + "github.com/grpc-ecosystem/grpc-gateway/runtime" + "github.com/spf13/cobra" + "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/codec" codectypes "github.com/cosmos/cosmos-sdk/codec/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" simtypes "github.com/cosmos/cosmos-sdk/types/simulation" - "github.com/grpc-ecosystem/grpc-gateway/runtime" - "github.com/spf13/cobra" + + abci "github.com/cometbft/cometbft/abci/types" "github.com/cosmos/ibc-go/v7/modules/apps/transfer/client/cli" "github.com/cosmos/ibc-go/v7/modules/apps/transfer/keeper" diff --git a/modules/apps/transfer/simulation/decoder_test.go b/modules/apps/transfer/simulation/decoder_test.go index 26d7dbf4b94..72dd721fac4 100644 --- a/modules/apps/transfer/simulation/decoder_test.go +++ b/modules/apps/transfer/simulation/decoder_test.go @@ -4,9 +4,10 @@ import ( "fmt" "testing" - "github.com/cosmos/cosmos-sdk/types/kv" "github.com/stretchr/testify/require" + "github.com/cosmos/cosmos-sdk/types/kv" + "github.com/cosmos/ibc-go/v7/modules/apps/transfer/simulation" "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types" "github.com/cosmos/ibc-go/v7/testing/simapp" diff --git a/modules/apps/transfer/simulation/genesis_test.go b/modules/apps/transfer/simulation/genesis_test.go index 6b56251e97f..11c61aca767 100644 --- a/modules/apps/transfer/simulation/genesis_test.go +++ b/modules/apps/transfer/simulation/genesis_test.go @@ -5,13 +5,15 @@ import ( "math/rand" "testing" + "github.com/stretchr/testify/require" + sdkmath "cosmossdk.io/math" + "github.com/cosmos/cosmos-sdk/codec" codectypes "github.com/cosmos/cosmos-sdk/codec/types" cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" "github.com/cosmos/cosmos-sdk/types/module" simtypes "github.com/cosmos/cosmos-sdk/types/simulation" - "github.com/stretchr/testify/require" "github.com/cosmos/ibc-go/v7/modules/apps/transfer/simulation" "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types" diff --git a/modules/apps/transfer/transfer_test.go b/modules/apps/transfer/transfer_test.go index eec87eb60cd..74315f35fd6 100644 --- a/modules/apps/transfer/transfer_test.go +++ b/modules/apps/transfer/transfer_test.go @@ -3,9 +3,11 @@ package transfer_test import ( "testing" + "github.com/stretchr/testify/suite" + sdkmath "cosmossdk.io/math" + sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/stretchr/testify/suite" "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types" clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" diff --git a/modules/apps/transfer/types/codec.go b/modules/apps/transfer/types/codec.go index 2d66ca534a7..e04fb6fab0c 100644 --- a/modules/apps/transfer/types/codec.go +++ b/modules/apps/transfer/types/codec.go @@ -3,7 +3,6 @@ package types import ( "bytes" - "github.com/cosmos/cosmos-sdk/x/authz" "github.com/cosmos/gogoproto/jsonpb" "github.com/cosmos/gogoproto/proto" @@ -11,6 +10,7 @@ import ( codectypes "github.com/cosmos/cosmos-sdk/codec/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/msgservice" + "github.com/cosmos/cosmos-sdk/x/authz" ) // RegisterLegacyAminoCodec registers the necessary x/ibc transfer interfaces and concrete types diff --git a/modules/apps/transfer/types/coin.go b/modules/apps/transfer/types/coin.go index 6799b763013..fad6532af81 100644 --- a/modules/apps/transfer/types/coin.go +++ b/modules/apps/transfer/types/coin.go @@ -5,6 +5,7 @@ import ( "strings" sdkmath "cosmossdk.io/math" + sdk "github.com/cosmos/cosmos-sdk/types" ) diff --git a/modules/apps/transfer/types/expected_keepers.go b/modules/apps/transfer/types/expected_keepers.go index 389d423a18f..e4997fd879f 100644 --- a/modules/apps/transfer/types/expected_keepers.go +++ b/modules/apps/transfer/types/expected_keepers.go @@ -3,8 +3,8 @@ package types import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/x/auth/types" - capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" + capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" connectiontypes "github.com/cosmos/ibc-go/v7/modules/core/03-connection/types" channeltypes "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" ibcexported "github.com/cosmos/ibc-go/v7/modules/core/exported" diff --git a/modules/apps/transfer/types/msgs.go b/modules/apps/transfer/types/msgs.go index a9d9c1d7adf..7bc92bf3363 100644 --- a/modules/apps/transfer/types/msgs.go +++ b/modules/apps/transfer/types/msgs.go @@ -4,6 +4,7 @@ import ( "strings" errorsmod "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" diff --git a/modules/apps/transfer/types/msgs_test.go b/modules/apps/transfer/types/msgs_test.go index 22423d403f9..b967e699fa8 100644 --- a/modules/apps/transfer/types/msgs_test.go +++ b/modules/apps/transfer/types/msgs_test.go @@ -4,10 +4,12 @@ import ( "fmt" "testing" + "github.com/stretchr/testify/require" + sdkmath "cosmossdk.io/math" + "github.com/cosmos/cosmos-sdk/crypto/keys/secp256k1" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/stretchr/testify/require" "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types" clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" diff --git a/modules/apps/transfer/types/packet.go b/modules/apps/transfer/types/packet.go index 92e60a646ea..66f3e5730e1 100644 --- a/modules/apps/transfer/types/packet.go +++ b/modules/apps/transfer/types/packet.go @@ -6,6 +6,7 @@ import ( errorsmod "cosmossdk.io/errors" sdkmath "cosmossdk.io/math" + sdk "github.com/cosmos/cosmos-sdk/types" ibcerrors "github.com/cosmos/ibc-go/v7/modules/core/errors" diff --git a/modules/apps/transfer/types/trace.go b/modules/apps/transfer/types/trace.go index 2c9581d9078..f539ba65cf4 100644 --- a/modules/apps/transfer/types/trace.go +++ b/modules/apps/transfer/types/trace.go @@ -8,9 +8,11 @@ import ( "strings" errorsmod "cosmossdk.io/errors" + + sdk "github.com/cosmos/cosmos-sdk/types" + tmbytes "github.com/cometbft/cometbft/libs/bytes" tmtypes "github.com/cometbft/cometbft/types" - sdk "github.com/cosmos/cosmos-sdk/types" channeltypes "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" host "github.com/cosmos/ibc-go/v7/modules/core/24-host" diff --git a/modules/apps/transfer/types/transfer_authorization.go b/modules/apps/transfer/types/transfer_authorization.go index 119b148e8cb..c276064e422 100644 --- a/modules/apps/transfer/types/transfer_authorization.go +++ b/modules/apps/transfer/types/transfer_authorization.go @@ -5,6 +5,7 @@ import ( errorsmod "cosmossdk.io/errors" sdkmath "cosmossdk.io/math" + sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/x/authz" diff --git a/modules/apps/transfer/types/transfer_authorization_test.go b/modules/apps/transfer/types/transfer_authorization_test.go index eb50f2e5f8a..da2764cba39 100644 --- a/modules/apps/transfer/types/transfer_authorization_test.go +++ b/modules/apps/transfer/types/transfer_authorization_test.go @@ -2,8 +2,10 @@ package types_test import ( sdkmath "cosmossdk.io/math" + 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" diff --git a/modules/core/02-client/abci_test.go b/modules/core/02-client/abci_test.go index 170f5a63524..b825acee6ba 100644 --- a/modules/core/02-client/abci_test.go +++ b/modules/core/02-client/abci_test.go @@ -4,11 +4,13 @@ import ( "strings" "testing" - abci "github.com/cometbft/cometbft/abci/types" - tmproto "github.com/cometbft/cometbft/proto/tendermint/types" + "github.com/stretchr/testify/suite" + sdk "github.com/cosmos/cosmos-sdk/types" upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types" - "github.com/stretchr/testify/suite" + + abci "github.com/cometbft/cometbft/abci/types" + tmproto "github.com/cometbft/cometbft/proto/tendermint/types" client "github.com/cosmos/ibc-go/v7/modules/core/02-client" "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" diff --git a/modules/core/02-client/client/cli/cli.go b/modules/core/02-client/client/cli/cli.go index f1017e2df0f..fd5b4b95338 100644 --- a/modules/core/02-client/client/cli/cli.go +++ b/modules/core/02-client/client/cli/cli.go @@ -1,9 +1,10 @@ package cli import ( - "github.com/cosmos/cosmos-sdk/client" "github.com/spf13/cobra" + "github.com/cosmos/cosmos-sdk/client" + "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" ) diff --git a/modules/core/02-client/client/cli/query.go b/modules/core/02-client/client/cli/query.go index 337b142419c..692e5517522 100644 --- a/modules/core/02-client/client/cli/query.go +++ b/modules/core/02-client/client/cli/query.go @@ -4,10 +4,11 @@ import ( "errors" "fmt" + "github.com/spf13/cobra" + "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cosmos/cosmos-sdk/version" - "github.com/spf13/cobra" "github.com/cosmos/ibc-go/v7/modules/core/02-client/client/utils" "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" diff --git a/modules/core/02-client/client/cli/tx.go b/modules/core/02-client/client/cli/tx.go index 14401a659fc..7966daf7dac 100644 --- a/modules/core/02-client/client/cli/tx.go +++ b/modules/core/02-client/client/cli/tx.go @@ -5,6 +5,8 @@ import ( "os" "strconv" + "github.com/spf13/cobra" + "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cosmos/cosmos-sdk/client/tx" @@ -14,7 +16,6 @@ import ( govcli "github.com/cosmos/cosmos-sdk/x/gov/client/cli" govtypes "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1" upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types" - "github.com/spf13/cobra" "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" "github.com/cosmos/ibc-go/v7/modules/core/exported" diff --git a/modules/core/02-client/client/utils/utils.go b/modules/core/02-client/client/utils/utils.go index f776bb00ae2..5caf7679712 100644 --- a/modules/core/02-client/client/utils/utils.go +++ b/modules/core/02-client/client/utils/utils.go @@ -4,10 +4,12 @@ import ( "context" errorsmod "cosmossdk.io/errors" - tmtypes "github.com/cometbft/cometbft/types" + "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/codec" + tmtypes "github.com/cometbft/cometbft/types" + "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" commitmenttypes "github.com/cosmos/ibc-go/v7/modules/core/23-commitment/types" host "github.com/cosmos/ibc-go/v7/modules/core/24-host" diff --git a/modules/core/02-client/keeper/client.go b/modules/core/02-client/keeper/client.go index 1be50fdb820..34b8ff8c528 100644 --- a/modules/core/02-client/keeper/client.go +++ b/modules/core/02-client/keeper/client.go @@ -1,8 +1,10 @@ package keeper import ( - errorsmod "cosmossdk.io/errors" metrics "github.com/armon/go-metrics" + + errorsmod "cosmossdk.io/errors" + "github.com/cosmos/cosmos-sdk/telemetry" sdk "github.com/cosmos/cosmos-sdk/types" diff --git a/modules/core/02-client/keeper/grpc_query.go b/modules/core/02-client/keeper/grpc_query.go index 009439381bd..3b0b671c18c 100644 --- a/modules/core/02-client/keeper/grpc_query.go +++ b/modules/core/02-client/keeper/grpc_query.go @@ -7,12 +7,14 @@ import ( "sort" "strings" + "google.golang.org/grpc/codes" + "google.golang.org/grpc/status" + errorsmod "cosmossdk.io/errors" + "github.com/cosmos/cosmos-sdk/store/prefix" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/query" - "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" host "github.com/cosmos/ibc-go/v7/modules/core/24-host" diff --git a/modules/core/02-client/keeper/keeper.go b/modules/core/02-client/keeper/keeper.go index 9a79011cd1a..b26aa5eaf0d 100644 --- a/modules/core/02-client/keeper/keeper.go +++ b/modules/core/02-client/keeper/keeper.go @@ -6,8 +6,7 @@ import ( "strings" errorsmod "cosmossdk.io/errors" - "github.com/cometbft/cometbft/libs/log" - "github.com/cometbft/cometbft/light" + "github.com/cosmos/cosmos-sdk/codec" "github.com/cosmos/cosmos-sdk/store/prefix" storetypes "github.com/cosmos/cosmos-sdk/store/types" @@ -15,6 +14,9 @@ import ( paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types" + "github.com/cometbft/cometbft/libs/log" + "github.com/cometbft/cometbft/light" + "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" commitmenttypes "github.com/cosmos/ibc-go/v7/modules/core/23-commitment/types" host "github.com/cosmos/ibc-go/v7/modules/core/24-host" diff --git a/modules/core/02-client/keeper/keeper_test.go b/modules/core/02-client/keeper/keeper_test.go index 50d6fedc23e..fd67d93286c 100644 --- a/modules/core/02-client/keeper/keeper_test.go +++ b/modules/core/02-client/keeper/keeper_test.go @@ -5,14 +5,19 @@ import ( "testing" "time" + "github.com/stretchr/testify/suite" + sdkmath "cosmossdk.io/math" - tmbytes "github.com/cometbft/cometbft/libs/bytes" - tmproto "github.com/cometbft/cometbft/proto/tendermint/types" - tmtypes "github.com/cometbft/cometbft/types" + "github.com/cosmos/cosmos-sdk/codec" cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" sdk "github.com/cosmos/cosmos-sdk/types" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" + + tmbytes "github.com/cometbft/cometbft/libs/bytes" + tmproto "github.com/cometbft/cometbft/proto/tendermint/types" + tmtypes "github.com/cometbft/cometbft/types" + "github.com/cosmos/ibc-go/v7/modules/core/02-client/keeper" "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" commitmenttypes "github.com/cosmos/ibc-go/v7/modules/core/23-commitment/types" @@ -23,7 +28,6 @@ import ( ibctesting "github.com/cosmos/ibc-go/v7/testing" ibctestingmock "github.com/cosmos/ibc-go/v7/testing/mock" "github.com/cosmos/ibc-go/v7/testing/simapp" - "github.com/stretchr/testify/suite" ) const ( diff --git a/modules/core/02-client/keeper/proposal.go b/modules/core/02-client/keeper/proposal.go index 2cb0787be47..f35f00d616d 100644 --- a/modules/core/02-client/keeper/proposal.go +++ b/modules/core/02-client/keeper/proposal.go @@ -1,8 +1,10 @@ package keeper import ( - errorsmod "cosmossdk.io/errors" metrics "github.com/armon/go-metrics" + + errorsmod "cosmossdk.io/errors" + "github.com/cosmos/cosmos-sdk/telemetry" sdk "github.com/cosmos/cosmos-sdk/types" diff --git a/modules/core/02-client/migrations/v7/genesis.go b/modules/core/02-client/migrations/v7/genesis.go index e2f803dd35d..13eec1df18f 100644 --- a/modules/core/02-client/migrations/v7/genesis.go +++ b/modules/core/02-client/migrations/v7/genesis.go @@ -2,6 +2,7 @@ package v7 import ( errorsmod "cosmossdk.io/errors" + "github.com/cosmos/cosmos-sdk/codec" clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" diff --git a/modules/core/02-client/migrations/v7/store.go b/modules/core/02-client/migrations/v7/store.go index 280431dc5e7..e8794dd9c17 100644 --- a/modules/core/02-client/migrations/v7/store.go +++ b/modules/core/02-client/migrations/v7/store.go @@ -4,6 +4,7 @@ import ( "strings" errorsmod "cosmossdk.io/errors" + "github.com/cosmos/cosmos-sdk/codec" codectypes "github.com/cosmos/cosmos-sdk/codec/types" storetypes "github.com/cosmos/cosmos-sdk/store/types" diff --git a/modules/core/02-client/migrations/v7/store_test.go b/modules/core/02-client/migrations/v7/store_test.go index cb8be6e0f6d..524e439a4f6 100644 --- a/modules/core/02-client/migrations/v7/store_test.go +++ b/modules/core/02-client/migrations/v7/store_test.go @@ -4,9 +4,10 @@ import ( "strconv" "testing" - "github.com/cosmos/cosmos-sdk/codec" "github.com/stretchr/testify/suite" + "github.com/cosmos/cosmos-sdk/codec" + v7 "github.com/cosmos/ibc-go/v7/modules/core/02-client/migrations/v7" "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" host "github.com/cosmos/ibc-go/v7/modules/core/24-host" diff --git a/modules/core/02-client/proposal_handler.go b/modules/core/02-client/proposal_handler.go index e777d4fe71d..af6393c7f96 100644 --- a/modules/core/02-client/proposal_handler.go +++ b/modules/core/02-client/proposal_handler.go @@ -2,6 +2,7 @@ package client import ( errorsmod "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" govtypes "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1" diff --git a/modules/core/02-client/proposal_handler_test.go b/modules/core/02-client/proposal_handler_test.go index a4914f282cf..b96ee2a05fb 100644 --- a/modules/core/02-client/proposal_handler_test.go +++ b/modules/core/02-client/proposal_handler_test.go @@ -2,6 +2,7 @@ package client_test import ( sdkmath "cosmossdk.io/math" + sdk "github.com/cosmos/cosmos-sdk/types" distributiontypes "github.com/cosmos/cosmos-sdk/x/distribution/types" govtypes "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1" diff --git a/modules/core/02-client/simulation/decoder_test.go b/modules/core/02-client/simulation/decoder_test.go index 0fbaef2693c..543f77f2a4f 100644 --- a/modules/core/02-client/simulation/decoder_test.go +++ b/modules/core/02-client/simulation/decoder_test.go @@ -5,9 +5,10 @@ import ( "testing" "time" - "github.com/cosmos/cosmos-sdk/types/kv" "github.com/stretchr/testify/require" + "github.com/cosmos/cosmos-sdk/types/kv" + "github.com/cosmos/ibc-go/v7/modules/core/02-client/simulation" "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" host "github.com/cosmos/ibc-go/v7/modules/core/24-host" diff --git a/modules/core/02-client/types/client.go b/modules/core/02-client/types/client.go index f572adf526a..8fc6b63ee98 100644 --- a/modules/core/02-client/types/client.go +++ b/modules/core/02-client/types/client.go @@ -6,9 +6,11 @@ import ( "sort" "strings" + proto "github.com/cosmos/gogoproto/proto" + errorsmod "cosmossdk.io/errors" + codectypes "github.com/cosmos/cosmos-sdk/codec/types" - proto "github.com/cosmos/gogoproto/proto" host "github.com/cosmos/ibc-go/v7/modules/core/24-host" "github.com/cosmos/ibc-go/v7/modules/core/exported" diff --git a/modules/core/02-client/types/codec.go b/modules/core/02-client/types/codec.go index aba50a3b3a5..c71caaede98 100644 --- a/modules/core/02-client/types/codec.go +++ b/modules/core/02-client/types/codec.go @@ -1,12 +1,14 @@ package types import ( + proto "github.com/cosmos/gogoproto/proto" + errorsmod "cosmossdk.io/errors" + codectypes "github.com/cosmos/cosmos-sdk/codec/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/msgservice" govtypes "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1" - proto "github.com/cosmos/gogoproto/proto" ibcerrors "github.com/cosmos/ibc-go/v7/modules/core/errors" "github.com/cosmos/ibc-go/v7/modules/core/exported" diff --git a/modules/core/02-client/types/height.go b/modules/core/02-client/types/height.go index 75a840e5e13..94e9f4acd6f 100644 --- a/modules/core/02-client/types/height.go +++ b/modules/core/02-client/types/height.go @@ -8,6 +8,7 @@ import ( "strings" errorsmod "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" ibcerrors "github.com/cosmos/ibc-go/v7/modules/core/errors" diff --git a/modules/core/02-client/types/msgs.go b/modules/core/02-client/types/msgs.go index be1c0a83090..764154afcb5 100644 --- a/modules/core/02-client/types/msgs.go +++ b/modules/core/02-client/types/msgs.go @@ -2,6 +2,7 @@ package types import ( errorsmod "cosmossdk.io/errors" + codectypes "github.com/cosmos/cosmos-sdk/codec/types" sdk "github.com/cosmos/cosmos-sdk/types" diff --git a/modules/core/02-client/types/msgs_test.go b/modules/core/02-client/types/msgs_test.go index 2cb871c87e5..2d265dcbc6c 100644 --- a/modules/core/02-client/types/msgs_test.go +++ b/modules/core/02-client/types/msgs_test.go @@ -4,11 +4,12 @@ import ( "testing" "time" - sdk "github.com/cosmos/cosmos-sdk/types" "github.com/golang/protobuf/proto" //nolint:staticcheck "github.com/stretchr/testify/require" "github.com/stretchr/testify/suite" + sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" commitmenttypes "github.com/cosmos/ibc-go/v7/modules/core/23-commitment/types" solomachine "github.com/cosmos/ibc-go/v7/modules/light-clients/06-solomachine" diff --git a/modules/core/02-client/types/proposal.go b/modules/core/02-client/types/proposal.go index 0b22200242f..c51f4cf1900 100644 --- a/modules/core/02-client/types/proposal.go +++ b/modules/core/02-client/types/proposal.go @@ -5,6 +5,7 @@ import ( "reflect" errorsmod "cosmossdk.io/errors" + codectypes "github.com/cosmos/cosmos-sdk/codec/types" govtypes "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1" upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types" diff --git a/modules/core/03-connection/client/cli/query.go b/modules/core/03-connection/client/cli/query.go index e0d6d917d5b..9fe3250208f 100644 --- a/modules/core/03-connection/client/cli/query.go +++ b/modules/core/03-connection/client/cli/query.go @@ -3,10 +3,11 @@ package cli import ( "fmt" + "github.com/spf13/cobra" + "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cosmos/cosmos-sdk/version" - "github.com/spf13/cobra" "github.com/cosmos/ibc-go/v7/modules/core/03-connection/client/utils" "github.com/cosmos/ibc-go/v7/modules/core/03-connection/types" diff --git a/modules/core/03-connection/client/utils/utils.go b/modules/core/03-connection/client/utils/utils.go index a7cab07d6bf..729ad18783d 100644 --- a/modules/core/03-connection/client/utils/utils.go +++ b/modules/core/03-connection/client/utils/utils.go @@ -7,6 +7,7 @@ import ( "os" errorsmod "cosmossdk.io/errors" + "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/codec" diff --git a/modules/core/03-connection/keeper/grpc_query.go b/modules/core/03-connection/keeper/grpc_query.go index d095e2537f3..9cd1830d1e5 100644 --- a/modules/core/03-connection/keeper/grpc_query.go +++ b/modules/core/03-connection/keeper/grpc_query.go @@ -3,12 +3,14 @@ package keeper import ( "context" + "google.golang.org/grpc/codes" + "google.golang.org/grpc/status" + errorsmod "cosmossdk.io/errors" + "github.com/cosmos/cosmos-sdk/store/prefix" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/query" - "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" "github.com/cosmos/ibc-go/v7/modules/core/03-connection/types" diff --git a/modules/core/03-connection/keeper/handshake.go b/modules/core/03-connection/keeper/handshake.go index bea6d74ce15..61e50b7a55d 100644 --- a/modules/core/03-connection/keeper/handshake.go +++ b/modules/core/03-connection/keeper/handshake.go @@ -2,6 +2,7 @@ package keeper import ( errorsmod "cosmossdk.io/errors" + "github.com/cosmos/cosmos-sdk/telemetry" sdk "github.com/cosmos/cosmos-sdk/types" diff --git a/modules/core/03-connection/keeper/keeper.go b/modules/core/03-connection/keeper/keeper.go index ee37f913ef0..075ae4e4465 100644 --- a/modules/core/03-connection/keeper/keeper.go +++ b/modules/core/03-connection/keeper/keeper.go @@ -2,12 +2,14 @@ package keeper import ( errorsmod "cosmossdk.io/errors" - "github.com/cometbft/cometbft/libs/log" + "github.com/cosmos/cosmos-sdk/codec" storetypes "github.com/cosmos/cosmos-sdk/store/types" sdk "github.com/cosmos/cosmos-sdk/types" paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" + "github.com/cometbft/cometbft/libs/log" + clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" "github.com/cosmos/ibc-go/v7/modules/core/03-connection/types" commitmenttypes "github.com/cosmos/ibc-go/v7/modules/core/23-commitment/types" diff --git a/modules/core/03-connection/keeper/verify.go b/modules/core/03-connection/keeper/verify.go index c1316fb9ea2..b02f8b82d0f 100644 --- a/modules/core/03-connection/keeper/verify.go +++ b/modules/core/03-connection/keeper/verify.go @@ -4,6 +4,7 @@ import ( "math" errorsmod "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" diff --git a/modules/core/03-connection/simulation/decoder_test.go b/modules/core/03-connection/simulation/decoder_test.go index d93c1f10742..a511abeee74 100644 --- a/modules/core/03-connection/simulation/decoder_test.go +++ b/modules/core/03-connection/simulation/decoder_test.go @@ -4,9 +4,10 @@ import ( "fmt" "testing" - "github.com/cosmos/cosmos-sdk/types/kv" "github.com/stretchr/testify/require" + "github.com/cosmos/cosmos-sdk/types/kv" + "github.com/cosmos/ibc-go/v7/modules/core/03-connection/simulation" "github.com/cosmos/ibc-go/v7/modules/core/03-connection/types" host "github.com/cosmos/ibc-go/v7/modules/core/24-host" diff --git a/modules/core/03-connection/types/msgs.go b/modules/core/03-connection/types/msgs.go index 0d9c808cf27..67837a2133f 100644 --- a/modules/core/03-connection/types/msgs.go +++ b/modules/core/03-connection/types/msgs.go @@ -2,6 +2,7 @@ package types import ( errorsmod "cosmossdk.io/errors" + codectypes "github.com/cosmos/cosmos-sdk/codec/types" sdk "github.com/cosmos/cosmos-sdk/types" diff --git a/modules/core/03-connection/types/msgs_test.go b/modules/core/03-connection/types/msgs_test.go index 2f609c8bbc9..7e1749a8e26 100644 --- a/modules/core/03-connection/types/msgs_test.go +++ b/modules/core/03-connection/types/msgs_test.go @@ -5,15 +5,17 @@ import ( "testing" "time" - dbm "github.com/cometbft/cometbft-db" - abci "github.com/cometbft/cometbft/abci/types" - log "github.com/cometbft/cometbft/libs/log" + "github.com/stretchr/testify/require" + "github.com/stretchr/testify/suite" + "github.com/cosmos/cosmos-sdk/store/iavl" "github.com/cosmos/cosmos-sdk/store/rootmulti" storetypes "github.com/cosmos/cosmos-sdk/store/types" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/stretchr/testify/require" - "github.com/stretchr/testify/suite" + + dbm "github.com/cometbft/cometbft-db" + abci "github.com/cometbft/cometbft/abci/types" + log "github.com/cometbft/cometbft/libs/log" clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" "github.com/cosmos/ibc-go/v7/modules/core/03-connection/types" diff --git a/modules/core/04-channel/client/cli/cli.go b/modules/core/04-channel/client/cli/cli.go index f8c8afd4d39..b4d777d4b18 100644 --- a/modules/core/04-channel/client/cli/cli.go +++ b/modules/core/04-channel/client/cli/cli.go @@ -1,9 +1,10 @@ package cli import ( - "github.com/cosmos/cosmos-sdk/client" "github.com/spf13/cobra" + "github.com/cosmos/cosmos-sdk/client" + "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" ) diff --git a/modules/core/04-channel/client/cli/query.go b/modules/core/04-channel/client/cli/query.go index bac6660ed4e..1d51ef59a41 100644 --- a/modules/core/04-channel/client/cli/query.go +++ b/modules/core/04-channel/client/cli/query.go @@ -4,10 +4,11 @@ import ( "fmt" "strconv" + "github.com/spf13/cobra" + "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cosmos/cosmos-sdk/version" - "github.com/spf13/cobra" "github.com/cosmos/ibc-go/v7/modules/core/04-channel/client/utils" "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" diff --git a/modules/core/04-channel/client/utils/utils.go b/modules/core/04-channel/client/utils/utils.go index 7110ee2879b..980a261640e 100644 --- a/modules/core/04-channel/client/utils/utils.go +++ b/modules/core/04-channel/client/utils/utils.go @@ -5,6 +5,7 @@ import ( "encoding/binary" errorsmod "cosmossdk.io/errors" + "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/codec" diff --git a/modules/core/04-channel/keeper/grpc_query.go b/modules/core/04-channel/keeper/grpc_query.go index bf867810411..d0415e1bb63 100644 --- a/modules/core/04-channel/keeper/grpc_query.go +++ b/modules/core/04-channel/keeper/grpc_query.go @@ -5,12 +5,14 @@ import ( "strconv" "strings" + "google.golang.org/grpc/codes" + "google.golang.org/grpc/status" + errorsmod "cosmossdk.io/errors" + "github.com/cosmos/cosmos-sdk/store/prefix" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/query" - "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" connectiontypes "github.com/cosmos/ibc-go/v7/modules/core/03-connection/types" diff --git a/modules/core/04-channel/keeper/handshake.go b/modules/core/04-channel/keeper/handshake.go index 69213a0884c..3bc06ba83a4 100644 --- a/modules/core/04-channel/keeper/handshake.go +++ b/modules/core/04-channel/keeper/handshake.go @@ -4,10 +4,11 @@ import ( "fmt" errorsmod "cosmossdk.io/errors" + "github.com/cosmos/cosmos-sdk/telemetry" sdk "github.com/cosmos/cosmos-sdk/types" - capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" + capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" connectiontypes "github.com/cosmos/ibc-go/v7/modules/core/03-connection/types" "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" diff --git a/modules/core/04-channel/keeper/handshake_test.go b/modules/core/04-channel/keeper/handshake_test.go index ad349834e16..3b0c8057edc 100644 --- a/modules/core/04-channel/keeper/handshake_test.go +++ b/modules/core/04-channel/keeper/handshake_test.go @@ -4,7 +4,6 @@ import ( "fmt" capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" - clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" connectiontypes "github.com/cosmos/ibc-go/v7/modules/core/03-connection/types" "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" diff --git a/modules/core/04-channel/keeper/keeper.go b/modules/core/04-channel/keeper/keeper.go index d628abbed83..5a02b9e0fb3 100644 --- a/modules/core/04-channel/keeper/keeper.go +++ b/modules/core/04-channel/keeper/keeper.go @@ -4,14 +4,15 @@ import ( "strconv" "strings" - db "github.com/cometbft/cometbft-db" - "github.com/cometbft/cometbft/libs/log" "github.com/cosmos/cosmos-sdk/codec" storetypes "github.com/cosmos/cosmos-sdk/store/types" sdk "github.com/cosmos/cosmos-sdk/types" errorsmod "github.com/cosmos/cosmos-sdk/types/errors" - capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" + db "github.com/cometbft/cometbft-db" + "github.com/cometbft/cometbft/libs/log" + + capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" connectiontypes "github.com/cosmos/ibc-go/v7/modules/core/03-connection/types" "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" diff --git a/modules/core/04-channel/keeper/packet.go b/modules/core/04-channel/keeper/packet.go index 1ec5e94521c..d448d45b822 100644 --- a/modules/core/04-channel/keeper/packet.go +++ b/modules/core/04-channel/keeper/packet.go @@ -6,9 +6,10 @@ import ( "time" errorsmod "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" - capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" + capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" connectiontypes "github.com/cosmos/ibc-go/v7/modules/core/03-connection/types" "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" diff --git a/modules/core/04-channel/keeper/packet_test.go b/modules/core/04-channel/keeper/packet_test.go index 82cb113ae6a..6077127d432 100644 --- a/modules/core/04-channel/keeper/packet_test.go +++ b/modules/core/04-channel/keeper/packet_test.go @@ -5,8 +5,8 @@ import ( "fmt" errorsmod "cosmossdk.io/errors" - capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" + capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" connectiontypes "github.com/cosmos/ibc-go/v7/modules/core/03-connection/types" "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" diff --git a/modules/core/04-channel/keeper/timeout.go b/modules/core/04-channel/keeper/timeout.go index a0783131d9e..c0248917306 100644 --- a/modules/core/04-channel/keeper/timeout.go +++ b/modules/core/04-channel/keeper/timeout.go @@ -5,9 +5,10 @@ import ( "strconv" errorsmod "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" - capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" + capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" connectiontypes "github.com/cosmos/ibc-go/v7/modules/core/03-connection/types" "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" host "github.com/cosmos/ibc-go/v7/modules/core/24-host" diff --git a/modules/core/04-channel/keeper/timeout_test.go b/modules/core/04-channel/keeper/timeout_test.go index 337949b0288..3f834f4674b 100644 --- a/modules/core/04-channel/keeper/timeout_test.go +++ b/modules/core/04-channel/keeper/timeout_test.go @@ -5,8 +5,8 @@ import ( "fmt" errorsmod "cosmossdk.io/errors" - capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" + capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" connectiontypes "github.com/cosmos/ibc-go/v7/modules/core/03-connection/types" "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" diff --git a/modules/core/04-channel/simulation/decoder_test.go b/modules/core/04-channel/simulation/decoder_test.go index 64fd06d89f9..1e7bba78189 100644 --- a/modules/core/04-channel/simulation/decoder_test.go +++ b/modules/core/04-channel/simulation/decoder_test.go @@ -4,9 +4,10 @@ import ( "fmt" "testing" + "github.com/stretchr/testify/require" + sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/kv" - "github.com/stretchr/testify/require" "github.com/cosmos/ibc-go/v7/modules/core/04-channel/simulation" "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" diff --git a/modules/core/04-channel/types/acknowledgement.go b/modules/core/04-channel/types/acknowledgement.go index 3e4d02a1180..27617d391f5 100644 --- a/modules/core/04-channel/types/acknowledgement.go +++ b/modules/core/04-channel/types/acknowledgement.go @@ -6,6 +6,7 @@ import ( "strings" errorsmod "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" ) diff --git a/modules/core/04-channel/types/acknowledgement_test.go b/modules/core/04-channel/types/acknowledgement_test.go index 3d7c6222d08..b5ff0af3141 100644 --- a/modules/core/04-channel/types/acknowledgement_test.go +++ b/modules/core/04-channel/types/acknowledgement_test.go @@ -4,10 +4,12 @@ import ( "fmt" errorsmod "cosmossdk.io/errors" + + sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" + abcitypes "github.com/cometbft/cometbft/abci/types" tmprotostate "github.com/cometbft/cometbft/proto/tendermint/state" tmstate "github.com/cometbft/cometbft/state" - sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" ibcerrors "github.com/cosmos/ibc-go/v7/modules/core/errors" diff --git a/modules/core/04-channel/types/expected_keepers.go b/modules/core/04-channel/types/expected_keepers.go index 3230929bd98..342164e9393 100644 --- a/modules/core/04-channel/types/expected_keepers.go +++ b/modules/core/04-channel/types/expected_keepers.go @@ -2,8 +2,8 @@ package types import ( sdk "github.com/cosmos/cosmos-sdk/types" - capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" + capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" connectiontypes "github.com/cosmos/ibc-go/v7/modules/core/03-connection/types" "github.com/cosmos/ibc-go/v7/modules/core/exported" ) diff --git a/modules/core/04-channel/types/msgs.go b/modules/core/04-channel/types/msgs.go index 893b82156d0..6a7ff1752cc 100644 --- a/modules/core/04-channel/types/msgs.go +++ b/modules/core/04-channel/types/msgs.go @@ -4,6 +4,7 @@ import ( "encoding/base64" errorsmod "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" diff --git a/modules/core/04-channel/types/msgs_test.go b/modules/core/04-channel/types/msgs_test.go index 0d459dde865..9a80c8e68eb 100644 --- a/modules/core/04-channel/types/msgs_test.go +++ b/modules/core/04-channel/types/msgs_test.go @@ -4,14 +4,16 @@ import ( "fmt" "testing" - dbm "github.com/cometbft/cometbft-db" - abci "github.com/cometbft/cometbft/abci/types" - log "github.com/cometbft/cometbft/libs/log" + "github.com/stretchr/testify/suite" + "github.com/cosmos/cosmos-sdk/store/iavl" "github.com/cosmos/cosmos-sdk/store/rootmulti" storetypes "github.com/cosmos/cosmos-sdk/store/types" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/stretchr/testify/suite" + + dbm "github.com/cometbft/cometbft-db" + abci "github.com/cometbft/cometbft/abci/types" + log "github.com/cometbft/cometbft/libs/log" clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" diff --git a/modules/core/04-channel/types/packet.go b/modules/core/04-channel/types/packet.go index c007f3af9b0..26006f1fd20 100644 --- a/modules/core/04-channel/types/packet.go +++ b/modules/core/04-channel/types/packet.go @@ -4,6 +4,7 @@ import ( "crypto/sha256" errorsmod "cosmossdk.io/errors" + "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" diff --git a/modules/core/04-channel/types/packet_test.go b/modules/core/04-channel/types/packet_test.go index 780844dbb54..a33c6fb75bd 100644 --- a/modules/core/04-channel/types/packet_test.go +++ b/modules/core/04-channel/types/packet_test.go @@ -3,9 +3,10 @@ package types_test import ( "testing" + "github.com/stretchr/testify/require" + "github.com/cosmos/cosmos-sdk/codec" codectypes "github.com/cosmos/cosmos-sdk/codec/types" - "github.com/stretchr/testify/require" clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" diff --git a/modules/core/05-port/keeper/keeper.go b/modules/core/05-port/keeper/keeper.go index 802b818c8cc..f83c42af64b 100644 --- a/modules/core/05-port/keeper/keeper.go +++ b/modules/core/05-port/keeper/keeper.go @@ -3,10 +3,11 @@ package keeper import ( "fmt" - "github.com/cometbft/cometbft/libs/log" sdk "github.com/cosmos/cosmos-sdk/types" - capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" + "github.com/cometbft/cometbft/libs/log" + + capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" "github.com/cosmos/ibc-go/v7/modules/core/05-port/types" host "github.com/cosmos/ibc-go/v7/modules/core/24-host" "github.com/cosmos/ibc-go/v7/modules/core/exported" diff --git a/modules/core/05-port/keeper/keeper_test.go b/modules/core/05-port/keeper/keeper_test.go index b0459afa564..013f90868d9 100644 --- a/modules/core/05-port/keeper/keeper_test.go +++ b/modules/core/05-port/keeper/keeper_test.go @@ -3,11 +3,13 @@ package keeper_test import ( "testing" - tmproto "github.com/cometbft/cometbft/proto/tendermint/types" - sdk "github.com/cosmos/cosmos-sdk/types" "github.com/stretchr/testify/require" "github.com/stretchr/testify/suite" + sdk "github.com/cosmos/cosmos-sdk/types" + + tmproto "github.com/cometbft/cometbft/proto/tendermint/types" + "github.com/cosmos/ibc-go/v7/modules/core/05-port/keeper" "github.com/cosmos/ibc-go/v7/testing/simapp" ) diff --git a/modules/core/05-port/types/module.go b/modules/core/05-port/types/module.go index e6fef6420af..33465bf6f98 100644 --- a/modules/core/05-port/types/module.go +++ b/modules/core/05-port/types/module.go @@ -2,8 +2,8 @@ package types import ( sdk "github.com/cosmos/cosmos-sdk/types" - capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" + capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" channeltypes "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" "github.com/cosmos/ibc-go/v7/modules/core/exported" diff --git a/modules/core/23-commitment/types/commitment_test.go b/modules/core/23-commitment/types/commitment_test.go index 093e7df674c..9d204e108bf 100644 --- a/modules/core/23-commitment/types/commitment_test.go +++ b/modules/core/23-commitment/types/commitment_test.go @@ -3,12 +3,14 @@ package types_test import ( "testing" - dbm "github.com/cometbft/cometbft-db" - "github.com/cometbft/cometbft/libs/log" + "github.com/stretchr/testify/suite" + "github.com/cosmos/cosmos-sdk/store/iavl" "github.com/cosmos/cosmos-sdk/store/rootmulti" storetypes "github.com/cosmos/cosmos-sdk/store/types" - "github.com/stretchr/testify/suite" + + dbm "github.com/cometbft/cometbft-db" + "github.com/cometbft/cometbft/libs/log" ) type MerkleTestSuite struct { diff --git a/modules/core/23-commitment/types/merkle.go b/modules/core/23-commitment/types/merkle.go index 07c91deabc2..79a2c113fc6 100644 --- a/modules/core/23-commitment/types/merkle.go +++ b/modules/core/23-commitment/types/merkle.go @@ -5,11 +5,13 @@ import ( "fmt" "net/url" - errorsmod "cosmossdk.io/errors" - tmcrypto "github.com/cometbft/cometbft/proto/tendermint/crypto" "github.com/cosmos/gogoproto/proto" ics23 "github.com/cosmos/ics23/go" + errorsmod "cosmossdk.io/errors" + + tmcrypto "github.com/cometbft/cometbft/proto/tendermint/crypto" + "github.com/cosmos/ibc-go/v7/modules/core/exported" ) diff --git a/modules/core/23-commitment/types/merkle_test.go b/modules/core/23-commitment/types/merkle_test.go index 90fee1a8761..5b80c7ce266 100644 --- a/modules/core/23-commitment/types/merkle_test.go +++ b/modules/core/23-commitment/types/merkle_test.go @@ -4,9 +4,10 @@ import ( "fmt" "testing" - abci "github.com/cometbft/cometbft/abci/types" "github.com/stretchr/testify/require" + abci "github.com/cometbft/cometbft/abci/types" + "github.com/cosmos/ibc-go/v7/modules/core/23-commitment/types" ) diff --git a/modules/core/23-commitment/types/utils.go b/modules/core/23-commitment/types/utils.go index 83844d35960..79530fc51fd 100644 --- a/modules/core/23-commitment/types/utils.go +++ b/modules/core/23-commitment/types/utils.go @@ -1,9 +1,11 @@ package types import ( + ics23 "github.com/cosmos/ics23/go" + errorsmod "cosmossdk.io/errors" + crypto "github.com/cometbft/cometbft/proto/tendermint/crypto" - ics23 "github.com/cosmos/ics23/go" ) // ConvertProofs converts crypto.ProofOps into MerkleProof diff --git a/modules/core/23-commitment/types/utils_test.go b/modules/core/23-commitment/types/utils_test.go index 4f5b4f89f5c..f82dce0ad82 100644 --- a/modules/core/23-commitment/types/utils_test.go +++ b/modules/core/23-commitment/types/utils_test.go @@ -3,9 +3,10 @@ package types_test import ( "fmt" + "github.com/stretchr/testify/require" + abci "github.com/cometbft/cometbft/abci/types" crypto "github.com/cometbft/cometbft/proto/tendermint/crypto" - "github.com/stretchr/testify/require" "github.com/cosmos/ibc-go/v7/modules/core/23-commitment/types" ) diff --git a/modules/core/ante/ante_test.go b/modules/core/ante/ante_test.go index 20ed350a053..1ec224abe58 100644 --- a/modules/core/ante/ante_test.go +++ b/modules/core/ante/ante_test.go @@ -3,10 +3,11 @@ package ante_test import ( "testing" - sdk "github.com/cosmos/cosmos-sdk/types" "github.com/stretchr/testify/require" "github.com/stretchr/testify/suite" + sdk "github.com/cosmos/cosmos-sdk/types" + clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" channeltypes "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" host "github.com/cosmos/ibc-go/v7/modules/core/24-host" diff --git a/modules/core/client/cli/cli.go b/modules/core/client/cli/cli.go index 6d5da971264..08871519579 100644 --- a/modules/core/client/cli/cli.go +++ b/modules/core/client/cli/cli.go @@ -1,9 +1,10 @@ package cli import ( - "github.com/cosmos/cosmos-sdk/client" "github.com/spf13/cobra" + "github.com/cosmos/cosmos-sdk/client" + ibcclient "github.com/cosmos/ibc-go/v7/modules/core/02-client" connection "github.com/cosmos/ibc-go/v7/modules/core/03-connection" channel "github.com/cosmos/ibc-go/v7/modules/core/04-channel" diff --git a/modules/core/client/query.go b/modules/core/client/query.go index 19b490a1c25..57e06d56c3c 100644 --- a/modules/core/client/query.go +++ b/modules/core/client/query.go @@ -3,10 +3,11 @@ package client import ( "fmt" - abci "github.com/cometbft/cometbft/abci/types" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/codec" + abci "github.com/cometbft/cometbft/abci/types" + clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" commitmenttypes "github.com/cosmos/ibc-go/v7/modules/core/23-commitment/types" ibcexported "github.com/cosmos/ibc-go/v7/modules/core/exported" diff --git a/modules/core/exported/client.go b/modules/core/exported/client.go index 731d7e5edf7..1655df03141 100644 --- a/modules/core/exported/client.go +++ b/modules/core/exported/client.go @@ -1,9 +1,10 @@ package exported import ( + proto "github.com/cosmos/gogoproto/proto" + "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" - proto "github.com/cosmos/gogoproto/proto" ) // Status represents the status of a client diff --git a/modules/core/exported/expected_keepers.go b/modules/core/exported/expected_keepers.go index afd4bce4e56..f1496c7f2b2 100644 --- a/modules/core/exported/expected_keepers.go +++ b/modules/core/exported/expected_keepers.go @@ -2,6 +2,7 @@ package exported import ( sdk "github.com/cosmos/cosmos-sdk/types" + capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" ) diff --git a/modules/core/genesis_test.go b/modules/core/genesis_test.go index 51ba25a9ea0..64e60ee231c 100644 --- a/modules/core/genesis_test.go +++ b/modules/core/genesis_test.go @@ -4,10 +4,12 @@ import ( "fmt" "testing" - tmproto "github.com/cometbft/cometbft/proto/tendermint/types" - "github.com/cosmos/cosmos-sdk/codec" "github.com/stretchr/testify/suite" + "github.com/cosmos/cosmos-sdk/codec" + + tmproto "github.com/cometbft/cometbft/proto/tendermint/types" + ibc "github.com/cosmos/ibc-go/v7/modules/core" clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" connectiontypes "github.com/cosmos/ibc-go/v7/modules/core/03-connection/types" diff --git a/modules/core/keeper/keeper.go b/modules/core/keeper/keeper.go index fb2583a72c4..3c3d30a9ddf 100644 --- a/modules/core/keeper/keeper.go +++ b/modules/core/keeper/keeper.go @@ -7,8 +7,8 @@ import ( "github.com/cosmos/cosmos-sdk/codec" storetypes "github.com/cosmos/cosmos-sdk/store/types" paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" - capabilitykeeper "github.com/cosmos/ibc-go/modules/capability/keeper" + capabilitykeeper "github.com/cosmos/ibc-go/modules/capability/keeper" clientkeeper "github.com/cosmos/ibc-go/v7/modules/core/02-client/keeper" clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" connectionkeeper "github.com/cosmos/ibc-go/v7/modules/core/03-connection/keeper" diff --git a/modules/core/keeper/keeper_test.go b/modules/core/keeper/keeper_test.go index 8f927fb1815..19fb8132a07 100644 --- a/modules/core/keeper/keeper_test.go +++ b/modules/core/keeper/keeper_test.go @@ -4,13 +4,14 @@ import ( "testing" "time" + "github.com/stretchr/testify/suite" + sdk "github.com/cosmos/cosmos-sdk/types" stakingkeeper "github.com/cosmos/cosmos-sdk/x/staking/keeper" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" upgradekeeper "github.com/cosmos/cosmos-sdk/x/upgrade/keeper" - capabilitykeeper "github.com/cosmos/ibc-go/modules/capability/keeper" - "github.com/stretchr/testify/suite" + capabilitykeeper "github.com/cosmos/ibc-go/modules/capability/keeper" clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" ibcexported "github.com/cosmos/ibc-go/v7/modules/core/exported" ibckeeper "github.com/cosmos/ibc-go/v7/modules/core/keeper" diff --git a/modules/core/keeper/msg_server.go b/modules/core/keeper/msg_server.go index c75f11b8d87..dc2690e4e97 100644 --- a/modules/core/keeper/msg_server.go +++ b/modules/core/keeper/msg_server.go @@ -3,8 +3,10 @@ package keeper import ( "context" - errorsmod "cosmossdk.io/errors" metrics "github.com/armon/go-metrics" + + errorsmod "cosmossdk.io/errors" + "github.com/cosmos/cosmos-sdk/telemetry" sdk "github.com/cosmos/cosmos-sdk/types" diff --git a/modules/core/migrations/v7/genesis_test.go b/modules/core/migrations/v7/genesis_test.go index 943a9d9593f..bdbacb066b8 100644 --- a/modules/core/migrations/v7/genesis_test.go +++ b/modules/core/migrations/v7/genesis_test.go @@ -3,10 +3,11 @@ package v7_test import ( "testing" + "github.com/stretchr/testify/suite" + "github.com/cosmos/cosmos-sdk/codec" codectypes "github.com/cosmos/cosmos-sdk/codec/types" genutiltypes "github.com/cosmos/cosmos-sdk/x/genutil/types" - "github.com/stretchr/testify/suite" ibcclient "github.com/cosmos/ibc-go/v7/modules/core/02-client" clientv7 "github.com/cosmos/ibc-go/v7/modules/core/02-client/migrations/v7" diff --git a/modules/core/module.go b/modules/core/module.go index 08bec4991fb..501e5459f5b 100644 --- a/modules/core/module.go +++ b/modules/core/module.go @@ -5,15 +5,17 @@ import ( "encoding/json" "fmt" - abci "github.com/cometbft/cometbft/abci/types" + "github.com/grpc-ecosystem/grpc-gateway/runtime" + "github.com/spf13/cobra" + "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/codec" codectypes "github.com/cosmos/cosmos-sdk/codec/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" simtypes "github.com/cosmos/cosmos-sdk/types/simulation" - "github.com/grpc-ecosystem/grpc-gateway/runtime" - "github.com/spf13/cobra" + + abci "github.com/cometbft/cometbft/abci/types" ibcclient "github.com/cosmos/ibc-go/v7/modules/core/02-client" clientkeeper "github.com/cosmos/ibc-go/v7/modules/core/02-client/keeper" diff --git a/modules/core/simulation/decoder_test.go b/modules/core/simulation/decoder_test.go index bf0388ccd69..1c8787698e0 100644 --- a/modules/core/simulation/decoder_test.go +++ b/modules/core/simulation/decoder_test.go @@ -4,9 +4,10 @@ import ( "fmt" "testing" - "github.com/cosmos/cosmos-sdk/types/kv" "github.com/stretchr/testify/require" + "github.com/cosmos/cosmos-sdk/types/kv" + clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" connectiontypes "github.com/cosmos/ibc-go/v7/modules/core/03-connection/types" channeltypes "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" diff --git a/modules/core/simulation/genesis_test.go b/modules/core/simulation/genesis_test.go index f3bbf9ecc1c..bc589d016eb 100644 --- a/modules/core/simulation/genesis_test.go +++ b/modules/core/simulation/genesis_test.go @@ -5,13 +5,15 @@ import ( "math/rand" "testing" + "github.com/stretchr/testify/require" + sdkmath "cosmossdk.io/math" + "github.com/cosmos/cosmos-sdk/codec" codectypes "github.com/cosmos/cosmos-sdk/codec/types" cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" "github.com/cosmos/cosmos-sdk/types/module" simtypes "github.com/cosmos/cosmos-sdk/types/simulation" - "github.com/stretchr/testify/require" ibcexported "github.com/cosmos/ibc-go/v7/modules/core/exported" "github.com/cosmos/ibc-go/v7/modules/core/simulation" diff --git a/modules/light-clients/06-solomachine/client_state.go b/modules/light-clients/06-solomachine/client_state.go index fbd84e62534..282c421807a 100644 --- a/modules/light-clients/06-solomachine/client_state.go +++ b/modules/light-clients/06-solomachine/client_state.go @@ -4,6 +4,7 @@ import ( "reflect" errorsmod "cosmossdk.io/errors" + "github.com/cosmos/cosmos-sdk/codec" cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" sdk "github.com/cosmos/cosmos-sdk/types" diff --git a/modules/light-clients/06-solomachine/codec.go b/modules/light-clients/06-solomachine/codec.go index e18cd8b563c..2050df17d31 100644 --- a/modules/light-clients/06-solomachine/codec.go +++ b/modules/light-clients/06-solomachine/codec.go @@ -2,6 +2,7 @@ package solomachine import ( errorsmod "cosmossdk.io/errors" + "github.com/cosmos/cosmos-sdk/codec" codectypes "github.com/cosmos/cosmos-sdk/codec/types" "github.com/cosmos/cosmos-sdk/types/tx/signing" diff --git a/modules/light-clients/06-solomachine/consensus_state.go b/modules/light-clients/06-solomachine/consensus_state.go index 8925ec3a5c2..3394311ab96 100644 --- a/modules/light-clients/06-solomachine/consensus_state.go +++ b/modules/light-clients/06-solomachine/consensus_state.go @@ -4,6 +4,7 @@ import ( "strings" errorsmod "cosmossdk.io/errors" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" diff --git a/modules/light-clients/06-solomachine/header.go b/modules/light-clients/06-solomachine/header.go index 87d90dee48b..38c59ba7054 100644 --- a/modules/light-clients/06-solomachine/header.go +++ b/modules/light-clients/06-solomachine/header.go @@ -4,6 +4,7 @@ import ( "strings" errorsmod "cosmossdk.io/errors" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" diff --git a/modules/light-clients/06-solomachine/misbehaviour_handle.go b/modules/light-clients/06-solomachine/misbehaviour_handle.go index f65f3c95350..0d1d2a3a618 100644 --- a/modules/light-clients/06-solomachine/misbehaviour_handle.go +++ b/modules/light-clients/06-solomachine/misbehaviour_handle.go @@ -1,9 +1,9 @@ package solomachine import ( - "github.com/cosmos/cosmos-sdk/codec" - errorsmod "cosmossdk.io/errors" + + "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" commitmenttypes "github.com/cosmos/ibc-go/v7/modules/core/23-commitment/types" diff --git a/modules/light-clients/06-solomachine/module.go b/modules/light-clients/06-solomachine/module.go index 69c04e46f04..fea0450e1fd 100644 --- a/modules/light-clients/06-solomachine/module.go +++ b/modules/light-clients/06-solomachine/module.go @@ -3,12 +3,13 @@ package solomachine import ( "encoding/json" + "github.com/grpc-ecosystem/grpc-gateway/runtime" + "github.com/spf13/cobra" + "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/codec" codectypes "github.com/cosmos/cosmos-sdk/codec/types" "github.com/cosmos/cosmos-sdk/types/module" - "github.com/grpc-ecosystem/grpc-gateway/runtime" - "github.com/spf13/cobra" ) var _ module.AppModuleBasic = (*AppModuleBasic)(nil) diff --git a/modules/light-clients/06-solomachine/proof.go b/modules/light-clients/06-solomachine/proof.go index aab15c17d3c..f156e353408 100644 --- a/modules/light-clients/06-solomachine/proof.go +++ b/modules/light-clients/06-solomachine/proof.go @@ -2,6 +2,7 @@ package solomachine import ( errorsmod "cosmossdk.io/errors" + cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/crypto/types/multisig" "github.com/cosmos/cosmos-sdk/types/tx/signing" diff --git a/modules/light-clients/06-solomachine/proposal_handle.go b/modules/light-clients/06-solomachine/proposal_handle.go index 2e6fdfd7ed8..4ad6071cba0 100644 --- a/modules/light-clients/06-solomachine/proposal_handle.go +++ b/modules/light-clients/06-solomachine/proposal_handle.go @@ -4,6 +4,7 @@ import ( "reflect" errorsmod "cosmossdk.io/errors" + "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" diff --git a/modules/light-clients/06-solomachine/solomachine_test.go b/modules/light-clients/06-solomachine/solomachine_test.go index 824872df26e..b4b37b54857 100644 --- a/modules/light-clients/06-solomachine/solomachine_test.go +++ b/modules/light-clients/06-solomachine/solomachine_test.go @@ -4,13 +4,14 @@ import ( "testing" "time" + "github.com/stretchr/testify/require" + "github.com/stretchr/testify/suite" + codectypes "github.com/cosmos/cosmos-sdk/codec/types" cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" "github.com/cosmos/cosmos-sdk/crypto/keys/secp256k1" "github.com/cosmos/cosmos-sdk/testutil/testdata" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/stretchr/testify/require" - "github.com/stretchr/testify/suite" transfertypes "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types" clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" diff --git a/modules/light-clients/06-solomachine/update.go b/modules/light-clients/06-solomachine/update.go index 8d044e0a2e9..c08a3de3fb3 100644 --- a/modules/light-clients/06-solomachine/update.go +++ b/modules/light-clients/06-solomachine/update.go @@ -4,6 +4,7 @@ import ( "fmt" errorsmod "cosmossdk.io/errors" + "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" diff --git a/modules/light-clients/07-tendermint/client_state.go b/modules/light-clients/07-tendermint/client_state.go index 50284b84f48..722e2676415 100644 --- a/modules/light-clients/07-tendermint/client_state.go +++ b/modules/light-clients/07-tendermint/client_state.go @@ -4,12 +4,15 @@ import ( "strings" "time" + ics23 "github.com/cosmos/ics23/go" + errorsmod "cosmossdk.io/errors" - "github.com/cometbft/cometbft/light" - tmtypes "github.com/cometbft/cometbft/types" + "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" - ics23 "github.com/cosmos/ics23/go" + + "github.com/cometbft/cometbft/light" + tmtypes "github.com/cometbft/cometbft/types" clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" commitmenttypes "github.com/cosmos/ibc-go/v7/modules/core/23-commitment/types" diff --git a/modules/light-clients/07-tendermint/client_state_test.go b/modules/light-clients/07-tendermint/client_state_test.go index 9df8c6047ba..0eee6512d0c 100644 --- a/modules/light-clients/07-tendermint/client_state_test.go +++ b/modules/light-clients/07-tendermint/client_state_test.go @@ -3,9 +3,10 @@ package tendermint_test import ( "time" - sdk "github.com/cosmos/cosmos-sdk/types" ics23 "github.com/cosmos/ics23/go" + sdk "github.com/cosmos/cosmos-sdk/types" + transfertypes "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types" clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" channeltypes "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" diff --git a/modules/light-clients/07-tendermint/consensus_state.go b/modules/light-clients/07-tendermint/consensus_state.go index 86eb9a9fc58..b52fec596f9 100644 --- a/modules/light-clients/07-tendermint/consensus_state.go +++ b/modules/light-clients/07-tendermint/consensus_state.go @@ -4,6 +4,7 @@ import ( "time" errorsmod "cosmossdk.io/errors" + tmbytes "github.com/cometbft/cometbft/libs/bytes" tmtypes "github.com/cometbft/cometbft/types" diff --git a/modules/light-clients/07-tendermint/header.go b/modules/light-clients/07-tendermint/header.go index 8b0528a1f6c..1014c8a75ee 100644 --- a/modules/light-clients/07-tendermint/header.go +++ b/modules/light-clients/07-tendermint/header.go @@ -5,6 +5,7 @@ import ( "time" errorsmod "cosmossdk.io/errors" + tmtypes "github.com/cometbft/cometbft/types" clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" diff --git a/modules/light-clients/07-tendermint/migrations/expected_keepers.go b/modules/light-clients/07-tendermint/migrations/expected_keepers.go index e68bdbc97da..b655b187a27 100644 --- a/modules/light-clients/07-tendermint/migrations/expected_keepers.go +++ b/modules/light-clients/07-tendermint/migrations/expected_keepers.go @@ -1,9 +1,10 @@ package migrations import ( - "github.com/cometbft/cometbft/libs/log" sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/cometbft/cometbft/libs/log" + "github.com/cosmos/ibc-go/v7/modules/core/exported" ) diff --git a/modules/light-clients/07-tendermint/migrations/migrations.go b/modules/light-clients/07-tendermint/migrations/migrations.go index f5d28fe468f..bcb1deebeb1 100644 --- a/modules/light-clients/07-tendermint/migrations/migrations.go +++ b/modules/light-clients/07-tendermint/migrations/migrations.go @@ -2,6 +2,7 @@ package migrations import ( errorsmod "cosmossdk.io/errors" + "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" diff --git a/modules/light-clients/07-tendermint/misbehaviour.go b/modules/light-clients/07-tendermint/misbehaviour.go index f81f5a01385..bce812e4537 100644 --- a/modules/light-clients/07-tendermint/misbehaviour.go +++ b/modules/light-clients/07-tendermint/misbehaviour.go @@ -4,6 +4,7 @@ import ( "time" errorsmod "cosmossdk.io/errors" + tmproto "github.com/cometbft/cometbft/proto/tendermint/types" tmtypes "github.com/cometbft/cometbft/types" diff --git a/modules/light-clients/07-tendermint/misbehaviour_handle.go b/modules/light-clients/07-tendermint/misbehaviour_handle.go index 46b962fcabc..edc000dd0d5 100644 --- a/modules/light-clients/07-tendermint/misbehaviour_handle.go +++ b/modules/light-clients/07-tendermint/misbehaviour_handle.go @@ -6,10 +6,12 @@ import ( "time" errorsmod "cosmossdk.io/errors" - tmtypes "github.com/cometbft/cometbft/types" + "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" + tmtypes "github.com/cometbft/cometbft/types" + clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" "github.com/cosmos/ibc-go/v7/modules/core/exported" ) diff --git a/modules/light-clients/07-tendermint/module.go b/modules/light-clients/07-tendermint/module.go index e2201fc2876..516d7368afe 100644 --- a/modules/light-clients/07-tendermint/module.go +++ b/modules/light-clients/07-tendermint/module.go @@ -3,12 +3,13 @@ package tendermint import ( "encoding/json" + "github.com/grpc-ecosystem/grpc-gateway/runtime" + "github.com/spf13/cobra" + "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/codec" codectypes "github.com/cosmos/cosmos-sdk/codec/types" "github.com/cosmos/cosmos-sdk/types/module" - "github.com/grpc-ecosystem/grpc-gateway/runtime" - "github.com/spf13/cobra" ) var _ module.AppModuleBasic = (*AppModuleBasic)(nil) diff --git a/modules/light-clients/07-tendermint/proposal_handle.go b/modules/light-clients/07-tendermint/proposal_handle.go index 98b37ebf019..8205ef07893 100644 --- a/modules/light-clients/07-tendermint/proposal_handle.go +++ b/modules/light-clients/07-tendermint/proposal_handle.go @@ -5,6 +5,7 @@ import ( "time" errorsmod "cosmossdk.io/errors" + "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" diff --git a/modules/light-clients/07-tendermint/tendermint_test.go b/modules/light-clients/07-tendermint/tendermint_test.go index 3879282ef35..f3c5bb10c8a 100644 --- a/modules/light-clients/07-tendermint/tendermint_test.go +++ b/modules/light-clients/07-tendermint/tendermint_test.go @@ -4,12 +4,14 @@ import ( "testing" "time" + "github.com/stretchr/testify/suite" + + "github.com/cosmos/cosmos-sdk/codec" + sdk "github.com/cosmos/cosmos-sdk/types" + tmbytes "github.com/cometbft/cometbft/libs/bytes" tmproto "github.com/cometbft/cometbft/proto/tendermint/types" tmtypes "github.com/cometbft/cometbft/types" - "github.com/cosmos/cosmos-sdk/codec" - sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/stretchr/testify/suite" clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" ibctm "github.com/cosmos/ibc-go/v7/modules/light-clients/07-tendermint" diff --git a/modules/light-clients/07-tendermint/update.go b/modules/light-clients/07-tendermint/update.go index c3cd8144ff2..a82ea3acfcf 100644 --- a/modules/light-clients/07-tendermint/update.go +++ b/modules/light-clients/07-tendermint/update.go @@ -5,11 +5,13 @@ import ( "fmt" errorsmod "cosmossdk.io/errors" - "github.com/cometbft/cometbft/light" - tmtypes "github.com/cometbft/cometbft/types" + "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" + "github.com/cometbft/cometbft/light" + tmtypes "github.com/cometbft/cometbft/types" + clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" commitmenttypes "github.com/cosmos/ibc-go/v7/modules/core/23-commitment/types" host "github.com/cosmos/ibc-go/v7/modules/core/24-host" diff --git a/modules/light-clients/07-tendermint/update_test.go b/modules/light-clients/07-tendermint/update_test.go index b4e072ecbef..dc7e68629c1 100644 --- a/modules/light-clients/07-tendermint/update_test.go +++ b/modules/light-clients/07-tendermint/update_test.go @@ -3,9 +3,10 @@ package tendermint_test import ( "time" - tmtypes "github.com/cometbft/cometbft/types" sdk "github.com/cosmos/cosmos-sdk/types" + tmtypes "github.com/cometbft/cometbft/types" + clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" commitmenttypes "github.com/cosmos/ibc-go/v7/modules/core/23-commitment/types" host "github.com/cosmos/ibc-go/v7/modules/core/24-host" diff --git a/modules/light-clients/07-tendermint/upgrade.go b/modules/light-clients/07-tendermint/upgrade.go index 912a11d80a5..a8f18c5df9a 100644 --- a/modules/light-clients/07-tendermint/upgrade.go +++ b/modules/light-clients/07-tendermint/upgrade.go @@ -4,6 +4,7 @@ import ( "fmt" errorsmod "cosmossdk.io/errors" + "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types" diff --git a/modules/light-clients/09-localhost/client_state.go b/modules/light-clients/09-localhost/client_state.go index 902180a9292..a28ff2a942f 100644 --- a/modules/light-clients/09-localhost/client_state.go +++ b/modules/light-clients/09-localhost/client_state.go @@ -4,6 +4,7 @@ import ( "bytes" errorsmod "cosmossdk.io/errors" + "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" diff --git a/testing/app.go b/testing/app.go index 2f188d2770a..61f804c4a8d 100644 --- a/testing/app.go +++ b/testing/app.go @@ -5,12 +5,10 @@ import ( "testing" "time" + "github.com/stretchr/testify/require" + sdkmath "cosmossdk.io/math" - dbm "github.com/cometbft/cometbft-db" - abci "github.com/cometbft/cometbft/abci/types" - "github.com/cometbft/cometbft/libs/log" - tmproto "github.com/cometbft/cometbft/proto/tendermint/types" - tmtypes "github.com/cometbft/cometbft/types" + "github.com/cosmos/cosmos-sdk/baseapp" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/codec" @@ -22,9 +20,14 @@ import ( authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" - capabilitykeeper "github.com/cosmos/ibc-go/modules/capability/keeper" - "github.com/stretchr/testify/require" + dbm "github.com/cometbft/cometbft-db" + abci "github.com/cometbft/cometbft/abci/types" + "github.com/cometbft/cometbft/libs/log" + tmproto "github.com/cometbft/cometbft/proto/tendermint/types" + tmtypes "github.com/cometbft/cometbft/types" + + capabilitykeeper "github.com/cosmos/ibc-go/modules/capability/keeper" "github.com/cosmos/ibc-go/v7/modules/core/keeper" "github.com/cosmos/ibc-go/v7/testing/simapp" ibctestingtypes "github.com/cosmos/ibc-go/v7/testing/types" diff --git a/testing/chain.go b/testing/chain.go index 13ce21a8ec4..17513334525 100644 --- a/testing/chain.go +++ b/testing/chain.go @@ -5,14 +5,11 @@ import ( "testing" "time" + "github.com/stretchr/testify/require" + errorsmod "cosmossdk.io/errors" sdkmath "cosmossdk.io/math" - abci "github.com/cometbft/cometbft/abci/types" - "github.com/cometbft/cometbft/crypto/tmhash" - tmproto "github.com/cometbft/cometbft/proto/tendermint/types" - tmprotoversion "github.com/cometbft/cometbft/proto/tendermint/version" - tmtypes "github.com/cometbft/cometbft/types" - tmversion "github.com/cometbft/cometbft/version" + "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/codec" "github.com/cosmos/cosmos-sdk/crypto/keys/secp256k1" @@ -22,10 +19,16 @@ import ( banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" "github.com/cosmos/cosmos-sdk/x/staking/testutil" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" + + abci "github.com/cometbft/cometbft/abci/types" + "github.com/cometbft/cometbft/crypto/tmhash" + tmproto "github.com/cometbft/cometbft/proto/tendermint/types" + tmprotoversion "github.com/cometbft/cometbft/proto/tendermint/version" + tmtypes "github.com/cometbft/cometbft/types" + tmversion "github.com/cometbft/cometbft/version" + capabilitykeeper "github.com/cosmos/ibc-go/modules/capability/keeper" capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" - "github.com/stretchr/testify/require" - clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" commitmenttypes "github.com/cosmos/ibc-go/v7/modules/core/23-commitment/types" host "github.com/cosmos/ibc-go/v7/modules/core/24-host" diff --git a/testing/chain_test.go b/testing/chain_test.go index e0a97795e38..8eb6315716c 100644 --- a/testing/chain_test.go +++ b/testing/chain_test.go @@ -3,9 +3,11 @@ package ibctesting_test import ( "testing" + "github.com/stretchr/testify/require" + sdkmath "cosmossdk.io/math" + "github.com/cosmos/cosmos-sdk/x/staking/types" - "github.com/stretchr/testify/require" ibctesting "github.com/cosmos/ibc-go/v7/testing" ) diff --git a/testing/coordinator.go b/testing/coordinator.go index 0ad4b05a40e..1f3418a983c 100644 --- a/testing/coordinator.go +++ b/testing/coordinator.go @@ -6,8 +6,9 @@ import ( "testing" "time" - abci "github.com/cometbft/cometbft/abci/types" "github.com/stretchr/testify/require" + + abci "github.com/cometbft/cometbft/abci/types" ) var ( diff --git a/testing/endpoint.go b/testing/endpoint.go index 98c8d22f6f6..c938f99d5e6 100644 --- a/testing/endpoint.go +++ b/testing/endpoint.go @@ -4,9 +4,10 @@ import ( "fmt" "strings" + "github.com/stretchr/testify/require" + "github.com/cosmos/cosmos-sdk/baseapp" sdk "github.com/cosmos/cosmos-sdk/types" - "github.com/stretchr/testify/require" clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" connectiontypes "github.com/cosmos/ibc-go/v7/modules/core/03-connection/types" diff --git a/testing/events.go b/testing/events.go index ac1fdd71954..69fef9d1f8c 100644 --- a/testing/events.go +++ b/testing/events.go @@ -4,9 +4,10 @@ import ( "fmt" "strconv" - sdk "github.com/cosmos/cosmos-sdk/types" "github.com/stretchr/testify/suite" + sdk "github.com/cosmos/cosmos-sdk/types" + clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" connectiontypes "github.com/cosmos/ibc-go/v7/modules/core/03-connection/types" channeltypes "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" diff --git a/testing/mock/ibc_app.go b/testing/mock/ibc_app.go index 530bfaae4b5..ada64edfb40 100644 --- a/testing/mock/ibc_app.go +++ b/testing/mock/ibc_app.go @@ -2,9 +2,9 @@ package mock import ( sdk "github.com/cosmos/cosmos-sdk/types" + capabilitykeeper "github.com/cosmos/ibc-go/modules/capability/keeper" capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" - channeltypes "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" "github.com/cosmos/ibc-go/v7/modules/core/exported" ) diff --git a/testing/mock/ibc_module.go b/testing/mock/ibc_module.go index 698fad5f623..ec03110e164 100644 --- a/testing/mock/ibc_module.go +++ b/testing/mock/ibc_module.go @@ -7,8 +7,8 @@ import ( "strings" sdk "github.com/cosmos/cosmos-sdk/types" - capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" + capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" channeltypes "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" host "github.com/cosmos/ibc-go/v7/modules/core/24-host" "github.com/cosmos/ibc-go/v7/modules/core/exported" diff --git a/testing/mock/mock.go b/testing/mock/mock.go index 871996a9293..ca6e9c49eee 100644 --- a/testing/mock/mock.go +++ b/testing/mock/mock.go @@ -4,16 +4,18 @@ import ( "encoding/json" "fmt" - abci "github.com/cometbft/cometbft/abci/types" + "github.com/grpc-ecosystem/grpc-gateway/runtime" + "github.com/spf13/cobra" + "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/codec" codectypes "github.com/cosmos/cosmos-sdk/codec/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" - capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" - "github.com/grpc-ecosystem/grpc-gateway/runtime" - "github.com/spf13/cobra" + abci "github.com/cometbft/cometbft/abci/types" + + capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" channeltypes "github.com/cosmos/ibc-go/v7/modules/core/04-channel/types" porttypes "github.com/cosmos/ibc-go/v7/modules/core/05-port/types" host "github.com/cosmos/ibc-go/v7/modules/core/24-host" diff --git a/testing/mock/privval.go b/testing/mock/privval.go index a92cc1fc5fa..660fb481416 100644 --- a/testing/mock/privval.go +++ b/testing/mock/privval.go @@ -1,12 +1,13 @@ package mock import ( - "github.com/cometbft/cometbft/crypto" - tmproto "github.com/cometbft/cometbft/proto/tendermint/types" - tmtypes "github.com/cometbft/cometbft/types" cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" "github.com/cosmos/cosmos-sdk/crypto/keys/ed25519" cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" + + "github.com/cometbft/cometbft/crypto" + tmproto "github.com/cometbft/cometbft/proto/tendermint/types" + tmtypes "github.com/cometbft/cometbft/types" ) var _ tmtypes.PrivValidator = PV{} diff --git a/testing/mock/privval_test.go b/testing/mock/privval_test.go index d8ef0e4409b..0814c265b03 100644 --- a/testing/mock/privval_test.go +++ b/testing/mock/privval_test.go @@ -3,9 +3,10 @@ package mock_test import ( "testing" + "github.com/stretchr/testify/require" + tmproto "github.com/cometbft/cometbft/proto/tendermint/types" tmtypes "github.com/cometbft/cometbft/types" - "github.com/stretchr/testify/require" "github.com/cosmos/ibc-go/v7/testing/mock" ) diff --git a/testing/simapp/ante_handler.go b/testing/simapp/ante_handler.go index 1a0e2106045..1214324e66b 100644 --- a/testing/simapp/ante_handler.go +++ b/testing/simapp/ante_handler.go @@ -2,6 +2,7 @@ package simapp import ( errorsmod "cosmossdk.io/errors" + sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/x/auth/ante" diff --git a/testing/simapp/app.go b/testing/simapp/app.go index 63a7c522f18..90b9e5ab5bd 100644 --- a/testing/simapp/app.go +++ b/testing/simapp/app.go @@ -8,15 +8,17 @@ import ( "os" "path/filepath" + "github.com/gorilla/mux" + "github.com/rakyll/statik/fs" + "github.com/spf13/cast" + + _ "github.com/cosmos/cosmos-sdk/client/docs/statik" // this is used for serving docs + autocliv1 "cosmossdk.io/api/cosmos/autocli/v1" reflectionv1 "cosmossdk.io/api/cosmos/reflection/v1" - dbm "github.com/cometbft/cometbft-db" - abci "github.com/cometbft/cometbft/abci/types" - "github.com/cometbft/cometbft/libs/log" - tmos "github.com/cometbft/cometbft/libs/os" + "github.com/cosmos/cosmos-sdk/baseapp" "github.com/cosmos/cosmos-sdk/client" - _ "github.com/cosmos/cosmos-sdk/client/docs/statik" // this is used for serving docs nodeservice "github.com/cosmos/cosmos-sdk/client/grpc/node" "github.com/cosmos/cosmos-sdk/client/grpc/tmservice" "github.com/cosmos/cosmos-sdk/codec" @@ -88,14 +90,15 @@ import ( upgradeclient "github.com/cosmos/cosmos-sdk/x/upgrade/client" upgradekeeper "github.com/cosmos/cosmos-sdk/x/upgrade/keeper" upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types" - "github.com/gorilla/mux" - "github.com/rakyll/statik/fs" - "github.com/spf13/cast" + + dbm "github.com/cometbft/cometbft-db" + abci "github.com/cometbft/cometbft/abci/types" + "github.com/cometbft/cometbft/libs/log" + tmos "github.com/cometbft/cometbft/libs/os" "github.com/cosmos/ibc-go/modules/capability" capabilitykeeper "github.com/cosmos/ibc-go/modules/capability/keeper" capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" - ica "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts" icacontroller "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller" icacontrollerkeeper "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller/keeper" diff --git a/testing/simapp/export.go b/testing/simapp/export.go index 444c21c706e..05f8ffb4768 100644 --- a/testing/simapp/export.go +++ b/testing/simapp/export.go @@ -4,12 +4,13 @@ import ( "encoding/json" "log" - tmproto "github.com/cometbft/cometbft/proto/tendermint/types" servertypes "github.com/cosmos/cosmos-sdk/server/types" sdk "github.com/cosmos/cosmos-sdk/types" slashingtypes "github.com/cosmos/cosmos-sdk/x/slashing/types" "github.com/cosmos/cosmos-sdk/x/staking" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" + + tmproto "github.com/cometbft/cometbft/proto/tendermint/types" ) // ExportAppStateAndValidators exports the state of the application for a genesis diff --git a/testing/simapp/genesis_account_test.go b/testing/simapp/genesis_account_test.go index be767553606..c4488bb2826 100644 --- a/testing/simapp/genesis_account_test.go +++ b/testing/simapp/genesis_account_test.go @@ -4,11 +4,13 @@ import ( "testing" "time" - "github.com/cometbft/cometbft/crypto" + "github.com/stretchr/testify/require" + "github.com/cosmos/cosmos-sdk/crypto/keys/secp256k1" sdk "github.com/cosmos/cosmos-sdk/types" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" - "github.com/stretchr/testify/require" + + "github.com/cometbft/cometbft/crypto" "github.com/cosmos/ibc-go/v7/testing/simapp" ) diff --git a/testing/simapp/sim_bench_test.go b/testing/simapp/sim_bench_test.go index 4146da0a4b8..51f6ba5d410 100644 --- a/testing/simapp/sim_bench_test.go +++ b/testing/simapp/sim_bench_test.go @@ -5,11 +5,12 @@ import ( "os" "testing" - tmproto "github.com/cometbft/cometbft/proto/tendermint/types" "github.com/cosmos/cosmos-sdk/baseapp" simtestutil "github.com/cosmos/cosmos-sdk/testutil/sims" simtypes "github.com/cosmos/cosmos-sdk/types/simulation" "github.com/cosmos/cosmos-sdk/x/simulation" + + tmproto "github.com/cometbft/cometbft/proto/tendermint/types" ) // Profile with: diff --git a/testing/simapp/sim_test.go b/testing/simapp/sim_test.go index 5e4bcaa9d69..2122d46d79f 100644 --- a/testing/simapp/sim_test.go +++ b/testing/simapp/sim_test.go @@ -7,10 +7,8 @@ import ( "os" "testing" - dbm "github.com/cometbft/cometbft-db" - abci "github.com/cometbft/cometbft/abci/types" - "github.com/cometbft/cometbft/libs/log" - tmproto "github.com/cometbft/cometbft/proto/tendermint/types" + "github.com/stretchr/testify/require" + "github.com/cosmos/cosmos-sdk/baseapp" "github.com/cosmos/cosmos-sdk/store" storetypes "github.com/cosmos/cosmos-sdk/store/types" @@ -28,9 +26,13 @@ import ( "github.com/cosmos/cosmos-sdk/x/simulation" slashingtypes "github.com/cosmos/cosmos-sdk/x/slashing/types" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" - capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" - "github.com/stretchr/testify/require" + dbm "github.com/cometbft/cometbft-db" + abci "github.com/cometbft/cometbft/abci/types" + "github.com/cometbft/cometbft/libs/log" + tmproto "github.com/cometbft/cometbft/proto/tendermint/types" + + capabilitytypes "github.com/cosmos/ibc-go/modules/capability/types" ibctransfertypes "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types" ibcexported "github.com/cosmos/ibc-go/v7/modules/core/exported" ) diff --git a/testing/simapp/simd/cmd/cmd_test.go b/testing/simapp/simd/cmd/cmd_test.go index 4ac8843035a..1ffb1ec7243 100644 --- a/testing/simapp/simd/cmd/cmd_test.go +++ b/testing/simapp/simd/cmd/cmd_test.go @@ -4,9 +4,10 @@ import ( "fmt" "testing" + "github.com/stretchr/testify/require" + svrcmd "github.com/cosmos/cosmos-sdk/server/cmd" "github.com/cosmos/cosmos-sdk/x/genutil/client/cli" - "github.com/stretchr/testify/require" "github.com/cosmos/ibc-go/v7/testing/simapp" "github.com/cosmos/ibc-go/v7/testing/simapp/simd/cmd" diff --git a/testing/simapp/simd/cmd/root.go b/testing/simapp/simd/cmd/root.go index ad020c353bc..7a7d59a5453 100644 --- a/testing/simapp/simd/cmd/root.go +++ b/testing/simapp/simd/cmd/root.go @@ -6,11 +6,9 @@ import ( "os" "path/filepath" - dbm "github.com/cometbft/cometbft-db" - tmcfg "github.com/cometbft/cometbft/config" - tmcli "github.com/cometbft/cometbft/libs/cli" - "github.com/cometbft/cometbft/libs/log" - tmtypes "github.com/cometbft/cometbft/types" + "github.com/spf13/cast" + "github.com/spf13/cobra" + "github.com/cosmos/cosmos-sdk/baseapp" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/config" @@ -29,8 +27,12 @@ import ( "github.com/cosmos/cosmos-sdk/x/auth/types" "github.com/cosmos/cosmos-sdk/x/crisis" genutilcli "github.com/cosmos/cosmos-sdk/x/genutil/client/cli" - "github.com/spf13/cast" - "github.com/spf13/cobra" + + dbm "github.com/cometbft/cometbft-db" + tmcfg "github.com/cometbft/cometbft/config" + tmcli "github.com/cometbft/cometbft/libs/cli" + "github.com/cometbft/cometbft/libs/log" + tmtypes "github.com/cometbft/cometbft/types" "github.com/cosmos/ibc-go/v7/testing/simapp" "github.com/cosmos/ibc-go/v7/testing/simapp/params" diff --git a/testing/simapp/state.go b/testing/simapp/state.go index fb69deb7512..d7e5853d162 100644 --- a/testing/simapp/state.go +++ b/testing/simapp/state.go @@ -9,8 +9,7 @@ import ( "time" sdkmath "cosmossdk.io/math" - tmjson "github.com/cometbft/cometbft/libs/json" - tmtypes "github.com/cometbft/cometbft/types" + "github.com/cosmos/cosmos-sdk/codec" "github.com/cosmos/cosmos-sdk/crypto/keys/secp256k1" sdk "github.com/cosmos/cosmos-sdk/types" @@ -20,6 +19,9 @@ import ( banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" + tmjson "github.com/cometbft/cometbft/libs/json" + tmtypes "github.com/cometbft/cometbft/types" + simappparams "github.com/cosmos/ibc-go/v7/testing/simapp/params" ) diff --git a/testing/simapp/test_helpers.go b/testing/simapp/test_helpers.go index 64226ae9d74..7399cf697c6 100644 --- a/testing/simapp/test_helpers.go +++ b/testing/simapp/test_helpers.go @@ -6,12 +6,10 @@ import ( "testing" "time" + "github.com/stretchr/testify/require" + sdkmath "cosmossdk.io/math" - dbm "github.com/cometbft/cometbft-db" - abci "github.com/cometbft/cometbft/abci/types" - "github.com/cometbft/cometbft/libs/log" - tmproto "github.com/cometbft/cometbft/proto/tendermint/types" - tmtypes "github.com/cometbft/cometbft/types" + bam "github.com/cosmos/cosmos-sdk/baseapp" "github.com/cosmos/cosmos-sdk/client" codectypes "github.com/cosmos/cosmos-sdk/codec/types" @@ -23,7 +21,12 @@ import ( authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" - "github.com/stretchr/testify/require" + + dbm "github.com/cometbft/cometbft-db" + abci "github.com/cometbft/cometbft/abci/types" + "github.com/cometbft/cometbft/libs/log" + tmproto "github.com/cometbft/cometbft/proto/tendermint/types" + tmtypes "github.com/cometbft/cometbft/types" "github.com/cosmos/ibc-go/v7/testing/mock" ) diff --git a/testing/simapp/upgrades/upgrades.go b/testing/simapp/upgrades/upgrades.go index fef17bce5a0..1a8a8a9052c 100644 --- a/testing/simapp/upgrades/upgrades.go +++ b/testing/simapp/upgrades/upgrades.go @@ -10,8 +10,8 @@ import ( paramskeeper "github.com/cosmos/cosmos-sdk/x/params/keeper" paramstypes "github.com/cosmos/cosmos-sdk/x/params/types" upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types" - capabilitykeeper "github.com/cosmos/ibc-go/modules/capability/keeper" + capabilitykeeper "github.com/cosmos/ibc-go/modules/capability/keeper" v6 "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller/migrations/v6" clientkeeper "github.com/cosmos/ibc-go/v7/modules/core/02-client/keeper" "github.com/cosmos/ibc-go/v7/modules/core/exported" diff --git a/testing/simapp/utils.go b/testing/simapp/utils.go index faa7bbcf820..31f4b1aa05a 100644 --- a/testing/simapp/utils.go +++ b/testing/simapp/utils.go @@ -3,9 +3,10 @@ package simapp import ( "os" + simtypes "github.com/cosmos/cosmos-sdk/types/simulation" + dbm "github.com/cometbft/cometbft-db" "github.com/cometbft/cometbft/libs/log" - simtypes "github.com/cosmos/cosmos-sdk/types/simulation" ) // SetupSimulation creates the config, db (levelDB), temporary directory and logger for diff --git a/testing/simapp/utils_test.go b/testing/simapp/utils_test.go index 4b828a2e4d7..b9f07a0b9bb 100644 --- a/testing/simapp/utils_test.go +++ b/testing/simapp/utils_test.go @@ -4,6 +4,8 @@ import ( "fmt" "testing" + "github.com/stretchr/testify/require" + "github.com/cosmos/cosmos-sdk/codec" "github.com/cosmos/cosmos-sdk/std" "github.com/cosmos/cosmos-sdk/testutil/sims" @@ -11,7 +13,6 @@ import ( "github.com/cosmos/cosmos-sdk/types/kv" "github.com/cosmos/cosmos-sdk/types/module" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" - "github.com/stretchr/testify/require" ) func makeCodec(bm module.BasicManager) *codec.LegacyAmino { diff --git a/testing/solomachine.go b/testing/solomachine.go index 313e93de696..df683d3ea0c 100644 --- a/testing/solomachine.go +++ b/testing/solomachine.go @@ -4,7 +4,10 @@ import ( "testing" "time" + "github.com/stretchr/testify/require" + sdkmath "cosmossdk.io/math" + "github.com/cosmos/cosmos-sdk/codec" codectypes "github.com/cosmos/cosmos-sdk/codec/types" kmultisig "github.com/cosmos/cosmos-sdk/crypto/keys/multisig" @@ -13,7 +16,6 @@ import ( "github.com/cosmos/cosmos-sdk/crypto/types/multisig" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/tx/signing" - "github.com/stretchr/testify/require" transfertypes "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types" clienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" diff --git a/testing/utils.go b/testing/utils.go index 08d483a218d..302d0e70822 100644 --- a/testing/utils.go +++ b/testing/utils.go @@ -3,9 +3,10 @@ package ibctesting import ( "testing" + "github.com/stretchr/testify/require" + abci "github.com/cometbft/cometbft/abci/types" tmtypes "github.com/cometbft/cometbft/types" - "github.com/stretchr/testify/require" ) // ApplyValSetChanges takes in tmtypes.ValidatorSet and []abci.ValidatorUpdate and will return a new tmtypes.ValidatorSet which has the diff --git a/testing/values.go b/testing/values.go index 0251e40bc81..3e933053c23 100644 --- a/testing/values.go +++ b/testing/values.go @@ -8,6 +8,7 @@ import ( "time" sdkmath "cosmossdk.io/math" + sdk "github.com/cosmos/cosmos-sdk/types" ibctransfertypes "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types" From e3b218281bc3dce9dae78fba79ac3b66d9992ad9 Mon Sep 17 00:00:00 2001 From: Carlos Rodriguez Date: Tue, 20 Jun 2023 21:51:21 +0200 Subject: [PATCH 7/7] docs: update docs for updating client params (#3869) * update docs for updating client params * Update setup.md * Update setup.md --- docs/ibc/light-clients/setup.md | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) diff --git a/docs/ibc/light-clients/setup.md b/docs/ibc/light-clients/setup.md index 9e97ab22de5..288f2b74def 100644 --- a/docs/ibc/light-clients/setup.md +++ b/docs/ibc/light-clients/setup.md @@ -101,14 +101,10 @@ Within the `02-client` submodule, the [`ClientState` is then initialized](https: In order to successfully create an IBC client using a new client type, it [must be supported](https://github.com/cosmos/ibc-go/blob/v7.0.0/modules/core/02-client/keeper/client.go#L19-L25). Light client support in IBC is gated by on-chain governance. The allow list may be updated by submitting a new governance proposal to update the `02-client` parameter `AllowedClients`. - See below for example: ```shell -%s tx gov submit-proposal param-change --from= +%s tx gov submit-proposal --from ``` where `proposal.json` contains: @@ -116,14 +112,17 @@ where `proposal.json` contains: ```json { "title": "IBC Clients Param Change", - "description": "Update allowed clients", - "changes": [ + "summary": "Update allowed clients", + "messages": [ { - "subspace": "ibc", - "key": "AllowedClients", - "value": ["06-solomachine", "07-tendermint", "0x-new-client"] + "@type": "/ibc.core.client.v1.MsgUpdateParams", + "authority": "cosmos1...", // The gov module account address + "params": { + "allowed_clients": ["06-solomachine", "07-tendermint", "0x-new-client"] + } } ], - "deposit": "1000stake" + "metadata": "AQ==", + "deposit": "100stake" } ```