You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We shuffle the sortedProposedBlocks during dispute state so that every staker follows different order when iterating over blocks for dispute.
The Shuffle() function which we are using is also changing the original sortedProposedBlocks array resulting in fetching of wrong blockIndex
for e.g -
sortedProposedBlocks= [5,4,2,3,1]
randomSortedProposedBlocks = Shuffle[sortedProposedBlocks]
randomSortedProposedBlocks = [4,5,1,2,3]
Ideally sortedProposedBlocks should be same i.e [5,4,2,3,1]
But it also changes,
sortedProposedBlocks = [4,5,1,2,3]
it follows sortedProposedBlocks = randomSortedProposedBlocks