diff --git a/common/eth2/src/lib.rs b/common/eth2/src/lib.rs index 5cd34faf2..9f7af3996 100644 --- a/common/eth2/src/lib.rs +++ b/common/eth2/src/lib.rs @@ -1443,32 +1443,6 @@ impl BeaconNodeHttpClient { self.get(path).await } - /// `GET v1/validator/blocks_and_blobs/{slot}` - pub async fn get_validator_blocks_and_blobs>( - &self, - slot: Slot, - randao_reveal: &SignatureBytes, - graffiti: Option<&Graffiti>, - ) -> Result>, Error> { - let mut path = self.eth_path(V1)?; - - path.path_segments_mut() - .map_err(|()| Error::InvalidUrl(self.server.clone()))? - .push("validator") - .push("blocks_and_blobs") - .push(&slot.to_string()); - - path.query_pairs_mut() - .append_pair("randao_reveal", &randao_reveal.to_string()); - - if let Some(graffiti) = graffiti { - path.query_pairs_mut() - .append_pair("graffiti", &graffiti.to_string()); - } - - self.get(path).await - } - /// `GET v2/validator/blinded_blocks/{slot}` pub async fn get_validator_blinded_blocks>( &self, diff --git a/common/eth2/src/types.rs b/common/eth2/src/types.rs index 3f4273730..36f80afd1 100644 --- a/common/eth2/src/types.rs +++ b/common/eth2/src/types.rs @@ -1218,37 +1218,6 @@ pub struct LivenessResponseData { pub is_live: bool, } -#[derive(PartialEq, Debug, Serialize, Deserialize)] -#[serde(bound = "T: EthSpec, Payload: AbstractExecPayload")] -pub struct BlocksAndBlobs> { - pub block: BeaconBlock, - pub blobs: Vec>, - pub kzg_aggregate_proof: KzgProof, -} - -impl> ForkVersionDeserialize - for BlocksAndBlobs -{ - fn deserialize_by_fork<'de, D: serde::Deserializer<'de>>( - value: serde_json::value::Value, - fork_name: ForkName, - ) -> Result { - #[derive(Deserialize)] - #[serde(bound = "T: EthSpec")] - struct Helper { - block: serde_json::Value, - blobs: Vec>, - kzg_aggregate_proof: KzgProof, - } - let helper: Helper = serde_json::from_value(value).map_err(serde::de::Error::custom)?; - - Ok(Self { - block: BeaconBlock::deserialize_by_fork::<'de, D>(helper.block, fork_name)?, - blobs: helper.blobs, - kzg_aggregate_proof: helper.kzg_aggregate_proof, - }) - } -} #[derive(Debug, Serialize, Deserialize)] pub struct ForkChoice { pub justified_checkpoint: Checkpoint,