-
Notifications
You must be signed in to change notification settings - Fork 53
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
improve(finalizer): Filter USDC from arbitrum and op stack finalizers #1539
improve(finalizer): Filter USDC from arbitrum and op stack finalizers #1539
Conversation
…nsactions to query for CCTP l2->l1 transactions We’re not de-duping the set of txn receipts to query for CCTP l2 to l1 deposits, but we do this in the l1 to l2 direciton. What’s unique for L2 to L1 is we look for SpokePool.TokensBridged() events but we forget there might be multiple of these in the same block
…or multiple day downtime Currently the finalizer is optimized for run-time speed and tries to look over as short of an event search window as possible. However, this provides very little margin for error in case the finalizer goes down for multiple days.
// We want to conservatively query for events that are between 0 and 24 hours old | ||
// because Linea L1->L2 messages are claimable after ~20 mins. | ||
const { fromBlock, toBlock } = await getBlockRangeByHoursOffsets(l1ChainId, 24, 0); | ||
const { fromBlock, toBlock } = await getBlockRangeByHoursOffsets(l1ChainId, 24 * 7, 0); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
forgot to add this longer look back in #1535
// because Linea L2->L1 messages are claimable after 6 - 32 hours | ||
const { fromBlock, toBlock } = await getBlockRangeByHoursOffsets(l2ChainId, 72, 8); | ||
// Linea L2->L1 messages are claimable after 6 - 32 hours | ||
const { fromBlock, toBlock } = await getBlockRangeByHoursOffsets(l2ChainId, 24 * 8, 6); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
forgot to add this in #1535
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I feel like there's a way around the logIndexesForMessage
- I'll look into it this week
2cb56d8
into
james/account-for-polygon-finalization
* fix(finalizer): polygon * improve(finalizer): Filter USDC from arbitrum and op stack finalizers (#1539) * fix(Finalizer): Dedup transaction hash list when creating list of transactions to query for CCTP l2->l1 transactions We’re not de-duping the set of txn receipts to query for CCTP l2 to l1 deposits, but we do this in the l1 to l2 direciton. What’s unique for L2 to L1 is we look for SpokePool.TokensBridged() events but we forget there might be multiple of these in the same block * improve(finalizer): Increase margin of error for finalizer to cover for multiple day downtime Currently the finalizer is optimized for run-time speed and tries to look over as short of an event search window as possible. However, this provides very little margin for error in case the finalizer goes down for multiple days. * Update l2ToL1.ts * add arbitrum/optimism filters * Update l2ToL1.ts * Update arbitrum.ts --------- Co-authored-by: nicholaspai <[email protected]>
No description provided.