Very small set of changes to support PSBT-based fee bumping on watchonly wallets in QT.
quasi-companion to #16373
Very small set of changes to support PSBT-based fee bumping on watchonly wallets in QT.
quasi-companion to #16373
The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.
No conflicts as of last run.
@Sjors appears to be due to the forward declaration of SendCoinsRecipient
in qt/guiutil.h
, and is already somewhat covered in an exception:
"qt/guiutil -> qt/walletmodel -> qt/optionsmodel -> qt/guiutil"
If my reading is correct I propose to add this particular path to the exception list in lieu of a larger refactor which should get rid of both the exceptions:
"qt/guiutil -> qt/walletmodel -> qt/guiutil
526+ if (create_psbt) {
527+ PartiallySignedTransaction psbtx(mtx);
528+ bool complete = false;
529+ const TransactionError err = wallet().fillPSBT(psbtx, complete, SIGHASH_ALL, false /* sign */, true /* bip32derivs */);
530+ assert(!complete);
531+ assert(err == TransactionError::OK);
Code review ACK e3b19d8, nits/nice-to-haves:
QMessageBox::critical
instead of assert
. Are you sure it’s always safe to continue putting the PSBT on the clipboard after a failure?
Concept ACK on using
QMessageBox::critical
instead ofassert
. Are you sure it’s always safe to continue putting the PSBT on the clipboard after a failure?
Oh, indeed, there should be a “return false;” after the messagebox. This is what you get for making reasonable changes in response to review, Greg. :-(
ACK 3c30d7118a5d5cb40c3686e0da884d3928caaeba
nit: squash, but 3 ACKs, so meh.
Correct me if I’m wrong but I see 3 things that should be addressed later:
bumpFee
should not be in the wallet model - could follow same approach as WalletControllerActivity
- because IMO it’s wrong to open message boxes (any GUI change) or copy to clipboard from a model class;bumpFee
should be asynchronous - 1. above would help here - if from the GUI thread we hit cs_main or cs_wallet then that’s bad;Code review ACK 3c30d7118a5d5cb40c3686e0da884d3928caaeba.
I’ll address my concerns in a follow up.