Add finalized state check as optional interfaces to avoid breaking shared code#100
Open
Krish-vemula wants to merge 3 commits intomainfrom
Open
Add finalized state check as optional interfaces to avoid breaking shared code#100Krish-vemula wants to merge 3 commits intomainfrom
Krish-vemula wants to merge 3 commits intomainfrom
Conversation
|
…ared code # Conflicts: # multinode/node_test.go
Move this field out of the shared MultiNode struct to avoid imposing it on chains that don't use finalized state checking (e.g. Solana). The EVM side provides this value through its own NodePool config, and the framework's optional FinalizedStateCheckConfig interface handles the type assertion in node_lifecycle.go.
2c72bb8 to
de28b86
Compare
amit-momin
reviewed
May 1, 2026
| n.metrics.IncrementPollsFailed(ctx, n.name) | ||
| pollFailures++ | ||
| } | ||
| lggr.Warnw("Finalized state check failed with RPC error", "err", stateErr, "pollFailures", pollFailures) |
Contributor
There was a problem hiding this comment.
Wouldn't we want this to be an error log?
amit-momin
reviewed
May 1, 2026
| lggr.Warnw("Finalized state still not available", "err", stateErr) | ||
| continue | ||
| } | ||
| lggr.Warnw("Finalized state check failed with RPC error", "err", stateErr) |
Contributor
There was a problem hiding this comment.
Same with this one. Should we use error log when it's an error we're not expecting?
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds optional multinode support for detecting RPC nodes that cannot serve historical state at the latest finalized block.
This reintroduces the finalized-state availability check without adding new requirements to the shared
NodeConfigorRPCClientinterfaces. Instead, chains opt in by implementing optional interfaces:FinalizedStateCheckConfigFinalizedStateCheckerThis keeps the framework generic and avoids forcing non-EVM chains, such as Solana, to add no-op boilerplate.