forked from cerc-io/laconicd-deprecated
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
|
||||
@ -38,96 +35,91 @@ message ChainConfig {
|
||||
// Homestead switch block (< 0 no fork, 0 = already homestead)
|
||||
string homestead_block = 1 [
|
||||
(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int",
|
||||
(gogoproto.moretags) = "yaml:\"homestead_block\"",
|
||||
(gogoproto.nullable) = false
|
||||
(gogoproto.moretags) = "yaml:\"homestead_block\"",
|
||||
(gogoproto.nullable) = false
|
||||
];
|
||||
// TheDAO hard-fork switch block (< 0 no fork)
|
||||
string dao_fork_block = 2 [
|
||||
(gogoproto.customname) = "DAOForkBlock",
|
||||
(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int",
|
||||
(gogoproto.moretags) = "yaml:\"dao_fork_block\"",
|
||||
(gogoproto.nullable) = false
|
||||
(gogoproto.moretags) = "yaml:\"dao_fork_block\"",
|
||||
(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 [
|
||||
(gogoproto.customname) = "EIP150Block",
|
||||
(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int",
|
||||
(gogoproto.moretags) = "yaml:\"eip150_block\"",
|
||||
(gogoproto.nullable) = false
|
||||
(gogoproto.moretags) = "yaml:\"eip150_block\"",
|
||||
(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",
|
||||
(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int",
|
||||
(gogoproto.moretags) = "yaml:\"eip155_block\"",
|
||||
(gogoproto.nullable) = false
|
||||
(gogoproto.moretags) = "yaml:\"eip155_block\"",
|
||||
(gogoproto.nullable) = false
|
||||
];
|
||||
// EIP158 HF block
|
||||
string eip158_block = 7 [
|
||||
(gogoproto.customname) = "EIP158Block",
|
||||
(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int",
|
||||
(gogoproto.moretags) = "yaml:\"eip158_block\"",
|
||||
(gogoproto.nullable) = false
|
||||
(gogoproto.moretags) = "yaml:\"eip158_block\"",
|
||||
(gogoproto.nullable) = false
|
||||
];
|
||||
// Byzantium switch block (< 0 no fork, 0 = already on byzantium)
|
||||
string byzantium_block = 8 [
|
||||
(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int",
|
||||
(gogoproto.moretags) = "yaml:\"byzantium_block\"",
|
||||
(gogoproto.nullable) = false
|
||||
(gogoproto.moretags) = "yaml:\"byzantium_block\"",
|
||||
(gogoproto.nullable) = false
|
||||
];
|
||||
// Constantinople switch block (< 0 no fork, 0 = already activated)
|
||||
string constantinople_block = 9 [
|
||||
(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int",
|
||||
(gogoproto.moretags) = "yaml:\"constantinople_block\"",
|
||||
(gogoproto.nullable) = false
|
||||
(gogoproto.moretags) = "yaml:\"constantinople_block\"",
|
||||
(gogoproto.nullable) = false
|
||||
];
|
||||
// Petersburg switch block (< 0 same as Constantinople)
|
||||
string petersburg_block = 10 [
|
||||
(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int",
|
||||
(gogoproto.moretags) = "yaml:\"petersburg_block\"",
|
||||
(gogoproto.nullable) = false
|
||||
(gogoproto.moretags) = "yaml:\"petersburg_block\"",
|
||||
(gogoproto.nullable) = false
|
||||
];
|
||||
// Istanbul switch block (< 0 no fork, 0 = already on istanbul)
|
||||
string istanbul_block = 11 [
|
||||
(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int",
|
||||
(gogoproto.moretags) = "yaml:\"istanbul_block\"",
|
||||
(gogoproto.nullable) = false
|
||||
(gogoproto.moretags) = "yaml:\"istanbul_block\"",
|
||||
(gogoproto.nullable) = false
|
||||
];
|
||||
// Eip-2384 (bomb delay) switch block (< 0 no fork, 0 = already activated)
|
||||
string muir_glacier_block = 12 [
|
||||
(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int",
|
||||
(gogoproto.moretags) = "yaml:\"muir_glacier_block\"",
|
||||
(gogoproto.nullable) = false
|
||||
(gogoproto.moretags) = "yaml:\"muir_glacier_block\"",
|
||||
(gogoproto.nullable) = false
|
||||
];
|
||||
// YOLO v2: https://github.com/ethereum/EIPs/pull/2657 (Ephemeral testnet)
|
||||
string yolo_v2_block = 13 [
|
||||
(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int",
|
||||
(gogoproto.moretags) = "yaml:\"yolo_v2_block\"",
|
||||
(gogoproto.nullable) = false
|
||||
(gogoproto.moretags) = "yaml:\"yolo_v2_block\"",
|
||||
(gogoproto.nullable) = false
|
||||
];
|
||||
// EWASM switch block (< 0 no fork, 0 = already activated)
|
||||
string ewasm_block = 14 [
|
||||
(gogoproto.customname) = "EWASMBlock",
|
||||
(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int",
|
||||
(gogoproto.moretags) = "yaml:\"ewasm_block\"",
|
||||
(gogoproto.nullable) = false
|
||||
(gogoproto.moretags) = "yaml:\"ewasm_block\"",
|
||||
(gogoproto.nullable) = false
|
||||
];
|
||||
}
|
||||
|
||||
// State represents a single Storage key value pair item.
|
||||
message State {
|
||||
string key = 1;
|
||||
string key = 1;
|
||||
string value = 2;
|
||||
}
|
||||
|
||||
@ -135,7 +127,7 @@ message State {
|
||||
// with a given hash. It it used for import/export data as transactions are not
|
||||
// persisted on blockchain state after an upgrade.
|
||||
message TransactionLogs {
|
||||
string hash = 1;
|
||||
string hash = 1;
|
||||
repeated Log logs = 2;
|
||||
}
|
||||
|
||||
@ -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
|
||||
@ -176,13 +168,13 @@ message Log {
|
||||
message TxReceipt {
|
||||
option (gogoproto.goproto_getters) = false;
|
||||
|
||||
bytes hash = 1;
|
||||
bytes from = 2;
|
||||
TxData data = 3;
|
||||
TxResult result = 4;
|
||||
uint64 index = 5;
|
||||
uint64 blockHeight = 6;
|
||||
bytes blockHash = 7;
|
||||
bytes hash = 1;
|
||||
bytes from = 2;
|
||||
TxData data = 3;
|
||||
TxResult result = 4;
|
||||
uint64 index = 5;
|
||||
uint64 blockHeight = 6;
|
||||
bytes blockHash = 7;
|
||||
}
|
||||
|
||||
// TxResult stores results of Tx execution.
|
||||
@ -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.
|
||||
@ -79,7 +78,7 @@ service Query {
|
||||
|
||||
// QueryAccountRequest is the request type for the Query/Account RPC method.
|
||||
message QueryAccountRequest {
|
||||
option (gogoproto.equal) = false;
|
||||
option (gogoproto.equal) = false;
|
||||
option (gogoproto.goproto_getters) = false;
|
||||
|
||||
// address is the ethereum hex address to query the account for.
|
||||
@ -98,7 +97,7 @@ message QueryAccountResponse {
|
||||
|
||||
// QueryCosmosAccountRequest is the request type for the Query/CosmosAccount RPC method.
|
||||
message QueryCosmosAccountRequest {
|
||||
option (gogoproto.equal) = false;
|
||||
option (gogoproto.equal) = false;
|
||||
option (gogoproto.goproto_getters) = false;
|
||||
|
||||
// address is the ethereum hex address to query the account for.
|
||||
@ -117,7 +116,7 @@ message QueryCosmosAccountResponse {
|
||||
|
||||
// QueryBalanceRequest is the request type for the Query/Balance RPC method.
|
||||
message QueryBalanceRequest {
|
||||
option (gogoproto.equal) = false;
|
||||
option (gogoproto.equal) = false;
|
||||
option (gogoproto.goproto_getters) = false;
|
||||
|
||||
// address is the ethereum hex address to query the balance for.
|
||||
@ -132,7 +131,7 @@ message QueryBalanceResponse {
|
||||
|
||||
// QueryStorageRequest is the request type for the Query/Storage RPC method.
|
||||
message QueryStorageRequest {
|
||||
option (gogoproto.equal) = false;
|
||||
option (gogoproto.equal) = false;
|
||||
option (gogoproto.goproto_getters) = false;
|
||||
|
||||
/// address is the ethereum hex address to query the storage state for.
|
||||
@ -151,7 +150,7 @@ message QueryStorageResponse {
|
||||
|
||||
// QueryCodeRequest is the request type for the Query/Code RPC method.
|
||||
message QueryCodeRequest {
|
||||
option (gogoproto.equal) = false;
|
||||
option (gogoproto.equal) = false;
|
||||
option (gogoproto.goproto_getters) = false;
|
||||
|
||||
// address is the ethereum hex address to query the code for.
|
||||
@ -167,7 +166,7 @@ message QueryCodeResponse {
|
||||
|
||||
// QueryTxLogsRequest is the request type for the Query/TxLogs RPC method.
|
||||
message QueryTxLogsRequest {
|
||||
option (gogoproto.equal) = false;
|
||||
option (gogoproto.equal) = false;
|
||||
option (gogoproto.goproto_getters) = false;
|
||||
|
||||
// hash is the ethereum transaction hex hash to query the logs for.
|
||||
@ -182,7 +181,7 @@ message QueryTxLogsResponse {
|
||||
|
||||
// QueryTxReceiptRequest is the request type for the Query/TxReceipt RPC method.
|
||||
message QueryTxReceiptRequest {
|
||||
option (gogoproto.equal) = false;
|
||||
option (gogoproto.equal) = false;
|
||||
option (gogoproto.goproto_getters) = false;
|
||||
|
||||
// hash is the ethereum transaction hex hash to query the receipt for.
|
||||
@ -197,7 +196,7 @@ message QueryTxReceiptResponse {
|
||||
|
||||
// QueryTxReceiptsByBlockHeightRequest is the request type for the Query/TxReceiptsByBlockHeight RPC method.
|
||||
message QueryTxReceiptsByBlockHeightRequest {
|
||||
option (gogoproto.equal) = false;
|
||||
option (gogoproto.equal) = false;
|
||||
option (gogoproto.goproto_getters) = false;
|
||||
|
||||
// height is the block height to query tx receipts for
|
||||
@ -212,7 +211,7 @@ message QueryTxReceiptsByBlockHeightResponse {
|
||||
|
||||
// QueryTxReceiptsByBlockHashRequest is the request type for the Query/TxReceiptsByBlockHash RPC method.
|
||||
message QueryTxReceiptsByBlockHashRequest {
|
||||
option (gogoproto.equal) = false;
|
||||
option (gogoproto.equal) = false;
|
||||
option (gogoproto.goproto_getters) = false;
|
||||
|
||||
// hash is the ethereum transaction hex hash to query the receipt for.
|
||||
@ -227,7 +226,7 @@ message QueryTxReceiptsByBlockHashResponse {
|
||||
|
||||
// QueryBlockLogsRequest is the request type for the Query/BlockLogs RPC method.
|
||||
message QueryBlockLogsRequest {
|
||||
option (gogoproto.equal) = false;
|
||||
option (gogoproto.equal) = false;
|
||||
option (gogoproto.goproto_getters) = false;
|
||||
|
||||
// hash is the block hash to query the logs for.
|
||||
@ -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
|
||||
@ -57,14 +54,14 @@ message MsgEthereumTxResponse {
|
||||
message SigCache {
|
||||
option (gogoproto.goproto_getters) = false;
|
||||
|
||||
EIP155Signer signer = 1;
|
||||
bytes address = 2;
|
||||
EIP155Signer signer = 1;
|
||||
bytes address = 2;
|
||||
}
|
||||
|
||||
// EIP155Transaction implements Signer using the EIP155 rules.
|
||||
message EIP155Signer {
|
||||
option (gogoproto.goproto_getters) = false;
|
||||
|
||||
bytes chain_id = 1 [(gogoproto.customname) = "chainId"];
|
||||
bytes chain_id = 1 [(gogoproto.customname) = "chainId"];
|
||||
bytes chain_id_mul = 2 [(gogoproto.customname) = "chainIdMul"];
|
||||
}
|
||||
|
@ -10,16 +10,13 @@ option go_package = "github.com/cosmos/ethermint/types";
|
||||
// EthAccount implements the authtypes.AccountI interface and embeds an
|
||||
// authtypes.BaseAccount type. It is compatible with the auth AccountKeeper.
|
||||
message EthAccount {
|
||||
option (gogoproto.goproto_getters) = false;
|
||||
option (gogoproto.goproto_getters) = false;
|
||||
option (gogoproto.goproto_stringer) = false;
|
||||
option (gogoproto.equal) = 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,19 +3,19 @@
|
||||
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 \
|
||||
-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
|
||||
fi
|
||||
|
||||
# generate swagger files (filter query files)
|
||||
query_file=$(find "${dir}" -maxdepth 1 -name 'query.proto')
|
||||
if [[ ! -z "$query_file" ]]; then
|
||||
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
|
||||
fi
|
||||
done
|
||||
|
||||
# combine swagger files
|
||||
@ -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;
|
||||
}
|
||||
|
114
third_party/proto/gogoproto/gogo.proto
vendored
114
third_party/proto/gogoproto/gogo.proto
vendored
@ -31,16 +31,16 @@ package gogoproto;
|
||||
|
||||
import "google/protobuf/descriptor.proto";
|
||||
|
||||
option java_package = "com.google.protobuf";
|
||||
option java_package = "com.google.protobuf";
|
||||
option java_outer_classname = "GoGoProtos";
|
||||
option go_package = "github.com/gogo/protobuf/gogoproto";
|
||||
option go_package = "github.com/gogo/protobuf/gogoproto";
|
||||
|
||||
extend google.protobuf.EnumOptions {
|
||||
optional bool goproto_enum_prefix = 62001;
|
||||
optional bool goproto_enum_stringer = 62021;
|
||||
optional bool enum_stringer = 62022;
|
||||
optional string enum_customname = 62023;
|
||||
optional bool enumdecl = 62024;
|
||||
optional bool goproto_enum_prefix = 62001;
|
||||
optional bool goproto_enum_stringer = 62021;
|
||||
optional bool enum_stringer = 62022;
|
||||
optional string enum_customname = 62023;
|
||||
optional bool enumdecl = 62024;
|
||||
}
|
||||
|
||||
extend google.protobuf.EnumValueOptions {
|
||||
@ -48,98 +48,98 @@ extend google.protobuf.EnumValueOptions {
|
||||
}
|
||||
|
||||
extend google.protobuf.FileOptions {
|
||||
optional bool goproto_getters_all = 63001;
|
||||
optional bool goproto_getters_all = 63001;
|
||||
optional bool goproto_enum_prefix_all = 63002;
|
||||
optional bool goproto_stringer_all = 63003;
|
||||
optional bool verbose_equal_all = 63004;
|
||||
optional bool face_all = 63005;
|
||||
optional bool gostring_all = 63006;
|
||||
optional bool populate_all = 63007;
|
||||
optional bool stringer_all = 63008;
|
||||
optional bool onlyone_all = 63009;
|
||||
optional bool goproto_stringer_all = 63003;
|
||||
optional bool verbose_equal_all = 63004;
|
||||
optional bool face_all = 63005;
|
||||
optional bool gostring_all = 63006;
|
||||
optional bool populate_all = 63007;
|
||||
optional bool stringer_all = 63008;
|
||||
optional bool onlyone_all = 63009;
|
||||
|
||||
optional bool equal_all = 63013;
|
||||
optional bool description_all = 63014;
|
||||
optional bool testgen_all = 63015;
|
||||
optional bool benchgen_all = 63016;
|
||||
optional bool marshaler_all = 63017;
|
||||
optional bool unmarshaler_all = 63018;
|
||||
optional bool equal_all = 63013;
|
||||
optional bool description_all = 63014;
|
||||
optional bool testgen_all = 63015;
|
||||
optional bool benchgen_all = 63016;
|
||||
optional bool marshaler_all = 63017;
|
||||
optional bool unmarshaler_all = 63018;
|
||||
optional bool stable_marshaler_all = 63019;
|
||||
|
||||
optional bool sizer_all = 63020;
|
||||
|
||||
optional bool goproto_enum_stringer_all = 63021;
|
||||
optional bool enum_stringer_all = 63022;
|
||||
optional bool enum_stringer_all = 63022;
|
||||
|
||||
optional bool unsafe_marshaler_all = 63023;
|
||||
optional bool unsafe_marshaler_all = 63023;
|
||||
optional bool unsafe_unmarshaler_all = 63024;
|
||||
|
||||
optional bool goproto_extensions_map_all = 63025;
|
||||
optional bool goproto_unrecognized_all = 63026;
|
||||
optional bool gogoproto_import = 63027;
|
||||
optional bool protosizer_all = 63028;
|
||||
optional bool compare_all = 63029;
|
||||
optional bool typedecl_all = 63030;
|
||||
optional bool enumdecl_all = 63031;
|
||||
optional bool goproto_unrecognized_all = 63026;
|
||||
optional bool gogoproto_import = 63027;
|
||||
optional bool protosizer_all = 63028;
|
||||
optional bool compare_all = 63029;
|
||||
optional bool typedecl_all = 63030;
|
||||
optional bool enumdecl_all = 63031;
|
||||
|
||||
optional bool goproto_registration = 63032;
|
||||
optional bool messagename_all = 63033;
|
||||
optional bool messagename_all = 63033;
|
||||
|
||||
optional bool goproto_sizecache_all = 63034;
|
||||
optional bool goproto_unkeyed_all = 63035;
|
||||
optional bool goproto_unkeyed_all = 63035;
|
||||
}
|
||||
|
||||
extend google.protobuf.MessageOptions {
|
||||
optional bool goproto_getters = 64001;
|
||||
optional bool goproto_getters = 64001;
|
||||
optional bool goproto_stringer = 64003;
|
||||
optional bool verbose_equal = 64004;
|
||||
optional bool face = 64005;
|
||||
optional bool gostring = 64006;
|
||||
optional bool populate = 64007;
|
||||
optional bool stringer = 67008;
|
||||
optional bool onlyone = 64009;
|
||||
optional bool verbose_equal = 64004;
|
||||
optional bool face = 64005;
|
||||
optional bool gostring = 64006;
|
||||
optional bool populate = 64007;
|
||||
optional bool stringer = 67008;
|
||||
optional bool onlyone = 64009;
|
||||
|
||||
optional bool equal = 64013;
|
||||
optional bool description = 64014;
|
||||
optional bool testgen = 64015;
|
||||
optional bool benchgen = 64016;
|
||||
optional bool marshaler = 64017;
|
||||
optional bool unmarshaler = 64018;
|
||||
optional bool equal = 64013;
|
||||
optional bool description = 64014;
|
||||
optional bool testgen = 64015;
|
||||
optional bool benchgen = 64016;
|
||||
optional bool marshaler = 64017;
|
||||
optional bool unmarshaler = 64018;
|
||||
optional bool stable_marshaler = 64019;
|
||||
|
||||
optional bool sizer = 64020;
|
||||
|
||||
optional bool unsafe_marshaler = 64023;
|
||||
optional bool unsafe_marshaler = 64023;
|
||||
optional bool unsafe_unmarshaler = 64024;
|
||||
|
||||
optional bool goproto_extensions_map = 64025;
|
||||
optional bool goproto_unrecognized = 64026;
|
||||
optional bool goproto_unrecognized = 64026;
|
||||
|
||||
optional bool protosizer = 64028;
|
||||
optional bool compare = 64029;
|
||||
optional bool compare = 64029;
|
||||
|
||||
optional bool typedecl = 64030;
|
||||
|
||||
optional bool messagename = 64033;
|
||||
|
||||
optional bool goproto_sizecache = 64034;
|
||||
optional bool goproto_unkeyed = 64035;
|
||||
optional bool goproto_unkeyed = 64035;
|
||||
}
|
||||
|
||||
extend google.protobuf.FieldOptions {
|
||||
optional bool nullable = 65001;
|
||||
optional bool embed = 65002;
|
||||
optional bool nullable = 65001;
|
||||
optional bool embed = 65002;
|
||||
optional string customtype = 65003;
|
||||
optional string customname = 65004;
|
||||
optional string jsontag = 65005;
|
||||
optional string moretags = 65006;
|
||||
optional string casttype = 65007;
|
||||
optional string castkey = 65008;
|
||||
optional string castvalue = 65009;
|
||||
optional string jsontag = 65005;
|
||||
optional string moretags = 65006;
|
||||
optional string casttype = 65007;
|
||||
optional string castkey = 65008;
|
||||
optional string castvalue = 65009;
|
||||
|
||||
optional bool stdtime = 65010;
|
||||
optional bool stdtime = 65010;
|
||||
optional bool stdduration = 65011;
|
||||
optional bool wktpointer = 65012;
|
||||
optional bool wktpointer = 65012;
|
||||
|
||||
optional string castrepeated = 65013;
|
||||
}
|
||||
|
@ -19,11 +19,11 @@ package google.api;
|
||||
import "google/api/http.proto";
|
||||
import "google/protobuf/descriptor.proto";
|
||||
|
||||
option go_package = "google.golang.org/genproto/googleapis/api/annotations;annotations";
|
||||
option java_multiple_files = true;
|
||||
option go_package = "google.golang.org/genproto/googleapis/api/annotations;annotations";
|
||||
option java_multiple_files = true;
|
||||
option java_outer_classname = "AnnotationsProto";
|
||||
option java_package = "com.google.api";
|
||||
option objc_class_prefix = "GAPI";
|
||||
option java_package = "com.google.api";
|
||||
option objc_class_prefix = "GAPI";
|
||||
|
||||
extend google.protobuf.MethodOptions {
|
||||
// See `HttpRule`.
|
||||
|
10
third_party/proto/google/api/http.proto
vendored
10
third_party/proto/google/api/http.proto
vendored
@ -16,12 +16,12 @@ syntax = "proto3";
|
||||
|
||||
package google.api;
|
||||
|
||||
option cc_enable_arenas = true;
|
||||
option go_package = "google.golang.org/genproto/googleapis/api/annotations;annotations";
|
||||
option java_multiple_files = true;
|
||||
option cc_enable_arenas = true;
|
||||
option go_package = "google.golang.org/genproto/googleapis/api/annotations;annotations";
|
||||
option java_multiple_files = true;
|
||||
option java_outer_classname = "HttpProto";
|
||||
option java_package = "com.google.api";
|
||||
option objc_class_prefix = "GAPI";
|
||||
option java_package = "com.google.api";
|
||||
option objc_class_prefix = "GAPI";
|
||||
|
||||
// Defines the HTTP configuration for an API service. It contains a list of
|
||||
// [HttpRule][google.api.HttpRule], each specifying the mapping of an RPC method
|
||||
|
10
third_party/proto/google/api/httpbody.proto
vendored
10
third_party/proto/google/api/httpbody.proto
vendored
@ -19,12 +19,12 @@ package google.api;
|
||||
|
||||
import "google/protobuf/any.proto";
|
||||
|
||||
option cc_enable_arenas = true;
|
||||
option go_package = "google.golang.org/genproto/googleapis/api/httpbody;httpbody";
|
||||
option java_multiple_files = true;
|
||||
option cc_enable_arenas = true;
|
||||
option go_package = "google.golang.org/genproto/googleapis/api/httpbody;httpbody";
|
||||
option java_multiple_files = true;
|
||||
option java_outer_classname = "HttpBodyProto";
|
||||
option java_package = "com.google.api";
|
||||
option objc_class_prefix = "GAPI";
|
||||
option java_package = "com.google.api";
|
||||
option objc_class_prefix = "GAPI";
|
||||
|
||||
// Message that represents an arbitrary HTTP body. It should only be used for
|
||||
// payload formats that can't be represented as JSON, such as raw binary or
|
||||
|
10
third_party/proto/google/protobuf/any.proto
vendored
10
third_party/proto/google/protobuf/any.proto
vendored
@ -34,12 +34,12 @@ package google.protobuf;
|
||||
|
||||
import "gogoproto/gogo.proto";
|
||||
|
||||
option csharp_namespace = "Google.Protobuf.WellKnownTypes";
|
||||
option go_package = "types";
|
||||
option java_package = "com.google.protobuf";
|
||||
option csharp_namespace = "Google.Protobuf.WellKnownTypes";
|
||||
option go_package = "types";
|
||||
option java_package = "com.google.protobuf";
|
||||
option java_outer_classname = "AnyProto";
|
||||
option java_multiple_files = true;
|
||||
option objc_class_prefix = "GPB";
|
||||
option java_multiple_files = true;
|
||||
option objc_class_prefix = "GPB";
|
||||
|
||||
// `Any` contains an arbitrary serialized protocol buffer message along with a
|
||||
// URL that describes the type of the serialized message.
|
||||
|
159
third_party/proto/google/protobuf/descriptor.proto
vendored
159
third_party/proto/google/protobuf/descriptor.proto
vendored
@ -40,12 +40,12 @@ syntax = "proto2";
|
||||
|
||||
package google.protobuf;
|
||||
|
||||
option go_package = "google.golang.org/protobuf/types/descriptorpb";
|
||||
option java_package = "com.google.protobuf";
|
||||
option go_package = "google.golang.org/protobuf/types/descriptorpb";
|
||||
option java_package = "com.google.protobuf";
|
||||
option java_outer_classname = "DescriptorProtos";
|
||||
option csharp_namespace = "Google.Protobuf.Reflection";
|
||||
option objc_class_prefix = "GPB";
|
||||
option cc_enable_arenas = true;
|
||||
option csharp_namespace = "Google.Protobuf.Reflection";
|
||||
option objc_class_prefix = "GPB";
|
||||
option cc_enable_arenas = true;
|
||||
|
||||
// descriptor.proto must be optimized for speed because reflection-based
|
||||
// algorithms don't work during bootstrapping.
|
||||
@ -53,11 +53,13 @@ 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 {
|
||||
optional string name = 1; // file name, relative to root of source tree
|
||||
optional string name = 1; // file name, relative to root of source tree
|
||||
optional string package = 2; // e.g. "foo", "foo.bar", etc.
|
||||
|
||||
// Names of files imported by this file.
|
||||
@ -69,10 +71,10 @@ message FileDescriptorProto {
|
||||
repeated int32 weak_dependency = 11;
|
||||
|
||||
// All top-level definitions in this file.
|
||||
repeated DescriptorProto message_type = 4;
|
||||
repeated EnumDescriptorProto enum_type = 5;
|
||||
repeated ServiceDescriptorProto service = 6;
|
||||
repeated FieldDescriptorProto extension = 7;
|
||||
repeated DescriptorProto message_type = 4;
|
||||
repeated EnumDescriptorProto enum_type = 5;
|
||||
repeated ServiceDescriptorProto service = 6;
|
||||
repeated FieldDescriptorProto extension = 7;
|
||||
|
||||
optional FileOptions options = 8;
|
||||
|
||||
@ -91,15 +93,15 @@ message FileDescriptorProto {
|
||||
message DescriptorProto {
|
||||
optional string name = 1;
|
||||
|
||||
repeated FieldDescriptorProto field = 2;
|
||||
repeated FieldDescriptorProto field = 2;
|
||||
repeated FieldDescriptorProto extension = 6;
|
||||
|
||||
repeated DescriptorProto nested_type = 3;
|
||||
repeated EnumDescriptorProto enum_type = 4;
|
||||
repeated DescriptorProto nested_type = 3;
|
||||
repeated EnumDescriptorProto enum_type = 4;
|
||||
|
||||
message ExtensionRange {
|
||||
optional int32 start = 1; // Inclusive.
|
||||
optional int32 end = 2; // Exclusive.
|
||||
optional int32 end = 2; // Exclusive.
|
||||
|
||||
optional ExtensionRangeOptions options = 3;
|
||||
}
|
||||
@ -114,7 +116,7 @@ message DescriptorProto {
|
||||
// not overlap.
|
||||
message ReservedRange {
|
||||
optional int32 start = 1; // Inclusive.
|
||||
optional int32 end = 2; // Exclusive.
|
||||
optional int32 end = 2; // Exclusive.
|
||||
}
|
||||
repeated ReservedRange reserved_range = 9;
|
||||
// Reserved field names, which may not be used by fields in the same message.
|
||||
@ -136,33 +138,33 @@ message FieldDescriptorProto {
|
||||
// 0 is reserved for errors.
|
||||
// Order is weird for historical reasons.
|
||||
TYPE_DOUBLE = 1;
|
||||
TYPE_FLOAT = 2;
|
||||
TYPE_FLOAT = 2;
|
||||
// Not ZigZag encoded. Negative numbers take 10 bytes. Use TYPE_SINT64 if
|
||||
// negative values are likely.
|
||||
TYPE_INT64 = 3;
|
||||
TYPE_INT64 = 3;
|
||||
TYPE_UINT64 = 4;
|
||||
// Not ZigZag encoded. Negative numbers take 10 bytes. Use TYPE_SINT32 if
|
||||
// negative values are likely.
|
||||
TYPE_INT32 = 5;
|
||||
TYPE_INT32 = 5;
|
||||
TYPE_FIXED64 = 6;
|
||||
TYPE_FIXED32 = 7;
|
||||
TYPE_BOOL = 8;
|
||||
TYPE_STRING = 9;
|
||||
TYPE_BOOL = 8;
|
||||
TYPE_STRING = 9;
|
||||
// Tag-delimited aggregate.
|
||||
// Group type is deprecated and not supported in proto3. However, Proto3
|
||||
// implementations should still be able to parse the group wire format and
|
||||
// treat group fields as unknown fields.
|
||||
TYPE_GROUP = 10;
|
||||
TYPE_GROUP = 10;
|
||||
TYPE_MESSAGE = 11; // Length-delimited aggregate.
|
||||
|
||||
// New in version 2.
|
||||
TYPE_BYTES = 12;
|
||||
TYPE_UINT32 = 13;
|
||||
TYPE_ENUM = 14;
|
||||
TYPE_BYTES = 12;
|
||||
TYPE_UINT32 = 13;
|
||||
TYPE_ENUM = 14;
|
||||
TYPE_SFIXED32 = 15;
|
||||
TYPE_SFIXED64 = 16;
|
||||
TYPE_SINT32 = 17; // Uses ZigZag encoding.
|
||||
TYPE_SINT64 = 18; // Uses ZigZag encoding.
|
||||
TYPE_SINT32 = 17; // Uses ZigZag encoding.
|
||||
TYPE_SINT64 = 18; // Uses ZigZag encoding.
|
||||
}
|
||||
|
||||
enum Label {
|
||||
@ -172,9 +174,9 @@ message FieldDescriptorProto {
|
||||
LABEL_REPEATED = 3;
|
||||
}
|
||||
|
||||
optional string name = 1;
|
||||
optional int32 number = 3;
|
||||
optional Label label = 4;
|
||||
optional string name = 1;
|
||||
optional int32 number = 3;
|
||||
optional Label label = 4;
|
||||
|
||||
// If type_name is set, this need not be set. If both this and type_name
|
||||
// are set, this must be one of TYPE_ENUM, TYPE_MESSAGE or TYPE_GROUP.
|
||||
@ -236,7 +238,7 @@ message FieldDescriptorProto {
|
||||
|
||||
// Describes a oneof.
|
||||
message OneofDescriptorProto {
|
||||
optional string name = 1;
|
||||
optional string name = 1;
|
||||
optional OneofOptions options = 2;
|
||||
}
|
||||
|
||||
@ -256,7 +258,7 @@ message EnumDescriptorProto {
|
||||
// domain.
|
||||
message EnumReservedRange {
|
||||
optional int32 start = 1; // Inclusive.
|
||||
optional int32 end = 2; // Inclusive.
|
||||
optional int32 end = 2; // Inclusive.
|
||||
}
|
||||
|
||||
// Range of reserved numeric values. Reserved numeric values may not be used
|
||||
@ -271,15 +273,15 @@ message EnumDescriptorProto {
|
||||
|
||||
// Describes a value within an enum.
|
||||
message EnumValueDescriptorProto {
|
||||
optional string name = 1;
|
||||
optional int32 number = 2;
|
||||
optional string name = 1;
|
||||
optional int32 number = 2;
|
||||
|
||||
optional EnumValueOptions options = 3;
|
||||
}
|
||||
|
||||
// Describes a service.
|
||||
message ServiceDescriptorProto {
|
||||
optional string name = 1;
|
||||
optional string name = 1;
|
||||
repeated MethodDescriptorProto method = 2;
|
||||
|
||||
optional ServiceOptions options = 3;
|
||||
@ -291,15 +293,15 @@ message MethodDescriptorProto {
|
||||
|
||||
// Input and output type names. These are resolved in the same way as
|
||||
// FieldDescriptorProto.type_name, but must refer to a message type.
|
||||
optional string input_type = 2;
|
||||
optional string input_type = 2;
|
||||
optional string output_type = 3;
|
||||
|
||||
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,16 +368,16 @@ 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 {
|
||||
SPEED = 1; // Generate complete code for parsing, serialization,
|
||||
// etc.
|
||||
CODE_SIZE = 2; // Use ReflectionOps to implement these methods.
|
||||
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,18 +685,17 @@ 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
|
||||
// methods, and PUT verb for idempotent methods instead of the default POST.
|
||||
enum IdempotencyLevel {
|
||||
IDEMPOTENCY_UNKNOWN = 0;
|
||||
NO_SIDE_EFFECTS = 1; // implies idempotent
|
||||
IDEMPOTENT = 2; // idempotent, but may have side effects
|
||||
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;
|
||||
@ -716,19 +717,19 @@ message UninterpretedOption {
|
||||
// E.g.,{ ["foo", false], ["bar.baz", true], ["qux", false] } represents
|
||||
// "foo.(bar.baz).qux".
|
||||
message NamePart {
|
||||
required string name_part = 1;
|
||||
required bool is_extension = 2;
|
||||
required string name_part = 1;
|
||||
required bool is_extension = 2;
|
||||
}
|
||||
repeated NamePart name = 2;
|
||||
|
||||
// The value of the uninterpreted option, in whatever type the tokenizer
|
||||
// identified it as during parsing. Exactly one of these should be set.
|
||||
optional string identifier_value = 3;
|
||||
optional string identifier_value = 3;
|
||||
optional uint64 positive_int_value = 4;
|
||||
optional int64 negative_int_value = 5;
|
||||
optional double double_value = 6;
|
||||
optional bytes string_value = 7;
|
||||
optional string aggregate_value = 8;
|
||||
optional int64 negative_int_value = 5;
|
||||
optional double double_value = 6;
|
||||
optional bytes string_value = 7;
|
||||
optional string aggregate_value = 8;
|
||||
}
|
||||
|
||||
// ===================================================================
|
||||
@ -781,7 +782,7 @@ message SourceCodeInfo {
|
||||
// ignore those that it doesn't understand, as more types of locations could
|
||||
// be recorded in the future.
|
||||
repeated Location location = 1;
|
||||
message Location {
|
||||
message Location {
|
||||
// Identifies which part of the FileDescriptorProto was defined at this
|
||||
// location.
|
||||
//
|
||||
@ -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
|
||||
@ -861,8 +862,8 @@ message SourceCodeInfo {
|
||||
// optional int32 grault = 6;
|
||||
//
|
||||
// // ignored detached comments.
|
||||
optional string leading_comments = 3;
|
||||
optional string trailing_comments = 4;
|
||||
optional string leading_comments = 3;
|
||||
optional string trailing_comments = 4;
|
||||
repeated string leading_detached_comments = 6;
|
||||
}
|
||||
}
|
||||
@ -874,10 +875,10 @@ message GeneratedCodeInfo {
|
||||
// An Annotation connects some span of text in generated code to an element
|
||||
// of its generating .proto file.
|
||||
repeated Annotation annotation = 1;
|
||||
message Annotation {
|
||||
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;
|
||||
|
107
third_party/proto/tendermint/abci/types.proto
vendored
107
third_party/proto/tendermint/abci/types.proto
vendored
@ -58,13 +58,12 @@ message RequestSetOption {
|
||||
}
|
||||
|
||||
message RequestInitChain {
|
||||
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];
|
||||
bytes app_state_bytes = 5;
|
||||
int64 initial_height = 6;
|
||||
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];
|
||||
bytes app_state_bytes = 5;
|
||||
int64 initial_height = 6;
|
||||
}
|
||||
|
||||
message RequestQuery {
|
||||
@ -102,13 +101,12 @@ message RequestEndBlock {
|
||||
message RequestCommit {}
|
||||
|
||||
// lists available snapshots
|
||||
message RequestListSnapshots {
|
||||
}
|
||||
message RequestListSnapshots {}
|
||||
|
||||
// offers a snapshot to the application
|
||||
message RequestOfferSnapshot {
|
||||
Snapshot snapshot = 1; // snapshot offered by peers
|
||||
bytes app_hash = 2; // light client-verified app hash for snapshot height
|
||||
Snapshot snapshot = 1; // snapshot offered by peers
|
||||
bytes app_hash = 2; // light client-verified app hash for snapshot height
|
||||
}
|
||||
|
||||
// loads a snapshot chunk
|
||||
@ -187,8 +185,8 @@ message ResponseInitChain {
|
||||
message ResponseQuery {
|
||||
uint32 code = 1;
|
||||
// bytes data = 2; // use "value" instead.
|
||||
string log = 3; // nondeterministic
|
||||
string info = 4; // nondeterministic
|
||||
string log = 3; // nondeterministic
|
||||
string info = 4; // nondeterministic
|
||||
int64 index = 5;
|
||||
bytes key = 6;
|
||||
bytes value = 7;
|
||||
@ -198,40 +196,35 @@ 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 {
|
||||
uint32 code = 1;
|
||||
bytes data = 2;
|
||||
string log = 3; // nondeterministic
|
||||
string info = 4; // nondeterministic
|
||||
string log = 3; // nondeterministic
|
||||
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"];
|
||||
string codespace = 8;
|
||||
repeated Event events = 7 [(gogoproto.nullable) = false, (gogoproto.jsontag) = "events,omitempty"];
|
||||
string codespace = 8;
|
||||
}
|
||||
|
||||
message ResponseDeliverTx {
|
||||
uint32 code = 1;
|
||||
bytes data = 2;
|
||||
string log = 3; // nondeterministic
|
||||
string info = 4; // nondeterministic
|
||||
string log = 3; // nondeterministic
|
||||
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"];
|
||||
string codespace = 8;
|
||||
repeated Event events = 7 [(gogoproto.nullable) = false, (gogoproto.jsontag) = "events,omitempty"];
|
||||
string codespace = 8;
|
||||
}
|
||||
|
||||
message ResponseEndBlock {
|
||||
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 ValidatorUpdate validator_updates = 1 [(gogoproto.nullable) = false];
|
||||
ConsensusParams consensus_param_updates = 2;
|
||||
repeated Event events = 3 [(gogoproto.nullable) = false, (gogoproto.jsontag) = "events,omitempty"];
|
||||
}
|
||||
|
||||
message ResponseCommit {
|
||||
@ -248,12 +241,12 @@ message ResponseOfferSnapshot {
|
||||
Result result = 1;
|
||||
|
||||
enum Result {
|
||||
UNKNOWN = 0; // Unknown result, abort all snapshot restoration
|
||||
ACCEPT = 1; // Snapshot accepted, apply chunks
|
||||
ABORT = 2; // Abort all snapshot restoration
|
||||
REJECT = 3; // Reject this specific snapshot, try others
|
||||
REJECT_FORMAT = 4; // Reject all snapshots of this format, try others
|
||||
REJECT_SENDER = 5; // Reject all snapshots from the sender(s), try others
|
||||
UNKNOWN = 0; // Unknown result, abort all snapshot restoration
|
||||
ACCEPT = 1; // Snapshot accepted, apply chunks
|
||||
ABORT = 2; // Abort all snapshot restoration
|
||||
REJECT = 3; // Reject this specific snapshot, try others
|
||||
REJECT_FORMAT = 4; // Reject all snapshots of this format, try others
|
||||
REJECT_SENDER = 5; // Reject all snapshots from the sender(s), try others
|
||||
}
|
||||
}
|
||||
|
||||
@ -263,16 +256,16 @@ message ResponseLoadSnapshotChunk {
|
||||
|
||||
message ResponseApplySnapshotChunk {
|
||||
Result result = 1;
|
||||
repeated uint32 refetch_chunks = 2; // Chunks to refetch and reapply
|
||||
repeated string reject_senders = 3; // Chunk senders to reject and ban
|
||||
repeated uint32 refetch_chunks = 2; // Chunks to refetch and reapply
|
||||
repeated string reject_senders = 3; // Chunk senders to reject and ban
|
||||
|
||||
enum Result {
|
||||
UNKNOWN = 0; // Unknown result, abort all snapshot restoration
|
||||
ACCEPT = 1; // Chunk successfully accepted
|
||||
ABORT = 2; // Abort all snapshot restoration
|
||||
RETRY = 3; // Retry chunk (combine with refetch and reject)
|
||||
RETRY_SNAPSHOT = 4; // Retry snapshot (combine with refetch and reject)
|
||||
REJECT_SNAPSHOT = 5; // Reject this snapshot, try others
|
||||
UNKNOWN = 0; // Unknown result, abort all snapshot restoration
|
||||
ACCEPT = 1; // Chunk successfully accepted
|
||||
ABORT = 2; // Abort all snapshot restoration
|
||||
RETRY = 3; // Retry chunk (combine with refetch and reject)
|
||||
RETRY_SNAPSHOT = 4; // Retry snapshot (combine with refetch and reject)
|
||||
REJECT_SNAPSHOT = 5; // Reject this snapshot, try others
|
||||
}
|
||||
}
|
||||
|
||||
@ -306,17 +299,14 @@ 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.
|
||||
message EventAttribute {
|
||||
bytes key = 1;
|
||||
bytes value = 2;
|
||||
bool index = 3; // nondeterministic
|
||||
bool index = 3; // nondeterministic
|
||||
}
|
||||
|
||||
// TxResult contains results of executing the transaction.
|
||||
@ -334,9 +324,9 @@ message TxResult {
|
||||
|
||||
// Validator
|
||||
message Validator {
|
||||
bytes address = 1; // The first 20 bytes of SHA256(public key)
|
||||
bytes address = 1; // The first 20 bytes of SHA256(public key)
|
||||
// PubKey pub_key = 2 [(gogoproto.nullable)=false];
|
||||
int64 power = 3; // The voting power
|
||||
int64 power = 3; // The voting power
|
||||
}
|
||||
|
||||
// ValidatorUpdate
|
||||
@ -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
|
||||
@ -378,11 +365,11 @@ message Evidence {
|
||||
// State Sync Types
|
||||
|
||||
message Snapshot {
|
||||
uint64 height = 1; // The height at which the snapshot was taken
|
||||
uint32 format = 2; // The application-specific snapshot format
|
||||
uint32 chunks = 3; // Number of chunks in the snapshot
|
||||
bytes hash = 4; // Arbitrary snapshot hash, equal only if identical
|
||||
bytes metadata = 5; // Arbitrary application metadata
|
||||
uint64 height = 1; // The height at which the snapshot was taken
|
||||
uint32 format = 2; // The application-specific snapshot format
|
||||
uint32 chunks = 3; // Number of chunks in the snapshot
|
||||
bytes hash = 4; // Arbitrary snapshot hash, equal only if identical
|
||||
bytes metadata = 5; // Arbitrary application metadata
|
||||
}
|
||||
|
||||
//----------------------------------------
|
||||
|
@ -17,19 +17,19 @@ message Evidence {
|
||||
|
||||
// DuplicateVoteEvidence contains evidence of a validator signed two conflicting votes.
|
||||
message DuplicateVoteEvidence {
|
||||
tendermint.types.Vote vote_a = 1;
|
||||
tendermint.types.Vote vote_b = 2;
|
||||
int64 total_voting_power = 3;
|
||||
int64 validator_power = 4;
|
||||
google.protobuf.Timestamp timestamp = 5 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true];
|
||||
tendermint.types.Vote vote_a = 1;
|
||||
tendermint.types.Vote vote_b = 2;
|
||||
int64 total_voting_power = 3;
|
||||
int64 validator_power = 4;
|
||||
google.protobuf.Timestamp timestamp = 5 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true];
|
||||
}
|
||||
|
||||
// LightClientAttackEvidence contains evidence of a set of validators attempting to mislead a light client.
|
||||
message LightClientAttackEvidence {
|
||||
tendermint.types.LightBlock conflicting_block = 1;
|
||||
int64 common_height = 2;
|
||||
tendermint.types.LightBlock conflicting_block = 1;
|
||||
int64 common_height = 2;
|
||||
repeated tendermint.types.Validator byzantine_validators = 3;
|
||||
int64 total_voting_power = 4;
|
||||
int64 total_voting_power = 4;
|
||||
google.protobuf.Timestamp timestamp = 5 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true];
|
||||
}
|
||||
|
||||
|
@ -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.
|
||||
|
48
third_party/proto/tendermint/types/types.proto
vendored
48
third_party/proto/tendermint/types/types.proto
vendored
@ -66,19 +66,19 @@ message Header {
|
||||
BlockID last_block_id = 5 [(gogoproto.nullable) = false];
|
||||
|
||||
// hashes of block data
|
||||
bytes last_commit_hash = 6; // commit from validators from the last block
|
||||
bytes data_hash = 7; // transactions
|
||||
bytes last_commit_hash = 6; // commit from validators from the last block
|
||||
bytes data_hash = 7; // transactions
|
||||
|
||||
// hashes from the app output from the prev block
|
||||
bytes validators_hash = 8; // validators for the current block
|
||||
bytes next_validators_hash = 9; // validators for the next block
|
||||
bytes consensus_hash = 10; // consensus params for current block
|
||||
bytes app_hash = 11; // state after txs from the previous block
|
||||
bytes last_results_hash = 12; // root hash of all results from the txs from the previous block
|
||||
bytes validators_hash = 8; // validators for the current block
|
||||
bytes next_validators_hash = 9; // validators for the next block
|
||||
bytes consensus_hash = 10; // consensus params for current block
|
||||
bytes app_hash = 11; // state after txs from the previous block
|
||||
bytes last_results_hash = 12; // root hash of all results from the txs from the previous block
|
||||
|
||||
// consensus info
|
||||
bytes evidence_hash = 13; // evidence included in the block
|
||||
bytes proposer_address = 14; // original proposer of the block
|
||||
bytes evidence_hash = 13; // evidence included in the block
|
||||
bytes proposer_address = 14; // original proposer of the block
|
||||
}
|
||||
|
||||
// Data contains the set of transactions included in the block
|
||||
@ -95,30 +95,27 @@ 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];
|
||||
bytes validator_address = 6;
|
||||
int32 validator_index = 7;
|
||||
bytes signature = 8;
|
||||
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;
|
||||
}
|
||||
|
||||
// Commit contains the evidence that a block was committed by a set of validators.
|
||||
message Commit {
|
||||
int64 height = 1;
|
||||
int32 round = 2;
|
||||
BlockID block_id = 3 [(gogoproto.nullable) = false, (gogoproto.customname) = "BlockID"];
|
||||
repeated CommitSig signatures = 4 [(gogoproto.nullable) = false];
|
||||
int64 height = 1;
|
||||
int32 round = 2;
|
||||
BlockID block_id = 3 [(gogoproto.nullable) = false, (gogoproto.customname) = "BlockID"];
|
||||
repeated CommitSig signatures = 4 [(gogoproto.nullable) = false];
|
||||
}
|
||||
|
||||
// CommitSig is a part of the Vote included in a Commit.
|
||||
message CommitSig {
|
||||
BlockIDFlag block_id_flag = 1;
|
||||
bytes validator_address = 2;
|
||||
google.protobuf.Timestamp timestamp = 3
|
||||
[(gogoproto.nullable) = false, (gogoproto.stdtime) = true];
|
||||
bytes signature = 4;
|
||||
google.protobuf.Timestamp timestamp = 3 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true];
|
||||
bytes signature = 4;
|
||||
}
|
||||
|
||||
message Proposal {
|
||||
@ -127,9 +124,8 @@ 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];
|
||||
bytes signature = 7;
|
||||
google.protobuf.Timestamp timestamp = 6 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true];
|
||||
bytes signature = 7;
|
||||
}
|
||||
|
||||
message SignedHeader {
|
||||
|
@ -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