Conversation
Test results172 tests 172 ✅ 17m 18s ⏱️ Results for commit 3d81567. ♻️ This comment has been updated with latest results. |
| .from_block(from_block) | ||
| .to_block(to_block) |
There was a problem hiding this comment.
Are you sure that get_logs will work with an arbitrary block range? I recall eth-watcher in Era having complex logic to handle the corresponding errors in a similar situation.
lib/interop_watcher/src/lib.rs
Outdated
|
|
||
| let interop_roots_envelope = InteropRootsEnvelope::from_interop_roots(interop_roots); | ||
|
|
||
| self.output.send(interop_roots_envelope).await?; |
There was a problem hiding this comment.
An error here corresponds to the disconnected receiver (i.e., on normal or abnormal node shutdown). Correspondingly, it would make more sense to exit the component normally in this case.
| let filter = Filter::new() | ||
| .from_block(from_block) | ||
| .to_block(to_block) | ||
| .address(self.contract_address) |
There was a problem hiding this comment.
Future work: Is there a way to check the address on construction, e.g. by invoking some getter in the contract? This could prevent misconfigurations etc.
Summary
Add a subcomponent for watching interop roots, composing interop system transactions and sending them down transaction stream.
TODO:
[ ] - Add config value for interop mode(GW or L1)
[ ] - Add persistence to watcher
Breaking Changes
Rollout Instructions
-->