Skip to main content

Crate foundry_evm_networks

Crate foundry_evm_networks 

Source
Expand description

Β§foundry-evm-networks

Runtime selection and shared configuration for Foundry’s EVM network families.

NetworkConfigs describes the active execution profile selected by configuration, CLI flags, hardforks, or fork endpoint discovery. Cargo features only determine which optional NetworkVariant values are compiled into a binary; they do not select a network at runtime.

Concrete Alloy network and EVM factory types are associated by FoundryEvmNetwork in foundry-evm-core. See the custom EVM integration guide for the cross-crate ownership and state-lifecycle contract.

Re-exportsΒ§

pub(crate) use crate::celo::transfer::CELO_TRANSFER_ADDRESS; πŸ”’
pub(crate) use crate::celo::transfer::PRECOMPILE_ID_CELO_TRANSFER; πŸ”’
pub(crate) use alloy_primitives::Address; πŸ”’
pub(crate) use alloy_primitives::ChainId; πŸ”’
pub(crate) use alloy_primitives::address; πŸ”’
pub(crate) use Chain; πŸ”’
pub(crate) use NamedChain; πŸ”’
pub(crate) use Chiado; πŸ”’
pub(crate) use Gnosis; πŸ”’
pub(crate) use Moonbase; πŸ”’
pub(crate) use Moonbeam; πŸ”’
pub(crate) use MoonbeamDev; πŸ”’
pub(crate) use Moonriver; πŸ”’
pub(crate) use Rsk; πŸ”’
pub(crate) use RskTestnet; πŸ”’
pub(crate) use eip1559::BaseFeeParams; πŸ”’
pub(crate) use eip7840::BlobParams; πŸ”’
pub(crate) use DynPrecompile; πŸ”’
pub(crate) use PrecompilesMap; πŸ”’
pub(crate) use Address; πŸ”’
pub(crate) use ChainId; πŸ”’
pub(crate) use address; πŸ”’
pub(crate) use clap::Parser; πŸ”’
pub(crate) use EthereumHardfork; πŸ”’
pub(crate) use ExecutionSpec; πŸ”’
pub(crate) use FoundryHardfork; πŸ”’
pub(crate) use TempoHardfork; πŸ”’
pub(crate) use latest_active_tempo_hardfork; πŸ”’
pub(crate) use Precompile as RevmPrecompile; πŸ”’
pub(crate) use P256VERIFY; πŸ”’
pub(crate) use P256VERIFY_OSAKA; πŸ”’
pub(crate) use Deserialize; πŸ”’
pub(crate) use Deserialize; πŸ”’
pub(crate) use Serialize; πŸ”’
pub(crate) use Serialize; πŸ”’
pub(crate) use std::collections::BTreeMap; πŸ”’
pub(crate) use ACCOUNT_KEYCHAIN_ADDRESS; πŸ”’
pub(crate) use ADDRESS_REGISTRY_ADDRESS; πŸ”’
pub(crate) use CURRENT_COMMITTEE_ADDRESS; πŸ”’
pub(crate) use NONCE_PRECOMPILE_ADDRESS; πŸ”’
pub(crate) use RECEIVE_POLICY_GUARD_ADDRESS; πŸ”’
pub(crate) use SIGNATURE_VERIFIER_ADDRESS; πŸ”’
pub(crate) use STABLECOIN_DEX_ADDRESS; πŸ”’
pub(crate) use STORAGE_CREDITS_ADDRESS; πŸ”’
pub(crate) use TIP_FEE_MANAGER_ADDRESS; πŸ”’
pub(crate) use TIP20_CHANNEL_RESERVE_ADDRESS; πŸ”’
pub(crate) use TIP20_FACTORY_ADDRESS; πŸ”’
pub(crate) use TIP403_REGISTRY_ADDRESS; πŸ”’
pub(crate) use VALIDATOR_CONFIG_ADDRESS; πŸ”’
pub(crate) use VALIDATOR_CONFIG_V2_ADDRESS; πŸ”’
pub(crate) use ActivationRegistryStorage; πŸ”’
pub(crate) use B20FactoryStorage; πŸ”’
pub(crate) use NonceManagerStorage; πŸ”’
pub(crate) use PolicyRegistryStorage; πŸ”’
pub(crate) use TxContextStorage; πŸ”’
pub(crate) use foundry_evm_hardforks::BaseUpgrade; πŸ”’
pub(crate) use foundry_evm_hardforks::OpHardfork; πŸ”’
pub(crate) use foundry_evm_hardforks::MonadHardfork; πŸ”’

ModulesΒ§

arbitrum
Minimal Arbitrum system contract compatibility helpers.
celo
Celo-specific execution support.
optimism πŸ”’
Optimism-specific extensions for NetworkConfigs and related helpers.

StructsΒ§

NetworkConfigs
NetworkContractSizeLimits
Runtime and initcode byte-size limits for a configured network.

EnumsΒ§

NetworkVariant

ConstantsΒ§

BASE_CODE_SENTINEL_ADDRESSES
Fixed Base precompiles that expose at least one function returning no data.
BASE_PRECOMPILES πŸ”’
BSC_MAINNET_CHAIN_ID πŸ”’
BSC_MAINNET_HABER_TIMESTAMP πŸ”’
BSC_MAINNET_OSAKA_TIMESTAMP πŸ”’
BSC_P256_ADDRESS πŸ”’
BSC secp256r1 precompile address introduced by the Haber hardfork.
BSC_TESTNET_CHAIN_ID πŸ”’
BSC_TESTNET_HABER_TIMESTAMP πŸ”’
BSC_TESTNET_OSAKA_TIMESTAMP πŸ”’
MONAD_CHEATCODE_ADDRESS
The Monad cheatcode handler address.
MONAD_PRECOMPILES πŸ”’
MONAD_PRECOMPILE_LABELS πŸ”’
TEMPO_PRECOMPILES
Labels of all well-known Tempo precompiles, keyed by address.
TEMPO_PRECOMPILE_ADDRESSES
All well-known Tempo precompile addresses.

FunctionsΒ§

active_base_precompiles
Returns the fixed Base precompiles active at upgrade.
active_tempo_precompile_addresses
Returns the well-known Tempo precompile addresses active at hardfork.
apply_bsc_p256_precompile
Applies the BSC P256 precompile active at the given timestamp.
bsc_p256_precompile πŸ”’
Returns the BSC P256 precompile for the given timestamp. The outer option distinguishes BSC chains from unrelated chains, while the inner option disables P256 before Haber.
is_base_precompile_active_at
Returns whether a fixed Base precompile is active at upgrade.
is_monad_precompile_active_at
Returns whether a well-known Monad precompile address is active at hardfork.
is_tempo_precompile_active_at
Returns whether a well-known Tempo precompile address is active at hardfork.
resolved_precompile_labels
Returns custom precompile labels for an already resolved execution hardfork. This metadata lookup does not discover or select an execution network.