Skip to content

Draft: Proto: refactor parametric constants and add tooling for preparing migrations

Context

This MR makes a couple of changes in an attempt to fix #1966

  1. Move constants into their own modules to represent current and previous, Constants_parametric_repr and Constants_parametric_previous_repr, respectively.
  2. Add script to automatically update Constants_parametric_previous_repr with a specified protocol version's Constants_parametric_repr and clean up protocol migration code. There is currently a complete standalone script and an incomplete integration into snapshot_alpha.sh.

This is currently a draft since it is undecided if:

  1. This is an approach we would like to take.
  2. If the script should be integrated into snapshot_alpha.sh or be used as a standalone script (currently named copy_and_prepare_parametric_constants.sh).

Manually testing the MR

See !4580 (comment 867699735) for a way to test the standalone script.

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
Edited by metanivek

Merge request reports