A very experimental PLC implementation which uses BFT consensus for decentralization

Fix non-determinism in processing of challenge transactions

gbl08ma.com 5cdbe9fc 67bf9fda

verified
+2 -2
+2 -2
abciapp/tx_challenge.go
··· 115 115 }, nil 116 116 } 117 117 118 - if time.Since(toHeightBlockMeta.Header.Time) > CommitToChallengeMaxAge { 118 + if deps.readTx.Timestamp().Sub(toHeightBlockMeta.Header.Time) > CommitToChallengeMaxAge { 119 119 return &processResult{ 120 120 Code: 4206, 121 121 Info: "outdated challenge range", ··· 264 264 }, nil 265 265 } 266 266 267 - if time.Since(blockAfterMeta.Header.Time) > CompleteChallengeMaxAge { 267 + if deps.readTx.Timestamp().Sub(blockAfterMeta.Header.Time) > CompleteChallengeMaxAge { 268 268 // validator must commit to a new challenge 269 269 return &processResult{ 270 270 Code: 4303,