package
0.0.2
Repository: https://github.com/aizelnetwork/cosmevm.git
Documentation: pkg.go.dev

# Functions

AddressStoragePrefix returns a prefix to iterate over a given account storage.
AdjustExtraDecimalsBigInt replaces all extra decimals by zero of an amount with 18 decimals in big.Int when having a decimal configuration different than 18 decimals.
BinSearch executes the binary search and hone in on an executable gas limit.
ConvertAmountFrom18DecimalsBigInt convert the given amount into a 18 decimals representation.
ConvertAmountTo18DecimalsBigInt convert the given amount into a 18 decimals representation.
ConvertAmountToLegacy18Decimals convert the given amount into a 18 decimals representation.
ConvertBigIntFrom18DecimalsToLegacyDec converts the given amount into a LegacyDec with the corresponding decimals of the EVM denom.
ConvertCoinsFrom18Decimals returns the given coins with the Amount of the evm coin converted from the 18 decimals representation to the original one.
ConvertEvmCoinFrom18Decimals converts the coin's Amount from 18 decimals to its original representation.
DecodeTransactionLogs decodes an protobuf-encoded byte slice into TransactionLogs.
DecodeTxResponse decodes an protobuf-encoded byte slice into TxResponse.
No description provided by the author
DefaultGenesisState sets default evm genesis state with empty accounts and default params and chain config values.
DefaultParams returns default evm parameters.
EffectiveGasPrice computes the effective gas price based on eip-1559 rules `effectiveGasPrice = min(baseFee + tipCap, feeCap)`.
EncodeTransactionLogs encodes TransactionLogs slice into a protobuf-encoded byte slice.
GetChainConfig returns the `chainConfig`.
GetEthChainConfig returns the `chainConfig` used in the EVM (geth type).
GetEVMCoinDecimals returns the decimals used in the representation of the EVM coin.
GetEVMCoinDenom returns the denom used for the EVM coin.
GetTxPriority returns the priority of a given Ethereum tx.
No description provided by the author
IsEmptyCodeHash checks if the given byte slice represents an empty code hash.
IsLondon returns if london hardfork is enabled.
LogsToEthereum casts the Ethermint Logs to a slice of Ethereum Logs.
MustConvertEvmCoinTo18Decimals converts the coin's Amount from its original representation into a 18 decimals.
NewAccessList creates a new protobuf-compatible AccessList from an ethereum core AccessList type.
NewDefaultOpCodesHooks creates a new DefaultOpCodesHooks instance.
No description provided by the author
NewEVMConfigurator returns a pointer to a new EVMConfigurator object.
NewExecErrorWithReason unpacks the revert return bytes and returns a wrapped error with the return reason.
NewGenesisState creates a new genesis state.
No description provided by the author
NewLogFromEth creates a new Log instance from a Ethereum type Log.
No description provided by the author
No description provided by the author
NewNoOpTracer creates a no-op vm.Tracer.
NewParams creates a new Params instance.
No description provided by the author
No description provided by the author
NewState creates a new State instance.
NewTracer creates a new Logger tracer to collect execution traces from an EVM transaction.
NewTransactionLogs creates a new NewTransactionLogs instance.
NewTransactionLogsFromEth creates a new NewTransactionLogs instance using []*ethtypes.Log.
NewTx returns a reference to a new Ethereum transaction message.
NOTE: All non-protected transactions (i.e non EIP155 signed) will fail if the AllowUnprotectedTxs parameter is disabled.
PackTxData constructs a new Any packed with the given tx data value.
Deprecated: ParamKeyTable returns the parameter key table.
RegisterInterfaces registers the client interfaces to protobuf Any.
RegisterLegacyAminoCodec required for EIP-712.
RegisterMsgHandler registers the http handlers for service Msg to "mux".
RegisterMsgHandlerClient registers the http handlers for service Msg to "mux".
RegisterMsgHandlerFromEndpoint is same as RegisterMsgHandler but automatically dials to "endpoint" and closes the connection when "ctx" gets done.
RegisterMsgHandlerServer registers the http handlers for service Msg to "mux".
No description provided by the author
RegisterQueryHandler registers the http handlers for service Query to "mux".
RegisterQueryHandlerClient registers the http handlers for service Query to "mux".
RegisterQueryHandlerFromEndpoint is same as RegisterQueryHandler but automatically dials to "endpoint" and closes the connection when "ctx" gets done.
RegisterQueryHandlerServer registers the http handlers for service Query to "mux".
No description provided by the author
StateKey defines the full key under which an account state is stored.
UnpackEthMsg unpacks an Ethereum message from a Cosmos SDK message.
UnpackTxData unpacks an Any into a TxData.
UnwrapEthereumMsg extracts MsgEthereumTx from wrapping sdk.Tx.
ValidatePrecompiles checks if the precompile addresses are valid and unique.

# Constants

ACCESS_TYPE_PERMISSIONED only allows the operation for specific addresses.
ACCESS_TYPE_PERMISSIONLESS does not restrict the operation to anyone.
ACCESS_TYPE_RESTRICTED restrict the operation to anyone.
Evm module events.
Evm module events.
Evm module events.
tx failed in eth vm execution.
Evm module events.
Evm module events.
Evm module events.
Evm module events.
Evm module events.
Evm module events.
Evm module events.
Evm module events.
No description provided by the author
No description provided by the author
No description provided by the author
EighteenDecimals is the Decimals used for Cosmos coin with 18 decimals.
Evm module events.
Evm module events.
Evm module events.
Evm module events.
No description provided by the author
No description provided by the author
No description provided by the author
Internal call type is used in case of smart contract methods calls.
MaxPrecompileCalls is the maximum number of precompile calls within a transaction.
Evm module events.
Evm module events.
ModuleName string name of module.
No description provided by the author
RouterKey uses module name for routing.
RPC call type is used on requests to eth_estimateGas rpc API endpoint.
SixDecimals is the Decimals used for Cosmos coin with 6 decimals.
No description provided by the author
No description provided by the author
StoreKey key for ethereum storage data, account code (StateDB) or block related data for Web3.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
TransientKey is the key to access the EVM transient store, that is reset during the Commit phase.
TypeMsgEthereumTx defines the type string of an Ethereum transaction.
No description provided by the author

# Variables

No description provided by the author
No description provided by the author
nolint:staticcheck.
AvailableStaticPrecompiles defines the full list of all available EVM extension addresses.
ChainsCoinInfo is a map of the chain id and its corresponding EvmCoinInfo that allows initializing the app with different coin info based on the chain id.
No description provided by the author
DefaultAllowUnprotectedTxs rejects all unprotected txs (i.e false).
No description provided by the author
No description provided by the author
No description provided by the author
DefaultExtraEIPs defines the default extra EIPs to be included On v15, EIP 3855 was enabled.
DefaultPriorityReduction is the default amount of price values required for 1 unit of priority.
DefaultStaticPrecompiles defines the default active precompiles.
EmptyCodeHash is keccak256 hash of nil to represent empty code.
ErrABIPack returns an error if the contract ABI packing fails.
ErrABIUnpack returns an error if the contract ABI unpacking fails.
ErrCallDisabled returns an error if the EnableCall parameter is false.
ErrCreateDisabled returns an error if the EnableCreate parameter is false.
ErrGasOverflow returns an error if gas computation overlow/underflow.
ErrInactivePrecompile returns an error if a call is made to an inactive precompile.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
ErrInvalidAccount returns an error if the account is not an EVM compatible account.
ErrInvalidAmount returns an error if a tx contains an invalid amount.
ErrInvalidBaseFee returns an error if a the base fee cap value is invalid.
ErrInvalidChainConfig returns an error resulting from an invalid ChainConfig.
ErrInvalidGasCap returns an error if a the gas cap value is negative or invalid.
ErrInvalidGasFee returns an error if the tx gas fee is out of bound.
ErrInvalidGasLimit returns an error if gas limit value is invalid.
ErrInvalidGasPrice returns an error if an invalid gas price is provided to the tx.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
ErrInvalidRefund returns an error if a the gas refund value is invalid.
ErrInvalidState returns an error resulting from an invalid Storage State.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
ErrVMExecution returns an error resulting from an error in EVM execution.
ErrZeroAddress returns an error resulting from an zero (empty) ethereum Address.
KVStore key prefixes.
KVStore key prefixes.
KVStore key prefixes.
KVStore key prefixes.
Transient Store key prefixes.
Transient Store key prefixes.
Transient Store key prefixes.
Transient Store key prefixes.
ModuleCdc references the global evm module codec.
No description provided by the author
Parameter keys.
Parameter keys.
Parameter keys.
Parameter keys.
Parameter keys.
Parameter keys.

# Structs

AccessControl defines the permission policy of the EVM for creating and calling contracts.
AccessControlType defines the permission type for policies.
AccessListTx is the data of EIP-2930 access list transactions.
AccessTuple is the element type of an access list.
ChainConfig defines the Ethereum ChainConfig parameters using *sdk.Int values instead of *big.Int.
CompiledContract contains compiled bytecode and abi.
DefaultOpCodesHooks is the default implementation of OpCodeHooks for EVMOS chain The hooks are used to enforce access control policies on EVM operations.
DynamicFeeTx is the data of EIP-1559 dynamic fee transactions.
EstimateGasResponse defines EstimateGas response.
EthCallRequest defines EthCall request.
EventBlockBloom defines an Ethereum block bloom filter event.
EventEthereumTx defines the event for an Ethereum transaction.
EventMessage.
EventTxLog defines the event for an Ethereum transaction log.
EvmCoinInfo struct holds the name and decimals of the EVM denom.
EVMConfigurator allows to extend x/evm module configurations.
EvmTxArgs encapsulates all possible params to create all EVM txs types.
ExtensionOptionsEthereumTx is an extension option for ethereum transactions.
GenesisAccount defines an account to be initialized in the genesis state.
GenesisState defines the evm module's genesis state.
HardhatCompiledContract is a type used to unpack the compiled JSON data which is generated by running `npx hardhat compile` for a given smart contract.
LegacyTx is the transaction data of regular Ethereum transactions.
Log represents an protobuf compatible Ethereum Log that defines a contract log event.
MsgEthereumTx encapsulates an Ethereum transaction as an SDK message.
MsgEthereumTxResponse defines the Msg/EthereumTx response type.
MsgUpdateParams defines a Msg for updating the x/evm module parameters.
MsgUpdateParamsResponse defines the response structure for executing a MsgUpdateParams message.
NoOpTracer is an empty implementation of vm.Tracer interface.
Params defines the EVM module parameters.
QueryAccountRequest is the request type for the Query/Account RPC method.
QueryAccountResponse is the response type for the Query/Account RPC method.
QueryBalanceRequest is the request type for the Query/Balance RPC method.
QueryBalanceResponse is the response type for the Query/Balance RPC method.
QueryBaseFeeRequest defines the request type for querying the EIP1559 base fee.
QueryBaseFeeResponse returns the EIP1559 base fee.
QueryCodeRequest is the request type for the Query/Code RPC method.
QueryCodeResponse is the response type for the Query/Code RPC method.
QueryConfigRequest defines the request type for querying the Config.
QueryConfigResponse returns the EVM Config.
QueryCosmosAccountRequest is the request type for the Query/CosmosAccount RPC method.
QueryCosmosAccountResponse is the response type for the Query/CosmosAccount RPC method.
QueryGlobalMinGasPriceRequest defines the request type for querying the GlobalMinGasPrice.
QueryGlobalMinGasPriceResponse returns the GlobalMinGasPrice.
QueryParamsRequest defines the request type for querying x/evm parameters.
QueryParamsResponse defines the response type for querying x/evm parameters.
QueryStorageRequest is the request type for the Query/Storage RPC method.
QueryStorageResponse is the response type for the Query/Storage RPC method.
QueryTraceBlockRequest defines TraceTx request.
QueryTraceBlockResponse defines TraceBlock response.
QueryTraceTxRequest defines TraceTx request.
QueryTraceTxResponse defines TraceTx response.
QueryTxLogsRequest is the request type for the Query/TxLogs RPC method.
QueryTxLogsResponse is the response type for the Query/TxLogs RPC method.
QueryValidatorAccountRequest is the request type for the Query/ValidatorAccount RPC method.
QueryValidatorAccountResponse is the response type for the Query/ValidatorAccount RPC method.
RestrictedPermissionPolicy is a permission policy that restricts contract creation and calls based on a set of accessControl.
RevertError is an API error that encompass an EVM revert with JSON error code and a binary data blob.
State represents a single Storage key value pair item.
TraceConfig holds extra parameters to trace functions.
TransactionArgs represents the arguments to construct a new transaction or a message call using JSON-RPC.
TransactionLogs define the logs generated from a transaction execution with a given hash.
TxResult stores results of Tx execution.
TxTraceResult is the result of a single transaction trace during a block trace.
UnimplementedMsgServer can be embedded to have forward compatible implementations.
UnimplementedQueryServer can be embedded to have forward compatible implementations.

# Interfaces

AccountKeeper defines the expected account keeper interface.
BankKeeper defines the expected interface needed to retrieve account balances.
BankWrapper defines the methods required by the wrapper around the Cosmos SDK x/bank keeper that is used to manage an EVM coin with a configurable value for decimals.
Erc20Keeper defines the expected interface needed to instantiate ERC20 precompiles.
FeeMarketKeeper defines the expected interfaces needed for the feemarket.
MsgClient is the client API for Msg service.
MsgServer is the server API for Msg service.
OpCodeHooks extends the geth OpCodeHooks interface to add custom hooks for EVM operations.
PermissionPolicy is the interface that defines the permission policy for contract creation and calls.
QueryClient is the client API for Query service.
QueryServer is the server API for Query service.
StakingKeeper returns the historical headers kept in store.
No description provided by the author
TxData implements the Ethereum transaction tx structure.

# Type aliases

AccessList is an EIP-2930 access list that represents the slice of the protobuf AccessTuples.
AccessType defines the types of permissions for the operations.
No description provided by the author
No description provided by the author
No description provided by the author
Decimals represents the decimal representation of a Cosmos coin.
HexString is a byte array that serializes to hex.
No description provided by the author
Storage represents the account Storage map as a slice of single key value State pairs.