Modulesยง
- optimism ๐
optimism - Optimism-specific dynamic EIP-1559 fee rules.
Structsยง
- FeeDetails
- FeeHistory
Cache Item - A single item in the whole fee history cache
- FeeHistory
Service - An async service that takes care of the
FeeHistorycache - FeeManager
- Stores the fee related information
- FeeRules ๐
- FeeSnapshot ๐
- Chain-derived fee state for the next block.
- FeeState ๐
- Parent
Header ๐Fees
Enumsยง
- Base
FeeRules ๐
Constantsยง
- BASE_
FEE_ CHANGE_ DENOMINATOR - Bounds the amount the base fee can change between blocks.
- INITIAL_
BASE_ FEE - Initial base fee for EIP-1559 blocks.
- INITIAL_
GAS_ PRICE - Initial default gas price for the first block
- MAX_
FEE_ HISTORY_ CACHE_ SIZE - Maximum number of entries in the fee history cache
- MIN_
SUGGESTED_ PRIORITY_ FEE - Minimum suggested priority fee
- REWARD_
PERCENTILE_ ๐RESOLUTION - Number of cached reward samples per percentile.
Staticsยง
- REWARD_
PERCENTILES ๐ - Percentile list from 0.0 to 100.0 with a 0.5 resolution (201 points).
Functionsยง
- calculate_
next_ ๐block_ base_ fee_ per_ gas - calculate_
parent_ ๐header_ fees - create_
fee_ ๐history_ cache_ item - Builds the
FeeHistoryCacheItemfor a single block. - insert_
fee_ ๐history_ cache_ item - Inserts an entry into the fee history cache and trims it back to
fee_history_limit. - reward_
percentiles ๐ - Calculates percentile rewards from transactions sorted by effective reward.
- tempo_
next_ ๐block_ base_ fee - Computes the next blockโs base fee for a Tempo chain.