Skip to content

Proto/AI: add level, round, slot to Misbehaviour.t

Diane Gallois-Wong requested to merge diane@misbehaviour_repr into master

Context

This MR adds fields level, round, and slot to the Misbehaviour.t type. These new fields are unused for now, but they will be useful to improve the slashing implementation (see #6781).

Before this, the misbehaviour.ml file gets renamed to misbehaviour_repr.ml which is re-exported as the Misbehaviour module through Alpha_context. Indeed, the new fields need to have _repr types (Raw_level_repr.t, Round_repr.t, Slot_repr.t) because this file is a dependency for other files, such as denunciations_repr.ml and delegate_slashed_deposits_storage.ml, which are "below" alpha_context.ml.

The new fields are not used yet in the tests either. The follow-up MR !11601 (merged) will update the tests to correctly simulate and check these fields.

Manually testing the MR

Not much to do since this MR only introduces dead code for now; check the CI as usual.

Checklist

  • Document the interface of any function added or modified (see the coding guidelines)
  • [N/A] Document any change to the user interface, including configuration parameters (see node configuration)
  • [see !11601 (merged)] Provide automatic testing (see the testing guide).
  • [N/A] For new features and bug fixes, add an item in the appropriate changelog (docs/protocols/alpha.rst for the protocol and the environment, CHANGES.rst at the root of the repository for everything else).
  • Select suitable reviewers using the Reviewers field below.
  • Select as Assignee the next person who should take action on that MR
Edited by Diane Gallois-Wong

Merge request reports

Loading