-
Notifications
You must be signed in to change notification settings - Fork 37.7k
[RPC] getblock: Added help text for chainwork value #7232
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
@instagibbs yes; that description was written by me based upon my reading of the code. |
ACK |
@@ -384,6 +384,7 @@ UniValue getblock(const UniValue& params, bool fHelp) | |||
" \"nonce\" : n, (numeric) The nonce\n" | |||
" \"bits\" : \"1d00ffff\", (string) The bits\n" | |||
" \"difficulty\" : x.xxx, (numeric) The difficulty\n" | |||
" \"chainwork\" : \"xxxx\", (string) The estimated number of block header hashes checked from the genesis block to this block, in hexadecimal\n" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't understand this sentence. I like (string) Expected number of hashes required to produce the current chain (in hex)
better.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What don't you understand about it specifically? Would:
(string) Expected number of hashes required to produce the chain up to this block (in hex)
be better? As-is it's ambiguous to what "current chain" means. In getblockchaininfo it clearly means the valid chain with most work.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
block header hashes
is not immediately clear what this means. Usually blocks with hashes that don't hit the diff are not considered valid, so they are not counted. Then "estimated" gives the hint that they are counted as well.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@instagibbs I like your suggestion as well.
Updated wording re: @MarcoFalke comments. |
9478fc9
to
94bdd71
Compare
utACK 94bdd71 |
94bdd71 Added help text for chainwork value (Gregory Sanders)
utACK |
I took the text from bitcoin.org's description. @harding Is this originally from there?
edit: Changed the wording