Skip to content

Commit dfeb08f

Browse files
committed
Merge #753: Improve docs regarding PSBT finalization
8963e8c Improve docs w.r.t. PSBT finalization (Elias Rohrer) Pull request description: ### Description This PR includes just a few tiny changes to the docs trying to make it a bit more clear what PSBT finalization is and what to expect. ### Notes to the reviewers ### Changelog notice ### Checklists #### All Submissions: * [x] I've signed all my commits * [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk/blob/master/CONTRIBUTING.md) * [x] I ran `cargo fmt` and `cargo clippy` before committing ACKs for top commit: afilini: ACK 8963e8c Tree-SHA512: ea1a6c715c2832cdf3a428654fb8fad08a0549e46a808ca7a424590145fc2c40164ea08eb636ce5cd648dd6335480accd1d91f9e37e9397feaf0dac2015e8baa
2 parents 562cb81 + 8963e8c commit dfeb08f

File tree

2 files changed

+10
-5
lines changed

2 files changed

+10
-5
lines changed

src/wallet/mod.rs

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1196,7 +1196,12 @@ where
11961196
}
11971197
}
11981198

1199-
/// Try to finalize a PSBT
1199+
/// Finalize a PSBT, i.e., for each input determine if sufficient data is available to pass
1200+
/// validation and construct the respective `scriptSig` or `scriptWitness`. Please refer to
1201+
/// [BIP174](https://github.com/bitcoin/bips/blob/master/bip-0174.mediawiki#Input_Finalizer)
1202+
/// for further information.
1203+
///
1204+
/// Returns `true` if the PSBT could be finalized, and `false` otherwise.
12001205
///
12011206
/// The [`SignOptions`] can be used to tweak the behavior of the finalizer.
12021207
pub fn finalize_psbt(

src/wallet/signer.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -696,14 +696,14 @@ pub struct SignOptions {
696696
/// Defaults to `false` which will only allow signing using `SIGHASH_ALL`.
697697
pub allow_all_sighashes: bool,
698698

699-
/// Whether to remove partial_sigs from psbt inputs while finalizing psbt.
699+
/// Whether to remove partial signatures from the PSBT inputs while finalizing PSBT.
700700
///
701-
/// Defaults to `true` which will remove partial_sigs after finalizing.
701+
/// Defaults to `true` which will remove partial signatures during finalization.
702702
pub remove_partial_sigs: bool,
703703

704-
/// Whether to try finalizing psbt input after the inputs are signed.
704+
/// Whether to try finalizing the PSBT after the inputs are signed.
705705
///
706-
/// Defaults to `true` which will try fianlizing psbt after inputs are signed.
706+
/// Defaults to `true` which will try finalizing PSBT after inputs are signed.
707707
pub try_finalize: bool,
708708

709709
/// Specifies which Taproot script-spend leaves we should sign for. This option is

0 commit comments

Comments
 (0)