mirror of
https://github.com/sigp/lighthouse.git
synced 2026-03-20 13:24:44 +00:00
Fixed Payload Reconstruction Bug (#3796)
This commit is contained in:
@@ -939,6 +939,7 @@ impl<T: BeaconChainTypes> BeaconChain<T> {
|
||||
Some(DatabaseBlock::Blinded(block)) => block,
|
||||
None => return Ok(None),
|
||||
};
|
||||
let fork = blinded_block.fork_name(&self.spec)?;
|
||||
|
||||
// If we only have a blinded block, load the execution payload from the EL.
|
||||
let block_message = blinded_block.message();
|
||||
@@ -953,7 +954,7 @@ impl<T: BeaconChainTypes> BeaconChain<T> {
|
||||
.execution_layer
|
||||
.as_ref()
|
||||
.ok_or(Error::ExecutionLayerMissing)?
|
||||
.get_payload_by_block_hash(exec_block_hash)
|
||||
.get_payload_by_block_hash(exec_block_hash, fork)
|
||||
.await
|
||||
.map_err(|e| Error::ExecutionLayerErrorPayloadReconstruction(exec_block_hash, e))?
|
||||
.ok_or(Error::BlockHashMissingFromExecutionLayer(exec_block_hash))?;
|
||||
|
||||
@@ -207,6 +207,7 @@ pub enum BeaconChainError {
|
||||
CommitteePromiseFailed(oneshot_broadcast::Error),
|
||||
MaxCommitteePromises(usize),
|
||||
BlsToExecutionChangeBadFork(ForkName),
|
||||
InconsistentFork(InconsistentFork),
|
||||
}
|
||||
|
||||
easy_from_to!(SlotProcessingError, BeaconChainError);
|
||||
@@ -230,6 +231,7 @@ easy_from_to!(ForkChoiceStoreError, BeaconChainError);
|
||||
easy_from_to!(HistoricalBlockError, BeaconChainError);
|
||||
easy_from_to!(StateAdvanceError, BeaconChainError);
|
||||
easy_from_to!(BlockReplayError, BeaconChainError);
|
||||
easy_from_to!(InconsistentFork, BeaconChainError);
|
||||
|
||||
#[derive(Debug)]
|
||||
pub enum BlockProductionError {
|
||||
|
||||
Reference in New Issue
Block a user