-
Notifications
You must be signed in to change notification settings - Fork 37.7k
doc: Add missing optional to getblockfrompeer #23702
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
Needed for #23083 |
utACK aaaa34e |
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.
Post-merge ACK, one nit for any follow-ups.
"getblockfrompeer", | ||
"\nAttempt to fetch block from a given peer.\n" | ||
"\nWe must have the header for this block, e.g. using submitheader.\n" | ||
"\nReturns {} if a block-request was successfully scheduled\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.
- "\nReturns {} if a block-request was successfully scheduled\n",
+ "\nReturns {} if a block-request was successfully scheduled.\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.
The trailing newline isn't needed either. Whitespace will be normalized by the doc generator.
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 added the .
in #23706, but I was not able to drop the trailing \n
without messing up the formatting of bitcoin-cli help getblockfrompeer
.
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.
Sorry, I never implemented this. Done in #23714
aaaa34e doc: Add missing optional to getblockfrompeer (MarcoFalke) Pull request description: Can be reviewed with `--word-diff-regex=. --ignore-all-space` ACKs for top commit: Sjors: utACK aaaa34e Tree-SHA512: 7f46c82a46b8cc19f7eb549b9aa13be8cd6849a8ef8a2ddda6d1eee6978d099fccadd29a2bf817f44d601b905f5d5f6b5d8f4f54be5ee8b914b520359c058e68
Github-Pull: bitcoin#23702 Rebased-From: aaaa34e
…mpeer cd289f3 doc: Add missing optional to getblockfrompeer (MarcoFalke) Pull request description: Can be reviewed with `--word-diff-regex=. --ignore-all-space` ACKs for top commit: Sjors: utACK cd289f3 Tree-SHA512: 7f46c82a46b8cc19f7eb549b9aa13be8cd6849a8ef8a2ddda6d1eee6978d099fccadd29a2bf817f44d601b905f5d5f6b5d8f4f54be5ee8b914b520359c058e68
Summary: This adds an RPC method to fetch a block directly from a peer. This can used to fetch stale blocks with lower proof of work that are normally ignored by the node (`headers-only` in `getchaintips`). Limitations: - you have to specify which peer to fetch the block from - the node must already have the header Co-authored-by: John Newbery <john@johnnewbery.com> This is a backport of [[bitcoin/bitcoin#20295 | core#20295]], [[bitcoin/bitcoin#23702 | core#23702]] and [[bitcoin/bitcoin#23706 | core#23706]] (partial) bitcoin/bitcoin@dce8c4c bitcoin/bitcoin@aaaa34e bitcoin/bitcoin@bfbf91d bitcoin/bitcoin@809d66b bitcoin/bitcoin@0e3d7c5 The main commit is the first one. The other commits are minor style & comments improvements, and one commit removing an unnecessary argument in the newly added `FetchBlock` function. Test Plan: `ninja all check-all` Reviewers: #bitcoin_abc, Fabien Reviewed By: #bitcoin_abc, Fabien Subscribers: Fabien Differential Revision: https://reviews.bitcoinabc.org/D12716
Can be reviewed with
--word-diff-regex=. --ignore-all-space