-
Notifications
You must be signed in to change notification settings - Fork 17
Description
Forks happen regularly on Goerli.
A deal/task can immediately go off-chain to a contribution timeout status if the contribution timeout value read on the blockchain was 0 (1970-01-01).
eg.: https://core.dev-pool.goerli.iex.ec/tasks/0xa4d31e17e8e55aa70a4a17c3c05a2832983f815b10adaba190e2a5d038e54a2b
contributionDeadline":"1970-01-01"
With latest code:
return; |
the task won't be added at all.
Nevertheless, if a deal has been received (meaning the task exists) while the on-chain contributionTimeout is 0, it is very likely the blockchain node is on a fork. In this case, we might be able to detect it and schedule a re-read until the blockchain node is on the right fork again.
Note: The case where we first received a deal on a fork which isn't the mainchain anymore (couple blocks after) is (probably?) less likely.