cleanup proto
This commit is contained in:
parent
6f7470c2e0
commit
4a9d63356e
3
Makefile
3
Makefile
@ -364,9 +364,6 @@ proto-swagger-gen:
|
||||
proto-format:
|
||||
find ./ -not -path "./third_party/*" -name *.proto -exec clang-format -i {} \;
|
||||
|
||||
proto-swagger-gen:
|
||||
@./scripts/protoc-swagger-gen.sh
|
||||
|
||||
proto-lint:
|
||||
@$(DOCKER_BUF) check lint --error-format=json
|
||||
|
||||
|
@ -7,7 +7,7 @@
|
||||
},
|
||||
"apis": [
|
||||
{
|
||||
"url": "./tmp-swagger-gen/ethermint/evm/v1beta1/query.swagger.json",
|
||||
"url": "./tmp-swagger-gen/ethermint/evm/v1alpha1/query.swagger.json",
|
||||
"operationIds": {
|
||||
"rename": {
|
||||
"Params": "EvmParams"
|
||||
|
File diff suppressed because one or more lines are too long
File diff suppressed because it is too large
Load Diff
@ -16,4 +16,6 @@ message PubKey {
|
||||
|
||||
// PrivKey defines a type alias for an ecdsa.PrivateKey that implements
|
||||
// Tendermint's PrivateKey interface.
|
||||
message PrivKey { bytes key = 1; }
|
||||
message PrivKey {
|
||||
bytes key = 1;
|
||||
}
|
||||
|
@ -11,16 +11,13 @@ message Params {
|
||||
|
||||
// evm_denom represents the token denomination used to run the EVM state
|
||||
// transitions.
|
||||
string evm_denom = 1 [ (gogoproto.moretags) = "yaml:\"evm_denom\""];
|
||||
string evm_denom = 1 [(gogoproto.moretags) = "yaml:\"evm_denom\""];
|
||||
// enable_create toggles state transitions that use the vm.Create function
|
||||
bool enable_create = 2 [ (gogoproto.moretags) = "yaml:\"enable_create\""];
|
||||
bool enable_create = 2 [(gogoproto.moretags) = "yaml:\"enable_create\""];
|
||||
// enable_call toggles state transitions that use the vm.Call function
|
||||
bool enable_call = 3 [ (gogoproto.moretags) = "yaml:\"enable_call\""];
|
||||
bool enable_call = 3 [(gogoproto.moretags) = "yaml:\"enable_call\""];
|
||||
// extra_eips defines the additional EIPs for the vm.Config
|
||||
repeated int64 extra_eips = 4 [
|
||||
(gogoproto.customname) = "ExtraEIPs",
|
||||
(gogoproto.moretags) = "yaml:\"extra_eips\""
|
||||
];
|
||||
repeated int64 extra_eips = 4 [(gogoproto.customname) = "ExtraEIPs", (gogoproto.moretags) = "yaml:\"extra_eips\""];
|
||||
}
|
||||
|
||||
// ChainConfig defines the Ethereum ChainConfig parameters using sdk.Int values
|
||||
@ -49,10 +46,8 @@ message ChainConfig {
|
||||
(gogoproto.nullable) = false
|
||||
];
|
||||
// Whether the nodes supports or opposes the DAO hard-fork
|
||||
bool dao_fork_support = 3 [
|
||||
(gogoproto.customname) = "DAOForkSupport",
|
||||
(gogoproto.moretags) = "yaml:\"dao_fork_support\""
|
||||
];
|
||||
bool dao_fork_support = 3
|
||||
[(gogoproto.customname) = "DAOForkSupport", (gogoproto.moretags) = "yaml:\"dao_fork_support\""];
|
||||
// EIP150 implements the Gas price changes
|
||||
// (https://github.com/ethereum/EIPs/issues/150) EIP150 HF block (< 0 no fork)
|
||||
string eip150_block = 4 [
|
||||
@ -62,10 +57,7 @@ message ChainConfig {
|
||||
(gogoproto.nullable) = false
|
||||
];
|
||||
// EIP150 HF hash (needed for header only clients as only gas pricing changed)
|
||||
string eip150_hash = 5 [
|
||||
(gogoproto.customname) = "EIP150Hash",
|
||||
(gogoproto.moretags) = "yaml:\"byzantium_block\""
|
||||
];
|
||||
string eip150_hash = 5 [(gogoproto.customname) = "EIP150Hash", (gogoproto.moretags) = "yaml:\"byzantium_block\""];
|
||||
// EIP155Block HF block
|
||||
string eip155_block = 6 [
|
||||
(gogoproto.customname) = "EIP155Block",
|
||||
@ -156,15 +148,15 @@ message Log {
|
||||
// but not secured by consensus.
|
||||
|
||||
// block in which the transaction was included
|
||||
uint64 block_number = 4 [ (gogoproto.jsontag) = "blockNumber" ];
|
||||
uint64 block_number = 4 [(gogoproto.jsontag) = "blockNumber"];
|
||||
// hash of the transaction
|
||||
string tx_hash = 5 [ (gogoproto.jsontag) = "transactionHash" ];
|
||||
string tx_hash = 5 [(gogoproto.jsontag) = "transactionHash"];
|
||||
// index of the transaction in the block
|
||||
uint64 tx_index = 6 [ (gogoproto.jsontag) = "transactionIndex" ];
|
||||
uint64 tx_index = 6 [(gogoproto.jsontag) = "transactionIndex"];
|
||||
// hash of the block in which the transaction was included
|
||||
string block_hash = 7 [ (gogoproto.jsontag) = "blockHash" ];
|
||||
string block_hash = 7 [(gogoproto.jsontag) = "blockHash"];
|
||||
// index of the log in the block
|
||||
uint64 index = 8 [ (gogoproto.jsontag) = "logIndex" ];
|
||||
uint64 index = 8 [(gogoproto.jsontag) = "logIndex"];
|
||||
|
||||
// The Removed field is true if this log was reverted due to a chain
|
||||
// reorganisation. You must pay attention to this field if you receive logs
|
||||
@ -192,16 +184,12 @@ message TxResult {
|
||||
// contract_address contains the ethereum address of the created contract (if
|
||||
// any). If the state transition is an evm.Call, the contract address will be
|
||||
// empty.
|
||||
string contract_address = 1
|
||||
[ (gogoproto.moretags) = "yaml:\"contract_address\"" ];
|
||||
string contract_address = 1 [(gogoproto.moretags) = "yaml:\"contract_address\""];
|
||||
// bloom represents the bloom filter bytes
|
||||
bytes bloom = 2;
|
||||
// tx_logs contains the transaction hash and the proto-compatible ethereum
|
||||
// logs.
|
||||
TransactionLogs tx_logs = 3 [
|
||||
(gogoproto.moretags) = "yaml:\"tx_logs\"",
|
||||
(gogoproto.nullable) = false
|
||||
];
|
||||
TransactionLogs tx_logs = 3 [(gogoproto.moretags) = "yaml:\"tx_logs\"", (gogoproto.nullable) = false];
|
||||
// ret defines the bytes from the execution.
|
||||
bytes ret = 4;
|
||||
// reverted flag is set to true when the call has been reverted
|
||||
@ -218,18 +206,12 @@ message TxData {
|
||||
// nonce corresponds to the account nonce (transaction sequence).
|
||||
uint64 nonce = 1 [(gogoproto.customname) = "AccountNonce"];
|
||||
// price defines the unsigned integer value of the gas price in bytes.
|
||||
bytes price = 2 [
|
||||
(gogoproto.jsontag) = "gasPrice"
|
||||
];
|
||||
bytes price = 2 [(gogoproto.jsontag) = "gasPrice"];
|
||||
// gas defines the gas limit defined for the transaction.
|
||||
uint64 gas = 3 [(gogoproto.customname) = "GasLimit"];
|
||||
bytes to = 4 [
|
||||
(gogoproto.customname) = "Recipient"
|
||||
];
|
||||
bytes to = 4 [(gogoproto.customname) = "Recipient"];
|
||||
// value defines the unsigned integer value of the transaction amount.
|
||||
bytes value = 5 [
|
||||
(gogoproto.customname) = "Amount"
|
||||
];
|
||||
bytes value = 5 [(gogoproto.customname) = "Amount"];
|
||||
// input defines the data payload bytes of the transaction.
|
||||
bytes input = 6 [(gogoproto.customname) = "Payload"];
|
||||
// v defines the signature value
|
||||
@ -239,7 +221,7 @@ message TxData {
|
||||
// s define the signature value
|
||||
bytes s = 9;
|
||||
// hash defines the tx data hash, which is only used when marshaling to JSON.
|
||||
string hash = 10 [ (gogoproto.moretags) = "rlp:\"-\"" ];
|
||||
string hash = 10 [(gogoproto.moretags) = "rlp:\"-\""];
|
||||
}
|
||||
|
||||
message BytesList {
|
||||
|
@ -9,19 +9,13 @@ option go_package = "github.com/cosmos/ethermint/x/evm/types";
|
||||
// GenesisState defines the evm module's genesis state.
|
||||
message GenesisState {
|
||||
// accounts is an array containing the ethereum genesis accounts.
|
||||
repeated GenesisAccount accounts = 1 [ (gogoproto.nullable) = false ];
|
||||
repeated GenesisAccount accounts = 1 [(gogoproto.nullable) = false];
|
||||
// chain_config defines the Ethereum chain configuration.
|
||||
ChainConfig chain_config = 2 [
|
||||
(gogoproto.moretags) = "yaml:\"chain_config\"",
|
||||
(gogoproto.nullable) = false
|
||||
];
|
||||
ChainConfig chain_config = 2 [(gogoproto.moretags) = "yaml:\"chain_config\"", (gogoproto.nullable) = false];
|
||||
// params defines all the paramaters of the module.
|
||||
Params params = 3 [ (gogoproto.nullable) = false ];
|
||||
Params params = 3 [(gogoproto.nullable) = false];
|
||||
|
||||
repeated TransactionLogs txs_logs = 4 [
|
||||
(gogoproto.moretags) = "yaml:\"txs_logs\"",
|
||||
(gogoproto.nullable) = false
|
||||
];
|
||||
repeated TransactionLogs txs_logs = 4 [(gogoproto.moretags) = "yaml:\"txs_logs\"", (gogoproto.nullable) = false];
|
||||
}
|
||||
|
||||
// GenesisAccount defines an account to be initialized in the genesis state.
|
||||
@ -33,8 +27,5 @@ message GenesisAccount {
|
||||
// code defines the hex bytes of the account code.
|
||||
string code = 2;
|
||||
// storage defines the set of state key values for the account.
|
||||
repeated State storage = 3 [
|
||||
(gogoproto.nullable) = false,
|
||||
(gogoproto.castrepeated) = "Storage"
|
||||
];
|
||||
repeated State storage = 3 [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "Storage"];
|
||||
}
|
||||
|
@ -27,8 +27,7 @@ service Query {
|
||||
|
||||
// Storage queries the balance of all coins for a single account.
|
||||
rpc Storage(QueryStorageRequest) returns (QueryStorageResponse) {
|
||||
option (google.api.http).get =
|
||||
"/ethermint/evm/v1alpha1/storage/{address}/{key}";
|
||||
option (google.api.http).get = "/ethermint/evm/v1alpha1/storage/{address}/{key}";
|
||||
}
|
||||
|
||||
// Code queries the balance of all coins for a single account.
|
||||
@ -237,12 +236,14 @@ message QueryBlockLogsRequest {
|
||||
// QueryTxLogs is the response type for the Query/BlockLogs RPC method.
|
||||
message QueryBlockLogsResponse {
|
||||
// logs represents the ethereum logs generated at the given block hash.
|
||||
repeated TransactionLogs tx_logs = 1 [ (gogoproto.nullable) = false ];
|
||||
repeated TransactionLogs tx_logs = 1 [(gogoproto.nullable) = false];
|
||||
}
|
||||
|
||||
// QueryBlockBloomRequest is the request type for the Query/BlockBloom RPC
|
||||
// method.
|
||||
message QueryBlockBloomRequest { int64 height = 1; }
|
||||
message QueryBlockBloomRequest {
|
||||
int64 height = 1;
|
||||
}
|
||||
|
||||
// QueryBlockBloomResponse is the response type for the Query/BlockBloom RPC
|
||||
// method.
|
||||
@ -257,7 +258,7 @@ message QueryParamsRequest {}
|
||||
// QueryParamsResponse defines the response type for querying x/evm parameters.
|
||||
message QueryParamsResponse {
|
||||
// params define the evm module parameters.
|
||||
Params params = 1 [ (gogoproto.nullable) = false ];
|
||||
Params params = 1 [(gogoproto.nullable) = false];
|
||||
}
|
||||
|
||||
// QueryStaticCallRequest defines static call request
|
||||
|
@ -18,8 +18,8 @@ message MsgEthereumTx {
|
||||
|
||||
TxData data = 1;
|
||||
// caches
|
||||
double size = 2 [ (gogoproto.jsontag) = "-" ];
|
||||
SigCache from = 3 [ (gogoproto.jsontag) = "-" ];
|
||||
double size = 2 [(gogoproto.jsontag) = "-"];
|
||||
SigCache from = 3 [(gogoproto.jsontag) = "-"];
|
||||
}
|
||||
|
||||
message ExtensionOptionsEthereumTx {
|
||||
@ -37,15 +37,12 @@ message MsgEthereumTxResponse {
|
||||
// contract_address contains the ethereum address of the created contract (if
|
||||
// any). If the state transition is an evm.Call, the contract address will be
|
||||
// empty.
|
||||
string contract_address = 1 [(gogoproto.moretags) = "yaml:\"contract_address\"" ];
|
||||
string contract_address = 1 [(gogoproto.moretags) = "yaml:\"contract_address\""];
|
||||
// bloom represents the bloom filter bytes
|
||||
bytes bloom = 2;
|
||||
// tx_logs contains the transaction hash and the proto-compatible ethereum
|
||||
// logs.
|
||||
TransactionLogs tx_logs = 3 [
|
||||
(gogoproto.moretags) = "yaml:\"tx_logs\"",
|
||||
(gogoproto.nullable) = false
|
||||
];
|
||||
TransactionLogs tx_logs = 3 [(gogoproto.moretags) = "yaml:\"tx_logs\"", (gogoproto.nullable) = false];
|
||||
// ret defines the bytes from the execution.
|
||||
bytes ret = 4;
|
||||
// reverted flag is set to true when the call has been reverted
|
||||
|
@ -14,12 +14,9 @@ message EthAccount {
|
||||
option (gogoproto.goproto_stringer) = false;
|
||||
option (gogoproto.equal) = false;
|
||||
|
||||
option (cosmos_proto.implements_interface) =
|
||||
"github.com/cosmos/cosmos-sdk/x/auth/types.AccountI";
|
||||
option (cosmos_proto.implements_interface) = "github.com/cosmos/cosmos-sdk/x/auth/types.AccountI";
|
||||
|
||||
cosmos.auth.v1beta1.BaseAccount base_account = 1 [
|
||||
(gogoproto.embed) = true,
|
||||
(gogoproto.moretags) = "yaml:\"base_account\""
|
||||
];
|
||||
bytes code_hash = 2 [ (gogoproto.moretags) = "yaml:\"code_hash\"" ];
|
||||
cosmos.auth.v1beta1.BaseAccount base_account = 1
|
||||
[(gogoproto.embed) = true, (gogoproto.moretags) = "yaml:\"base_account\""];
|
||||
bytes code_hash = 2 [(gogoproto.moretags) = "yaml:\"code_hash\""];
|
||||
}
|
||||
|
@ -3,18 +3,18 @@
|
||||
set -eo pipefail
|
||||
|
||||
mkdir -p ./tmp-swagger-gen
|
||||
proto_dirs=$(find ./proto -path -prune -o -name '*.proto' -print0 | xargs -0 -n1 dirname | sort | uniq)
|
||||
proto_dirs=$(find ./proto ./third_party/proto -path -prune -o -name '*.proto' -print0 | xargs -0 -n1 dirname | sort | uniq)
|
||||
for dir in $proto_dirs; do
|
||||
|
||||
# generate swagger files (filter query files)
|
||||
query_file=$(find "${dir}" -maxdepth 1 -name 'query.proto')
|
||||
if [[ ! -z "$query_file" ]]; then
|
||||
buf protoc \
|
||||
protoc \
|
||||
-I "proto" \
|
||||
-I "third_party/proto" \
|
||||
"$query_file" \
|
||||
--swagger_out=./tmp-swagger-gen \
|
||||
--swagger_opt=logtostderr=true --swagger_opt=fqn_for_swagger_name=true --swagger_opt=simple_operation_ids=true
|
||||
--swagger_out ./tmp-swagger-gen \
|
||||
--swagger_opt logtostderr=true --swagger_opt fqn_for_swagger_name=true --swagger_opt simple_operation_ids=true
|
||||
fi
|
||||
done
|
||||
|
||||
@ -25,3 +25,6 @@ swagger-combine ./client/docs/config.json -o ./client/docs/swagger-ui/swagger.ya
|
||||
|
||||
# clean swagger files
|
||||
rm -rf ./tmp-swagger-gen
|
||||
|
||||
# generate binary for static server
|
||||
statik -src=./client/docs/swagger-ui -dest=./client/docs
|
||||
|
4
third_party/proto/cosmos_proto/cosmos.proto
vendored
4
third_party/proto/cosmos_proto/cosmos.proto
vendored
@ -11,4 +11,6 @@ extend google.protobuf.MessageOptions {
|
||||
string implements_interface = 93002;
|
||||
}
|
||||
|
||||
extend google.protobuf.FieldOptions { string accepts_interface = 93001; }
|
||||
extend google.protobuf.FieldOptions {
|
||||
string accepts_interface = 93001;
|
||||
}
|
||||
|
@ -53,7 +53,9 @@ option optimize_for = SPEED;
|
||||
|
||||
// The protocol compiler can output a FileDescriptorSet containing the .proto
|
||||
// files it parses.
|
||||
message FileDescriptorSet { repeated FileDescriptorProto file = 1; }
|
||||
message FileDescriptorSet {
|
||||
repeated FileDescriptorProto file = 1;
|
||||
}
|
||||
|
||||
// Describes a complete .proto file.
|
||||
message FileDescriptorProto {
|
||||
@ -297,9 +299,9 @@ message MethodDescriptorProto {
|
||||
optional MethodOptions options = 4;
|
||||
|
||||
// Identifies if client streams multiple client messages
|
||||
optional bool client_streaming = 5 [ default = false ];
|
||||
optional bool client_streaming = 5 [default = false];
|
||||
// Identifies if server streams multiple server messages
|
||||
optional bool server_streaming = 6 [ default = false ];
|
||||
optional bool server_streaming = 6 [default = false];
|
||||
}
|
||||
|
||||
// ===================================================================
|
||||
@ -355,10 +357,10 @@ message FileOptions {
|
||||
// named by java_outer_classname. However, the outer class will still be
|
||||
// generated to contain the file's getDescriptor() method as well as any
|
||||
// top-level extensions defined in the file.
|
||||
optional bool java_multiple_files = 10 [ default = false ];
|
||||
optional bool java_multiple_files = 10 [default = false];
|
||||
|
||||
// This option does nothing.
|
||||
optional bool java_generate_equals_and_hash = 20 [ deprecated = true ];
|
||||
optional bool java_generate_equals_and_hash = 20 [deprecated = true];
|
||||
|
||||
// If set true, then the Java2 code generator will generate code that
|
||||
// throws an exception whenever an attempt is made to assign a non-UTF-8
|
||||
@ -366,7 +368,7 @@ message FileOptions {
|
||||
// Message reflection will do the same.
|
||||
// However, an extension field still accepts non-UTF-8 byte sequences.
|
||||
// This option has no effect on when used with the lite runtime.
|
||||
optional bool java_string_check_utf8 = 27 [ default = false ];
|
||||
optional bool java_string_check_utf8 = 27 [default = false];
|
||||
|
||||
// Generated classes can be optimized for speed or code size.
|
||||
enum OptimizeMode {
|
||||
@ -375,7 +377,7 @@ message FileOptions {
|
||||
CODE_SIZE = 2; // Use ReflectionOps to implement these methods.
|
||||
LITE_RUNTIME = 3; // Generate code using MessageLite and the lite runtime.
|
||||
}
|
||||
optional OptimizeMode optimize_for = 9 [ default = SPEED ];
|
||||
optional OptimizeMode optimize_for = 9 [default = SPEED];
|
||||
|
||||
// Sets the Go package where structs generated from this .proto will be
|
||||
// placed. If omitted, the Go package will be derived from the following:
|
||||
@ -394,20 +396,20 @@ message FileOptions {
|
||||
// that generate code specific to your particular RPC system. Therefore,
|
||||
// these default to false. Old code which depends on generic services should
|
||||
// explicitly set them to true.
|
||||
optional bool cc_generic_services = 16 [ default = false ];
|
||||
optional bool java_generic_services = 17 [ default = false ];
|
||||
optional bool py_generic_services = 18 [ default = false ];
|
||||
optional bool php_generic_services = 42 [ default = false ];
|
||||
optional bool cc_generic_services = 16 [default = false];
|
||||
optional bool java_generic_services = 17 [default = false];
|
||||
optional bool py_generic_services = 18 [default = false];
|
||||
optional bool php_generic_services = 42 [default = false];
|
||||
|
||||
// Is this file deprecated?
|
||||
// Depending on the target platform, this can emit Deprecated annotations
|
||||
// for everything in the file, or it will be completely ignored; in the very
|
||||
// least, this is a formalization for deprecating files.
|
||||
optional bool deprecated = 23 [ default = false ];
|
||||
optional bool deprecated = 23 [default = false];
|
||||
|
||||
// Enables the use of arenas for the proto messages in this file. This applies
|
||||
// only to generated classes for C++.
|
||||
optional bool cc_enable_arenas = 31 [ default = true ];
|
||||
optional bool cc_enable_arenas = 31 [default = true];
|
||||
|
||||
// Sets the objective c class prefix which is prepended to all objective c
|
||||
// generated classes from this .proto. There is no default.
|
||||
@ -471,18 +473,18 @@ message MessageOptions {
|
||||
//
|
||||
// Because this is an option, the above two restrictions are not enforced by
|
||||
// the protocol compiler.
|
||||
optional bool message_set_wire_format = 1 [ default = false ];
|
||||
optional bool message_set_wire_format = 1 [default = false];
|
||||
|
||||
// Disables the generation of the standard "descriptor()" accessor, which can
|
||||
// conflict with a field of the same name. This is meant to make migration
|
||||
// from proto1 easier; new code should avoid fields named "descriptor".
|
||||
optional bool no_standard_descriptor_accessor = 2 [ default = false ];
|
||||
optional bool no_standard_descriptor_accessor = 2 [default = false];
|
||||
|
||||
// Is this message deprecated?
|
||||
// Depending on the target platform, this can emit Deprecated annotations
|
||||
// for the message, or it will be completely ignored; in the very least,
|
||||
// this is a formalization for deprecating messages.
|
||||
optional bool deprecated = 3 [ default = false ];
|
||||
optional bool deprecated = 3 [default = false];
|
||||
|
||||
// Whether the message is an automatically generated map entry type for the
|
||||
// maps field.
|
||||
@ -522,7 +524,7 @@ message FieldOptions {
|
||||
// representation of the field than it normally would. See the specific
|
||||
// options below. This option is not yet implemented in the open source
|
||||
// release -- sorry, we'll try to include it in a future version!
|
||||
optional CType ctype = 1 [ default = STRING ];
|
||||
optional CType ctype = 1 [default = STRING];
|
||||
enum CType {
|
||||
// Default mode.
|
||||
STRING = 0;
|
||||
@ -549,7 +551,7 @@ message FieldOptions {
|
||||
//
|
||||
// This option is an enum to permit additional types to be added, e.g.
|
||||
// goog.math.Integer.
|
||||
optional JSType jstype = 6 [ default = JS_NORMAL ];
|
||||
optional JSType jstype = 6 [default = JS_NORMAL];
|
||||
enum JSType {
|
||||
// Use the default type.
|
||||
JS_NORMAL = 0;
|
||||
@ -589,16 +591,16 @@ message FieldOptions {
|
||||
// implementation must either *always* check its required fields, or *never*
|
||||
// check its required fields, regardless of whether or not the message has
|
||||
// been parsed.
|
||||
optional bool lazy = 5 [ default = false ];
|
||||
optional bool lazy = 5 [default = false];
|
||||
|
||||
// Is this field deprecated?
|
||||
// Depending on the target platform, this can emit Deprecated annotations
|
||||
// for accessors, or it will be completely ignored; in the very least, this
|
||||
// is a formalization for deprecating fields.
|
||||
optional bool deprecated = 3 [ default = false ];
|
||||
optional bool deprecated = 3 [default = false];
|
||||
|
||||
// For Google-internal migration only. Do not use.
|
||||
optional bool weak = 10 [ default = false ];
|
||||
optional bool weak = 10 [default = false];
|
||||
|
||||
// The parser stores options it doesn't recognize here. See above.
|
||||
repeated UninterpretedOption uninterpreted_option = 999;
|
||||
@ -627,7 +629,7 @@ message EnumOptions {
|
||||
// Depending on the target platform, this can emit Deprecated annotations
|
||||
// for the enum, or it will be completely ignored; in the very least, this
|
||||
// is a formalization for deprecating enums.
|
||||
optional bool deprecated = 3 [ default = false ];
|
||||
optional bool deprecated = 3 [default = false];
|
||||
|
||||
reserved 5; // javanano_as_lite
|
||||
|
||||
@ -643,7 +645,7 @@ message EnumValueOptions {
|
||||
// Depending on the target platform, this can emit Deprecated annotations
|
||||
// for the enum value, or it will be completely ignored; in the very least,
|
||||
// this is a formalization for deprecating enum values.
|
||||
optional bool deprecated = 1 [ default = false ];
|
||||
optional bool deprecated = 1 [default = false];
|
||||
|
||||
// The parser stores options it doesn't recognize here. See above.
|
||||
repeated UninterpretedOption uninterpreted_option = 999;
|
||||
@ -663,7 +665,7 @@ message ServiceOptions {
|
||||
// Depending on the target platform, this can emit Deprecated annotations
|
||||
// for the service, or it will be completely ignored; in the very least,
|
||||
// this is a formalization for deprecating services.
|
||||
optional bool deprecated = 33 [ default = false ];
|
||||
optional bool deprecated = 33 [default = false];
|
||||
|
||||
// The parser stores options it doesn't recognize here. See above.
|
||||
repeated UninterpretedOption uninterpreted_option = 999;
|
||||
@ -683,7 +685,7 @@ message MethodOptions {
|
||||
// Depending on the target platform, this can emit Deprecated annotations
|
||||
// for the method, or it will be completely ignored; in the very least,
|
||||
// this is a formalization for deprecating methods.
|
||||
optional bool deprecated = 33 [ default = false ];
|
||||
optional bool deprecated = 33 [default = false];
|
||||
|
||||
// Is this method side-effect-free (or safe in HTTP parlance), or idempotent,
|
||||
// or neither? HTTP based RPC implementation may choose GET verb for safe
|
||||
@ -693,8 +695,7 @@ message MethodOptions {
|
||||
NO_SIDE_EFFECTS = 1; // implies idempotent
|
||||
IDEMPOTENT = 2; // idempotent, but may have side effects
|
||||
}
|
||||
optional IdempotencyLevel idempotency_level = 34
|
||||
[ default = IDEMPOTENCY_UNKNOWN ];
|
||||
optional IdempotencyLevel idempotency_level = 34 [default = IDEMPOTENCY_UNKNOWN];
|
||||
|
||||
// The parser stores options it doesn't recognize here. See above.
|
||||
repeated UninterpretedOption uninterpreted_option = 999;
|
||||
@ -805,14 +806,14 @@ message SourceCodeInfo {
|
||||
// [ 4, 3, 2, 7 ]
|
||||
// this path refers to the whole field declaration (from the beginning
|
||||
// of the label to the terminating semicolon).
|
||||
repeated int32 path = 1 [ packed = true ];
|
||||
repeated int32 path = 1 [packed = true];
|
||||
|
||||
// Always has exactly three or four elements: start line, start column,
|
||||
// end line (optional, otherwise assumed same as start line), end column.
|
||||
// These are packed into a single field for efficiency. Note that line
|
||||
// and column numbers are zero-based -- typically you will want to add
|
||||
// 1 to each before displaying to a user.
|
||||
repeated int32 span = 2 [ packed = true ];
|
||||
repeated int32 span = 2 [packed = true];
|
||||
|
||||
// If this SourceCodeInfo represents a complete declaration, these are any
|
||||
// comments appearing before and after the declaration which appear to be
|
||||
@ -877,7 +878,7 @@ message GeneratedCodeInfo {
|
||||
message Annotation {
|
||||
// Identifies the element in the original source .proto file. This field
|
||||
// is formatted the same as SourceCodeInfo.Location.path.
|
||||
repeated int32 path = 1 [ packed = true ];
|
||||
repeated int32 path = 1 [packed = true];
|
||||
|
||||
// Identifies the filesystem path to the original source .proto.
|
||||
optional string source_file = 2;
|
||||
|
31
third_party/proto/tendermint/abci/types.proto
vendored
31
third_party/proto/tendermint/abci/types.proto
vendored
@ -58,8 +58,7 @@ message RequestSetOption {
|
||||
}
|
||||
|
||||
message RequestInitChain {
|
||||
google.protobuf.Timestamp time = 1
|
||||
[(gogoproto.nullable) = false, (gogoproto.stdtime) = true];
|
||||
google.protobuf.Timestamp time = 1 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true];
|
||||
string chain_id = 2;
|
||||
ConsensusParams consensus_params = 3;
|
||||
repeated ValidatorUpdate validators = 4 [(gogoproto.nullable) = false];
|
||||
@ -102,8 +101,7 @@ message RequestEndBlock {
|
||||
message RequestCommit {}
|
||||
|
||||
// lists available snapshots
|
||||
message RequestListSnapshots {
|
||||
}
|
||||
message RequestListSnapshots {}
|
||||
|
||||
// offers a snapshot to the application
|
||||
message RequestOfferSnapshot {
|
||||
@ -198,8 +196,7 @@ message ResponseQuery {
|
||||
}
|
||||
|
||||
message ResponseBeginBlock {
|
||||
repeated Event events = 1
|
||||
[(gogoproto.nullable) = false, (gogoproto.jsontag) = "events,omitempty"];
|
||||
repeated Event events = 1 [(gogoproto.nullable) = false, (gogoproto.jsontag) = "events,omitempty"];
|
||||
}
|
||||
|
||||
message ResponseCheckTx {
|
||||
@ -209,8 +206,7 @@ message ResponseCheckTx {
|
||||
string info = 4; // nondeterministic
|
||||
int64 gas_wanted = 5 [json_name = "gas_wanted"];
|
||||
int64 gas_used = 6 [json_name = "gas_used"];
|
||||
repeated Event events = 7
|
||||
[(gogoproto.nullable) = false, (gogoproto.jsontag) = "events,omitempty"];
|
||||
repeated Event events = 7 [(gogoproto.nullable) = false, (gogoproto.jsontag) = "events,omitempty"];
|
||||
string codespace = 8;
|
||||
}
|
||||
|
||||
@ -221,17 +217,14 @@ message ResponseDeliverTx {
|
||||
string info = 4; // nondeterministic
|
||||
int64 gas_wanted = 5 [json_name = "gas_wanted"];
|
||||
int64 gas_used = 6 [json_name = "gas_used"];
|
||||
repeated Event events = 7
|
||||
[(gogoproto.nullable) = false, (gogoproto.jsontag) = "events,omitempty"];
|
||||
repeated Event events = 7 [(gogoproto.nullable) = false, (gogoproto.jsontag) = "events,omitempty"];
|
||||
string codespace = 8;
|
||||
}
|
||||
|
||||
message ResponseEndBlock {
|
||||
repeated ValidatorUpdate validator_updates = 1
|
||||
[(gogoproto.nullable) = false];
|
||||
repeated ValidatorUpdate validator_updates = 1 [(gogoproto.nullable) = false];
|
||||
ConsensusParams consensus_param_updates = 2;
|
||||
repeated Event events = 3
|
||||
[(gogoproto.nullable) = false, (gogoproto.jsontag) = "events,omitempty"];
|
||||
repeated Event events = 3 [(gogoproto.nullable) = false, (gogoproto.jsontag) = "events,omitempty"];
|
||||
}
|
||||
|
||||
message ResponseCommit {
|
||||
@ -306,10 +299,7 @@ message LastCommitInfo {
|
||||
// Later, transactions may be queried using these events.
|
||||
message Event {
|
||||
string type = 1;
|
||||
repeated EventAttribute attributes = 2 [
|
||||
(gogoproto.nullable) = false,
|
||||
(gogoproto.jsontag) = "attributes,omitempty"
|
||||
];
|
||||
repeated EventAttribute attributes = 2 [(gogoproto.nullable) = false, (gogoproto.jsontag) = "attributes,omitempty"];
|
||||
}
|
||||
|
||||
// EventAttribute is a single key-value pair, associated with an event.
|
||||
@ -364,10 +354,7 @@ message Evidence {
|
||||
// The height when the offense occurred
|
||||
int64 height = 3;
|
||||
// The corresponding time where the offense occurred
|
||||
google.protobuf.Timestamp time = 4 [
|
||||
(gogoproto.nullable) = false,
|
||||
(gogoproto.stdtime) = true
|
||||
];
|
||||
google.protobuf.Timestamp time = 4 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true];
|
||||
// Total voting power of the validator set in case the ABCI application does
|
||||
// not store historical validators.
|
||||
// https://github.com/tendermint/tendermint/issues/4581
|
||||
|
@ -45,8 +45,7 @@ message EvidenceParams {
|
||||
// It should correspond with an app's "unbonding period" or other similar
|
||||
// mechanism for handling [Nothing-At-Stake
|
||||
// attacks](https://github.com/ethereum/wiki/wiki/Proof-of-Stake-FAQ#what-is-the-nothing-at-stake-problem-and-how-can-it-be-fixed).
|
||||
google.protobuf.Duration max_age_duration = 2
|
||||
[(gogoproto.nullable) = false, (gogoproto.stdduration) = true];
|
||||
google.protobuf.Duration max_age_duration = 2 [(gogoproto.nullable) = false, (gogoproto.stdduration) = true];
|
||||
|
||||
// This sets the maximum size of total evidence in bytes that can be committed in a single block.
|
||||
// and should fall comfortably under the max block bytes.
|
||||
|
12
third_party/proto/tendermint/types/types.proto
vendored
12
third_party/proto/tendermint/types/types.proto
vendored
@ -95,10 +95,8 @@ message Vote {
|
||||
SignedMsgType type = 1;
|
||||
int64 height = 2;
|
||||
int32 round = 3;
|
||||
BlockID block_id = 4
|
||||
[(gogoproto.nullable) = false, (gogoproto.customname) = "BlockID"]; // zero if vote is nil.
|
||||
google.protobuf.Timestamp timestamp = 5
|
||||
[(gogoproto.nullable) = false, (gogoproto.stdtime) = true];
|
||||
BlockID block_id = 4 [(gogoproto.nullable) = false, (gogoproto.customname) = "BlockID"]; // zero if vote is nil.
|
||||
google.protobuf.Timestamp timestamp = 5 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true];
|
||||
bytes validator_address = 6;
|
||||
int32 validator_index = 7;
|
||||
bytes signature = 8;
|
||||
@ -116,8 +114,7 @@ message Commit {
|
||||
message CommitSig {
|
||||
BlockIDFlag block_id_flag = 1;
|
||||
bytes validator_address = 2;
|
||||
google.protobuf.Timestamp timestamp = 3
|
||||
[(gogoproto.nullable) = false, (gogoproto.stdtime) = true];
|
||||
google.protobuf.Timestamp timestamp = 3 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true];
|
||||
bytes signature = 4;
|
||||
}
|
||||
|
||||
@ -127,8 +124,7 @@ message Proposal {
|
||||
int32 round = 3;
|
||||
int32 pol_round = 4;
|
||||
BlockID block_id = 5 [(gogoproto.customname) = "BlockID", (gogoproto.nullable) = false];
|
||||
google.protobuf.Timestamp timestamp = 6
|
||||
[(gogoproto.nullable) = false, (gogoproto.stdtime) = true];
|
||||
google.protobuf.Timestamp timestamp = 6 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true];
|
||||
bytes signature = 7;
|
||||
}
|
||||
|
||||
|
@ -18,13 +18,13 @@ func RegisterInterfaces(registry codectypes.InterfaceRegistry) {
|
||||
&MsgEthereumTx{},
|
||||
)
|
||||
|
||||
registry.RegisterInterface("injective.evm.v1beta1.ExtensionOptionsEthereumTx", (*ExtensionOptionsEthereumTxI)(nil))
|
||||
registry.RegisterInterface("injective.evm.v1alpha1.ExtensionOptionsEthereumTx", (*ExtensionOptionsEthereumTxI)(nil))
|
||||
registry.RegisterImplementations(
|
||||
(*ExtensionOptionsEthereumTxI)(nil),
|
||||
&ExtensionOptionsEthereumTx{},
|
||||
)
|
||||
|
||||
registry.RegisterInterface("injective.evm.v1beta1.ExtensionOptionsWeb3Tx", (*ExtensionOptionsWeb3TxI)(nil))
|
||||
registry.RegisterInterface("injective.evm.v1alpha1.ExtensionOptionsWeb3Tx", (*ExtensionOptionsWeb3TxI)(nil))
|
||||
registry.RegisterImplementations(
|
||||
(*ExtensionOptionsWeb3TxI)(nil),
|
||||
&ExtensionOptionsWeb3Tx{},
|
||||
|
Loading…
Reference in New Issue
Block a user