Eric 6fff02fd91
Workaround for Hardhat timestamp bug
Likely due to a Hardhat bug in which the callbacks for subscription events are called and awaited before updating its local understanding of the last block time, Hardhat will report a block time in the `newHeads` event that is generally 1 second before the time reported from `getLatestBlock.timestamp`. This was causing issues with the OnChainClock's offset and therefore the `now()` used by the `OnChainClock` would sometimes be off by a second (or more), causing tests to fail.

This commit introduce a `codex_use_hardhat` compilation flag, that when set, will always get the latest block timestamp from Hardhat via the `getLatestBlock.timestamp` RPC call for `OnChainClock.now` calls. Otherwise, the last block timestamp reported in the `newHeads` event will be used.

Update the docker dist tests compilation flag for simulated proof failures (it was not correct), and explicitly add the `codex_use_hardhat=false` for clarity.
2023-12-14 17:09:18 +11:00
..
2022-01-10 09:32:56 -06:00
2023-09-13 16:17:56 +02:00
2023-08-01 16:47:57 -07:00
2023-08-01 16:47:57 -07:00
2023-08-01 16:47:57 -07:00
2023-08-01 16:47:57 -07:00
2023-04-19 15:06:00 +02:00
2023-09-13 16:17:56 +02:00
2023-09-13 16:17:56 +02:00