-
Notifications
You must be signed in to change notification settings - Fork 17
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Propagate invalid fill reasons to caller (#486)
This change provides additional information to the caller of queryHistoricalDepositForFill(). In the case that a fill is not found, a cause code is associated: 0: The deposit ID was invalid for the SpokePool (i.e. cannot exist). 1: The deposit ID was valid, but it wasn't found within scraped data (i.e. maybe the RPCs aren't serving it in eth_getLogs() requests). 2: The deposit ID was valid, but one or more fields in the corresponding deposit were mismatched (i.e. the fill was invalid). This is most interesting for case (1), where there's a reasonable indication that the deposit should be held within the SpokePoolClient's deposit map, but isn't. This indirectly acts like a qualitative measure for RPC provider responses and will allow the upper layers to dynamically revert to more conservative behaviour. The minor package version was bumped as part of this work because it's a breaking change.
- Loading branch information
Showing
4 changed files
with
96 additions
and
26 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters