-
Notifications
You must be signed in to change notification settings - Fork 1.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Raise custom exception instead of ValueError when a method is unavailable at the node #2448
Comments
It may happen due to unavailable method at the node via a web3 query. This should go away if ethereum/web3.py#2448 is implemented
I like this idea but we'll have to think about how to parse the error response to accommodate the most users. I can't remember if error code numbers are standardized across clients. I'll add this to our v6 breaking changes issue to discuss with the team. Eventually in v6 we're also planning on adding a |
Understood! That would be a really cool change. Will be looking at the issue to see how it progresses ❤️ |
pip freeze
outputWhat was wrong?
Please include any of the following that are applicable:
Make this call via web3.py
https://nodes.mewapi.io/rpc/eth
How can it be fixed?
I think it would be much better if we, the users of web3, have a different exception to catch when a method is not available in the node, rather than raising a generic
ValueError
.How about
MethodUnavailable
?The text was updated successfully, but these errors were encountered: