Skip to content

Expose way to select only (n-)confirmed UTXOs for TX creation #143

@tnull

Description

@tnull

Describe the enhancement
Add a way to create transactions with bdk::Wallet that only spend confirmed UTXOs.
This could easily be done by adding a corresponding must_only_use_confirmed_tx field to TxParams and ORing it into

https://github.com/bitcoindevkit/bdk/blob/81c76133911b3a99a4e1303052f96c858ca65cf5/crates/bdk/src/wallet/mod.rs#L1473

However, TxParams is currently pending exposure:
https://github.com/bitcoindevkit/bdk/blob/81c76133911b3a99a4e1303052f96c858ca65cf5/crates/bdk/src/wallet/tx_builder.rs#L129

Use case
This is needed to use BDK's coin selection for bumping transactions generated by LDK, in particular for https://docs.rs/lightning/0.0.116-alpha1/lightning/events/bump_transaction/trait.CoinSelectionSource.html#tymethod.select_confirmed_utxos

Metadata

Metadata

Assignees

Labels

new featureNew feature or request

Type

No type

Projects

Status

Done

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions