We are throwing two different error descriptions for the same problematic:
“Expected type {expected], got {type}” –> RPCTypeCheckArgument()
“JSON value of type {type} is not of expected type {expected}” –> UniValue::checkType()
RPC: unify arg type error message
We were throwing two different errors for the same problematic:
* "Expected type {expected], got {type}" --> RPCTypeCheckArgument()
* "JSON value of type {type} is not of expected type {expected}" --> UniValue::checkType()
2870a97121
furszy renamed this:
RPC: unify arg type error message
rpc: unify arg type error message
on Sep 12, 2022
maflcko
commented at 1:31 pm on September 12, 2022:
member
Makes sense to use the same error string that univalue uses internally. The univalue error string was most recently changed in fae5ce87950.
DrahtBot added the label
RPC/REST/ZMQ
on Sep 12, 2022
DrahtBot
commented at 4:28 pm on September 12, 2022:
contributor
The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.
Conflicts
Reviewers, this pull request conflicts with the following ones:
#26039 (rpc: Return RPC_TYPE_ERROR, not RPC_MISC_ERROR on type mismatch (1/2) by MarcoFalke)
#25737 (rpc: remove redundant univalue type checks by furszy)
If you consider this pull request important, please also help to review the conflicting pull requests. Ideally, start with the one that should be merged first.
fanquake approved
fanquake
commented at 9:12 am on September 13, 2022:
member
ACK2870a97121ebeb4750a8d72cd5f39d9600767bc4
fanquake merged this
on Sep 13, 2022
fanquake closed this
on Sep 13, 2022
sidhujag referenced this in commit
6bc24d594c
on Sep 13, 2022
This is a metadata mirror of the GitHub repository
bitcoin/bitcoin.
This site is not affiliated with GitHub.
Content is generated from a GitHub metadata backup.
generated: 2024-12-18 21:12 UTC
This site is hosted by @0xB10C More mirrored repositories can be found on mirror.b10c.me