From c864bc783926c963ca787a91366b16271e8e1b59 Mon Sep 17 00:00:00 2001 From: Amaury M <1293565+amaurym@users.noreply.github.com> Date: Thu, 6 Oct 2022 12:09:31 +0200 Subject: [PATCH 1/9] Revert "chore: change id to use uint64 in `AccountAddressByID` (#13411)" This reverts commit 3d0e214446fbd888621da5a5f87ed90ce87d17ef. --- CHANGELOG.md | 1 - api/cosmos/auth/v1beta1/query.pulsar.go | 22 ++--- proto/cosmos/auth/v1beta1/query.proto | 2 +- x/auth/client/cli/query.go | 4 +- x/auth/keeper/grpc_query.go | 6 +- x/auth/keeper/grpc_query_test.go | 10 +- x/auth/types/query.pb.go | 122 ++++++++++++------------ x/auth/types/query.pb.gw.go | 4 +- 8 files changed, 91 insertions(+), 80 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index c6446bc9cd7b..05da79589c1f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -143,7 +143,6 @@ Ref: https://keepachangelog.com/en/1.0.0/ * (codec) [#12964](https://github.com/cosmos/cosmos-sdk/pull/12964) `ProtoCodec.MarshalInterface` now returns an error when serializing unregistered types and a subsequent `ProtoCodec.UnmarshalInterface` would fail. * (x/staking) [#12973](https://github.com/cosmos/cosmos-sdk/pull/12973) Removed `stakingkeeper.RandomValidator`. Use `testutil.RandSliceElem(r, sk.GetAllValidators(ctx))` instead. * (x/gov) [13160](https://github.com/cosmos/cosmos-sdk/pull/13160) Remove custom marshaling of proposl and voteoption. -* (x/auth) [13411](https://github.com/cosmos/cosmos-sdk/pull/13411) Change account id to use uint64 in `AccountAddressByID` grpc query. * (types) [13430](https://github.com/cosmos/cosmos-sdk/pull/13430) Remove unused code `ResponseCheckTx` and `ResponseDeliverTx` ### CLI Breaking Changes diff --git a/api/cosmos/auth/v1beta1/query.pulsar.go b/api/cosmos/auth/v1beta1/query.pulsar.go index 6336b68e6d06..799865e0bdfe 100644 --- a/api/cosmos/auth/v1beta1/query.pulsar.go +++ b/api/cosmos/auth/v1beta1/query.pulsar.go @@ -6058,8 +6058,8 @@ func (x *fastReflection_QueryAccountAddressByIDRequest) Interface() protoreflect // While iterating, mutating operations may only be performed // on the current field descriptor. func (x *fastReflection_QueryAccountAddressByIDRequest) Range(f func(protoreflect.FieldDescriptor, protoreflect.Value) bool) { - if x.Id != uint64(0) { - value := protoreflect.ValueOfUint64(x.Id) + if x.Id != int64(0) { + value := protoreflect.ValueOfInt64(x.Id) if !f(fd_QueryAccountAddressByIDRequest_id, value) { return } @@ -6080,7 +6080,7 @@ func (x *fastReflection_QueryAccountAddressByIDRequest) Range(f func(protoreflec func (x *fastReflection_QueryAccountAddressByIDRequest) Has(fd protoreflect.FieldDescriptor) bool { switch fd.FullName() { case "cosmos.auth.v1beta1.QueryAccountAddressByIDRequest.id": - return x.Id != uint64(0) + return x.Id != int64(0) default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.auth.v1beta1.QueryAccountAddressByIDRequest")) @@ -6098,7 +6098,7 @@ func (x *fastReflection_QueryAccountAddressByIDRequest) Has(fd protoreflect.Fiel func (x *fastReflection_QueryAccountAddressByIDRequest) Clear(fd protoreflect.FieldDescriptor) { switch fd.FullName() { case "cosmos.auth.v1beta1.QueryAccountAddressByIDRequest.id": - x.Id = uint64(0) + x.Id = int64(0) default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.auth.v1beta1.QueryAccountAddressByIDRequest")) @@ -6117,7 +6117,7 @@ func (x *fastReflection_QueryAccountAddressByIDRequest) Get(descriptor protorefl switch descriptor.FullName() { case "cosmos.auth.v1beta1.QueryAccountAddressByIDRequest.id": value := x.Id - return protoreflect.ValueOfUint64(value) + return protoreflect.ValueOfInt64(value) default: if descriptor.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.auth.v1beta1.QueryAccountAddressByIDRequest")) @@ -6139,7 +6139,7 @@ func (x *fastReflection_QueryAccountAddressByIDRequest) Get(descriptor protorefl func (x *fastReflection_QueryAccountAddressByIDRequest) Set(fd protoreflect.FieldDescriptor, value protoreflect.Value) { switch fd.FullName() { case "cosmos.auth.v1beta1.QueryAccountAddressByIDRequest.id": - x.Id = value.Uint() + x.Id = value.Int() default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.auth.v1beta1.QueryAccountAddressByIDRequest")) @@ -6176,7 +6176,7 @@ func (x *fastReflection_QueryAccountAddressByIDRequest) Mutable(fd protoreflect. func (x *fastReflection_QueryAccountAddressByIDRequest) NewField(fd protoreflect.FieldDescriptor) protoreflect.Value { switch fd.FullName() { case "cosmos.auth.v1beta1.QueryAccountAddressByIDRequest.id": - return protoreflect.ValueOfUint64(uint64(0)) + return protoreflect.ValueOfInt64(int64(0)) default: if fd.IsExtension() { panic(fmt.Errorf("proto3 declared messages do not support extensions: cosmos.auth.v1beta1.QueryAccountAddressByIDRequest")) @@ -6346,7 +6346,7 @@ func (x *fastReflection_QueryAccountAddressByIDRequest) ProtoMethods() *protoifa } b := dAtA[iNdEx] iNdEx++ - x.Id |= uint64(b&0x7F) << shift + x.Id |= int64(b&0x7F) << shift if b < 0x80 { break } @@ -8191,7 +8191,7 @@ type QueryAccountAddressByIDRequest struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` + Id int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` } func (x *QueryAccountAddressByIDRequest) Reset() { @@ -8214,7 +8214,7 @@ func (*QueryAccountAddressByIDRequest) Descriptor() ([]byte, []int) { return file_cosmos_auth_v1beta1_query_proto_rawDescGZIP(), []int{14} } -func (x *QueryAccountAddressByIDRequest) GetId() uint64 { +func (x *QueryAccountAddressByIDRequest) GetId() int64 { if x != nil { return x.Id } @@ -8417,7 +8417,7 @@ var file_cosmos_auth_v1beta1_query_proto_rawDesc = []byte{ 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x42, 0x79, 0x74, 0x65, 0x73, 0x22, 0x30, 0x0a, 0x1e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x42, 0x79, 0x49, 0x44, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, - 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x02, 0x69, 0x64, 0x22, 0x64, + 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x69, 0x64, 0x22, 0x64, 0x0a, 0x1f, 0x51, 0x75, 0x65, 0x72, 0x79, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x42, 0x79, 0x49, 0x44, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x41, 0x0a, 0x0f, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x5f, 0x61, 0x64, 0x64, diff --git a/proto/cosmos/auth/v1beta1/query.proto b/proto/cosmos/auth/v1beta1/query.proto index 656f5d4bd719..8cfa1fab0fcf 100644 --- a/proto/cosmos/auth/v1beta1/query.proto +++ b/proto/cosmos/auth/v1beta1/query.proto @@ -181,7 +181,7 @@ message AddressStringToBytesResponse { // QueryAccountAddressByIDRequest is the request type for AccountAddressByID rpc method message QueryAccountAddressByIDRequest { - uint64 id = 1; + int64 id = 1; } // QueryAccountAddressByIDResponse is the response type for AccountAddressByID rpc method diff --git a/x/auth/client/cli/query.go b/x/auth/client/cli/query.go index 6ddde70a30f6..3c9dd000106c 100644 --- a/x/auth/client/cli/query.go +++ b/x/auth/client/cli/query.go @@ -139,9 +139,9 @@ func GetAccountAddressByIDCmd() *cobra.Command { return err } - id, err := strconv.ParseUint(args[0], 10, 64) + id, err := strconv.ParseInt(args[0], 10, 64) if err != nil { - return fmt.Errorf("id %s not a valid uint, please input a valid account-id", args[0]) + return err } queryClient := types.NewQueryClient(clientCtx) diff --git a/x/auth/keeper/grpc_query.go b/x/auth/keeper/grpc_query.go index 2322076ddd77..bb09dbdeac9a 100644 --- a/x/auth/keeper/grpc_query.go +++ b/x/auth/keeper/grpc_query.go @@ -24,8 +24,12 @@ func (ak AccountKeeper) AccountAddressByID(c context.Context, req *types.QueryAc return nil, status.Errorf(codes.InvalidArgument, "empty request") } + if req.Id < 0 { + return nil, status.Error(codes.InvalidArgument, "Invalid account id") + } + ctx := sdk.UnwrapSDKContext(c) - address := ak.GetAccountAddressByID(ctx, req.Id) + address := ak.GetAccountAddressByID(ctx, uint64(req.GetId())) if len(address) == 0 { return nil, status.Errorf(codes.NotFound, "account address not found with id %d", req.Id) } diff --git a/x/auth/keeper/grpc_query_test.go b/x/auth/keeper/grpc_query_test.go index 70594178fbdb..86bec2e27ef6 100644 --- a/x/auth/keeper/grpc_query_test.go +++ b/x/auth/keeper/grpc_query_test.go @@ -166,6 +166,14 @@ func (suite *KeeperTestSuite) TestGRPCQueryAccountAddressByID() { expPass bool posttests func(res *types.QueryAccountAddressByIDResponse) }{ + { + "invalid request", + func() { + req = &types.QueryAccountAddressByIDRequest{Id: -1} + }, + false, + func(res *types.QueryAccountAddressByIDResponse) {}, + }, { "account address not found", func() { @@ -179,7 +187,7 @@ func (suite *KeeperTestSuite) TestGRPCQueryAccountAddressByID() { func() { account := suite.accountKeeper.NewAccountWithAddress(suite.ctx, addr) suite.accountKeeper.SetAccount(suite.ctx, account) - req = &types.QueryAccountAddressByIDRequest{Id: account.GetAccountNumber()} + req = &types.QueryAccountAddressByIDRequest{Id: int64(account.GetAccountNumber())} }, true, func(res *types.QueryAccountAddressByIDResponse) { diff --git a/x/auth/types/query.pb.go b/x/auth/types/query.pb.go index a3b43c9516a9..60192dc75978 100644 --- a/x/auth/types/query.pb.go +++ b/x/auth/types/query.pb.go @@ -667,7 +667,7 @@ func (m *AddressStringToBytesResponse) GetAddressBytes() []byte { // QueryAccountAddressByIDRequest is the request type for AccountAddressByID rpc method type QueryAccountAddressByIDRequest struct { - Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` + Id int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` } func (m *QueryAccountAddressByIDRequest) Reset() { *m = QueryAccountAddressByIDRequest{} } @@ -703,7 +703,7 @@ func (m *QueryAccountAddressByIDRequest) XXX_DiscardUnknown() { var xxx_messageInfo_QueryAccountAddressByIDRequest proto.InternalMessageInfo -func (m *QueryAccountAddressByIDRequest) GetId() uint64 { +func (m *QueryAccountAddressByIDRequest) GetId() int64 { if m != nil { return m.Id } @@ -873,66 +873,66 @@ func init() { proto.RegisterFile("cosmos/auth/v1beta1/query.proto", fileDescript var fileDescriptor_c451370b3929a27c = []byte{ // 971 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x96, 0xcf, 0x6f, 0x1b, 0x45, - 0x14, 0xc7, 0xbd, 0x21, 0x24, 0xe1, 0xc5, 0x0d, 0xd2, 0xc4, 0x15, 0x61, 0x9d, 0xda, 0xd1, 0x16, - 0x1a, 0x27, 0xd4, 0xbb, 0x8d, 0x93, 0x03, 0x05, 0x84, 0x14, 0x37, 0x80, 0x72, 0xa8, 0x64, 0xb6, - 0x39, 0x71, 0xc0, 0x5a, 0x7b, 0x37, 0x9b, 0x15, 0xcd, 0x8e, 0xeb, 0x59, 0xa3, 0x46, 0x55, 0x2e, - 0x48, 0x48, 0xbd, 0x54, 0x42, 0x82, 0x3f, 0x20, 0x07, 0xc4, 0x99, 0x43, 0xe0, 0xca, 0xb5, 0xea, - 0xa9, 0x82, 0x0b, 0x27, 0x84, 0x12, 0x24, 0xf8, 0x33, 0x90, 0x67, 0xde, 0xec, 0x8f, 0x64, 0x6c,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, 0x54, 0xcd, 0xfc, 0x3c, 0x89, 0x13, 0xe3, + 0x7f, 0xd8, 0x78, 0x25, 0xd5, 0xd4, 0x26, 0xea, 0x6c, 0x8c, 0x79, 0x24, 0xf4, 0xf5, 0x2b, 0x78, + 0x20, 0xe7, 0x7b, 0x09, 0x67, 0x9d, 0xbc, 0x3b, 0x86, 0x33, 0xbe, 0x2a, 0x62, 0x5a, 0x1f, 0x91, + 0x5f, 0x12, 0xee, 0xcc, 0x80, 0x1f, 0xcf, 0xad, 0x7a, 0x51, 0xc6, 0x73, 0x2b, 0x5f, 0x0f, 0xe3, + 0x7e, 0xc2, 0x6d, 0x92, 0xbb, 0xb9, 0xb8, 0xc5, 0x63, 0x75, 0x44, 0x7e, 0xd0, 0x60, 0x2e, 0x35, + 0x68, 0xc9, 0xdd, 0x89, 0xb7, 0x35, 0x35, 0xde, 0xf5, 0x7a, 0x4e, 0xeb, 0xfc, 0xf9, 0x95, 0x6f, + 0xd1, 0x70, 0x6e, 0x27, 0x03, 0xa9, 0xf9, 0xe0, 0xe5, 0x59, 0x45, 0x3b, 0x3d, 0xab, 0x68, 0x7f, + 0x9d, 0x55, 0xb4, 0x6f, 0xcf, 0x2b, 0x85, 0xd3, 0xf3, 0x4a, 0xe1, 0x8f, 0xf3, 0x4a, 0xe1, 0xf3, + 0x55, 0x3f, 0x88, 0xf6, 0x07, 0x1d, 0xb3, 0x4b, 0x0f, 0xa4, 0xa0, 0xf8, 0x53, 0x67, 0xee, 0x97, + 0xd6, 0x53, 0xa1, 0x1e, 0x1d, 0xf6, 0x3c, 0xd6, 0x99, 0xe6, 0xff, 0xd5, 0x6c, 0xfc, 0x17, 0x00, + 0x00, 0xff, 0xff, 0x83, 0xfa, 0x46, 0x09, 0x54, 0x0c, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -3304,7 +3304,7 @@ func (m *QueryAccountAddressByIDRequest) Unmarshal(dAtA []byte) error { } b := dAtA[iNdEx] iNdEx++ - m.Id |= uint64(b&0x7F) << shift + m.Id |= int64(b&0x7F) << shift if b < 0x80 { break } diff --git a/x/auth/types/query.pb.gw.go b/x/auth/types/query.pb.gw.go index f11d69b03cda..5c1ff90d4753 100644 --- a/x/auth/types/query.pb.gw.go +++ b/x/auth/types/query.pb.gw.go @@ -139,7 +139,7 @@ func request_Query_AccountAddressByID_0(ctx context.Context, marshaler runtime.M return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "id") } - protoReq.Id, err = runtime.Uint64(val) + protoReq.Id, err = runtime.Int64(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "id", err) @@ -166,7 +166,7 @@ func local_request_Query_AccountAddressByID_0(ctx context.Context, marshaler run return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "id") } - protoReq.Id, err = runtime.Uint64(val) + protoReq.Id, err = runtime.Int64(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "id", err) From f390a86f4815b0d4f3dcd5c056d3df69590a4c08 Mon Sep 17 00:00:00 2001 From: Amaury M <1293565+amaurym@users.noreply.github.com> Date: Thu, 6 Oct 2022 12:11:06 +0200 Subject: [PATCH 2/9] Add since --- proto/cosmos/auth/v1beta1/query.proto | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/proto/cosmos/auth/v1beta1/query.proto b/proto/cosmos/auth/v1beta1/query.proto index 8cfa1fab0fcf..3e08225b411a 100644 --- a/proto/cosmos/auth/v1beta1/query.proto +++ b/proto/cosmos/auth/v1beta1/query.proto @@ -31,6 +31,8 @@ service Query { } // AccountAddressByID returns account address based on account id + // + // Since: cosmos-sdk 0.46.2 rpc AccountAddressByID(QueryAccountAddressByIDRequest) returns (QueryAccountAddressByIDResponse) { option (cosmos.query.v1.module_query_safe) = true; option (google.api.http).get = "/cosmos/auth/v1beta1/address_by_id/{id}"; @@ -180,16 +182,22 @@ message AddressStringToBytesResponse { } // QueryAccountAddressByIDRequest is the request type for AccountAddressByID rpc method +// +// Since: cosmos-sdk 0.46.2 message QueryAccountAddressByIDRequest { int64 id = 1; } // QueryAccountAddressByIDResponse is the response type for AccountAddressByID rpc method +// +// Since: cosmos-sdk 0.46.2 message QueryAccountAddressByIDResponse { string account_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; } // QueryAccountInfoRequest is the Query/AccountInfo request type. +// +// Since: cosmos-sdk 0.47 message QueryAccountInfoRequest { // address is the account address string. @@ -197,6 +205,8 @@ message QueryAccountInfoRequest { } // QueryAccountInfoResponse is the Query/AccountInfo response type. +// +// Since: cosmos-sdk 0.47 message QueryAccountInfoResponse { // info is the account info which is represented by BaseAccount. From 1e3ab692a4e9f72824fb599419e091b6b46861de Mon Sep 17 00:00:00 2001 From: Amaury M <1293565+amaurym@users.noreply.github.com> Date: Thu, 6 Oct 2022 12:16:19 +0200 Subject: [PATCH 3/9] Update CLI command --- CHANGELOG.md | 1 + proto/cosmos/auth/v1beta1/query.proto | 3 +++ x/auth/client/cli/query.go | 16 ++++++++-------- 3 files changed, 12 insertions(+), 8 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 05da79589c1f..e73e865f49e4 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -148,6 +148,7 @@ Ref: https://keepachangelog.com/en/1.0.0/ ### CLI Breaking Changes * (tx) [#12659](https://github.com/cosmos/cosmos-sdk/pull/12659) Remove broadcast mode `block`. +* (auth) [#TODO](https://github.com/cosmos/cosmos-sdk/pull/TODO) The `q auth address-by-id` CLI command has been renamed to `q auth address-by-acc-num` to be more explicit. ### Bug Fixes diff --git a/proto/cosmos/auth/v1beta1/query.proto b/proto/cosmos/auth/v1beta1/query.proto index 3e08225b411a..46404bfaa780 100644 --- a/proto/cosmos/auth/v1beta1/query.proto +++ b/proto/cosmos/auth/v1beta1/query.proto @@ -185,6 +185,9 @@ message AddressStringToBytesResponse { // // Since: cosmos-sdk 0.46.2 message QueryAccountAddressByIDRequest { + // id is the account number of the address to be queried. This field + // should have been an uint64 (like all account numbers), and will be + // updated to uint64 in a future version of the auth query. int64 id = 1; } diff --git a/x/auth/client/cli/query.go b/x/auth/client/cli/query.go index 3c9dd000106c..0b1520f90751 100644 --- a/x/auth/client/cli/query.go +++ b/x/auth/client/cli/query.go @@ -42,7 +42,7 @@ func GetQueryCmd() *cobra.Command { cmd.AddCommand( GetAccountCmd(), - GetAccountAddressByIDCmd(), + GetAddressByAccNumCmd(), GetAccountsCmd(), QueryParamsCmd(), QueryModuleAccountsCmd(), @@ -126,26 +126,26 @@ func GetAccountCmd() *cobra.Command { return cmd } -// GetAccountAddressByIDCmd returns a query account that will display the account address of a given account id. -func GetAccountAddressByIDCmd() *cobra.Command { +// GetAddressByAccNumCmd returns a query account that will display the account address of a given account id. +func GetAddressByAccNumCmd() *cobra.Command { cmd := &cobra.Command{ - Use: "address-by-id [id]", - Short: "Query for account address by account id", + Use: "address-by-acc-num [acc-num]", + Short: "Query for an address by account number", Args: cobra.ExactArgs(1), - Example: fmt.Sprintf("%s q auth address-by-id 1", version.AppName), + Example: fmt.Sprintf("%s q auth address-by-acc-num 1", version.AppName), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientQueryContext(cmd) if err != nil { return err } - id, err := strconv.ParseInt(args[0], 10, 64) + accNum, err := strconv.ParseInt(args[0], 10, 64) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) - res, err := queryClient.AccountAddressByID(cmd.Context(), &types.QueryAccountAddressByIDRequest{Id: id}) + res, err := queryClient.AccountAddressByID(cmd.Context(), &types.QueryAccountAddressByIDRequest{Id: accNum}) if err != nil { return err } From 169eee35520477fd6bc2bf19aa87a397259ac062 Mon Sep 17 00:00:00 2001 From: Amaury M <1293565+amaurym@users.noreply.github.com> Date: Thu, 6 Oct 2022 12:23:37 +0200 Subject: [PATCH 4/9] make proto-gen --- CHANGELOG.md | 2 +- api/cosmos/auth/v1beta1/query.pulsar.go | 11 +++++++++++ api/cosmos/auth/v1beta1/query_grpc.pb.go | 4 ++++ api/cosmos/distribution/v1beta1/query_grpc.pb.go | 4 ++-- api/cosmos/group/v1/types.pulsar.go | 16 ++++++++-------- client/grpc/tmservice/query.pb.go | 2 +- store/types/commit_info.pb.go | 2 +- x/auth/client/cli/query.go | 7 ++++--- x/auth/types/query.pb.go | 15 +++++++++++++++ x/distribution/types/genesis.pb.go | 4 ++-- x/distribution/types/query.pb.go | 8 ++++---- x/gov/types/v1beta1/genesis.pb.go | 6 +++--- x/group/types.pb.go | 2 +- 13 files changed, 57 insertions(+), 26 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index e73e865f49e4..8ebecd02fc64 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -144,11 +144,11 @@ Ref: https://keepachangelog.com/en/1.0.0/ * (x/staking) [#12973](https://github.com/cosmos/cosmos-sdk/pull/12973) Removed `stakingkeeper.RandomValidator`. Use `testutil.RandSliceElem(r, sk.GetAllValidators(ctx))` instead. * (x/gov) [13160](https://github.com/cosmos/cosmos-sdk/pull/13160) Remove custom marshaling of proposl and voteoption. * (types) [13430](https://github.com/cosmos/cosmos-sdk/pull/13430) Remove unused code `ResponseCheckTx` and `ResponseDeliverTx` +* (auth) [#13460](https://github.com/cosmos/cosmos-sdk/pull/13460) The `q auth address-by-id` CLI command has been renamed to `q auth address-by-acc-num` to be more explicit. However, the old `address-by-id` version is still kept as an alias, for backwards compatibility. ### CLI Breaking Changes * (tx) [#12659](https://github.com/cosmos/cosmos-sdk/pull/12659) Remove broadcast mode `block`. -* (auth) [#TODO](https://github.com/cosmos/cosmos-sdk/pull/TODO) The `q auth address-by-id` CLI command has been renamed to `q auth address-by-acc-num` to be more explicit. ### Bug Fixes diff --git a/api/cosmos/auth/v1beta1/query.pulsar.go b/api/cosmos/auth/v1beta1/query.pulsar.go index 799865e0bdfe..12d8be14908e 100644 --- a/api/cosmos/auth/v1beta1/query.pulsar.go +++ b/api/cosmos/auth/v1beta1/query.pulsar.go @@ -8186,11 +8186,16 @@ func (x *AddressStringToBytesResponse) GetAddressBytes() []byte { } // QueryAccountAddressByIDRequest is the request type for AccountAddressByID rpc method +// +// Since: cosmos-sdk 0.46.2 type QueryAccountAddressByIDRequest struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields + // id is the account number of the address to be queried. This field + // should have been an uint64 (like all account numbers), and will be + // updated to uint64 in a future version of the auth query. Id int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` } @@ -8222,6 +8227,8 @@ func (x *QueryAccountAddressByIDRequest) GetId() int64 { } // QueryAccountAddressByIDResponse is the response type for AccountAddressByID rpc method +// +// Since: cosmos-sdk 0.46.2 type QueryAccountAddressByIDResponse struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -8258,6 +8265,8 @@ func (x *QueryAccountAddressByIDResponse) GetAccountAddress() string { } // QueryAccountInfoRequest is the Query/AccountInfo request type. +// +// Since: cosmos-sdk 0.47 type QueryAccountInfoRequest struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -8295,6 +8304,8 @@ func (x *QueryAccountInfoRequest) GetAddress() string { } // QueryAccountInfoResponse is the Query/AccountInfo response type. +// +// Since: cosmos-sdk 0.47 type QueryAccountInfoResponse struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache diff --git a/api/cosmos/auth/v1beta1/query_grpc.pb.go b/api/cosmos/auth/v1beta1/query_grpc.pb.go index 691aa58c1c17..341fff6d8926 100644 --- a/api/cosmos/auth/v1beta1/query_grpc.pb.go +++ b/api/cosmos/auth/v1beta1/query_grpc.pb.go @@ -32,6 +32,8 @@ type QueryClient interface { // Account returns account details based on address. Account(ctx context.Context, in *QueryAccountRequest, opts ...grpc.CallOption) (*QueryAccountResponse, error) // AccountAddressByID returns account address based on account id + // + // Since: cosmos-sdk 0.46.2 AccountAddressByID(ctx context.Context, in *QueryAccountAddressByIDRequest, opts ...grpc.CallOption) (*QueryAccountAddressByIDResponse, error) // Params queries all parameters. Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) @@ -160,6 +162,8 @@ type QueryServer interface { // Account returns account details based on address. Account(context.Context, *QueryAccountRequest) (*QueryAccountResponse, error) // AccountAddressByID returns account address based on account id + // + // Since: cosmos-sdk 0.46.2 AccountAddressByID(context.Context, *QueryAccountAddressByIDRequest) (*QueryAccountAddressByIDResponse, error) // Params queries all parameters. Params(context.Context, *QueryParamsRequest) (*QueryParamsResponse, error) diff --git a/api/cosmos/distribution/v1beta1/query_grpc.pb.go b/api/cosmos/distribution/v1beta1/query_grpc.pb.go index f360bf192133..edff38fb877d 100644 --- a/api/cosmos/distribution/v1beta1/query_grpc.pb.go +++ b/api/cosmos/distribution/v1beta1/query_grpc.pb.go @@ -24,7 +24,7 @@ const _ = grpc.SupportPackageIsVersion7 type QueryClient interface { // Params queries params of the distribution module. Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) - // ValidatorDistributionInfo queries validator commision and self-delegation rewards for validator + // ValidatorDistributionInfo queries validator commission and self-delegation rewards for validator ValidatorDistributionInfo(ctx context.Context, in *QueryValidatorDistributionInfoRequest, opts ...grpc.CallOption) (*QueryValidatorDistributionInfoResponse, error) // ValidatorOutstandingRewards queries rewards of a validator address. ValidatorOutstandingRewards(ctx context.Context, in *QueryValidatorOutstandingRewardsRequest, opts ...grpc.CallOption) (*QueryValidatorOutstandingRewardsResponse, error) @@ -149,7 +149,7 @@ func (c *queryClient) CommunityPool(ctx context.Context, in *QueryCommunityPoolR type QueryServer interface { // Params queries params of the distribution module. Params(context.Context, *QueryParamsRequest) (*QueryParamsResponse, error) - // ValidatorDistributionInfo queries validator commision and self-delegation rewards for validator + // ValidatorDistributionInfo queries validator commission and self-delegation rewards for validator ValidatorDistributionInfo(context.Context, *QueryValidatorDistributionInfoRequest) (*QueryValidatorDistributionInfoResponse, error) // ValidatorOutstandingRewards queries rewards of a validator address. ValidatorOutstandingRewards(context.Context, *QueryValidatorOutstandingRewardsRequest) (*QueryValidatorOutstandingRewardsResponse, error) diff --git a/api/cosmos/group/v1/types.pulsar.go b/api/cosmos/group/v1/types.pulsar.go index a33c437d9c4e..ed118238896a 100644 --- a/api/cosmos/group/v1/types.pulsar.go +++ b/api/cosmos/group/v1/types.pulsar.go @@ -7533,10 +7533,10 @@ func (x *MemberRequest) GetMetadata() string { // ThresholdDecisionPolicy is a decision policy where a proposal passes when it // satisfies the two following conditions: -// 1. The sum of all `YES` voters' weights is greater or equal than the defined -// `threshold`. -// 2. The voting and execution periods of the proposal respect the parameters -// given by `windows`. +// 1. The sum of all `YES` voters' weights is greater or equal than the defined +// `threshold`. +// 2. The voting and execution periods of the proposal respect the parameters +// given by `windows`. type ThresholdDecisionPolicy struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -7585,10 +7585,10 @@ func (x *ThresholdDecisionPolicy) GetWindows() *DecisionPolicyWindows { // PercentageDecisionPolicy is a decision policy where a proposal passes when // it satisfies the two following conditions: -// 1. The percentage of all `YES` voters' weights out of the total group weight -// is greater or equal than the given `percentage`. -// 2. The voting and execution periods of the proposal respect the parameters -// given by `windows`. +// 1. The percentage of all `YES` voters' weights out of the total group weight +// is greater or equal than the given `percentage`. +// 2. The voting and execution periods of the proposal respect the parameters +// given by `windows`. type PercentageDecisionPolicy struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache diff --git a/client/grpc/tmservice/query.pb.go b/client/grpc/tmservice/query.pb.go index 91a57bd07e2d..e177d553f4c4 100644 --- a/client/grpc/tmservice/query.pb.go +++ b/client/grpc/tmservice/query.pb.go @@ -1055,7 +1055,7 @@ func (m *ABCIQueryResponse) GetCodespace() string { } // ProofOp defines an operation used for calculating Merkle root. The data could -// be arbitrary format, providing nessecary data for example neighbouring node +// be arbitrary format, providing necessary data for example neighbouring node // hash. // // Note: This type is a duplicate of the ProofOp proto type defined in Tendermint. diff --git a/store/types/commit_info.pb.go b/store/types/commit_info.pb.go index d18987954efd..eb91c1a87a1b 100644 --- a/store/types/commit_info.pb.go +++ b/store/types/commit_info.pb.go @@ -131,7 +131,7 @@ func (m *StoreInfo) GetCommitId() CommitID { return CommitID{} } -// CommitID defines the committment information when a specific store is +// CommitID defines the commitment information when a specific store is // committed. type CommitID struct { Version int64 `protobuf:"varint,1,opt,name=version,proto3" json:"version,omitempty"` diff --git a/x/auth/client/cli/query.go b/x/auth/client/cli/query.go index 0b1520f90751..e705acac7832 100644 --- a/x/auth/client/cli/query.go +++ b/x/auth/client/cli/query.go @@ -42,7 +42,7 @@ func GetQueryCmd() *cobra.Command { cmd.AddCommand( GetAccountCmd(), - GetAddressByAccNumCmd(), + GetAddressByIdCmd(), GetAccountsCmd(), QueryParamsCmd(), QueryModuleAccountsCmd(), @@ -126,10 +126,11 @@ func GetAccountCmd() *cobra.Command { return cmd } -// GetAddressByAccNumCmd returns a query account that will display the account address of a given account id. -func GetAddressByAccNumCmd() *cobra.Command { +// GetAddressByIdCmd returns a query account that will display the account address of a given account id. +func GetAddressByIdCmd() *cobra.Command { cmd := &cobra.Command{ Use: "address-by-acc-num [acc-num]", + Aliases: []string{"address-by-id"}, Short: "Query for an address by account number", Args: cobra.ExactArgs(1), Example: fmt.Sprintf("%s q auth address-by-acc-num 1", version.AppName), diff --git a/x/auth/types/query.pb.go b/x/auth/types/query.pb.go index 60192dc75978..9135b90e4615 100644 --- a/x/auth/types/query.pb.go +++ b/x/auth/types/query.pb.go @@ -666,7 +666,12 @@ func (m *AddressStringToBytesResponse) GetAddressBytes() []byte { } // QueryAccountAddressByIDRequest is the request type for AccountAddressByID rpc method +// +// Since: cosmos-sdk 0.46.2 type QueryAccountAddressByIDRequest struct { + // id is the account number of the address to be queried. This field + // should have been an uint64 (like all account numbers), and will be + // updated to uint64 in a future version of the auth query. Id int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` } @@ -711,6 +716,8 @@ func (m *QueryAccountAddressByIDRequest) GetId() int64 { } // QueryAccountAddressByIDResponse is the response type for AccountAddressByID rpc method +// +// Since: cosmos-sdk 0.46.2 type QueryAccountAddressByIDResponse struct { AccountAddress string `protobuf:"bytes,1,opt,name=account_address,json=accountAddress,proto3" json:"account_address,omitempty"` } @@ -756,6 +763,8 @@ func (m *QueryAccountAddressByIDResponse) GetAccountAddress() string { } // QueryAccountInfoRequest is the Query/AccountInfo request type. +// +// Since: cosmos-sdk 0.47 type QueryAccountInfoRequest struct { // address is the account address string. Address string `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"` @@ -802,6 +811,8 @@ func (m *QueryAccountInfoRequest) GetAddress() string { } // QueryAccountInfoResponse is the Query/AccountInfo response type. +// +// Since: cosmos-sdk 0.47 type QueryAccountInfoResponse struct { // info is the account info which is represented by BaseAccount. Info *BaseAccount `protobuf:"bytes,1,opt,name=info,proto3" json:"info,omitempty"` @@ -957,6 +968,8 @@ type QueryClient interface { // Account returns account details based on address. Account(ctx context.Context, in *QueryAccountRequest, opts ...grpc.CallOption) (*QueryAccountResponse, error) // AccountAddressByID returns account address based on account id + // + // Since: cosmos-sdk 0.46.2 AccountAddressByID(ctx context.Context, in *QueryAccountAddressByIDRequest, opts ...grpc.CallOption) (*QueryAccountAddressByIDResponse, error) // Params queries all parameters. Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) @@ -1083,6 +1096,8 @@ type QueryServer interface { // Account returns account details based on address. Account(context.Context, *QueryAccountRequest) (*QueryAccountResponse, error) // AccountAddressByID returns account address based on account id + // + // Since: cosmos-sdk 0.46.2 AccountAddressByID(context.Context, *QueryAccountAddressByIDRequest) (*QueryAccountAddressByIDResponse, error) // Params queries all parameters. Params(context.Context, *QueryParamsRequest) (*QueryParamsResponse, error) diff --git a/x/distribution/types/genesis.pb.go b/x/distribution/types/genesis.pb.go index 49955de6d0f1..a37c3c6b0c9a 100644 --- a/x/distribution/types/genesis.pb.go +++ b/x/distribution/types/genesis.pb.go @@ -73,7 +73,7 @@ var xxx_messageInfo_DelegatorWithdrawInfo proto.InternalMessageInfo type ValidatorOutstandingRewardsRecord struct { // validator_address is the address of the validator. ValidatorAddress string `protobuf:"bytes,1,opt,name=validator_address,json=validatorAddress,proto3" json:"validator_address,omitempty"` - // outstanding_rewards represents the oustanding rewards of a validator. + // outstanding_rewards represents the outstanding rewards of a validator. OutstandingRewards github_com_cosmos_cosmos_sdk_types.DecCoins `protobuf:"bytes,2,rep,name=outstanding_rewards,json=outstandingRewards,proto3,castrepeated=github.com/cosmos/cosmos-sdk/types.DecCoins" json:"outstanding_rewards"` } @@ -284,7 +284,7 @@ var xxx_messageInfo_DelegatorStartingInfoRecord proto.InternalMessageInfo type ValidatorSlashEventRecord struct { // validator_address is the address of the validator. ValidatorAddress string `protobuf:"bytes,1,opt,name=validator_address,json=validatorAddress,proto3" json:"validator_address,omitempty"` - // height defines the block height at which the slash event occured. + // height defines the block height at which the slash event occurred. Height uint64 `protobuf:"varint,2,opt,name=height,proto3" json:"height,omitempty"` // period is the period of the slash event. Period uint64 `protobuf:"varint,3,opt,name=period,proto3" json:"period,omitempty"` diff --git a/x/distribution/types/query.pb.go b/x/distribution/types/query.pb.go index b0e010abffde..ffa6250b5e1e 100644 --- a/x/distribution/types/query.pb.go +++ b/x/distribution/types/query.pb.go @@ -168,7 +168,7 @@ type QueryValidatorDistributionInfoResponse struct { OperatorAddress string `protobuf:"bytes,1,opt,name=operator_address,json=operatorAddress,proto3" json:"operator_address,omitempty"` // self_bond_rewards defines the self delegations rewards. SelfBondRewards github_com_cosmos_cosmos_sdk_types.DecCoins `protobuf:"bytes,2,rep,name=self_bond_rewards,json=selfBondRewards,proto3,castrepeated=github.com/cosmos/cosmos-sdk/types.DecCoins" json:"self_bond_rewards"` - // commission defines the commision the validator received. + // commission defines the commission the validator received. Commission github_com_cosmos_cosmos_sdk_types.DecCoins `protobuf:"bytes,3,rep,name=commission,proto3,castrepeated=github.com/cosmos/cosmos-sdk/types.DecCoins" json:"commission"` } @@ -375,7 +375,7 @@ func (m *QueryValidatorCommissionRequest) GetValidatorAddress() string { // QueryValidatorCommissionResponse is the response type for the // Query/ValidatorCommission RPC method type QueryValidatorCommissionResponse struct { - // commission defines the commision the validator received. + // commission defines the commission the validator received. Commission ValidatorAccumulatedCommission `protobuf:"bytes,1,opt,name=commission,proto3" json:"commission"` } @@ -1073,7 +1073,7 @@ const _ = grpc.SupportPackageIsVersion4 type QueryClient interface { // Params queries params of the distribution module. Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) - // ValidatorDistributionInfo queries validator commision and self-delegation rewards for validator + // ValidatorDistributionInfo queries validator commission and self-delegation rewards for validator ValidatorDistributionInfo(ctx context.Context, in *QueryValidatorDistributionInfoRequest, opts ...grpc.CallOption) (*QueryValidatorDistributionInfoResponse, error) // ValidatorOutstandingRewards queries rewards of a validator address. ValidatorOutstandingRewards(ctx context.Context, in *QueryValidatorOutstandingRewardsRequest, opts ...grpc.CallOption) (*QueryValidatorOutstandingRewardsResponse, error) @@ -1196,7 +1196,7 @@ func (c *queryClient) CommunityPool(ctx context.Context, in *QueryCommunityPoolR type QueryServer interface { // Params queries params of the distribution module. Params(context.Context, *QueryParamsRequest) (*QueryParamsResponse, error) - // ValidatorDistributionInfo queries validator commision and self-delegation rewards for validator + // ValidatorDistributionInfo queries validator commission and self-delegation rewards for validator ValidatorDistributionInfo(context.Context, *QueryValidatorDistributionInfoRequest) (*QueryValidatorDistributionInfoResponse, error) // ValidatorOutstandingRewards queries rewards of a validator address. ValidatorOutstandingRewards(context.Context, *QueryValidatorOutstandingRewardsRequest) (*QueryValidatorOutstandingRewardsResponse, error) diff --git a/x/gov/types/v1beta1/genesis.pb.go b/x/gov/types/v1beta1/genesis.pb.go index 804b3a8ce04b..da127cbabf31 100644 --- a/x/gov/types/v1beta1/genesis.pb.go +++ b/x/gov/types/v1beta1/genesis.pb.go @@ -33,11 +33,11 @@ type GenesisState struct { Votes Votes `protobuf:"bytes,3,rep,name=votes,proto3,castrepeated=Votes" json:"votes"` // proposals defines all the proposals present at genesis. Proposals Proposals `protobuf:"bytes,4,rep,name=proposals,proto3,castrepeated=Proposals" json:"proposals"` - // params defines all the paramaters of related to deposit. + // params defines all the parameters of related to deposit. DepositParams DepositParams `protobuf:"bytes,5,opt,name=deposit_params,json=depositParams,proto3" json:"deposit_params"` - // params defines all the paramaters of related to voting. + // params defines all the parameters of related to voting. VotingParams VotingParams `protobuf:"bytes,6,opt,name=voting_params,json=votingParams,proto3" json:"voting_params"` - // params defines all the paramaters of related to tally. + // params defines all the parameters of related to tally. TallyParams TallyParams `protobuf:"bytes,7,opt,name=tally_params,json=tallyParams,proto3" json:"tally_params"` } diff --git a/x/group/types.pb.go b/x/group/types.pb.go index 7cbc0857009e..83436ac8e8e5 100644 --- a/x/group/types.pb.go +++ b/x/group/types.pb.go @@ -715,7 +715,7 @@ type Proposal struct { // whichever happens first. FinalTallyResult TallyResult `protobuf:"bytes,9,opt,name=final_tally_result,json=finalTallyResult,proto3" json:"final_tally_result"` // voting_period_end is the timestamp before which voting must be done. - // Unless a successfull MsgExec is called before (to execute a proposal whose + // Unless a successful MsgExec is called before (to execute a proposal whose // tally is successful before the voting period ends), tallying will be done // at this point, and the `final_tally_result`and `status` fields will be // accordingly updated. From 32002d0c3c194e13fc64892e6caaca53bb08f57d Mon Sep 17 00:00:00 2001 From: Amaury M <1293565+amaurym@users.noreply.github.com> Date: Thu, 6 Oct 2022 12:24:53 +0200 Subject: [PATCH 5/9] id->accNum --- proto/cosmos/auth/v1beta1/query.proto | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/proto/cosmos/auth/v1beta1/query.proto b/proto/cosmos/auth/v1beta1/query.proto index 46404bfaa780..ec8deed7d6db 100644 --- a/proto/cosmos/auth/v1beta1/query.proto +++ b/proto/cosmos/auth/v1beta1/query.proto @@ -30,7 +30,7 @@ service Query { option (google.api.http).get = "/cosmos/auth/v1beta1/accounts/{address}"; } - // AccountAddressByID returns account address based on account id + // AccountAddressByID returns account address based on account number. // // Since: cosmos-sdk 0.46.2 rpc AccountAddressByID(QueryAccountAddressByIDRequest) returns (QueryAccountAddressByIDResponse) { From 4e659ced948973c0972f7b5ab70764a5a710db07 Mon Sep 17 00:00:00 2001 From: Amaury M <1293565+amaurym@users.noreply.github.com> Date: Thu, 6 Oct 2022 12:25:22 +0200 Subject: [PATCH 6/9] No API breaking changes --- x/auth/client/cli/query.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/x/auth/client/cli/query.go b/x/auth/client/cli/query.go index e705acac7832..c86f66a04143 100644 --- a/x/auth/client/cli/query.go +++ b/x/auth/client/cli/query.go @@ -42,7 +42,7 @@ func GetQueryCmd() *cobra.Command { cmd.AddCommand( GetAccountCmd(), - GetAddressByIdCmd(), + GetAccountAddressByIDCmd(), GetAccountsCmd(), QueryParamsCmd(), QueryModuleAccountsCmd(), @@ -126,8 +126,8 @@ func GetAccountCmd() *cobra.Command { return cmd } -// GetAddressByIdCmd returns a query account that will display the account address of a given account id. -func GetAddressByIdCmd() *cobra.Command { +// GetAccountAddressByIDCmd returns a query account that will display the account address of a given account id. +func GetAccountAddressByIDCmd() *cobra.Command { cmd := &cobra.Command{ Use: "address-by-acc-num [acc-num]", Aliases: []string{"address-by-id"}, From de15237531fe9cd2c3ea339007ce8e2ce7f1e58a Mon Sep 17 00:00:00 2001 From: Amaury M <1293565+amaurym@users.noreply.github.com> Date: Thu, 6 Oct 2022 12:32:32 +0200 Subject: [PATCH 7/9] improve err msg --- x/auth/keeper/grpc_query.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/x/auth/keeper/grpc_query.go b/x/auth/keeper/grpc_query.go index bb09dbdeac9a..12b0e77e1800 100644 --- a/x/auth/keeper/grpc_query.go +++ b/x/auth/keeper/grpc_query.go @@ -25,13 +25,13 @@ func (ak AccountKeeper) AccountAddressByID(c context.Context, req *types.QueryAc } if req.Id < 0 { - return nil, status.Error(codes.InvalidArgument, "Invalid account id") + return nil, status.Error(codes.InvalidArgument, "invalid account number") } ctx := sdk.UnwrapSDKContext(c) address := ak.GetAccountAddressByID(ctx, uint64(req.GetId())) if len(address) == 0 { - return nil, status.Errorf(codes.NotFound, "account address not found with id %d", req.Id) + return nil, status.Errorf(codes.NotFound, "account address not found with account number %d", req.Id) } return &types.QueryAccountAddressByIDResponse{AccountAddress: address}, nil From 3a5d77a5b0afaaa788dfdd8dfe0b21760d69ba2c Mon Sep 17 00:00:00 2001 From: Amaury <1293565+amaurym@users.noreply.github.com> Date: Thu, 6 Oct 2022 12:33:58 +0200 Subject: [PATCH 8/9] Update CHANGELOG.md Co-authored-by: Julien Robert --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 8ebecd02fc64..ed542005dc28 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -143,7 +143,7 @@ Ref: https://keepachangelog.com/en/1.0.0/ * (codec) [#12964](https://github.com/cosmos/cosmos-sdk/pull/12964) `ProtoCodec.MarshalInterface` now returns an error when serializing unregistered types and a subsequent `ProtoCodec.UnmarshalInterface` would fail. * (x/staking) [#12973](https://github.com/cosmos/cosmos-sdk/pull/12973) Removed `stakingkeeper.RandomValidator`. Use `testutil.RandSliceElem(r, sk.GetAllValidators(ctx))` instead. * (x/gov) [13160](https://github.com/cosmos/cosmos-sdk/pull/13160) Remove custom marshaling of proposl and voteoption. -* (types) [13430](https://github.com/cosmos/cosmos-sdk/pull/13430) Remove unused code `ResponseCheckTx` and `ResponseDeliverTx` +* (types) [#13430](https://github.com/cosmos/cosmos-sdk/pull/13430) Remove unused code `ResponseCheckTx` and `ResponseDeliverTx` * (auth) [#13460](https://github.com/cosmos/cosmos-sdk/pull/13460) The `q auth address-by-id` CLI command has been renamed to `q auth address-by-acc-num` to be more explicit. However, the old `address-by-id` version is still kept as an alias, for backwards compatibility. ### CLI Breaking Changes From ed6a946d56a0615dc578f5d413c995a514687e4e Mon Sep 17 00:00:00 2001 From: Amaury <1293565+amaurym@users.noreply.github.com> Date: Thu, 6 Oct 2022 12:34:05 +0200 Subject: [PATCH 9/9] Update CHANGELOG.md Co-authored-by: Julien Robert --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index ed542005dc28..7f925ad7f6c7 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -142,7 +142,7 @@ Ref: https://keepachangelog.com/en/1.0.0/ * (x/genutil)[#12956](https://github.com/cosmos/cosmos-sdk/pull/12956) `genutil.AppModuleBasic` has a new attribute: genesis transaction validation function. The existing validation logic is implemented in `genutiltypes.DefaultMessageValidator`. Use `genutil.NewAppModuleBasic` to create a new genutil Module Basic. * (codec) [#12964](https://github.com/cosmos/cosmos-sdk/pull/12964) `ProtoCodec.MarshalInterface` now returns an error when serializing unregistered types and a subsequent `ProtoCodec.UnmarshalInterface` would fail. * (x/staking) [#12973](https://github.com/cosmos/cosmos-sdk/pull/12973) Removed `stakingkeeper.RandomValidator`. Use `testutil.RandSliceElem(r, sk.GetAllValidators(ctx))` instead. -* (x/gov) [13160](https://github.com/cosmos/cosmos-sdk/pull/13160) Remove custom marshaling of proposl and voteoption. +* (x/gov) [#13160](https://github.com/cosmos/cosmos-sdk/pull/13160) Remove custom marshaling of proposl and voteoption. * (types) [#13430](https://github.com/cosmos/cosmos-sdk/pull/13430) Remove unused code `ResponseCheckTx` and `ResponseDeliverTx` * (auth) [#13460](https://github.com/cosmos/cosmos-sdk/pull/13460) The `q auth address-by-id` CLI command has been renamed to `q auth address-by-acc-num` to be more explicit. However, the old `address-by-id` version is still kept as an alias, for backwards compatibility.