-
Notifications
You must be signed in to change notification settings - Fork 51
Open
Labels
Description
Goal
Short-term fixes have been made over time to avoid breaking the storage layout during upgrades. Here we want to break the storage layout by removing those short-term fixes and reach the desired storage layout.
Required changes
-
Add storage gap arrays at the end of the abstract contract storage and any struct used in an array (eg. Dispute, Round, Vote).
-
Unused variables and parameters
bool alreadyTransferred; // DEPRECATED. True if tokens were already transferred before delayed stake's execution.
uint256 public randomNumberRequestBlock; // DEPRECATED: to be removed in the next redeploy
uint256 public rngLookahead; // DEPRECATED: to be removed in the next redeploy
mapping(address jurorAccount => mapping(uint96 courtId => uint256)) public latestDelayedStakeIndex; // DEPRECATED. Maps the juror to its latest delayed stake. If there is already a delayed stake for this juror then it'll be replaced. latestDelayedStakeIndex[juror][courtID].
RemoveDisputeKitClassicBase.Round.nbVotes
but keep_nbVotes
inIDisputeKit.createDispute()
for forward-compatibility with future non-classic DKs.
uint256 nbVotes; // Maximal number of votes this dispute can get. -
Move state variables inside a struct
MoveDisputeKitClassicBase.alreadyDrawn
to the Round struct.
public alreadyDrawn; // True if the address has already been drawn, false by default. To be added to the Round struct when fully redeploying rather than upgrading.
Out-of-scope
Migration logic, this is left to #2119 .