File tree Expand file tree Collapse file tree 3 files changed +15
-4
lines changed
beacon_node/network/src/network_beacon_processor Expand file tree Collapse file tree 3 files changed +15
-4
lines changed Original file line number Diff line number Diff line change @@ -1160,7 +1160,8 @@ impl<T: BeaconChainTypes> NetworkBeaconProcessor<T> {
11601160 "Processed data column, waiting for other components"
11611161 ) ;
11621162
1163- self . attempt_data_column_reconstruction ( block_root) . await ;
1163+ self . attempt_data_column_reconstruction ( block_root, true )
1164+ . await ;
11641165 }
11651166 } ,
11661167 Err ( BlockError :: DuplicateFullyImported ( _) ) => {
Original file line number Diff line number Diff line change @@ -918,9 +918,13 @@ impl<T: BeaconChainTypes> NetworkBeaconProcessor<T> {
918918 ///
919919 /// Returns `Some(AvailabilityProcessingStatus)` if reconstruction is successfully performed,
920920 /// otherwise returns `None`.
921+ ///
922+ /// The `publish_columns` parameter controls whether reconstructed columns should be published
923+ /// to the gossip network.
921924 async fn attempt_data_column_reconstruction (
922925 self : & Arc < Self > ,
923926 block_root : Hash256 ,
927+ publish_columns : bool ,
924928 ) -> Option < AvailabilityProcessingStatus > {
925929 // Only supernodes attempt reconstruction
926930 if !self . network_globals . is_supernode ( ) {
@@ -930,7 +934,9 @@ impl<T: BeaconChainTypes> NetworkBeaconProcessor<T> {
930934 let result = self . chain . reconstruct_data_columns ( block_root) . await ;
931935 match result {
932936 Ok ( Some ( ( availability_processing_status, data_columns_to_publish) ) ) => {
933- self . publish_data_columns_gradually ( data_columns_to_publish, block_root) ;
937+ if publish_columns {
938+ self . publish_data_columns_gradually ( data_columns_to_publish, block_root) ;
939+ }
934940 match & availability_processing_status {
935941 AvailabilityProcessingStatus :: Imported ( hash) => {
936942 debug ! (
Original file line number Diff line number Diff line change @@ -383,8 +383,12 @@ impl<T: BeaconChainTypes> NetworkBeaconProcessor<T> {
383383 ) ;
384384 // Attempt reconstruction here before notifying sync, to avoid sending out more requests
385385 // that we may no longer need.
386- if let Some ( availability) =
387- self . attempt_data_column_reconstruction ( block_root) . await
386+ // We don't publish columns reconstructed from rpc columns to the gossip network,
387+ // as these are likely historic columns.
388+ let publish_columns = false ;
389+ if let Some ( availability) = self
390+ . attempt_data_column_reconstruction ( block_root, publish_columns)
391+ . await
388392 {
389393 result = Ok ( availability)
390394 }
You can’t perform that action at this time.
0 commit comments