fix(notifications): handle BlockNotFoundError#203
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review infoConfiguration used: defaults Review profile: CHILL Plan: Pro ⛔ Files ignored due to path filters (1)
📒 Files selected for processing (1)
📝 WalkthroughWalkthroughThe TradeNotificationProducer adds error handling for BlockNotFoundError when retrieving block data. A try/catch block now wraps the getBlock call, logging a warning and breaking batch processing when this specific error occurs, while rethrowing other errors. Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~8 minutes Poem
🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There is constant crash-looping with
BlockNotFoundErrorerror, which happens only on BSC chain (more likely related to reorgs).We should not crash in that case and just skip the block.
Summary by CodeRabbit