namada
namada copied to clipboard
Add counter to check proportional infraction punishment property
Per discussion with @brentstone.
In order to ensure the property that any bond contributing to an infraction is punished proportionally to the stake it committed to that infraction as the time of the infraction (not the time of detection), we do some intricate calculations. Due to delayed detection, it may be possible for the stake amounts to be slashed "below zero", but we do checked subtraction to ensure that this doesn't happen. However, that makes it difficult to check correct adherence to this property. I think we can keep a counter of "overslashed" stake, per delegator, validator, and epoch, and use this to check correct adherence to this property in the state machine tests.
~~we have the solution from quint https://github.com/informalsystems/partnership-heliax/pull/79 being implemented on top of re-delegation #1612~~
edit: the comment was relevant to an older version of this issue