forked from cerc-io/laconicd-deprecated
chore: Update linter and protogen configuration (#1478)
* add protolint yaml * Update .protolint.yml with Evmos settings * Add super-linter.yml for GH action * Copy .markdownlint.yml settings from Evmos * Sort proto imports * address protolint error in all Protobuf files * update Makefile to mirror Proto commands for Evmos * remove unnecessary go get command in protocgen.sh when using cosmos docker image * copy .clang-format from Evmos repo * apply make proto-format * Execute make proto-all after changes to config are complete * address last linter comment
This commit is contained in:
@@ -11,11 +11,13 @@ option go_package = "github.com/evmos/ethermint/crypto/ethsecp256k1";
|
||||
message PubKey {
|
||||
option (gogoproto.goproto_stringer) = false;
|
||||
|
||||
// key is the public key in byte form
|
||||
bytes key = 1;
|
||||
}
|
||||
|
||||
// PrivKey defines a type alias for an ecdsa.PrivateKey that implements
|
||||
// Tendermint's PrivateKey interface.
|
||||
message PrivKey {
|
||||
// key is the private key in byte form
|
||||
bytes key = 1;
|
||||
}
|
||||
|
||||
@@ -7,18 +7,18 @@ option go_package = "github.com/evmos/ethermint/x/evm/types";
|
||||
|
||||
// Params defines the EVM module parameters
|
||||
message Params {
|
||||
// evm denom represents the token denomination used to run the EVM state
|
||||
// evm_denom represents the token denomination used to run the EVM state
|
||||
// transitions.
|
||||
string evm_denom = 1 [(gogoproto.moretags) = "yaml:\"evm_denom\""];
|
||||
// enable create toggles state transitions that use the vm.Create function
|
||||
// enable_create toggles state transitions that use the vm.Create function
|
||||
bool enable_create = 2 [(gogoproto.moretags) = "yaml:\"enable_create\""];
|
||||
// enable call toggles state transitions that use the vm.Call function
|
||||
// enable_call toggles state transitions that use the vm.Call function
|
||||
bool enable_call = 3 [(gogoproto.moretags) = "yaml:\"enable_call\""];
|
||||
// extra eips defines the additional EIPs for the vm.Config
|
||||
// extra_eips defines the additional EIPs for the vm.Config
|
||||
repeated int64 extra_eips = 4 [(gogoproto.customname) = "ExtraEIPs", (gogoproto.moretags) = "yaml:\"extra_eips\""];
|
||||
// chain config defines the EVM chain configuration parameters
|
||||
// chain_config defines the EVM chain configuration parameters
|
||||
ChainConfig chain_config = 5 [(gogoproto.moretags) = "yaml:\"chain_config\"", (gogoproto.nullable) = false];
|
||||
// Allow unprotected transactions defines if replay-protected (i.e non EIP155
|
||||
// allow_unprotected_txs defines if replay-protected (i.e non EIP155
|
||||
// signed) transactions can be executed on the state machine.
|
||||
bool allow_unprotected_txs = 6;
|
||||
}
|
||||
@@ -26,102 +26,104 @@ message Params {
|
||||
// ChainConfig defines the Ethereum ChainConfig parameters using *sdk.Int values
|
||||
// instead of *big.Int.
|
||||
message ChainConfig {
|
||||
// Homestead switch block (nil no fork, 0 = already homestead)
|
||||
// homestead_block switch (nil no fork, 0 = already homestead)
|
||||
string homestead_block = 1 [
|
||||
(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int",
|
||||
(gogoproto.moretags) = "yaml:\"homestead_block\""
|
||||
(gogoproto.moretags) = "yaml:\"homestead_block\""
|
||||
];
|
||||
// TheDAO hard-fork switch block (nil no fork)
|
||||
// dao_fork_block corresponds to TheDAO hard-fork switch block (nil 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.moretags) = "yaml:\"dao_fork_block\""
|
||||
];
|
||||
// Whether the nodes supports or opposes the DAO hard-fork
|
||||
// dao_fork_support defines whether the nodes supports or opposes the DAO hard-fork
|
||||
bool dao_fork_support = 3
|
||||
[(gogoproto.customname) = "DAOForkSupport", (gogoproto.moretags) = "yaml:\"dao_fork_support\""];
|
||||
// EIP150 implements the Gas price changes
|
||||
// eip150_block: EIP150 implements the Gas price changes
|
||||
// (https://github.com/ethereum/EIPs/issues/150) EIP150 HF block (nil no fork)
|
||||
string eip150_block = 4 [
|
||||
(gogoproto.customname) = "EIP150Block",
|
||||
(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int",
|
||||
(gogoproto.moretags) = "yaml:\"eip150_block\""
|
||||
(gogoproto.moretags) = "yaml:\"eip150_block\""
|
||||
];
|
||||
// EIP150 HF hash (needed for header only clients as only gas pricing changed)
|
||||
// eip150_hash: 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\""];
|
||||
// EIP155Block HF block
|
||||
// eip155_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.moretags) = "yaml:\"eip155_block\""
|
||||
];
|
||||
// EIP158 HF block
|
||||
// eip158_block: 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.moretags) = "yaml:\"eip158_block\""
|
||||
];
|
||||
// Byzantium switch block (nil no fork, 0 = already on byzantium)
|
||||
// byzantium_block: Byzantium switch block (nil 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.moretags) = "yaml:\"byzantium_block\""
|
||||
];
|
||||
// Constantinople switch block (nil no fork, 0 = already activated)
|
||||
// constantinople_block: Constantinople switch block (nil no fork, 0 = already activated)
|
||||
string constantinople_block = 9 [
|
||||
(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int",
|
||||
(gogoproto.moretags) = "yaml:\"constantinople_block\""
|
||||
(gogoproto.moretags) = "yaml:\"constantinople_block\""
|
||||
];
|
||||
// Petersburg switch block (nil same as Constantinople)
|
||||
// petersburg_block: Petersburg switch block (nil same as Constantinople)
|
||||
string petersburg_block = 10 [
|
||||
(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int",
|
||||
(gogoproto.moretags) = "yaml:\"petersburg_block\""
|
||||
(gogoproto.moretags) = "yaml:\"petersburg_block\""
|
||||
];
|
||||
// Istanbul switch block (nil no fork, 0 = already on istanbul)
|
||||
// istanbul_block: Istanbul switch block (nil 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.moretags) = "yaml:\"istanbul_block\""
|
||||
];
|
||||
// Eip-2384 (bomb delay) switch block (nil no fork, 0 = already activated)
|
||||
// muir_glacier_block: Eip-2384 (bomb delay) switch block (nil 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.moretags) = "yaml:\"muir_glacier_block\""
|
||||
];
|
||||
// Berlin switch block (nil = no fork, 0 = already on berlin)
|
||||
// berlin_block: Berlin switch block (nil = no fork, 0 = already on berlin)
|
||||
string berlin_block = 13 [
|
||||
(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int",
|
||||
(gogoproto.moretags) = "yaml:\"berlin_block\""
|
||||
(gogoproto.moretags) = "yaml:\"berlin_block\""
|
||||
];
|
||||
// DEPRECATED: EWASM, YOLOV3 and Catalyst block have been deprecated
|
||||
reserved 14, 15, 16;
|
||||
reserved "yolo_v3_block", "ewasm_block", "catalyst_block";
|
||||
// London switch block (nil = no fork, 0 = already on london)
|
||||
// london_block: London switch block (nil = no fork, 0 = already on london)
|
||||
string london_block = 17 [
|
||||
(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int",
|
||||
(gogoproto.moretags) = "yaml:\"london_block\""
|
||||
(gogoproto.moretags) = "yaml:\"london_block\""
|
||||
];
|
||||
// Eip-4345 (bomb delay) switch block (nil = no fork, 0 = already activated)
|
||||
// arrow_glacier_block: Eip-4345 (bomb delay) switch block (nil = no fork, 0 = already activated)
|
||||
string arrow_glacier_block = 18 [
|
||||
(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int",
|
||||
(gogoproto.moretags) = "yaml:\"arrow_glacier_block\""
|
||||
(gogoproto.moretags) = "yaml:\"arrow_glacier_block\""
|
||||
];
|
||||
// DEPRECATED: merge fork block was deprecated: https://github.com/ethereum/go-ethereum/pull/24904
|
||||
reserved 19;
|
||||
reserved "merge_fork_block";
|
||||
// EIP-5133 (bomb delay) switch block (nil = no fork, 0 = already activated)
|
||||
// gray_glacier_block: EIP-5133 (bomb delay) switch block (nil = no fork, 0 = already activated)
|
||||
string gray_glacier_block = 20 [
|
||||
(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int",
|
||||
(gogoproto.moretags) = "yaml:\"gray_glacier_block\""
|
||||
(gogoproto.moretags) = "yaml:\"gray_glacier_block\""
|
||||
];
|
||||
// Virtual fork after The Merge to use as a network splitter
|
||||
// merge_netsplit_block: Virtual fork after The Merge to use as a network splitter
|
||||
string merge_netsplit_block = 21 [
|
||||
(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int",
|
||||
(gogoproto.moretags) = "yaml:\"merge_netsplit_block\""
|
||||
(gogoproto.moretags) = "yaml:\"merge_netsplit_block\""
|
||||
];
|
||||
}
|
||||
|
||||
// State represents a single Storage key value pair item.
|
||||
message State {
|
||||
string key = 1;
|
||||
// key is the stored key
|
||||
string key = 1;
|
||||
// value is the stored value for the given key
|
||||
string value = 2;
|
||||
}
|
||||
|
||||
@@ -129,38 +131,38 @@ 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;
|
||||
// hash of the transaction
|
||||
string hash = 1;
|
||||
// logs is an array of Logs for the given transaction hash
|
||||
repeated Log logs = 2;
|
||||
}
|
||||
|
||||
// Log represents an protobuf compatible Ethereum Log that defines a contract
|
||||
// log event. These events are generated by the LOG opcode and stored/indexed by
|
||||
// the node.
|
||||
//
|
||||
// NOTE: address, topics and data are consensus fields. The rest of the fields
|
||||
// are derived, i.e. filled in by the nodes, but not secured by consensus.
|
||||
message Log {
|
||||
// Consensus fields:
|
||||
|
||||
// address of the contract that generated the event
|
||||
string address = 1;
|
||||
// list of topics provided by the contract.
|
||||
// topics is a list of topics provided by the contract.
|
||||
repeated string topics = 2;
|
||||
// supplied by the contract, usually ABI-encoded
|
||||
// data which is supplied by the contract, usually ABI-encoded
|
||||
bytes data = 3;
|
||||
|
||||
// Derived fields. These fields are filled in by the node
|
||||
// but not secured by consensus.
|
||||
|
||||
// block in which the transaction was included
|
||||
// block_number of the block in which the transaction was included
|
||||
uint64 block_number = 4 [(gogoproto.jsontag) = "blockNumber"];
|
||||
// hash of the transaction
|
||||
// tx_hash is the transaction hash
|
||||
string tx_hash = 5 [(gogoproto.jsontag) = "transactionHash"];
|
||||
// index of the transaction in the block
|
||||
// tx_index of the transaction in the block
|
||||
uint64 tx_index = 6 [(gogoproto.jsontag) = "transactionIndex"];
|
||||
// hash of the block in which the transaction was included
|
||||
// block_hash of the block in which the transaction was included
|
||||
string block_hash = 7 [(gogoproto.jsontag) = "blockHash"];
|
||||
// index of the log in the block
|
||||
uint64 index = 8 [(gogoproto.jsontag) = "logIndex"];
|
||||
|
||||
// The Removed field is true if this log was reverted due to a chain
|
||||
// removed is true if this log was reverted due to a chain
|
||||
// reorganisation. You must pay attention to this field if you receive logs
|
||||
// through a filter query.
|
||||
bool removed = 9;
|
||||
@@ -191,9 +193,9 @@ message TxResult {
|
||||
message AccessTuple {
|
||||
option (gogoproto.goproto_getters) = false;
|
||||
|
||||
// hex formatted ethereum address
|
||||
// address is a hex formatted ethereum address
|
||||
string address = 1;
|
||||
// hex formatted hashes of the storage keys
|
||||
// storage_keys are hex formatted hashes of the storage keys
|
||||
repeated string storage_keys = 2 [(gogoproto.jsontag) = "storageKeys"];
|
||||
}
|
||||
|
||||
@@ -204,27 +206,27 @@ message TraceConfig {
|
||||
reserved 4, 7;
|
||||
reserved "disable_memory", "disable_return_data";
|
||||
|
||||
// custom javascript tracer
|
||||
// tracer is a custom javascript tracer
|
||||
string tracer = 1;
|
||||
// overrides the default timeout of 5 seconds for JavaScript-based tracing
|
||||
// timeout overrides the default timeout of 5 seconds for JavaScript-based tracing
|
||||
// calls
|
||||
string timeout = 2;
|
||||
// number of blocks the tracer is willing to go back
|
||||
// reexec defines the number of blocks the tracer is willing to go back
|
||||
uint64 reexec = 3;
|
||||
// disable stack capture
|
||||
// disable_stack switches stack capture
|
||||
bool disable_stack = 5 [(gogoproto.jsontag) = "disableStack"];
|
||||
// disable storage capture
|
||||
// disable_storage switches storage capture
|
||||
bool disable_storage = 6 [(gogoproto.jsontag) = "disableStorage"];
|
||||
// print output during capture end
|
||||
// debug can be used to print output during capture end
|
||||
bool debug = 8;
|
||||
// maximum length of output, but zero means unlimited
|
||||
// limit defines the maximum length of output, but zero means unlimited
|
||||
int32 limit = 9;
|
||||
// Chain overrides, can be used to execute a trace using future fork rules
|
||||
// overrides can be used to execute a trace using future fork rules
|
||||
ChainConfig overrides = 10;
|
||||
// enable memory capture
|
||||
// enable_memory switches memory capture
|
||||
bool enable_memory = 11 [(gogoproto.jsontag) = "enableMemory"];
|
||||
// enable return data capture
|
||||
// enable_return_data switches the capture of return data
|
||||
bool enable_return_data = 12 [(gogoproto.jsontag) = "enableReturnData"];
|
||||
// tracer config
|
||||
// tracer_json_config configures the tracer using a JSON string
|
||||
string tracer_json_config = 13 [(gogoproto.jsontag) = "tracerConfig"];
|
||||
}
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
syntax = "proto3";
|
||||
package ethermint.evm.v1;
|
||||
|
||||
import "gogoproto/gogo.proto";
|
||||
import "ethermint/evm/v1/evm.proto";
|
||||
import "gogoproto/gogo.proto";
|
||||
|
||||
option go_package = "github.com/evmos/ethermint/x/evm/types";
|
||||
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
syntax = "proto3";
|
||||
package ethermint.evm.v1;
|
||||
|
||||
import "gogoproto/gogo.proto";
|
||||
import "cosmos/base/query/v1beta1/pagination.proto";
|
||||
import "google/api/annotations.proto";
|
||||
import "ethermint/evm/v1/evm.proto";
|
||||
import "ethermint/evm/v1/tx.proto";
|
||||
import "gogoproto/gogo.proto";
|
||||
import "google/api/annotations.proto";
|
||||
import "google/protobuf/timestamp.proto";
|
||||
|
||||
option go_package = "github.com/evmos/ethermint/x/evm/types";
|
||||
@@ -78,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.
|
||||
@@ -89,7 +89,7 @@ message QueryAccountRequest {
|
||||
message QueryAccountResponse {
|
||||
// balance is the balance of the EVM denomination.
|
||||
string balance = 1;
|
||||
// code hash is the hex-formatted code bytes from the EOA.
|
||||
// code_hash is the hex-formatted code bytes from the EOA.
|
||||
string code_hash = 2;
|
||||
// nonce is the account's sequence number.
|
||||
uint64 nonce = 3;
|
||||
@@ -98,7 +98,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.
|
||||
@@ -112,14 +112,14 @@ message QueryCosmosAccountResponse {
|
||||
string cosmos_address = 1;
|
||||
// sequence is the account's sequence number.
|
||||
uint64 sequence = 2;
|
||||
// account_number is the account numbert
|
||||
// account_number is the account number
|
||||
uint64 account_number = 3;
|
||||
}
|
||||
|
||||
// QueryValidatorAccountRequest is the request type for the
|
||||
// Query/ValidatorAccount RPC method.
|
||||
message QueryValidatorAccountRequest {
|
||||
option (gogoproto.equal) = false;
|
||||
option (gogoproto.equal) = false;
|
||||
option (gogoproto.goproto_getters) = false;
|
||||
|
||||
// cons_address is the validator cons address to query the account for.
|
||||
@@ -139,7 +139,7 @@ message QueryValidatorAccountResponse {
|
||||
|
||||
// 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.
|
||||
@@ -154,10 +154,10 @@ 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.
|
||||
// address is the ethereum hex address to query the storage state for.
|
||||
string address = 1;
|
||||
|
||||
// key defines the key of the storage state
|
||||
@@ -167,13 +167,13 @@ message QueryStorageRequest {
|
||||
// QueryStorageResponse is the response type for the Query/Storage RPC
|
||||
// method.
|
||||
message QueryStorageResponse {
|
||||
// key defines the storage state value hash associated with the given key.
|
||||
// value defines the storage state value hash associated with the given key.
|
||||
string value = 1;
|
||||
}
|
||||
|
||||
// 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.
|
||||
@@ -189,7 +189,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.
|
||||
@@ -198,7 +198,7 @@ message QueryTxLogsRequest {
|
||||
cosmos.base.query.v1beta1.PageRequest pagination = 2;
|
||||
}
|
||||
|
||||
// QueryTxLogs is the response type for the Query/TxLogs RPC method.
|
||||
// QueryTxLogsResponse is the response type for the Query/TxLogs RPC method.
|
||||
message QueryTxLogsResponse {
|
||||
// logs represents the ethereum logs generated from the given transaction.
|
||||
repeated Log logs = 1;
|
||||
@@ -217,72 +217,73 @@ message QueryParamsResponse {
|
||||
|
||||
// EthCallRequest defines EthCall request
|
||||
message EthCallRequest {
|
||||
// same json format as the json rpc api.
|
||||
// args uses the same json format as the json rpc api.
|
||||
bytes args = 1;
|
||||
// the default gas cap to be used
|
||||
// gas_cap defines the default gas cap to be used
|
||||
uint64 gas_cap = 2;
|
||||
// the proposer of the requested block
|
||||
// proposer_address of the requested block in hex format
|
||||
bytes proposer_address = 3 [(gogoproto.casttype) = "github.com/cosmos/cosmos-sdk/types.ConsAddress"];
|
||||
// the eip155 chain id parsed from the requested block header
|
||||
// chain_id is the eip155 chain id parsed from the requested block header
|
||||
int64 chain_id = 4;
|
||||
}
|
||||
|
||||
// EstimateGasResponse defines EstimateGas response
|
||||
message EstimateGasResponse {
|
||||
// the estimated gas
|
||||
// gas returns the estimated gas
|
||||
uint64 gas = 1;
|
||||
}
|
||||
|
||||
// QueryTraceTxRequest defines TraceTx request
|
||||
message QueryTraceTxRequest {
|
||||
// msgEthereumTx for the requested transaction
|
||||
// msg is the MsgEthereumTx for the requested transaction
|
||||
MsgEthereumTx msg = 1;
|
||||
// tx_index is not necessary anymore
|
||||
reserved 2;
|
||||
reserved "tx_index";
|
||||
// TraceConfig holds extra parameters to trace functions.
|
||||
// trace_config holds extra parameters to trace functions.
|
||||
TraceConfig trace_config = 3;
|
||||
// the predecessor transactions included in the same block
|
||||
// predecessors is an array of transactions included in the same block
|
||||
// need to be replayed first to get correct context for tracing.
|
||||
repeated MsgEthereumTx predecessors = 4;
|
||||
// block number of requested transaction
|
||||
// block_number of requested transaction
|
||||
int64 block_number = 5;
|
||||
// block hex hash of requested transaction
|
||||
// block_hash of requested transaction
|
||||
string block_hash = 6;
|
||||
// block time of requested transaction
|
||||
// block_time of requested transaction
|
||||
google.protobuf.Timestamp block_time = 7 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true];
|
||||
// the proposer of the requested block
|
||||
// proposer_address is the proposer of the requested block
|
||||
bytes proposer_address = 8 [(gogoproto.casttype) = "github.com/cosmos/cosmos-sdk/types.ConsAddress"];
|
||||
// the eip155 chain id parsed from the requested block header
|
||||
// chain_id is the the eip155 chain id parsed from the requested block header
|
||||
int64 chain_id = 9;
|
||||
}
|
||||
|
||||
// QueryTraceTxResponse defines TraceTx response
|
||||
message QueryTraceTxResponse {
|
||||
// response serialized in bytes
|
||||
// data is the response serialized in bytes
|
||||
bytes data = 1;
|
||||
}
|
||||
|
||||
// QueryTraceBlockRequest defines TraceTx request
|
||||
message QueryTraceBlockRequest {
|
||||
// txs messages in the block
|
||||
// txs is an array of messages in the block
|
||||
repeated MsgEthereumTx txs = 1;
|
||||
// TraceConfig holds extra parameters to trace functions.
|
||||
// trace_config holds extra parameters to trace functions.
|
||||
TraceConfig trace_config = 3;
|
||||
// block number
|
||||
// block_number of the traced block
|
||||
int64 block_number = 5;
|
||||
// block hex hash
|
||||
// block_hash (hex) of the traced block
|
||||
string block_hash = 6;
|
||||
// block time
|
||||
// block_time of the traced block
|
||||
google.protobuf.Timestamp block_time = 7 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true];
|
||||
// the proposer of the requested block
|
||||
// proposer_address is the address of the requested block
|
||||
bytes proposer_address = 8 [(gogoproto.casttype) = "github.com/cosmos/cosmos-sdk/types.ConsAddress"];
|
||||
// the eip155 chain id parsed from the requested block header
|
||||
// chain_id is the eip155 chain id parsed from the requested block header
|
||||
int64 chain_id = 9;
|
||||
}
|
||||
|
||||
// QueryTraceBlockResponse defines TraceBlock response
|
||||
message QueryTraceBlockResponse {
|
||||
// data is the response serialized in bytes
|
||||
bytes data = 1;
|
||||
}
|
||||
|
||||
@@ -290,7 +291,8 @@ message QueryTraceBlockResponse {
|
||||
// fee.
|
||||
message QueryBaseFeeRequest {}
|
||||
|
||||
// BaseFeeResponse returns the EIP1559 base fee.
|
||||
// QueryBaseFeeResponse returns the EIP1559 base fee.
|
||||
message QueryBaseFeeResponse {
|
||||
// base_fee is the EIP1559 base fee
|
||||
string base_fee = 1 [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int"];
|
||||
}
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
syntax = "proto3";
|
||||
package ethermint.evm.v1;
|
||||
|
||||
import "cosmos_proto/cosmos.proto";
|
||||
import "ethermint/evm/v1/evm.proto";
|
||||
import "gogoproto/gogo.proto";
|
||||
import "google/api/annotations.proto";
|
||||
import "google/protobuf/any.proto";
|
||||
import "cosmos_proto/cosmos.proto";
|
||||
import "ethermint/evm/v1/evm.proto";
|
||||
|
||||
option go_package = "github.com/evmos/ethermint/x/evm/types";
|
||||
|
||||
@@ -21,15 +21,14 @@ service Msg {
|
||||
message MsgEthereumTx {
|
||||
option (gogoproto.goproto_getters) = false;
|
||||
|
||||
// inner transaction data
|
||||
// data is inner transaction data of the Ethereum transaction
|
||||
google.protobuf.Any data = 1;
|
||||
// caches
|
||||
|
||||
// DEPRECATED: encoded storage size of the transaction
|
||||
// size is the encoded storage size of the transaction (DEPRECATED)
|
||||
double size = 2 [(gogoproto.jsontag) = "-"];
|
||||
// transaction hash in hex format
|
||||
// hash of the transaction in hex format
|
||||
string hash = 3 [(gogoproto.moretags) = "rlp:\"-\""];
|
||||
// ethereum signer address in hex format. This address value is checked
|
||||
// from is the ethereum signer address in hex format. This address value is checked
|
||||
// against the address derived from the signature (V, R, S) using the
|
||||
// secp256k1 elliptic curve
|
||||
string from = 4;
|
||||
@@ -39,21 +38,21 @@ message MsgEthereumTx {
|
||||
// NOTE: All non-protected transactions (i.e non EIP155 signed) will fail if the
|
||||
// AllowUnprotectedTxs parameter is disabled.
|
||||
message LegacyTx {
|
||||
option (gogoproto.goproto_getters) = false;
|
||||
option (gogoproto.goproto_getters) = false;
|
||||
option (cosmos_proto.implements_interface) = "TxData";
|
||||
|
||||
// nonce corresponds to the account nonce (transaction sequence).
|
||||
uint64 nonce = 1;
|
||||
// gas price defines the value for each gas unit
|
||||
// gas_price defines the value for each gas unit
|
||||
string gas_price = 2 [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int"];
|
||||
// gas defines the gas limit defined for the transaction.
|
||||
uint64 gas = 3 [(gogoproto.customname) = "GasLimit"];
|
||||
// hex formatted address of the recipient
|
||||
// to is the hex formatted address of the recipient
|
||||
string to = 4;
|
||||
// value defines the unsigned integer value of the transaction amount.
|
||||
string value = 5
|
||||
[(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", (gogoproto.customname) = "Amount"];
|
||||
// input defines the data payload bytes of the transaction.
|
||||
// data is the data payload bytes of the transaction.
|
||||
bytes data = 6;
|
||||
// v defines the signature value
|
||||
bytes v = 7;
|
||||
@@ -65,28 +64,29 @@ message LegacyTx {
|
||||
|
||||
// AccessListTx is the data of EIP-2930 access list transactions.
|
||||
message AccessListTx {
|
||||
option (gogoproto.goproto_getters) = false;
|
||||
option (gogoproto.goproto_getters) = false;
|
||||
option (cosmos_proto.implements_interface) = "TxData";
|
||||
|
||||
// destination EVM chain ID
|
||||
// chain_id of the destination EVM chain
|
||||
string chain_id = 1 [
|
||||
(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int",
|
||||
(gogoproto.customname) = "ChainID",
|
||||
(gogoproto.jsontag) = "chainID"
|
||||
(gogoproto.jsontag) = "chainID"
|
||||
];
|
||||
// nonce corresponds to the account nonce (transaction sequence).
|
||||
uint64 nonce = 2;
|
||||
// gas price defines the value for each gas unit
|
||||
// gas_price defines the value for each gas unit
|
||||
string gas_price = 3 [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int"];
|
||||
// gas defines the gas limit defined for the transaction.
|
||||
uint64 gas = 4 [(gogoproto.customname) = "GasLimit"];
|
||||
// hex formatted address of the recipient
|
||||
// to is the recipient address in hex format
|
||||
string to = 5;
|
||||
// value defines the unsigned integer value of the transaction amount.
|
||||
string value = 6
|
||||
[(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", (gogoproto.customname) = "Amount"];
|
||||
// input defines the data payload bytes of the transaction.
|
||||
bytes data = 7;
|
||||
// data is the data payload bytes of the transaction.
|
||||
bytes data = 7;
|
||||
// accesses is an array of access tuples
|
||||
repeated AccessTuple accesses = 8
|
||||
[(gogoproto.castrepeated) = "AccessList", (gogoproto.jsontag) = "accessList", (gogoproto.nullable) = false];
|
||||
// v defines the signature value
|
||||
@@ -99,30 +99,31 @@ message AccessListTx {
|
||||
|
||||
// DynamicFeeTx is the data of EIP-1559 dinamic fee transactions.
|
||||
message DynamicFeeTx {
|
||||
option (gogoproto.goproto_getters) = false;
|
||||
option (gogoproto.goproto_getters) = false;
|
||||
option (cosmos_proto.implements_interface) = "TxData";
|
||||
|
||||
// destination EVM chain ID
|
||||
// chain_id of the destination EVM chain
|
||||
string chain_id = 1 [
|
||||
(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int",
|
||||
(gogoproto.customname) = "ChainID",
|
||||
(gogoproto.jsontag) = "chainID"
|
||||
(gogoproto.jsontag) = "chainID"
|
||||
];
|
||||
// nonce corresponds to the account nonce (transaction sequence).
|
||||
uint64 nonce = 2;
|
||||
// gas tip cap defines the max value for the gas tip
|
||||
// gas_tip_cap defines the max value for the gas tip
|
||||
string gas_tip_cap = 3 [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int"];
|
||||
// gas fee cap defines the max value for the gas fee
|
||||
// gas_fee_cap defines the max value for the gas fee
|
||||
string gas_fee_cap = 4 [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int"];
|
||||
// gas defines the gas limit defined for the transaction.
|
||||
uint64 gas = 5 [(gogoproto.customname) = "GasLimit"];
|
||||
// hex formatted address of the recipient
|
||||
// to is the hex formatted address of the recipient
|
||||
string to = 6;
|
||||
// value defines the the transaction amount.
|
||||
string value = 7
|
||||
[(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", (gogoproto.customname) = "Amount"];
|
||||
// input defines the data payload bytes of the transaction.
|
||||
bytes data = 8;
|
||||
// data is the data payload bytes of the transaction.
|
||||
bytes data = 8;
|
||||
// accesses is an array of access tuples
|
||||
repeated AccessTuple accesses = 9
|
||||
[(gogoproto.castrepeated) = "AccessList", (gogoproto.jsontag) = "accessList", (gogoproto.nullable) = false];
|
||||
// v defines the signature value
|
||||
@@ -133,6 +134,7 @@ message DynamicFeeTx {
|
||||
bytes s = 12;
|
||||
}
|
||||
|
||||
// ExtensionOptionsEthereumTx is an extension option for ethereum transactions
|
||||
message ExtensionOptionsEthereumTx {
|
||||
option (gogoproto.goproto_getters) = false;
|
||||
}
|
||||
@@ -141,18 +143,18 @@ message ExtensionOptionsEthereumTx {
|
||||
message MsgEthereumTxResponse {
|
||||
option (gogoproto.goproto_getters) = false;
|
||||
|
||||
// ethereum transaction hash in hex format. This hash differs from the
|
||||
// hash of the ethereum transaction in hex format. This hash differs from the
|
||||
// Tendermint sha256 hash of the transaction bytes. See
|
||||
// https://github.com/tendermint/tendermint/issues/6539 for reference
|
||||
string hash = 1;
|
||||
// logs contains the transaction hash and the proto-compatible ethereum
|
||||
// logs.
|
||||
repeated Log logs = 2;
|
||||
// returned data from evm function (result or data supplied with revert
|
||||
// ret is the returned data from evm function (result or data supplied with revert
|
||||
// opcode)
|
||||
bytes ret = 3;
|
||||
// vm error is the error returned by vm execution
|
||||
// vm_error is the error returned by vm execution
|
||||
string vm_error = 4;
|
||||
// gas consumed by the transaction
|
||||
// gas_used specifies how much gas was consumed by the transaction
|
||||
uint64 gas_used = 5;
|
||||
}
|
||||
|
||||
@@ -7,26 +7,26 @@ option go_package = "github.com/evmos/ethermint/x/feemarket/types";
|
||||
|
||||
// Params defines the EVM module parameters
|
||||
message Params {
|
||||
// no base fee forces the EIP-1559 base fee to 0 (needed for 0 price calls)
|
||||
// no_base_fee forces the EIP-1559 base fee to 0 (needed for 0 price calls)
|
||||
bool no_base_fee = 1;
|
||||
// base fee change denominator bounds the amount the base fee can change
|
||||
// base_fee_change_denominator bounds the amount the base fee can change
|
||||
// between blocks.
|
||||
uint32 base_fee_change_denominator = 2;
|
||||
// elasticity multiplier bounds the maximum gas limit an EIP-1559 block may
|
||||
// elasticity_multiplier bounds the maximum gas limit an EIP-1559 block may
|
||||
// have.
|
||||
uint32 elasticity_multiplier = 3;
|
||||
// DEPRECATED: initial base fee for EIP-1559 blocks.
|
||||
reserved 4;
|
||||
reserved "initial_base_fee";
|
||||
// height at which the base fee calculation is enabled.
|
||||
// enable_height defines at which block height the base fee calculation is enabled.
|
||||
int64 enable_height = 5;
|
||||
// base fee for EIP-1559 blocks.
|
||||
// base_fee for EIP-1559 blocks.
|
||||
string base_fee = 6 [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", (gogoproto.nullable) = false];
|
||||
// min_gas_price defines the minimum gas price value for cosmos and eth transactions
|
||||
string min_gas_price = 7
|
||||
[(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", (gogoproto.nullable) = false];
|
||||
// min gas denominator bounds the minimum gasUsed to be charged
|
||||
// to senders based on GasLimit
|
||||
// min_gas_multiplier bounds the minimum gas used to be charged
|
||||
// to senders based on gas limit
|
||||
string min_gas_multiplier = 8
|
||||
[(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", (gogoproto.nullable) = false];
|
||||
}
|
||||
|
||||
@@ -1,20 +1,20 @@
|
||||
syntax = "proto3";
|
||||
package ethermint.feemarket.v1;
|
||||
|
||||
import "gogoproto/gogo.proto";
|
||||
import "ethermint/feemarket/v1/feemarket.proto";
|
||||
import "gogoproto/gogo.proto";
|
||||
|
||||
option go_package = "github.com/evmos/ethermint/x/feemarket/types";
|
||||
|
||||
// GenesisState defines the feemarket module's genesis state.
|
||||
message GenesisState {
|
||||
// params defines all the paramaters of the module.
|
||||
// params defines all the parameters of the feemarket module.
|
||||
Params params = 1 [(gogoproto.nullable) = false];
|
||||
// DEPRECATED: base fee is the exported value from previous software version.
|
||||
// Zero by default.
|
||||
reserved 2;
|
||||
reserved "base_fee";
|
||||
// block gas is the amount of gas wanted on the last block before the upgrade.
|
||||
// block_gas is the amount of gas wanted on the last block before the upgrade.
|
||||
// Zero by default.
|
||||
uint64 block_gas = 3;
|
||||
}
|
||||
@@ -3,8 +3,8 @@ package ethermint.feemarket.v1;
|
||||
|
||||
import "gogoproto/gogo.proto";
|
||||
// import "cosmos/base/query/v1beta1/pagination.proto";
|
||||
import "google/api/annotations.proto";
|
||||
import "ethermint/feemarket/v1/feemarket.proto";
|
||||
import "google/api/annotations.proto";
|
||||
|
||||
option go_package = "github.com/evmos/ethermint/x/feemarket/types";
|
||||
|
||||
@@ -39,8 +39,9 @@ message QueryParamsResponse {
|
||||
// fee.
|
||||
message QueryBaseFeeRequest {}
|
||||
|
||||
// BaseFeeResponse returns the EIP1559 base fee.
|
||||
// QueryBaseFeeResponse returns the EIP1559 base fee.
|
||||
message QueryBaseFeeResponse {
|
||||
// base_fee is the EIP1559 base fee
|
||||
string base_fee = 1 [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int"];
|
||||
}
|
||||
|
||||
@@ -50,5 +51,6 @@ message QueryBlockGasRequest {}
|
||||
|
||||
// QueryBlockGasResponse returns block gas used for a given height.
|
||||
message QueryBlockGasResponse {
|
||||
// gas is the returned block gas
|
||||
int64 gas = 1;
|
||||
}
|
||||
@@ -10,13 +10,16 @@ option go_package = "github.com/evmos/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";
|
||||
|
||||
// base_account is an authtypes.BaseAccount
|
||||
cosmos.auth.v1beta1.BaseAccount base_account = 1
|
||||
[(gogoproto.embed) = true, (gogoproto.moretags) = "yaml:\"base_account\""];
|
||||
|
||||
// code_hash is the hash calculated from the code contents
|
||||
string code_hash = 2 [(gogoproto.moretags) = "yaml:\"code_hash\""];
|
||||
}
|
||||
|
||||
@@ -5,9 +5,9 @@ import "gogoproto/gogo.proto";
|
||||
|
||||
option go_package = "github.com/evmos/ethermint/types";
|
||||
|
||||
// ExtensionOptionDynamicFeeTx is an extension option that specify the maxPrioPrice for cosmos tx
|
||||
// ExtensionOptionDynamicFeeTx is an extension option that specifies the maxPrioPrice for cosmos tx
|
||||
message ExtensionOptionDynamicFeeTx {
|
||||
// the same as `max_priority_fee_per_gas` in eip-1559 spec
|
||||
// max_priority_price is the same as `max_priority_fee_per_gas` in eip-1559 spec
|
||||
string max_priority_price = 1
|
||||
[(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", (gogoproto.nullable) = false];
|
||||
}
|
||||
|
||||
@@ -9,21 +9,22 @@ option go_package = "github.com/evmos/ethermint/types";
|
||||
message TxResult {
|
||||
option (gogoproto.goproto_getters) = false;
|
||||
|
||||
// the block height
|
||||
// height of the blockchain
|
||||
int64 height = 1;
|
||||
// cosmos tx index
|
||||
// tx_index of the cosmos transaction
|
||||
uint32 tx_index = 2;
|
||||
// the msg index in a batch tx
|
||||
// msg_index in a batch transaction
|
||||
uint32 msg_index = 3;
|
||||
|
||||
// eth tx index, the index in the list of valid eth tx in the block,
|
||||
// eth_tx_index is the index in the list of valid eth tx in the block,
|
||||
// aka. the transaction list returned by eth_getBlock api.
|
||||
int32 eth_tx_index = 4;
|
||||
// if the eth tx is failed
|
||||
// failed is true if the eth transaction did not go succeed
|
||||
bool failed = 5;
|
||||
// gas used by tx, if exceeds block gas limit,
|
||||
// it's set to gas limit which is what's actually deducted by ante handler.
|
||||
// gas_used by the transaction. If it exceeds the block gas limit,
|
||||
// it's set to gas limit, which is what's actually deducted by ante handler.
|
||||
uint64 gas_used = 6;
|
||||
// the cumulative gas used within current batch tx
|
||||
// cumulative_gas_used specifies the cumulated amount of gas used for all
|
||||
// processed messages within the current batch transaction.
|
||||
uint64 cumulative_gas_used = 7;
|
||||
}
|
||||
|
||||
@@ -5,19 +5,21 @@ import "gogoproto/gogo.proto";
|
||||
|
||||
option go_package = "github.com/evmos/ethermint/types";
|
||||
|
||||
// ExtensionOptionsWeb3Tx is an extension option that specifies the typed chain id,
|
||||
// the fee payer as well as its signature data.
|
||||
message ExtensionOptionsWeb3Tx {
|
||||
option (gogoproto.goproto_getters) = false;
|
||||
|
||||
// typed data chain id used only in EIP712 Domain and should match
|
||||
// typed_data_chain_id is used only in EIP712 Domain and should match
|
||||
// Ethereum network ID in a Web3 provider (e.g. Metamask).
|
||||
uint64 typed_data_chain_id = 1
|
||||
[(gogoproto.jsontag) = "typedDataChainID,omitempty", (gogoproto.customname) = "TypedDataChainID"];
|
||||
|
||||
// fee payer is an account address for the fee payer. It will be validated
|
||||
// fee_payer is an account address for the fee payer. It will be validated
|
||||
// during EIP712 signature checking.
|
||||
string fee_payer = 2 [(gogoproto.jsontag) = "feePayer,omitempty"];
|
||||
|
||||
// fee payer sig is a signature data from the fee paying account,
|
||||
// fee_payer_sig is a signature data from the fee paying account,
|
||||
// allows to perform fee delegation when using EIP712 Domain.
|
||||
bytes fee_payer_sig = 3 [(gogoproto.jsontag) = "feePayerSig,omitempty"];
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user