You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This fails if attestation_count + skip_count >= len(active_validators) which is possible either if skip_count is large or if len(active_validators) < ATTESTER_COUNT. I think one should be able to fix this by using (attestation_count + skip_count) % len(active_validators) as the proposer index (but it would mean that the proposer is also an attester, not sure if that's an issue).
The implementation in this repository is a little bit more complicated because of the sample parameter, resulting in an infinity loop in get_shuffling: At some point remaining will be zero so the inner loop breaks, but the outer loop will still continue. Proposed fix here is to just get rid of the sample complexity and just yield each o[i] as soon as it's replaced.
From the spec:
This fails if
attestation_count + skip_count >= len(active_validators)
which is possible either ifskip_count
is large or iflen(active_validators) < ATTESTER_COUNT
. I think one should be able to fix this by using(attestation_count + skip_count) % len(active_validators)
as the proposer index (but it would mean that the proposer is also an attester, not sure if that's an issue).The implementation in this repository is a little bit more complicated because of the
sample
parameter, resulting in an infinity loop in get_shuffling: At some pointremaining
will be zero so the inner loop breaks, but the outer loop will still continue. Proposed fix here is to just get rid of thesample
complexity and justyield
eacho[i]
as soon as it's replaced.Finally, this check seems to be useless: https://github.com/ethereum/beacon_chain/blob/master/beacon_chain/state/state_transition.py#L59.
The text was updated successfully, but these errors were encountered: