Better error handling of an arbitrary number of different RPC providers and their varied responses
Opened this issue · 0 comments
shanefontaine commented
With the decentralized bonder role, anyone can use any RPC provider. This means the bonder will receive errors that it has never seen. Handle these, or ensure they're covered by a fallback.
Additionally, our current error handling is very ethers
specific. Given a possible upgrade in the future, try to head towards a more generalized error handling system.
Reference Conversation
maybe it would be good to determine what kind of errors to expect and see if ethers already handles them with a custom error type or create a wrapper to throw custom error types for any that ethers doesn't handle. errors such as:
- server error
- network error
- timeout
- tx failure
- nonce too low
- insufficient funds
- unprediable gas limit
- log range error
- onchain revert
- onchain call exception
etc