fix: use rpc url from transports in handlers #1070
Merged
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.
Before:
Handlers were using
getDefaultRpcUrl()
which takes the viem's public rpc url. This could lead to errors due to 429s or temporary outages of the public URLs.After:
Handlers use
getHandlerRpcUrl()
which takes the rpc url from the transports setup, that is, uses private (or fallback) urls, that should be more reliable.With this change we should minimize errors like these ones: https://balancer-labs.sentry.io/issues/5763086985/
We are also using private infura url for integration tests (sepolia and polygon) to make them more reliable.