Update SAMPLES_PER_SLOT to be number of custody groups instead of data columns (#7683)

Update `SAMPLES_PER_SLOT` to be number of custody groups instead of data columns. This should have no impact on the current implementation as config currently maintains a `group:subnet:column` ratio of `1:1:1`.  **In short, this PR doesn't change anything for Fusaka, but ensures compliance with the spec and potential future changes.**

I've added separate methods to compute sampling columns and custody groups for clarity: `spec.sampling_size_columns` and `spec.sampling_size_custod_groups`

See the clarifications in this PR for more details: https://github.com/ethereum/consensus-specs/pull/4251
This commit is contained in:
Jimmy Chen
2025-07-02 10:08:40 +10:00
committed by GitHub
parent e305cb1b92
commit 41742ce2bd
5 changed files with 71 additions and 30 deletions

View File

@@ -777,7 +777,7 @@ where
self.chain
.data_availability_checker
.custody_context()
.sampling_size(None, &self.chain.spec) as usize
.num_of_data_columns_to_sample(None, &self.chain.spec) as usize
}
pub fn slots_per_epoch(&self) -> u64 {