Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
improve(SpokePool): Prevent future deposit quoteTimestamps
Future quoteTimestamps create unusual challenges for the bots that process Deposit events. Fundamentally, it's impossible to compute the correct realizedLpFeePct for a deposit with a future quoteTimestamp, so all implementations must correctly park these early deposits and pull them out at the right time. Given that we are now seeing diversity in relayer implementations, it seems improbable that all will implement this correctly, and the downside is that they will lose funds for a slight mistake here. From the depositor side, for the most part it is hard to justify deliberately setting a The scenarios where this might harm users is: - A chain lags slightly behind the current time, meaning that deposits will fail due to very small time deltas. - A deposit from a multisig normally wants the widest possible time range to collect the necessary signatures, and is technically losing half of that window. For the former, this could be managed by the API, which supplies the suggested quoteTimestamp to the depositor. In cases where the chain has stalled, the API could simply throw a descriptive error. For the latter, this could be mitigated by doubling the current deposit window.
- Loading branch information