cosmosquad-labs / squad

Apache License 2.0
6 stars 3 forks source link

fix: sort map keys before iteration for deterministic execution #262

Closed hallazzang closed 2 years ago

hallazzang commented 2 years ago

Description

Since iteration order of map types is not deterministic, sort map keys before iteration.

dongsam commented 2 years ago

we'll test internally whether it's solved to deterministic and approve it.

dongsam commented 2 years ago

@hallazzang Could you add commit for fixing := range planCoins to deterministic also?

dongsam commented 2 years ago

In the TestAppStateDeterminism, I fixed that the seed was set to 1 and the test was not done properly, after that, the liquidity MatchOrders seems to have panic, so could you please check it?