Skip to content

Fix genesis initial fitness to match tenderbake invariants

vbot requested to merge nomadic-labs/tezos:vbot@readapt_genesis_fitness into master

Context

The previous MR !6621 (merged) was not actually correct for Lima: to correctly parse a tenderbake fitness, the invariant that a locked round must be less than or equal to the round component was not respected. This was not properly tested as it is difficult to adapt existing test framework to simulate this. However, !6537 (merged) will provide a proper test suite for that. Manual tests were confusing as the mempool will not yield an error until it tries to evaluate an operation.

We now use the round instead and aim to target the round 0. Usually, the activate command is called with the argument 1 thus we actually translate the <arg> to round <arg> - 1 giving round 0 to make sure that tests will be able to bake as soon as possible.

Checklist

  • Document the interface of any function added or modified (see the coding guidelines)
  • Document any change to the user interface, including configuration parameters (see node configuration)
  • Provide automatic testing (see the testing guide).
  • 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

Merge request reports