diff --git a/proto/cosmos/auth/v1beta1/query.proto b/proto/cosmos/auth/v1beta1/query.proto index 0b66da6050..b5c65e28c8 100644 --- a/proto/cosmos/auth/v1beta1/query.proto +++ b/proto/cosmos/auth/v1beta1/query.proto @@ -48,12 +48,12 @@ service Query { option (google.api.http).get = "/cosmos/auth/v1beta1/module_accounts/{name}"; } -// // Bech32Prefix queries bech32Prefix -// // -// // Since: cosmos-sdk 0.46 -// rpc Bech32Prefix(Bech32PrefixRequest) returns (Bech32PrefixResponse) { -// option (google.api.http).get = "/cosmos/auth/v1beta1/bech32"; -// } + // // Bech32Prefix queries bech32Prefix + // // + // // Since: cosmos-sdk 0.46 + // rpc Bech32Prefix(Bech32PrefixRequest) returns (Bech32PrefixResponse) { + // option (google.api.http).get = "/cosmos/auth/v1beta1/bech32"; + // } // AddressBytesToString converts Account Address bytes to string // @@ -138,12 +138,12 @@ message QueryModuleAccountByNameResponse { //// Bech32PrefixRequest is the request type for Bech32Prefix rpc method. //// //// Since: cosmos-sdk 0.46 -//message Bech32PrefixRequest {} +// message Bech32PrefixRequest {} //// Bech32PrefixResponse is the response type for Bech32Prefix rpc method. //// //// Since: cosmos-sdk 0.46 -//message Bech32PrefixResponse { +// message Bech32PrefixResponse { // string bech32_prefix = 1; //} diff --git a/proto/cosmos/crosschain/v1/query.proto b/proto/cosmos/crosschain/v1/query.proto index b5a5086448..9d721b6436 100644 --- a/proto/cosmos/crosschain/v1/query.proto +++ b/proto/cosmos/crosschain/v1/query.proto @@ -42,7 +42,7 @@ message QueryParamsResponse { // QueryCrossChainPackageRequest is the request type for the Query/CrossChainPackage RPC method. message QueryCrossChainPackageRequest { uint32 channel_id = 1; - uint64 sequence = 2; + uint64 sequence = 2; } // QueryCrossChainPackageResponse is the response type for the Query/CrossChainPackage RPC method. diff --git a/proto/cosmos/crypto/eth/bls/keys.proto b/proto/cosmos/crypto/eth/bls/keys.proto index f5289d8347..4e4a3d4c9e 100644 --- a/proto/cosmos/crypto/eth/bls/keys.proto +++ b/proto/cosmos/crypto/eth/bls/keys.proto @@ -6,7 +6,7 @@ import "gogoproto/gogo.proto"; option go_package = "github.com/cosmos/cosmos-sdk/crypto/keys/eth/bls"; // PubKey defines a bls public key -// Key is the compressed form of the pubkey. +// Key is the compressed form of the pubkey. message PubKey { option (gogoproto.goproto_stringer) = false; diff --git a/proto/cosmos/gashub/v1alpha1/gashub.proto b/proto/cosmos/gashub/v1alpha1/gashub.proto index 4d911da161..2408bb7e71 100644 --- a/proto/cosmos/gashub/v1alpha1/gashub.proto +++ b/proto/cosmos/gashub/v1alpha1/gashub.proto @@ -18,9 +18,9 @@ message Params { // MsgGasParams defines gas for a msg type message MsgGasParams { - option (gogoproto.equal) = true; + option (gogoproto.equal) = true; - string msg_type_url = 1 [(gogoproto.customname) = "MsgTypeUrl"]; + string msg_type_url = 1 [(gogoproto.customname) = "MsgTypeUrl"]; // gas_params is the oneof that represents either fixed_gas_params or dynamic_gas_params oneof gas_params { // fixed_type specifies fixed type gas params. @@ -34,14 +34,14 @@ message MsgGasParams { } // FixedGasParams defines the parameters for fixed gas type. message FixedGasParams { - option (gogoproto.equal) = true; + option (gogoproto.equal) = true; uint64 fixed_gas = 1 [(gogoproto.customname) = "FixedGas"]; } // DynamicGasParams defines the parameters for dynamic gas type. message DynamicGasParams { - option (gogoproto.equal) = true; + option (gogoproto.equal) = true; uint64 fixed_gas = 1 [(gogoproto.customname) = "FixedGas"]; uint64 gas_per_item = 2 [(gogoproto.customname) = "GasPerItem"]; diff --git a/proto/cosmos/gashub/v1alpha1/tx.proto b/proto/cosmos/gashub/v1alpha1/tx.proto index cceb2b773a..a0eeb94891 100644 --- a/proto/cosmos/gashub/v1alpha1/tx.proto +++ b/proto/cosmos/gashub/v1alpha1/tx.proto @@ -22,7 +22,7 @@ message MsgUpdateMsgGasParams { option (gogoproto.equal) = false; option (gogoproto.goproto_getters) = false; - string from = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + string from = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; repeated MsgGasParams new_params_set = 2; } diff --git a/proto/cosmos/oracle/v1/event.proto b/proto/cosmos/oracle/v1/event.proto index fed8591578..311afc1a87 100644 --- a/proto/cosmos/oracle/v1/event.proto +++ b/proto/cosmos/oracle/v1/event.proto @@ -2,7 +2,6 @@ syntax = "proto3"; package cosmos.oracle.v1; - option go_package = "github.com/cosmos/cosmos-sdk/x/oracle/types"; // EventPackageClaim is emitted when a cross chain package is processed diff --git a/proto/cosmos/oracle/v1/oracle.proto b/proto/cosmos/oracle/v1/oracle.proto index 7edd9a3cb3..dff6deb115 100644 --- a/proto/cosmos/oracle/v1/oracle.proto +++ b/proto/cosmos/oracle/v1/oracle.proto @@ -17,5 +17,5 @@ message Params { // RelayInterval holds start and end tiem of in-turn relayer message RelayInterval { uint64 start = 1; - uint64 end = 2; + uint64 end = 2; } diff --git a/proto/cosmos/oracle/v1/query.proto b/proto/cosmos/oracle/v1/query.proto index c184c025f7..65d4b6a5ac 100644 --- a/proto/cosmos/oracle/v1/query.proto +++ b/proto/cosmos/oracle/v1/query.proto @@ -32,7 +32,8 @@ message QueryParamsResponse { // QueryInturnRelayerRequest is the request type for the Query In-turn relayer RPC method. message QueryInturnRelayerRequest {} -message QueryInturnRelayerResponse{ - string bls_pub_key = 1; +// QueryInturnRelayerResponse is the response type for the Query In-turn relayer RPC method. +message QueryInturnRelayerResponse { + string bls_pub_key = 1; RelayInterval relay_interval = 2; } \ No newline at end of file diff --git a/proto/cosmos/oracle/v1/tx.proto b/proto/cosmos/oracle/v1/tx.proto index e0b2920a76..93c4b414a4 100644 --- a/proto/cosmos/oracle/v1/tx.proto +++ b/proto/cosmos/oracle/v1/tx.proto @@ -21,14 +21,14 @@ message MsgClaim { option (gogoproto.equal) = false; option (gogoproto.goproto_getters) = false; - string from_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - uint32 src_chain_id = 2; - uint32 dest_chain_id = 3; - uint64 sequence = 4; - uint64 timestamp = 5; - bytes payload = 6; - repeated fixed64 vote_address_set = 7; - bytes agg_signature = 8; + string from_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + uint32 src_chain_id = 2; + uint32 dest_chain_id = 3; + uint64 sequence = 4; + uint64 timestamp = 5; + bytes payload = 6; + repeated fixed64 vote_address_set = 7; + bytes agg_signature = 8; } // MsgClaimResponse defines the Msg/Claim response type diff --git a/proto/cosmos/params/v1beta1/params.proto b/proto/cosmos/params/v1beta1/params.proto index 0a081a4631..83936c7d32 100644 --- a/proto/cosmos/params/v1beta1/params.proto +++ b/proto/cosmos/params/v1beta1/params.proto @@ -16,8 +16,8 @@ message ParameterChangeProposal { string title = 1; string description = 2; repeated ParamChange changes = 3 [(gogoproto.nullable) = false]; - bool cross_chain = 4; // flag for cross chain proposal - repeated string addresses = 5; // used with cross_chain field to specify destination smart contract address(es) + bool cross_chain = 4; // flag for cross chain proposal + repeated string addresses = 5; // used with cross_chain field to specify destination smart contract address(es) } // ParamChange defines an individual parameter change, for use in diff --git a/proto/cosmos/slashing/v1beta1/tx.proto b/proto/cosmos/slashing/v1beta1/tx.proto index ab80d73086..0e5d6e12f5 100644 --- a/proto/cosmos/slashing/v1beta1/tx.proto +++ b/proto/cosmos/slashing/v1beta1/tx.proto @@ -40,8 +40,8 @@ message MsgImpeach { option (gogoproto.equal) = false; option (gogoproto.goproto_getters) = false; - string from = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - string validator_address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + string from = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + string validator_address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; } // MsgImpeachResponse defines the Msg/Impeach response type. diff --git a/proto/cosmos/staking/v1beta1/tx.proto b/proto/cosmos/staking/v1beta1/tx.proto index e6b0ef5952..8bbb201758 100644 --- a/proto/cosmos/staking/v1beta1/tx.proto +++ b/proto/cosmos/staking/v1beta1/tx.proto @@ -62,7 +62,7 @@ message MsgCreateValidator { string from = 8 [(cosmos_proto.scalar) = "cosmos.AddressString"]; string relayer_address = 9 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - string relayer_bls_key = 10; + string relayer_bls_key = 10; } // MsgCreateValidatorResponse defines the Msg/CreateValidator response type. @@ -87,8 +87,8 @@ message MsgEditValidator { string min_self_delegation = 4 [(cosmos_proto.scalar) = "cosmos.Int", (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int"]; - string relayer_address = 5 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - string relayer_bls_key = 6; // The BLS pubkey for the authorized relayer + string relayer_address = 5 [(cosmos_proto.scalar) = "cosmos.AddressString"]; + string relayer_bls_key = 6; // The BLS pubkey for the authorized relayer } // MsgEditValidatorResponse defines the Msg/EditValidator response type. diff --git a/proto/cosmos/tx/v1beta1/tx.proto b/proto/cosmos/tx/v1beta1/tx.proto index a57ca31d86..ba963bcf22 100644 --- a/proto/cosmos/tx/v1beta1/tx.proto +++ b/proto/cosmos/tx/v1beta1/tx.proto @@ -102,30 +102,30 @@ message SignDocEip712 { // chain_id is the identifier of the chain this transaction targets. // It prevents signed transactions from being used on another chain by an // attacker. - uint64 chain_id = 1[(gogoproto.jsontag) = "chain_id"]; + uint64 chain_id = 1 [(gogoproto.jsontag) = "chain_id"]; // account_number is the account number of the account in state. - uint64 account_number = 2[(gogoproto.jsontag) = "account_number"]; + uint64 account_number = 2 [(gogoproto.jsontag) = "account_number"]; // sequence is the sequence number of the signing account. - uint64 sequence = 3[(gogoproto.jsontag) = "sequence"]; + uint64 sequence = 3 [(gogoproto.jsontag) = "sequence"]; // Fee is the fee and gas limit for the transaction. The first signer is the // primary signer and the one which pays the fee. The fee can be calculated // based on the cost of evaluating the body and doing signature verification // of the signers. This can be estimated via simulation. - Fee fee = 4[(gogoproto.nullable) = false]; + Fee fee = 4 [(gogoproto.nullable) = false]; // msg is the msg in the EIP712 transaction. google.protobuf.Any msg = 5; // timeout_height is the transaction's timeout height (if set). - uint64 timeout_height = 6[(gogoproto.jsontag) = "timeout_height"]; + uint64 timeout_height = 6 [(gogoproto.jsontag) = "timeout_height"]; // memo is any arbitrary note/comment to be added to the transaction. // WARNING: in clients, any publicly exposed text should not be called memo, // but should be called `note` instead (see https://github.com/cosmos/cosmos-sdk/issues/9122). - string memo = 7[(gogoproto.jsontag) = "memo"]; + string memo = 7 [(gogoproto.jsontag) = "memo"]; // Tip is the optional tip used for transactions fees paid in another denom. // It should be left empty if the signer is not the tipper for this diff --git a/x/oracle/keeper/keeper_test.go b/x/oracle/keeper/keeper_test.go index 78ebc93d01..c454cc03d3 100644 --- a/x/oracle/keeper/keeper_test.go +++ b/x/oracle/keeper/keeper_test.go @@ -77,6 +77,7 @@ func (s *TestSuite) TestProcessClaim() { s.app.OracleKeeper.SetParams(s.ctx, types.Params{ RelayerTimeout: 5, RelayerRewardShare: 50, + RelayerInterval: 600, }) _, _, newValidators, blsKeys := createValidators(s.T(), s.ctx, s.app, []int64{9, 8, 7}) @@ -154,6 +155,7 @@ func (s *TestSuite) TestKeeper_IsRelayerValid() { s.app.OracleKeeper.SetParams(s.ctx, types.Params{ RelayerTimeout: 5, RelayerRewardShare: 50, + RelayerInterval: 600, }) vals := make([]stakingtypes.Validator, 5) diff --git a/x/oracle/keeper/msg_server_test.go b/x/oracle/keeper/msg_server_test.go index 94be454885..8e92747278 100644 --- a/x/oracle/keeper/msg_server_test.go +++ b/x/oracle/keeper/msg_server_test.go @@ -32,8 +32,8 @@ func (s *TestSuite) TestClaim() { s.app.OracleKeeper.SetParams(s.ctx, types.Params{ RelayerTimeout: 5, - RelayerBackoffTime: 3, RelayerRewardShare: 50, + RelayerInterval: 600, }) _, _, newValidators, blsKeys := createValidators(s.T(), s.ctx, s.app, []int64{9, 8, 7}) @@ -98,8 +98,8 @@ func (s *TestSuite) TestInvalidClaim() { s.app.OracleKeeper.SetParams(s.ctx, types.Params{ RelayerTimeout: 5, - RelayerBackoffTime: 3, RelayerRewardShare: 50, + RelayerInterval: 600, }) _, _, newValidators, blsKeys := createValidators(s.T(), s.ctx, s.app, []int64{9, 8, 7})