-
Notifications
You must be signed in to change notification settings - Fork 38.7k
Use wallet RBF default for walletcreatefundedpsbt #15911
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
|
(my initial attempt ddfce96d79809112d8253a8a82cc9bf11c3a1beb used |
aafdfde to
6096851
Compare
|
The following sections might be updated with supplementary metadata relevant to reviewers and maintainers. ConflictsReviewers, this pull request conflicts with the following ones:
If you consider this pull request important, please also help to review the conflicting pull requests. Ideally, start with the one that should be merged first. |
Github-Pull: bitcoin#15911 Rebased-From: 609685107bfb51d2ca8ab034694ad771ad267649
9a27860 to
9b1b9cf
Compare
|
utACK 9b1b9cf5632be18f3ad1bf2e10ebd004fceb2368 |
|
@Sjors Please squash the first and third commit, as they don't compile: |
|
@Sjors ^ 👀 |
|
Soon (TM), sorry for the delay. |
9b1b9cf to
f847fa9
Compare
|
Rebased and squashed first and last commit. @MarcoFalke hopefully good to go. |
meshcollider
left a comment
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.
Code review ACK f847fa961c29cf95416ba489d46d2a61368c7c61
f847fa9 to
07299aa
Compare
|
Fixed the typo. You can see the diff with: PREV=f847fa9 N=2 && git range-diff `git merge-base --all HEAD $PREV`...$PREV HEAD~$N...HEAD |
l2a5b1
left a comment
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.
ACK 4348388
+1 for finding this issue and fixing it. Feel free to ignore my review comments.
| #include <util/strencodings.h> | ||
|
|
||
| CMutableTransaction ConstructTransaction(const UniValue& inputs_in, const UniValue& outputs_in, const UniValue& locktime, const UniValue& rbf) | ||
| CMutableTransaction ConstructTransaction(const UniValue& inputs_in, const UniValue& outputs_in, const UniValue& locktime, bool rbf) |
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.
Will ConstructTransaction be moved out of the RPC module?
Without this change the issue could probably have been addressed with a small update in walletcreatefundedpsbt.
If ConstructTransaction stays in the RPC codebase forever then this change has also introduced duplicate code at two call sites for no reason.
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 expect more stuff to be moved out of the RPC over time, but for now this was the simplest fix, also easiest to backport.
promag
left a comment
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.
Concept ACK.
|
Moved to 0.18.2 |
17f0cb0 to
d6b3640
Compare
|
Rebased and addressed nits. |
|
Code Review ACK d6b3640 |
|
@MarcoFalke @l2a5b1 @meshcollider can you re-ACK? |
|
re-ACK d6b3640 |
|
ACK d6b3640 Show signature and timestampSignature: Timestamp of file with hash |
d6b3640 [test] walletcreatefundedpsbt: check RBF is disabled when -walletrbf=0 (Sjors Provoost) 9ed062b [doc] rpc: remove "fallback to" from RBF default help (Sjors Provoost) 4fcb698 [rpc] walletcreatefundedpsbt: use wallet default RBF (Sjors Provoost) Pull request description: The `walletcreatefundedpsbt` RPC call currently ignores `-walletrbf` and defaults to not use RBF. This PR fixes that. This PR also replaces UniValue in `ConstructTransaction` with a `bool` in preparation of moving this helper method out of the RPC codebase entirely. This may be a bit overkill, but does slightly simplify it. Fixes bitcoin#15878 ACKs for top commit: achow101: Code Review ACK d6b3640 l2a5b1: re-ACK d6b3640 MarcoFalke: ACK d6b3640 Tree-SHA512: 55b9bccd1ef36b54f6b34793017dc0721103099ad3761b3b04862291ee13d6915915d4dbb1a8567924fa56e5e95dfe10eec070e06701610e70c87f8ea92b2a00
d6b3640 [test] walletcreatefundedpsbt: check RBF is disabled when -walletrbf=0 (Sjors Provoost) 9ed062b [doc] rpc: remove "fallback to" from RBF default help (Sjors Provoost) 4fcb698 [rpc] walletcreatefundedpsbt: use wallet default RBF (Sjors Provoost) Pull request description: The `walletcreatefundedpsbt` RPC call currently ignores `-walletrbf` and defaults to not use RBF. This PR fixes that. This PR also replaces UniValue in `ConstructTransaction` with a `bool` in preparation of moving this helper method out of the RPC codebase entirely. This may be a bit overkill, but does slightly simplify it. Fixes bitcoin#15878 ACKs for top commit: achow101: Code Review ACK d6b3640 l2a5b1: re-ACK d6b3640 MarcoFalke: ACK d6b3640 Tree-SHA512: 55b9bccd1ef36b54f6b34793017dc0721103099ad3761b3b04862291ee13d6915915d4dbb1a8567924fa56e5e95dfe10eec070e06701610e70c87f8ea92b2a00
|
@Sjors Are you interested in backporting this? |
…etcreatefundedpsbt 576580f [test] walletcreatefundedpsbt: check RBF is disabled when -walletrbf=0 (Sjors Provoost) 0942a60 [doc] rpc: remove "fallback to" from RBF default help (Sjors Provoost) ee950ec [rpc] walletcreatefundedpsbt: use wallet default RBF (Sjors Provoost) Pull request description: Backport of #15911 for 0.18 branch. The original PR changed `rawtransaction_util.cpp`, whereas the backport changes `rawtransaction.cpp` to avoid having to also backport #15638. ACKs for top commit: meshcollider: re-utACK 576580f MarcoFalke: ACK 576580f Tree-SHA512: 51c40fc4db4f8739e93e931aeac572779d5ade0bfeb3bcb0082301cf73b4f48e31d4ccbe40421dc65d0ec091d6393685c0c9b8f76584c59249f13642e80a6da5
Github-Pull: bitcoin#15911 Partial-Rebased-From: 0580701e3e6503f0c3e6b844b2c0c48fa7c8caa4
d6b3640 [test] walletcreatefundedpsbt: check RBF is disabled when -walletrbf=0 (Sjors Provoost) 9ed062b [doc] rpc: remove "fallback to" from RBF default help (Sjors Provoost) 4fcb698 [rpc] walletcreatefundedpsbt: use wallet default RBF (Sjors Provoost) Pull request description: The `walletcreatefundedpsbt` RPC call currently ignores `-walletrbf` and defaults to not use RBF. This PR fixes that. This PR also replaces UniValue in `ConstructTransaction` with a `bool` in preparation of moving this helper method out of the RPC codebase entirely. This may be a bit overkill, but does slightly simplify it. Fixes bitcoin#15878 ACKs for top commit: achow101: Code Review ACK d6b3640 l2a5b1: re-ACK d6b3640 MarcoFalke: ACK d6b3640 Tree-SHA512: 55b9bccd1ef36b54f6b34793017dc0721103099ad3761b3b04862291ee13d6915915d4dbb1a8567924fa56e5e95dfe10eec070e06701610e70c87f8ea92b2a00
The
walletcreatefundedpsbtRPC call currently ignores-walletrbfand defaults to not use RBF. This PR fixes that.This PR also replaces UniValue in
ConstructTransactionwith aboolin preparation of moving this helper method out of the RPC codebase entirely. This may be a bit overkill, but does slightly simplify it.Fixes #15878