Skip to main content

Module config

Module config 

Source

Re-exportsΒ§

use crate::FeeManager; πŸ”’
use crate::PrecompileFactory; πŸ”’
use crate::eth::backend::db::Db; πŸ”’
use crate::eth::backend::db::SerializableState; πŸ”’
use crate::eth::backend::fork::ClientFork; πŸ”’
use crate::eth::backend::fork::ClientForkConfig; πŸ”’
use crate::eth::backend::fork::ForkEndpointIdentity; πŸ”’
use crate::eth::backend::fork::ensure_fork_network_supported; πŸ”’
use crate::eth::backend::genesis::GenesisConfig; πŸ”’
use crate::eth::backend::mem::fork_db::ForkedDatabase; πŸ”’
use crate::eth::backend::tempo_consensus::TempoConsensus; πŸ”’
use crate::eth::backend::time::duration_since_unix_epoch; πŸ”’
use crate::eth::fees::INITIAL_BASE_FEE; πŸ”’
use crate::eth::fees::INITIAL_GAS_PRICE; πŸ”’
use crate::eth::miner::INSTANT_COALESCE_WINDOW; πŸ”’
use crate::eth::pool::transactions::TransactionOrder; πŸ”’
use crate::mem; πŸ”’
use crate::mem::in_memory_db::StateRootDb; πŸ”’
use alloy_chains::Chain; πŸ”’
use alloy_consensus::BlockHeader; πŸ”’
use alloy_eips::BlockId; πŸ”’
use alloy_eips::eip1559::BaseFeeParams; πŸ”’
use alloy_eips::eip7840::BlobParams; πŸ”’
use alloy_evm::EvmEnv; πŸ”’
use alloy_genesis::Genesis; πŸ”’
use alloy_network::AnyNetwork; πŸ”’
use alloy_network::AnyRpcBlock; πŸ”’
use alloy_network::BlockResponse; πŸ”’
use alloy_network::TransactionResponse; πŸ”’
use alloy_primitives::Address; πŸ”’
use alloy_primitives::B256; πŸ”’
use alloy_primitives::BlockNumber; πŸ”’
use alloy_primitives::TxHash; πŸ”’
use alloy_primitives::U256; πŸ”’
use alloy_primitives::hex; πŸ”’
use alloy_primitives::hex; πŸ”’
use alloy_primitives::keccak256; πŸ”’
use alloy_primitives::map::HashMap; πŸ”’
use alloy_primitives::utils::Unit; πŸ”’
use alloy_provider::Provider; πŸ”’
use alloy_rpc_types::anvil::Metadata; πŸ”’
use alloy_rpc_types::anvil::NodeInfo; πŸ”’
use alloy_signer::Signer; πŸ”’
use alloy_signer_local::MnemonicBuilder; πŸ”’
use alloy_signer_local::PrivateKeySigner; πŸ”’
use alloy_signer_local::coins_bip39::English; πŸ”’
use alloy_signer_local::coins_bip39::Mnemonic; πŸ”’
use alloy_transport::TransportError; πŸ”’
use anvil_core::types::NodeBlobParams; πŸ”’
use anvil_server::ServerConfig; πŸ”’
use eyre::Context; πŸ”’
use eyre::Result; πŸ”’
use foundry_common::ALCHEMY_FREE_TIER_CUPS; πŸ”’
use foundry_common::NON_ARCHIVE_NODE_WARNING; πŸ”’
use foundry_common::REQUEST_TIMEOUT; πŸ”’
use foundry_common::provider::ProviderBuilder; πŸ”’
use foundry_common::provider::RetryProvider; πŸ”’
use foundry_common::provider::is_rpc_method_not_found; πŸ”’
use foundry_common::provider::redact_url; πŸ”’
use foundry_config::Config; πŸ”’
use foundry_evm::backend::BlockchainDb; πŸ”’
use foundry_evm::backend::BlockchainDbMeta; πŸ”’
use foundry_evm::backend::ForkBlock; πŸ”’
use foundry_evm::backend::SharedBackend; πŸ”’
use foundry_evm::backend::account_fetch_policy_for_source; πŸ”’
use foundry_evm::constants::DEFAULT_CREATE2_DEPLOYER; πŸ”’
use foundry_evm::hardfork::FoundryHardfork; πŸ”’
use foundry_evm::traces::CallTraceDecoderBuilder; πŸ”’
use foundry_evm::traces::identifier::SignaturesIdentifier; πŸ”’
use foundry_evm::utils::apply_chain_and_block_specific_env_changes_for_chain; πŸ”’
use foundry_evm::utils::block_env_from_header; πŸ”’
use foundry_evm::utils::get_blob_params_by_hardfork; πŸ”’
use foundry_evm_networks::NetworkConfigs; πŸ”’
use foundry_evm_networks::NetworkVariant; πŸ”’
use parking_lot::RwLock; πŸ”’
use rand_08::thread_rng; πŸ”’
use revm::context::BlockEnv; πŸ”’
use revm::context::CfgEnv; πŸ”’
use revm::context_interface::block::BlobExcessGasAndPrice; πŸ”’
use revm::primitives::hardfork::SpecId; πŸ”’
use serde_json::Value; πŸ”’
use serde_json::json; πŸ”’
use std::fmt::Write as FmtWrite; πŸ”’
use std::net::IpAddr; πŸ”’
use std::net::Ipv4Addr; πŸ”’
use std::num::NonZeroU64; πŸ”’
use std::path::PathBuf; πŸ”’
use std::sync::Arc; πŸ”’
use std::time::Duration; πŸ”’
use tempo_hardfork::TempoHardfork; πŸ”’
use tempo_hardfork::constants::gas::TEMPO_T0_BASE_FEE; πŸ”’
use tempo_hardfork::constants::gas::TEMPO_T1_BASE_FEE; πŸ”’
use tempo_precompiles::TIP_FEE_MANAGER_ADDRESS; πŸ”’
use tokio::sync::RwLock as TokioRwLock; πŸ”’
use yansi::Paint; πŸ”’
use alloy_chains::NamedChain; πŸ”’ base

StructsΒ§

AccountGenerator
Can create dev accounts
AnvilNodeInfoProbe πŸ”’
Best-effort Anvil detection that becomes strict after positive identification.
ForkOverrides πŸ”’
ForkTransactionReplay πŸ”’
One-shot source data for a transaction-hash fork replay.
NodeConfig
Configurations of the EVM node
PruneStateHistoryConfig
StableForkSnapshot πŸ”’

EnumsΒ§

ForkChoice
Fork delimiter used to specify which block or transaction to fork from.

ConstantsΒ§

BANNER πŸ”’
CHAIN_ID
Default chain id of the node
DEFAULT_GAS_LIMIT
The default gas limit for all transactions
DEFAULT_IPC_ENDPOINT
The default IPC endpoint
DEFAULT_MNEMONIC
Default mnemonic for dev accounts
DEFAULT_SLOTS_IN_AN_EPOCH
The default number of slots in an epoch used for safe/finalized block tags.
DEFAULT_TEMPO_EPOCH_LENGTH
Default number of block heights in a Tempo consensus epoch.
FORK_IDENTITY_PROBE_TIMEOUT πŸ”’
Keep optional identity probes from delaying startup on RPCs that stall on unknown methods.
NODE_PORT
Default port the rpc will open
VERSION_MESSAGE
The short version message information for the Foundry CLI.

FunctionsΒ§

anvil_dir
Returns the path to anvil dir ~/.foundry/anvil
anvil_tmp_dir
Returns the root path to anvil’s temporary storage ~/.foundry/anvil/
decode_node_info πŸ”’
Decodes an anvil_nodeInfo response and the blob params that newer Anvil versions add to it.
derive_block_and_replay πŸ”’
If the fork choice is a block number, simply return it with an empty list of transactions. If the fork choice is a transaction hash, determine the block that the transaction was mined in, and return the block number before the fork block along with all transactions in the fork block that are before (and including) the fork transaction.
find_latest_fork_block πŸ”’
Finds the latest appropriate block to fork
fork_source_id πŸ”’
source_hardfork πŸ”’
Resolves source-chain upgrades without changing another execution family’s historical lookup.
tempo_default_base_fee πŸ”’
validate_fork_transaction_replay πŸ”’