mirror of
https://github.com/sigp/lighthouse.git
synced 2026-05-08 01:05:47 +00:00
Save For Later
This commit is contained in:
10
consensus/state_processing/src/execution_processing.rs
Normal file
10
consensus/state_processing/src/execution_processing.rs
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
use crate::BlockProcessingError;
|
||||||
|
use types::{BeaconState, ChainSpec, EthSpec, SignedExecutionEnvelope};
|
||||||
|
|
||||||
|
pub fn process_execution_payload_envelope<E: EthSpec>(
|
||||||
|
state: &mut BeaconState<E>,
|
||||||
|
signed_envelope: SignedExecutionEnvelope<E>,
|
||||||
|
spec: &ChainSpec,
|
||||||
|
) -> Result<(), BlockProcessingError> {
|
||||||
|
Ok(())
|
||||||
|
}
|
||||||
@@ -21,6 +21,7 @@ pub mod block_replayer;
|
|||||||
pub mod common;
|
pub mod common;
|
||||||
pub mod consensus_context;
|
pub mod consensus_context;
|
||||||
pub mod epoch_cache;
|
pub mod epoch_cache;
|
||||||
|
pub mod execution_processing;
|
||||||
pub mod genesis;
|
pub mod genesis;
|
||||||
pub mod per_block_processing;
|
pub mod per_block_processing;
|
||||||
pub mod per_epoch_processing;
|
pub mod per_epoch_processing;
|
||||||
@@ -32,6 +33,7 @@ pub mod verify_operation;
|
|||||||
pub use all_caches::AllCaches;
|
pub use all_caches::AllCaches;
|
||||||
pub use block_replayer::{BlockReplayError, BlockReplayer};
|
pub use block_replayer::{BlockReplayError, BlockReplayer};
|
||||||
pub use consensus_context::{ConsensusContext, ContextError};
|
pub use consensus_context::{ConsensusContext, ContextError};
|
||||||
|
pub use execution_processing::process_execution_payload_envelope;
|
||||||
pub use genesis::{
|
pub use genesis::{
|
||||||
eth2_genesis_time, initialize_beacon_state_from_eth1, is_valid_genesis_state,
|
eth2_genesis_time, initialize_beacon_state_from_eth1, is_valid_genesis_state,
|
||||||
process_activations,
|
process_activations,
|
||||||
|
|||||||
@@ -38,7 +38,7 @@ use tree_hash_derive::TreeHash;
|
|||||||
#[arbitrary(bound = "E: EthSpec")]
|
#[arbitrary(bound = "E: EthSpec")]
|
||||||
#[ssz(enum_behaviour = "transparent")]
|
#[ssz(enum_behaviour = "transparent")]
|
||||||
#[tree_hash(enum_behaviour = "transparent")]
|
#[tree_hash(enum_behaviour = "transparent")]
|
||||||
pub struct ExecutionPayloadEnvelope<E: EthSpec> {
|
pub struct ExecutionEnvelope<E: EthSpec> {
|
||||||
#[superstruct(only(EIP7732), partial_getter(rename = "payload_eip7732"))]
|
#[superstruct(only(EIP7732), partial_getter(rename = "payload_eip7732"))]
|
||||||
pub payload: ExecutionPayloadEIP7732<E>,
|
pub payload: ExecutionPayloadEIP7732<E>,
|
||||||
#[serde(with = "serde_utils::quoted_u64")]
|
#[serde(with = "serde_utils::quoted_u64")]
|
||||||
@@ -41,8 +41,8 @@ pub mod eth1_data;
|
|||||||
pub mod eth_spec;
|
pub mod eth_spec;
|
||||||
pub mod execution_bid;
|
pub mod execution_bid;
|
||||||
pub mod execution_block_hash;
|
pub mod execution_block_hash;
|
||||||
|
pub mod execution_envelope;
|
||||||
pub mod execution_payload;
|
pub mod execution_payload;
|
||||||
pub mod execution_payload_envelope;
|
|
||||||
pub mod execution_payload_header;
|
pub mod execution_payload_header;
|
||||||
pub mod fork;
|
pub mod fork;
|
||||||
pub mod fork_data;
|
pub mod fork_data;
|
||||||
@@ -77,7 +77,7 @@ pub mod signed_beacon_block_header;
|
|||||||
pub mod signed_bls_to_execution_change;
|
pub mod signed_bls_to_execution_change;
|
||||||
pub mod signed_contribution_and_proof;
|
pub mod signed_contribution_and_proof;
|
||||||
pub mod signed_execution_bid;
|
pub mod signed_execution_bid;
|
||||||
pub mod signed_execution_payload_envelope;
|
pub mod signed_execution_envelope;
|
||||||
pub mod signed_voluntary_exit;
|
pub mod signed_voluntary_exit;
|
||||||
pub mod signing_data;
|
pub mod signing_data;
|
||||||
pub mod sync_committee_subscription;
|
pub mod sync_committee_subscription;
|
||||||
@@ -172,14 +172,12 @@ pub use crate::eth_spec::EthSpecId;
|
|||||||
pub use crate::execution_bid::ExecutionBid;
|
pub use crate::execution_bid::ExecutionBid;
|
||||||
pub use crate::execution_block_hash::ExecutionBlockHash;
|
pub use crate::execution_block_hash::ExecutionBlockHash;
|
||||||
pub use crate::execution_block_header::{EncodableExecutionBlockHeader, ExecutionBlockHeader};
|
pub use crate::execution_block_header::{EncodableExecutionBlockHeader, ExecutionBlockHeader};
|
||||||
|
pub use crate::execution_envelope::{ExecutionEnvelope, ExecutionEnvelopeEIP7732};
|
||||||
pub use crate::execution_payload::{
|
pub use crate::execution_payload::{
|
||||||
ExecutionPayload, ExecutionPayloadBellatrix, ExecutionPayloadCapella, ExecutionPayloadDeneb,
|
ExecutionPayload, ExecutionPayloadBellatrix, ExecutionPayloadCapella, ExecutionPayloadDeneb,
|
||||||
ExecutionPayloadEIP7732, ExecutionPayloadElectra, ExecutionPayloadRef, Transaction,
|
ExecutionPayloadEIP7732, ExecutionPayloadElectra, ExecutionPayloadRef, Transaction,
|
||||||
Transactions, Withdrawals,
|
Transactions, Withdrawals,
|
||||||
};
|
};
|
||||||
pub use crate::execution_payload_envelope::{
|
|
||||||
ExecutionPayloadEnvelope, ExecutionPayloadEnvelopeEIP7732,
|
|
||||||
};
|
|
||||||
pub use crate::execution_payload_header::{
|
pub use crate::execution_payload_header::{
|
||||||
ExecutionPayloadHeader, ExecutionPayloadHeaderBellatrix, ExecutionPayloadHeaderCapella,
|
ExecutionPayloadHeader, ExecutionPayloadHeaderBellatrix, ExecutionPayloadHeaderCapella,
|
||||||
ExecutionPayloadHeaderDeneb, ExecutionPayloadHeaderElectra, ExecutionPayloadHeaderRef,
|
ExecutionPayloadHeaderDeneb, ExecutionPayloadHeaderElectra, ExecutionPayloadHeaderRef,
|
||||||
@@ -255,7 +253,7 @@ pub use crate::signed_beacon_block_header::SignedBeaconBlockHeader;
|
|||||||
pub use crate::signed_bls_to_execution_change::SignedBlsToExecutionChange;
|
pub use crate::signed_bls_to_execution_change::SignedBlsToExecutionChange;
|
||||||
pub use crate::signed_contribution_and_proof::SignedContributionAndProof;
|
pub use crate::signed_contribution_and_proof::SignedContributionAndProof;
|
||||||
pub use crate::signed_execution_bid::SignedExecutionBid;
|
pub use crate::signed_execution_bid::SignedExecutionBid;
|
||||||
pub use crate::signed_execution_payload_envelope::SignedExecutionPayloadEnvelope;
|
pub use crate::signed_execution_envelope::SignedExecutionEnvelope;
|
||||||
pub use crate::signed_voluntary_exit::SignedVoluntaryExit;
|
pub use crate::signed_voluntary_exit::SignedVoluntaryExit;
|
||||||
pub use crate::signing_data::{SignedRoot, SigningData};
|
pub use crate::signing_data::{SignedRoot, SigningData};
|
||||||
pub use crate::slot_epoch::{Epoch, Slot};
|
pub use crate::slot_epoch::{Epoch, Slot};
|
||||||
|
|||||||
@@ -37,8 +37,8 @@ use tree_hash_derive::TreeHash;
|
|||||||
#[arbitrary(bound = "E: EthSpec")]
|
#[arbitrary(bound = "E: EthSpec")]
|
||||||
#[ssz(enum_behaviour = "transparent")]
|
#[ssz(enum_behaviour = "transparent")]
|
||||||
#[tree_hash(enum_behaviour = "transparent")]
|
#[tree_hash(enum_behaviour = "transparent")]
|
||||||
pub struct SignedExecutionPayloadEnvelope<E: EthSpec> {
|
pub struct SignedExecutionEnvelope<E: EthSpec> {
|
||||||
#[superstruct(only(EIP7732), partial_getter(rename = "message_eip7732"))]
|
#[superstruct(only(EIP7732), partial_getter(rename = "message_eip7732"))]
|
||||||
pub message: ExecutionPayloadEnvelopeEIP7732<E>,
|
pub message: ExecutionEnvelopeEIP7732<E>,
|
||||||
pub signature: Signature,
|
pub signature: Signature,
|
||||||
}
|
}
|
||||||
Reference in New Issue
Block a user