Skip to content

Commit 263f53e

Browse files
author
MarcoFalke
committed
Merge #18098: scripted-diff: Add missing spaces in RPCResult, Normalize type names
fad027f scripted-diff: Add missing spaces in RPCResult, Fix type names (MarcoFalke) Pull request description: This makes the rendered diff smaller when the RPCResult is machine generated later on (Previous attempts: #14601 and #14459) ACKs for top commit: Sjors: ACK fad027f Tree-SHA512: 48afd571b1cd349ca0b29bb444c1c7cda657e07dd96c610d479f931ccd938186aec98e533d0552b5b10afc9a3d7b911359260a49448e8e1106e3647b2c71f3ba
2 parents 94c0287 + fad027f commit 263f53e

File tree

8 files changed

+315
-315
lines changed

8 files changed

+315
-315
lines changed

src/rpc/blockchain.cpp

Lines changed: 111 additions & 111 deletions
Large diffs are not rendered by default.

src/rpc/mining.cpp

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,7 @@ static UniValue generatetodescriptor(const JSONRPCRequest& request)
154154
{"maxtries", RPCArg::Type::NUM, /* default */ "1000000", "How many iterations to try."},
155155
},
156156
RPCResult{
157-
"[ blockhashes ] (array) hashes of blocks generated\n"},
157+
"[ blockhashes ] (json array) hashes of blocks generated\n"},
158158
RPCExamples{
159159
"\nGenerate 11 blocks to mydesc\n" + HelpExampleCli("generatetodescriptor", "11 \"mydesc\"")},
160160
}
@@ -196,7 +196,7 @@ static UniValue generatetoaddress(const JSONRPCRequest& request)
196196
{"maxtries", RPCArg::Type::NUM, /* default */ "1000000", "How many iterations to try."},
197197
},
198198
RPCResult{
199-
"[ blockhashes ] (array) hashes of blocks generated\n"
199+
"[ blockhashes ] (json array) hashes of blocks generated\n"
200200
},
201201
RPCExamples{
202202
"\nGenerate 11 blocks to myaddress\n"
@@ -231,14 +231,14 @@ static UniValue getmininginfo(const JSONRPCRequest& request)
231231
{},
232232
RPCResult{
233233
"{\n"
234-
" \"blocks\": nnn, (numeric) The current block\n"
235-
" \"currentblockweight\": nnn, (numeric, optional) The block weight of the last assembled block (only present if a block was ever assembled)\n"
236-
" \"currentblocktx\": nnn, (numeric, optional) The number of block transactions of the last assembled block (only present if a block was ever assembled)\n"
237-
" \"difficulty\": xxx.xxxxx (numeric) The current difficulty\n"
238-
" \"networkhashps\": nnn, (numeric) The network hashes per second\n"
239-
" \"pooledtx\": n (numeric) The size of the mempool\n"
240-
" \"chain\": \"xxxx\", (string) current network name (main, test, regtest)\n"
241-
" \"warnings\": \"...\" (string) any network and blockchain warnings\n"
234+
" \"blocks\" : nnn, (numeric) The current block\n"
235+
" \"currentblockweight\" : nnn, (numeric, optional) The block weight of the last assembled block (only present if a block was ever assembled)\n"
236+
" \"currentblocktx\" : nnn, (numeric, optional) The number of block transactions of the last assembled block (only present if a block was ever assembled)\n"
237+
" \"difficulty\" : xxx.xxxxx (numeric) The current difficulty\n"
238+
" \"networkhashps\" : nnn, (numeric) The network hashes per second\n"
239+
" \"pooledtx\" : n (numeric) The size of the mempool\n"
240+
" \"chain\" : \"xxxx\", (string) current network name (main, test, regtest)\n"
241+
" \"warnings\" : \"...\" (string) any network and blockchain warnings\n"
242242
"}\n"
243243
},
244244
RPCExamples{
@@ -365,16 +365,16 @@ static UniValue getblocktemplate(const JSONRPCRequest& request)
365365
" },\n"
366366
" \"vbrequired\" : n, (numeric) bit mask of versionbits the server requires set in submissions\n"
367367
" \"previousblockhash\" : \"xxxx\", (string) The hash of current highest block\n"
368-
" \"transactions\" : [ (array) contents of non-coinbase transactions that should be included in the next block\n"
368+
" \"transactions\" : [ (json array) contents of non-coinbase transactions that should be included in the next block\n"
369369
" {\n"
370370
" \"data\" : \"xxxx\", (string) transaction data encoded in hexadecimal (byte-for-byte)\n"
371371
" \"txid\" : \"xxxx\", (string) transaction id encoded in little-endian hexadecimal\n"
372372
" \"hash\" : \"xxxx\", (string) hash encoded in little-endian hexadecimal (including witness data)\n"
373-
" \"depends\" : [ (array) array of numbers \n"
373+
" \"depends\" : [ (json array) array of numbers \n"
374374
" n (numeric) transactions before this one (by 1-based index in 'transactions' list) that must be present in the final block if this one is\n"
375375
" ,...\n"
376376
" ],\n"
377-
" \"fee\": n, (numeric) difference in value between transaction inputs and outputs (in satoshis); for coinbase transactions, this is a negative Number of the total collected block fees (ie, not including the block subsidy); if key is not present, fee is unknown and clients MUST NOT assume there isn't one\n"
377+
" \"fee\" : n, (numeric) difference in value between transaction inputs and outputs (in satoshis); for coinbase transactions, this is a negative Number of the total collected block fees (ie, not including the block subsidy); if key is not present, fee is unknown and clients MUST NOT assume there isn't one\n"
378378
" \"sigops\" : n, (numeric) total SigOps cost, as counted for purposes of block limits; if key is not present, sigop cost is unknown and clients MUST NOT assume it is zero\n"
379379
" \"weight\" : n, (numeric) total transaction weight, as counted for purposes of block limits\n"
380380
" }\n"
@@ -850,7 +850,7 @@ static UniValue estimatesmartfee(const JSONRPCRequest& request)
850850
RPCResult{
851851
"{\n"
852852
" \"feerate\" : x.x, (numeric, optional) estimate fee rate in " + CURRENCY_UNIT + "/kB\n"
853-
" \"errors\": [ str... ] (json array of strings, optional) Errors encountered during processing\n"
853+
" \"errors\" : [ str... ] (json array of strings, optional) Errors encountered during processing\n"
854854
" \"blocks\" : n (numeric) block number where estimate was found\n"
855855
"}\n"
856856
"\n"
@@ -924,7 +924,7 @@ static UniValue estimaterawfee(const JSONRPCRequest& request)
924924
" \"fail\" : { (json object, optional) information about the highest range of feerates to fail to meet the threshold\n"
925925
" ...\n"
926926
" },\n"
927-
" \"errors\": [ (json array, optional) Errors encountered during processing\n"
927+
" \"errors\" : [ (json array, optional) Errors encountered during processing\n"
928928
" \"str\", (string)\n"
929929
" ...\n"
930930
" ],\n"

src/rpc/misc.cpp

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -81,9 +81,9 @@ static UniValue createmultisig(const JSONRPCRequest& request)
8181
},
8282
RPCResult{
8383
"{\n"
84-
" \"address\":\"multisigaddress\", (string) The value of the new multisig address.\n"
85-
" \"redeemScript\":\"script\" (string) The string value of the hex-encoded redemption script.\n"
86-
" \"descriptor\":\"descriptor\" (string) The descriptor for this multisig\n"
84+
" \"address\" : \"multisigaddress\", (string) The value of the new multisig address.\n"
85+
" \"redeemScript\" : \"script\" (string) The string value of the hex-encoded redemption script.\n"
86+
" \"descriptor\" : \"descriptor\" (string) The descriptor for this multisig\n"
8787
"}\n"
8888
},
8989
RPCExamples{
@@ -187,7 +187,7 @@ UniValue deriveaddresses(const JSONRPCRequest& request)
187187
{"range", RPCArg::Type::RANGE, RPCArg::Optional::OMITTED_NAMED_ARG, "If a ranged descriptor is used, this specifies the end or the range (in [begin,end] notation) to derive."},
188188
},
189189
RPCResult{
190-
"[ address ] (array) the derived addresses\n"
190+
"[ address ] (json array) the derived addresses\n"
191191
},
192192
RPCExamples{
193193
"First three native segwit receive addresses\n" +
@@ -418,13 +418,13 @@ static UniValue getmemoryinfo(const JSONRPCRequest& request)
418418
{
419419
RPCResult{"mode \"stats\"",
420420
"{\n"
421-
" \"locked\": { (json object) Information about locked memory manager\n"
422-
" \"used\": xxxxx, (numeric) Number of bytes used\n"
423-
" \"free\": xxxxx, (numeric) Number of bytes available in current arenas\n"
424-
" \"total\": xxxxxxx, (numeric) Total number of bytes managed\n"
425-
" \"locked\": xxxxxx, (numeric) Amount of bytes that succeeded locking. If this number is smaller than total, locking pages failed at some point and key data could be swapped to disk.\n"
426-
" \"chunks_used\": xxxxx, (numeric) Number allocated chunks\n"
427-
" \"chunks_free\": xxxxx, (numeric) Number unused chunks\n"
421+
" \"locked\" : { (json object) Information about locked memory manager\n"
422+
" \"used\" : xxxxx, (numeric) Number of bytes used\n"
423+
" \"free\" : xxxxx, (numeric) Number of bytes available in current arenas\n"
424+
" \"total\" : xxxxxxx, (numeric) Total number of bytes managed\n"
425+
" \"locked\" : xxxxxx, (numeric) Amount of bytes that succeeded locking. If this number is smaller than total, locking pages failed at some point and key data could be swapped to disk.\n"
426+
" \"chunks_used\" : xxxxx, (numeric) Number allocated chunks\n"
427+
" \"chunks_free\" : xxxxx, (numeric) Number unused chunks\n"
428428
" }\n"
429429
"}\n"
430430
},
@@ -497,7 +497,7 @@ UniValue logging(const JSONRPCRequest& request)
497497
},
498498
RPCResult{
499499
"{ (json object where keys are the logging categories, and values indicates its status\n"
500-
" \"category\": true|false, (bool) if being debug logged or not. false:inactive, true:active\n"
500+
" \"category\" : true|false, (boolean) if being debug logged or not. false:inactive, true:active\n"
501501
" ...\n"
502502
"}\n"
503503
},

0 commit comments

Comments
 (0)