mirror of
https://github.com/sigp/lighthouse.git
synced 2026-04-27 09:43:36 +00:00
Update is_available check to support PeerDAS. (#6076)
* Update `is_available` check to support PeerDAS. * Merge branch 'unstable' into da-checker-das # Conflicts: # beacon_node/beacon_chain/src/data_availability_checker.rs # beacon_node/beacon_chain/src/data_availability_checker/overflow_lru_cache.rs * Simplify code using `map_or` * Merge branch 'unstable' into da-checker-das # Conflicts: # consensus/types/src/chain_spec.rs * Remove `epoch` method from `PendingComponents` * Add `put_kzg_verified_data_columns` method.
This commit is contained in:
19
beacon_node/beacon_chain/src/data_column_verification.rs
Normal file
19
beacon_node/beacon_chain/src/data_column_verification.rs
Normal file
@@ -0,0 +1,19 @@
|
||||
use derivative::Derivative;
|
||||
use ssz_derive::{Decode, Encode};
|
||||
use std::sync::Arc;
|
||||
use types::data_column_sidecar::{ColumnIndex, DataColumnSidecar};
|
||||
use types::EthSpec;
|
||||
|
||||
/// Data column that we must custody and has completed kzg verification
|
||||
#[derive(Debug, Derivative, Clone, Encode, Decode)]
|
||||
#[derivative(PartialEq, Eq)]
|
||||
#[ssz(struct_behaviour = "transparent")]
|
||||
pub struct KzgVerifiedCustodyDataColumn<E: EthSpec> {
|
||||
data: Arc<DataColumnSidecar<E>>,
|
||||
}
|
||||
|
||||
impl<E: EthSpec> KzgVerifiedCustodyDataColumn<E> {
|
||||
pub fn index(&self) -> ColumnIndex {
|
||||
self.data.index
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user