onflow/flow-core-contracts

Epochs: Remove Epoch setup parameters from resetEpoch and add counter

Closed this issue · 0 comments

Issue To Be Solved

EpochSetup parameters are not used by reset Epoch, so they can be removed from the function parameter list. We also need to include the current epoch counter.

Suggest A Solution

  • Remove clusterQCs and dkgKeys
  • Set the epoch metadata versions of those to nil
  • Add currentEpochCounter as a parameter to resetEpoch and revert if it doesn't match the current epoch counter stored by the smart contract.
  • Fix the reset epoch transaction and tests to use these changes

cc @jordanschalm