diff --git a/beacon_node/beacon_chain/src/errors.rs b/beacon_node/beacon_chain/src/errors.rs index 16d0faa303..a1a0ec74f6 100644 --- a/beacon_node/beacon_chain/src/errors.rs +++ b/beacon_node/beacon_chain/src/errors.rs @@ -292,7 +292,6 @@ pub enum BlockProductionError { MissingBlobs, MissingSyncAggregate, MissingExecutionPayload, - MissingExecutionBid, MissingKzgCommitment(String), TokioJoin(JoinError), BeaconChain(Box), diff --git a/consensus/state_processing/src/upgrade/gloas.rs b/consensus/state_processing/src/upgrade/gloas.rs index 9fede0a90a..e1ca954e11 100644 --- a/consensus/state_processing/src/upgrade/gloas.rs +++ b/consensus/state_processing/src/upgrade/gloas.rs @@ -87,7 +87,7 @@ pub fn upgrade_state_to_gloas( execution_payload_availability: BitVector::default(), // All bits set to false initially builder_pending_payments: Vector::new(vec![ BuilderPendingPayment::default(); - 2 * E::slots_per_epoch() as usize + E::builder_pending_withdrawals_limit() ])?, builder_pending_withdrawals: List::default(), // Empty list initially, latest_block_hash: pre.latest_execution_payload_header.block_hash, diff --git a/consensus/types/src/beacon_block.rs b/consensus/types/src/beacon_block.rs index 1483c49351..01816500ac 100644 --- a/consensus/types/src/beacon_block.rs +++ b/consensus/types/src/beacon_block.rs @@ -684,6 +684,7 @@ impl> EmptyBlock for BeaconBlockGloa /// TODO(EIP-7732) Mark's branch had the following implementation but not sure if it's needed so will just add header below for reference // impl> BeaconBlockEIP7732 { +// TODO(EIP-7732) Look into whether we can remove this in the future since no blinded blocks post-gloas impl From>> for BeaconBlockGloas> { diff --git a/consensus/types/src/beacon_block_body.rs b/consensus/types/src/beacon_block_body.rs index ecbbf63b14..0671598f74 100644 --- a/consensus/types/src/beacon_block_body.rs +++ b/consensus/types/src/beacon_block_body.rs @@ -170,7 +170,6 @@ impl<'a, E: EthSpec, Payload: AbstractExecPayload> BeaconBlockBodyRef<'a, E, Self::Deneb(body) => Ok(Payload::Ref::from(&body.execution_payload)), Self::Electra(body) => Ok(Payload::Ref::from(&body.execution_payload)), Self::Fulu(body) => Ok(Payload::Ref::from(&body.execution_payload)), - // TODO(eip-7732): idk if this is right there's no more execution payload Self::Gloas(_) => Err(Error::IncorrectStateVariant), } } @@ -229,6 +228,7 @@ impl<'a, E: EthSpec, Payload: AbstractExecPayload> BeaconBlockBodyRef<'a, E, /// Produces the proof of inclusion for a `KzgCommitment` in `self.blob_kzg_commitments` /// at `index` using an existing proof for the `blob_kzg_commitments` field. + /// TODO(EIP7732) Investigate calling functions since this will no longer work for glas since no block_kzg_commitments in the body anymore pub fn complete_kzg_commitment_merkle_proof( &self, index: usize, @@ -240,7 +240,6 @@ impl<'a, E: EthSpec, Payload: AbstractExecPayload> BeaconBlockBodyRef<'a, E, | Self::Bellatrix(_) | Self::Capella(_) | Self::Gloas(_) => Err(Error::IncorrectStateVariant), - // TODO(eip-7732): Mark's impl had the Self::EIP-7732 variant below, but I think it should produce error instead since no self.blob_kzg_commitments in BeaconState for gloas Self::Deneb(_) | Self::Electra(_) | Self::Fulu(_) => { // We compute the branches by generating 2 merkle trees: // 1. Merkle tree for the `blob_kzg_commitments` List object @@ -521,6 +520,7 @@ impl From>> } // Post-Fulu block bodies without payloads can be converted into block bodies with payloads +// TODO(EIP-7732) Look into whether we can remove this in the future since no blinded blocks post-gloas impl From>> for BeaconBlockBodyGloas> { diff --git a/consensus/types/src/beacon_state.rs b/consensus/types/src/beacon_state.rs index 7a9ba9ba0a..cb851fb592 100644 --- a/consensus/types/src/beacon_state.rs +++ b/consensus/types/src/beacon_state.rs @@ -1091,7 +1091,7 @@ impl BeaconState { BeaconState::Fulu(state) => Ok(ExecutionPayloadHeaderRef::Fulu( &state.latest_execution_payload_header, )), - // FIXME(EIP-7732): this is only to make the code compile, needs to be written later + // TODO(EIP-7732): investigate calling functions BeaconState::Gloas(_) => Err(Error::IncorrectStateVariant), } } @@ -1116,7 +1116,7 @@ impl BeaconState { BeaconState::Fulu(state) => Ok(ExecutionPayloadHeaderRefMut::Fulu( &mut state.latest_execution_payload_header, )), - // FIXME(EIP-7732): this is only to make the code compile, needs to be written later + // TODO(EIP-7732): investigate calling functions BeaconState::Gloas(_) => Err(Error::IncorrectStateVariant), } } @@ -1854,7 +1854,6 @@ impl BeaconState { | BeaconState::Altair(_) | BeaconState::Bellatrix(_) | BeaconState::Capella(_) => self.get_validator_churn_limit(spec)?, - // FIXME(EIP-7732): check this BeaconState::Deneb(_) | BeaconState::Electra(_) | BeaconState::Fulu(_) diff --git a/consensus/types/src/execution_payload_header.rs b/consensus/types/src/execution_payload_header.rs index 6a257638b5..c72183ef57 100644 --- a/consensus/types/src/execution_payload_header.rs +++ b/consensus/types/src/execution_payload_header.rs @@ -512,7 +512,6 @@ impl<'de, E: EthSpec> ContextDeserialize<'de, ForkName> for ExecutionPayloadHead Self::Fulu(Deserialize::deserialize(deserializer).map_err(convert_err)?) } - // FIXME(EIP7732): Check this ForkName::Base | ForkName::Altair | ForkName::Gloas => { return Err(serde::de::Error::custom(format!( "ExecutionPayloadHeader failed to deserialize: unsupported fork '{}'", diff --git a/consensus/types/src/signed_beacon_block.rs b/consensus/types/src/signed_beacon_block.rs index 98311a73e9..f197839ad3 100644 --- a/consensus/types/src/signed_beacon_block.rs +++ b/consensus/types/src/signed_beacon_block.rs @@ -649,6 +649,7 @@ impl SignedBeaconBlockFulu> { } // We can convert gloas blocks without payloads into blocks "with" payloads. +// TODO(EIP-7732) Look into whether we can remove this in the future since no blinded blocks post-gloas impl From>> for SignedBeaconBlockGloas> {