No description provided.
Update developer notes with RPC response guidelines #11135
pull promag wants to merge 1 commits into bitcoin:master from promag:2017-08-rpc-response-notes changing 1 files +5 −0-
promag commented at 2:55 PM on August 25, 2017: member
-
[doc] Add RPC response notes 62ecce75e4
-
jnewbery commented at 6:36 PM on August 25, 2017: member
ACK - seems like a reasonable suggestion. Agree that this should be a SHOULD rather than a MUST.
- fanquake added the label Docs and Output on Aug 25, 2017
-
mess110 commented at 11:33 PM on August 26, 2017: contributor
The main reason I can think of not to return a JSON object is if it returns something raw like a key or a number. Maybe there are also backward compatibility reasons why non JSON output is returned. Are there any other reasons?
Wouldn't it make it easier for clients to always expect a JSON object in the response? It would be future proof as well.
-
laanwj commented at 8:35 AM on August 28, 2017: member
Backward compatibility is a strong reason. We don't change existing interfaces unless there is a a good reason, and just conforming to a developer-notes item is not one.
Also, it's slightly easier to use from the command-line (especially scripts) with
bitcoin-cliif something returns a bare value. -
laanwj commented at 12:39 PM on August 28, 2017: member
I would bet RPC is mostly used with foreign client libraries than with bitcoin-cli
That's not the point, isn't it? despite a bet what use form is more common, many people are using
bitcoin-clias a command line client. -
promag commented at 1:45 PM on August 28, 2017: member
No it isn't for sure, but I think we shouldn't have
bitcoin-cliin mind when deciding API interface.As for
bitcoin-cli, I've previously suggested to have something like-rpcoutput=...to ease in those cases, but that's another topic.Do you think I should improve the guideline?
- promag renamed this:
Add RPC response notes
Update developer notes with RPC response guidelines
on Aug 29, 2017 - luke-jr approved
-
luke-jr commented at 7:00 AM on September 2, 2017: member
ACK
-
MarcoFalke commented at 8:50 AM on September 2, 2017: member
ACK 62ecce7
- laanwj merged this on Sep 6, 2017
- laanwj closed this on Sep 6, 2017
- laanwj referenced this in commit 21e2f2f799 on Sep 6, 2017
- PastaPastaPasta referenced this in commit a9a3ee7d27 on Sep 20, 2019
- PastaPastaPasta referenced this in commit e41b290bf6 on Sep 23, 2019
- PastaPastaPasta referenced this in commit eefbd448fd on Sep 23, 2019
- PastaPastaPasta referenced this in commit cc560b9ce7 on Sep 24, 2019
- PastaPastaPasta referenced this in commit 1b255fc16b on Nov 19, 2019
- PastaPastaPasta referenced this in commit 38a3868fce on Nov 21, 2019
- PastaPastaPasta referenced this in commit ce633a7490 on Dec 9, 2019
- PastaPastaPasta referenced this in commit ced462ec9c on Jan 1, 2020
- PastaPastaPasta referenced this in commit 0bce77c09e on Jan 2, 2020
- PastaPastaPasta referenced this in commit 06760febdd on Jan 2, 2020
- PastaPastaPasta referenced this in commit 10f7c5f066 on Jan 2, 2020
- ckti referenced this in commit c094118574 on Mar 28, 2021
- gades referenced this in commit 69487b2ffc on Jun 30, 2021
- DrahtBot locked this on Sep 8, 2021