Skip to content

Commit 33e7fc5

Browse files
committed
Merge bitcoin/bitcoin#33133: rpc: fix getpeerinfo ping duration unit docs
1252eeb rpc: fix getpeerinfo ping duration unit docs (0xb10c) Pull request description: The docs have been incorrect since a3789c7 (released in v25; master since Sept. 2022). Noticed while setting up monitoring using getpeerinfo. https://github.com/bitcoin/bitcoin/blob/0cb1ed2b7c634754f4ad0a0083d7cf40989d7f48/src/rpc/net.cpp#L249-L257 ACKs for top commit: luke-jr: utACK 1252eeb maflcko: lgtm ACK 1252eeb jonatack: ACK 1252eeb theStack: ACK 1252eeb janb84: ACK 1252eeb Tree-SHA512: 33f576336b2a4d9533f51f4641d564ee59ef692c5fa9a3cad239fc31465883d5da534bfd0e069be1e1d688e5f0dea3fe6850be19bf35335041b8f414d08f7f09
2 parents d1b5831 + 1252eeb commit 33e7fc5

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/rpc/net.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ static RPCHelpMan ping()
8585
return RPCHelpMan{
8686
"ping",
8787
"Requests that a ping be sent to all other nodes, to measure ping time.\n"
88-
"Results provided in getpeerinfo, pingtime and pingwait fields are decimal seconds.\n"
88+
"Results are provided in getpeerinfo.\n"
8989
"Ping command is handled in queue with all other commands, so it measures processing backlog, not just network ping.\n",
9090
{},
9191
RPCResult{RPCResult::Type::NONE, "", ""},
@@ -150,9 +150,9 @@ static RPCHelpMan getpeerinfo()
150150
{RPCResult::Type::NUM, "bytesrecv", "The total bytes received"},
151151
{RPCResult::Type::NUM_TIME, "conntime", "The " + UNIX_EPOCH_TIME + " of the connection"},
152152
{RPCResult::Type::NUM, "timeoffset", "The time offset in seconds"},
153-
{RPCResult::Type::NUM, "pingtime", /*optional=*/true, "The last ping time in milliseconds (ms), if any"},
154-
{RPCResult::Type::NUM, "minping", /*optional=*/true, "The minimum observed ping time in milliseconds (ms), if any"},
155-
{RPCResult::Type::NUM, "pingwait", /*optional=*/true, "The duration in milliseconds (ms) of an outstanding ping (if non-zero)"},
153+
{RPCResult::Type::NUM, "pingtime", /*optional=*/true, "The last ping time in seconds, if any"},
154+
{RPCResult::Type::NUM, "minping", /*optional=*/true, "The minimum observed ping time in seconds, if any"},
155+
{RPCResult::Type::NUM, "pingwait", /*optional=*/true, "The duration in seconds of an outstanding ping (if non-zero)"},
156156
{RPCResult::Type::NUM, "version", "The peer version, such as 70001"},
157157
{RPCResult::Type::STR, "subver", "The string version"},
158158
{RPCResult::Type::BOOL, "inbound", "Inbound (true) or Outbound (false)"},

0 commit comments

Comments
 (0)