Skip to content

Commit de7c855

Browse files
committed
rpc: recommend -rpcclienttimeout=0 for waitfor*
1 parent 77ec072 commit de7c855

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

src/rpc/blockchain.cpp

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -276,7 +276,8 @@ static RPCHelpMan waitfornewblock()
276276
{
277277
return RPCHelpMan{"waitfornewblock",
278278
"\nWaits for any new block and returns useful info about it.\n"
279-
"\nReturns the current block on timeout or exit.\n",
279+
"\nReturns the current block on timeout or exit.\n"
280+
"\nMake sure to use no RPC timeout (bitcoin-cli -rpcclienttimeout=0)",
280281
{
281282
{"timeout", RPCArg::Type::NUM, RPCArg::Default{0}, "Time in milliseconds to wait for a response. 0 indicates no timeout."},
282283
},
@@ -318,7 +319,8 @@ static RPCHelpMan waitforblock()
318319
{
319320
return RPCHelpMan{"waitforblock",
320321
"\nWaits for a specific new block and returns useful info about it.\n"
321-
"\nReturns the current block on timeout or exit.\n",
322+
"\nReturns the current block on timeout or exit.\n"
323+
"\nMake sure to use no RPC timeout (bitcoin-cli -rpcclienttimeout=0)",
322324
{
323325
{"blockhash", RPCArg::Type::STR_HEX, RPCArg::Optional::NO, "Block hash to wait for."},
324326
{"timeout", RPCArg::Type::NUM, RPCArg::Default{0}, "Time in milliseconds to wait for a response. 0 indicates no timeout."},
@@ -365,7 +367,8 @@ static RPCHelpMan waitforblockheight()
365367
return RPCHelpMan{"waitforblockheight",
366368
"\nWaits for (at least) block height and returns the height and hash\n"
367369
"of the current tip.\n"
368-
"\nReturns the current block on timeout or exit.\n",
370+
"\nReturns the current block on timeout or exit.\n"
371+
"\nMake sure to use no RPC timeout (bitcoin-cli -rpcclienttimeout=0)",
369372
{
370373
{"height", RPCArg::Type::NUM, RPCArg::Optional::NO, "Block height to wait for."},
371374
{"timeout", RPCArg::Type::NUM, RPCArg::Default{0}, "Time in milliseconds to wait for a response. 0 indicates no timeout."},

0 commit comments

Comments
 (0)