Fix error causes and messages in rpc/net.cpp#9713
Fix error causes and messages in rpc/net.cpp#9713jnewbery wants to merge 1 commit intobitcoin:masterfrom
Conversation
|
Looks awesome, but given the potential for error, why not go ahead and remove assert_raises() and conver thsoe into _message or _jsonrpc now? |
qa/rpc-tests/test_framework/util.py
Outdated
There was a problem hiding this comment.
EOL whitespace here and the line before it
|
Thanks for the comments @TheBlueMatt . This PR actually contains two commits from master - the first is #9707 and the second is the commit for this PR (fixing error causes/messages in net.cpp). Looks like you've reviewed both in this PR. I was going to look at removing |
|
I miscounted - there are many cases of |
There are a couple of errors in `setban()` which return incorrect or misleading errors. This commit fixes those and updates nodehandling.py to test that the correct error codes and messages are being returned. Also add a testcase for trying to setban on an invalid subnet.
e6cfd6e to
3295cde
Compare
|
#9707 has now been merged, so this PR contains only the commit to be reviewed. |
|
Closing in favour of #9853. |
There are a couple of errors in
setban()which return incorrect ormisleading errors. This commit fixes those and updates nodehandling.py
to test that the correct error codes and messages are being returned.
Also add a testcase for trying to setban on an invalid subnet.
This PR builds on top of #9707