[go: up one dir, main page]

Alpha/DAL: for a delegate, only count slots that can be attested

What

When computing the DAL participation of a delegate do not take the total number of protocol-attested slots in a cycle, but just the number of protocol-attested slots that the delegate could have attested.

Why

At some level a delegate may have no shard. In this case, the number of protocol-attested slots at that level should not be taken into account for that delegate.

How

Adapt Attested_dal_slots to also store the total attested slots that are also attestable by the delagate.

Tests

Also, the test Alpha: Testing DAL node (attesters receive DAL rewards) has become flaky, probably because we don't control well enough when the baker not supposed to attest enough is stopped. So my fix was to stop the baker sooner, in this way we're more sure it will not have enough participation. I've also tried with increasing the number of blocks per cycle, and this worked as well. However, I think the real fix to use use bake for instead of the baker daemon, and thus really control what is published and what is attested.

Edited by Eugen Zalinescu

Merge request reports

Loading