Struct NextBlockEnvAttributes
pub struct NextBlockEnvAttributes {
pub timestamp: u64,
pub suggested_fee_recipient: Address,
pub prev_randao: FixedBytes<32>,
pub gas_limit: u64,
pub parent_beacon_block_root: Option<FixedBytes<32>>,
pub withdrawals: Option<Withdrawals>,
pub extra_data: Bytes,
}Expand description
Traits and helper types used to abstract over EVM methods and types. Represents additional attributes required to configure the next block.
This struct contains all the information needed to build a new block that cannot be derived from the parent block header alone. These attributes are typically provided by the consensus layer (CL) through the Engine API during payload building.
§Relationship with ConfigureEvm and BlockAssembler
The flow for building a new block involves:
-
Receive attributes from the consensus layer containing:
- Timestamp for the new block
- Fee recipient (coinbase/beneficiary)
- Randomness value (prevRandao)
- Withdrawals to process
- Parent beacon block root for EIP-4788
-
Configure EVM environment using these attributes:
rust,ignore let evm_env = evm_config.next_evm_env(&parent, &attributes)?; -
Build the block with transactions:
rust,ignore let mut builder = evm_config.builder_for_next_block( &mut state, &parent, attributes )?; -
Assemble the final block using
BlockAssemblerwhich takes:- Execution results from all transactions
- The attributes used during execution
- Final state root after all changes
This design cleanly separates:
- Configuration (what parameters to use) - handled by
NextBlockEnvAttributes - Execution (running transactions) - handled by
BlockExecutor - Assembly (creating the final block) - handled by
BlockAssembler
The timestamp of the next block.
The suggested fee recipient for the next block.
§prev_randao: FixedBytes<32>The randomness value for the next block.
Block gas limit.
The parent beacon block root.
Withdrawals
Optional extra data.
§
§
Causes self to use its Binary implementation when Debug-formatted.
§
Causes self to use its Display implementation when
Debug-formatted.
§
Causes self to use its LowerExp implementation when
Debug-formatted.
§
Causes self to use its LowerHex implementation when
Debug-formatted.
§
Causes self to use its Octal implementation when Debug-formatted.
§
Causes self to use its Pointer implementation when
Debug-formatted.
§
Causes self to use its UpperExp implementation when
Debug-formatted.
§
Causes self to use its UpperHex implementation when
Debug-formatted.
§
§
Available on crate feature propagate-header only.
Propagate a header from the request to the response. Read more
§
Available on crate feature add-extension only.
§
Available on crate feature map-request-body only.
Apply a transformation to the request body. Read more
§
Available on crate feature map-response-body only.
Apply a transformation to the response body. Read more
§
Available on crate features compression-br or compression-deflate or compression-gzip or compression-zstd only.
Compresses response bodies. Read more
§
Available on crate features decompression-br or decompression-deflate or decompression-gzip or decompression-zstd only.
Decompress response bodies. Read more
§
Available on crate feature trace only.
High level tracing that classifies responses using HTTP status codes. Read more
§
Available on crate feature trace only.
High level tracing that classifies responses using gRPC headers. Read more
§
Available on crate feature follow-redirect only.
Available on crate feature sensitive-headers only.
Available on crate feature sensitive-headers only.
Available on crate feature sensitive-headers only.
Available on crate feature set-header only.
Insert a header into the request, if the header is not already present. Read more
Available on crate feature set-header only.
Insert a header into the response, if the header is not already present. Read more
§
Available on crate feature request-id only.
Add request id header and extension, using x-request-id as the header name. Read more
§
Available on crate feature request-id only.
Propgate request ids from requests to responses. Read more
§
Available on crate feature request-id only.
Propgate request ids from requests to responses, using x-request-id as the header name. Read more
§
Available on crate feature catch-panic only.
Catch panics and convert them into 500 Internal Server responses. Read more
§
§
Calls .tap() only in debug builds, and is erased in release builds.
§
Calls .tap_mut() only in debug builds, and is erased in release
builds.
§
Calls .tap_borrow() only in debug builds, and is erased in release
builds.
§
Calls .tap_borrow_mut() only in debug builds, and is erased in release
builds.
§
Calls .tap_ref() only in debug builds, and is erased in release
builds.
§
Calls .tap_ref_mut() only in debug builds, and is erased in release
builds.
§
Calls .tap_deref() only in debug builds, and is erased in release
builds.
§
Calls .tap_deref_mut() only in debug builds, and is erased in release
builds.
Note: Most layout information is completely unstable and may even differ between compilations. The only exception is types with certain repr(...) attributes. Please see the Rust Reference's “Type Layout” chapter for details on type layout guarantees.
Size: 160 bytes