Releases: bitcoindevkit/bdk
Release 1.0.0-beta.1
Summary
This release includes the first beta version of bdk_wallet
with a stable 1.0.0 API. The changes in this version include reworked wallet persistence, changeset, and construction, optional user provided RNG, custom tx sorting, and use of merkle proofs in bdk_electrum.
What's Changed
- fix(wallet)!: Simplify
SignOptions
and improve finalization logic by @ValuedMammal in #1476 - feat(wallet): Allow user provided RNG, make rand an optional dependency by @rustaceanrob in #1395
- refactor(wallet): Use Psbt::sighash_ecdsa for computing sighashes by @ValuedMammal in #1424
- refactor(wallet)!: Use
Weight
type instead ofusize
by @oleonardolima in #1468 - refactor(wallet): Remove usage of
blockdata::
from bitcoin paths by @tcharding in #1490 - refactor(chain): calculate DescriptorId as the sha256 hash of spk at index 0 by @notmandatory in #1486
- refactor(chain)!: Change tx_last_seen to
Option<u64>
by @ValuedMammal in #1416 - refactor(wallet)!: Add support for custom sorting and deprecate BIP69 by @nymius in #1487
- refactor(chain)!: Create module
indexer
by @ValuedMammal in #1493 - chore(chain)!: Rename
Append
toMerge
by @LagginTimes in #1502 - refactor(wallet)!: Simplify public_descriptor(), remove redundant function by @gnapoli23 in #1503
- ci: pin cc dependency version to build with rust 1.63 by @LagginTimes in #1505
- feat(electrum)!: Update
bdk_electrum
to use merkle proofs by @LagginTimes in #1489 - refactor(wallet)!: rework persistence, changeset, and construction by @evanlinjin in #1514
- refactor(chain)!: Update KeychainTxOutIndex methods to use owned K and ScriptBuf by @rustaceanrob in #1506
- Bump bdk version to 1.0.0-beta.1 by @notmandatory in #1522
New Contributors
- @nymius made their first contribution in #1487
- @gnapoli23 made their first contribution in #1503
Full Changelog: v1.0.0-alpha.13...v1.0.0-beta.1
Release 1.0.0-alpha.13
Summary
This release includes major changes required to finalize the bdk_wallet 1.0.0 APIs, including: upgrading to rust-bitcoin 0.32 and rust-miniscript 0.12.0, constructing a Wallet now requires two descriptors (external and internal), the db field was removed from Wallet, staged changes can be persisted via a blocking or async data store.
Changelog
Fixed
- Fix KeychainTxOutIndex range-based methods. #1463
Changed
- Upgrade rust bitcoin to 0.32.0, miniscript to 0.12.0. #1448
- Use compute_txid() instead of deprecated txid().
- Use minimal_non_dust() instead of dust_value().
- Use signature and sighash_type fields, instead of previous sig and hash_type.
- Use sighash::P2wpkhError, and sighash::TaprootError instead of older sighash::Error.
- Converts from Network to NetworkKind, where expected.
- Converts from Weight type to current used usize.
- Use .into() to convert from AbsLockTime and RelLockTime to absolute::LockTime and relative::LockTime.
- Remove use of deprecated ThirtyTwoByteHash trait, use Message::from_digest().
- Update the miniscript policy and dsl macros to proper expect and handle new Threshold type, instead of the previous two parameters.
- Add further bitcoin::Amount usage on public APIs. #1426
- Updated CreateTxError::FeeTooLow to use bitcoin::Amount.
- Updated Wallet::calculate_fee(). to use bitcoin::Amount
- Updated TxBuilder::fee_absolute(). to use bitcoin::Amount.
- Updated CalculateFeeError::NegativeFee to use bitcoin::SignedAmount.
- Updated TxGraph::calculate_fee(). to use bitcoin::Amount.
- Updated PsbUtils::fee_amount() to use bitcoin::Amount.
- Wallet::get_balance() renamed to Wallet::balance(). #1455
- Constructing a Wallet now requires two distinct descriptors. #1390
- Removed duplicated
InsufficientFunds
error member. #1441 - Refactor wallet and persist mods, remove bdk_persist crate. #1454 and #1473
- Removed
db
fromWallet
, users are now responsible for persisting changes, see docs and examples. - Removed the
bdk_persist
crate. - Remove persist submodule from bdk_chain.
- Change Wallet to outsource it's persistence logic by introducing Wallet::take_staged.
- Add take convenience method to Append trait.
- Removed
What's Changed
- feat: add further
bitcoin::Amount
usage on public APIs by @oleonardolima in #1426 - refactor(wallet): rename get_balance() to balance() by @notmandatory in #1455
- refactor(electrum) put the tx cache in electrum by @LLFourn in #1453
- Make Wallet require a change descriptor by @ValuedMammal in #1390
- Remove duplicated InsufficientFunds error member by @e1a0a0ea in #1441
- ci: pin url dependency version to build with rust 1.63 by @notmandatory in #1470
- bump(deps): upgrade rust
bitcoin
to0.32.0
,miniscript
to0.12.0
and others by @oleonardolima in #1448 - No descriptor ids in spk txout index by @LLFourn in #1463
- Refactor wallet and persist mod, remove bdk_persist crate by @notmandatory in #1454
- fix: typo on
SignedAmount
instead ofAmount
by @oleonardolima in #1458 - Remove
persist
submodule by @evanlinjin in #1473 - Bump bdk version to 1.0.0-alpha.13 by @notmandatory in #1472
New Contributors
Full Changelog: v1.0.0-alpha.12...v1.0.0-alpha.13
Release 1.0.0-alpha.12
Summary
This bi-weekly release fixes an electrum syncing bug when calculating fees and adds the bdk_sqlite crate for storing wallet data in a SQLite tables. The Wallet::allow_shrinking function was also remove because it was too easy to misuse. Also the bdk
crate was renamed to bdk_wallet
. See the changelog for all the details.
Changelog
Fixed
- Fixed
calculate_fee
result when syncing with electrum. #1443
Changed
- Removed
TxBuilder::allow_shrinking()
function. #1386 - Renamed
bdk
crate tobdk_wallet
. #1326 - Update Wallet to use
CombinedChangeSet
for persistence. #1128
Added
- Add
CombinedChangeSet
in bdk_persist crate. #1128 - Add
bdk_sqlite
crate implementing SQLite based wallet data storage. #1128 - Update
bdk_wallet
export feature to support taproot descriptors. #1393
What's Changed
- chore: rename bdk crate to bdk_wallet by @notmandatory in #1326
- fix(electrum): Fix
fetch_prev_txout
by @ValuedMammal in #1443 - feat: add bdk_sqlite crate implementing PersistBackend by @notmandatory in #1128
- Remove TxBuilder allow_shrinking() and unneeded context param by @notmandatory in #1386
- fix(export): add tr descriptor by @rustaceanrob in #1393
- Bump bdk version to 1.0.0-alpha.12 by @notmandatory in #1450
Full Changelog: v1.0.0-alpha.11...v1.0.0-alpha.12
Release 1.0.0-alpha.11
Summary
This incremental bi-weekly release includes three big improvements. New electrum full_scan and sync APIs were added for more efficiently querying blockchain data. And the keychain::Changeset now includes public key descriptors and keychain::Balance uses bitcoin::Amount instead of u32 sats amounts. See the changelog for all the details.
Changelog
Changed
- Include the descriptor in keychain::Changeset #1203
- Update bdk_electrum crate to use sync/full-scan structs #1403
- Update keychain::Balance to use bitcoin::Amount #1411
- Change
bdk_testenv
to re-export internally used crates. #1414 - Updated documentation for
full_scan
andsync
inbdk_esplora
. #1427
What's Changed
- test(wallet): add thread safety test by @rustaceanrob in #1417
- docs(esplora): fixed
full_scan
andsync
documentation by @LagginTimes in #1427 - chore: clean up
electrsd
andanyhow
dev dependencies by @LagginTimes in #1414 - feat: update
keychain::Balance
to usebitcoin::Amount
by @oleonardolima in #1411 - fix(persist): add default feature to enable bdk_chain/std by @notmandatory in #1423
- ci: Pin clippy to rust 1.78.0 by @ValuedMammal in #1430
- Include the descriptor in
keychain::Changeset
by @danielabrozzoni in #1203 - Update
bdk_electrum
crate to use sync/full-scan structs by @LagginTimes in #1403 - Bump bdk version to 1.0.0-alpha.11 by @notmandatory in #1437
New Contributors
- @oleonardolima made their first contribution in #1411
Full Changelog: v1.0.0-alpha.10...v1.0.0-alpha.11
Release 1.0.0-alpha.10
Summary
This incremental bi-weekly release improves the address API, simplifies the Esplora API, and introduced new structures for spk-based scanning that will enable easier syncing with electrum/esplora. It also introduces a new bdk-persist crate, removes the generic T from the Wallet, and makes KeychainTxOutIndex more range based.
Changelog
Fixed
- Enable blocking-https-rustls feature on esplora client #1408
Changed
- KeychainTxOutIndex methods modified to take ranges of keychains instead. #1324
- Remove the generic from wallet #1387
- Changed PersistenceBackend errors to depend on the anyhow crate
- Remove the generic T from Wallet
- Improve address API #1402
- Added Wallet methods:
- peek_address
- reveal_next_address
- next_unused_address
- reveal_addresses_to
- list_unused_addresses
- mark_used
- unmark_used
- Removed Wallet methods:
- get_address
- get_internal_address
- try_get_address
- try_get_internal_address
- Added Wallet methods:
- Simplified EsploraExt API #1380
- Changed EsploraExt API so that sync only requires one round of fetching data. The local_chain_update method is removed and the local_tip parameter is added to the full_scan and sync methods.
- Removed TxGraph::missing_heights and tx_graph::ChangeSet::missing_heights_from methods.
- Introduced CheckPoint::insert which allows convenient checkpoint-insertion. This is intended for use by chain-sources when crafting an update.
- Refactored merge_chains to also return the resultant CheckPoint tip.
- Optimized the update LocalChain logic - use the update CheckPoint as the new CheckPoint tip when possible.
- Introduce
bdk-persist
crate #1412 - Introduce universal sync/full-scan structures for spk-based syncing #1413
- Add universal structures for initiating/receiving sync/full-scan requests/results for spk-based syncing.
- Updated bdk_esplora chain-source to make use of new universal sync/full-scan structures.
What's Changed
- [chain] Make KeychainTxOutIndex more range based by @LLFourn in #1324
- fix(wallet): remove the generic from wallet by @rustaceanrob in #1387
- [wallet] Improve address API by @ValuedMammal in #1402
- Fix: enable blocking-https-rustls feature on esplora client by @thunderbiscuit in #1408
- Simplified
EsploraExt
API by @evanlinjin in #1380 - Add new crate
bdk-persist
by @rustaceanrob in #1412 - Introduce universal sync/full-scan structures for spk-based syncing by @evanlinjin in #1413
- fix: Cargo clippy lints by @danielabrozzoni in #1421
- Bump bdk version to 1.0.0-alpha.10 by @danielabrozzoni in #1420
New Contributors
- @rustaceanrob made their first contribution in #1387
Full Changelog: v1.0.0-alpha.9...v1.0.0-alpha.10
Release 1.0.0-alpha.9
Summary
This regular bi-weekly alpha release updates dependencies rust-bitcoin to v0.31.0 and rust-miniscript to v11.0.0 plus replaces the deprecated rust-miniscript function max_satisfaction_weight with max_weight_to_satisfy. It also adds chain module improvements needed to simplify syncing with electrum and esplora blockchain clients.
Changelog
Fixed
- Replace the deprecated max_satisfaction_weight from rust-miniscript to max_weight_to_satisfy. #1345
Changed
- Update dependencies: rust-bitcoin to v0.31.0 and rust-miniscript to v11.0.0. #1177
- Changed TxGraph to store transactions as Arc. This allows chain-sources to cheaply keep a copy of already-fetched transactions. #1373
- Add get and range methods to CheckPoint #1369
- Added get and range methods to CheckPoint (and in turn, LocalChain). This simulates an API where we have implemented a skip list of checkpoints (to implement in the future). This is a better API because we can query for any height or height range with just a checkpoint tip instead of relying on a separate checkpoint index (which needs to live in LocalChain).
- Changed LocalChain to have a faster Eq implementation. We now maintain an xor value of all checkpoint block hashes. We compare this xor value to determine whether two chains are equal.
- Added PartialEq implementation for CheckPoint and local_chain::Update.
- Methods into_tx_graph and into_confirmation_time_tx_graph for RelevantTxids are changed to no longer accept a seen_at parameter. #1385
- Added method update_last_seen_unconfirmed for TxGraph.
- Added proptest for CheckPoint::range. #1397
What's Changed
- Wrap transactions as
Arc<Transaction>
inTxGraph
by @evanlinjin in #1373 - fix: remove deprecated max_satisfaction_weight by @storopoli in #1345
- feat(chain): add
get
andrange
methods toCheckPoint
by @evanlinjin in #1369 - Fix last seen unconfirmed by @ValuedMammal in #1385
- Introduce proptesting, starting with
CheckPoint::range
by @evanlinjin in #1397 - Upgrade bitcoin/miniscript dependencies by @tcharding in #1177
- Bump bdk version to 1.0.0-alpha.9 by @notmandatory in #1404
Full Changelog: v1.0.0-alpha.8...v1.0.0-alpha.9
Release 1.0.0-alpha.8
Summary
This incremental bi-weekly release migrates API to use the rust-bitcoin FeeRate type, fixes PSBT finalization to remove extra taproot fields, and fixes blockchain scanning stop_gap definition and documentation. We recommend all 1.0.0-alpha users upgrade to this release.
Changelog
Fixed
Changed
What's Changed
- Explicitly state that we truncate file for
create_new
by @evanlinjin in #1384 - Migrate to bitcoin::FeeRate by @ValuedMammal in #1216
- Remove extra taproot fields when finalizing PSBT by @ValuedMammal in #1310
- Update bdk README by @ValuedMammal in #1378
- chore: extract
TestEnv
into separate crate by @LagginTimes in #1171 - fix: define and document
stop_gap
by @storopoli in #1351 - Fix cargo manifest for
bdk_testenv
by @evanlinjin in #1391 - Bump bdk version to 1.0.0-alpha.8 by @notmandatory in #1389
Full Changelog: v1.0.0-alpha.7...v1.0.0-alpha.8
Release 1.0.0-alpha.7
Summary
This incremental bi-weekly release includes an API change to relax the generic requirements on the wallet transaction builder and a small fix when manually looking ahead to unrevealed scripts. Unless you need one of these changes there's no need to upgrade to this release.
Changelog
Fixed
- Fix
KeychainTxOutIndex::lookahead_to_target
to look ahead to correct index. #1349
Changed
- Relax the generic requirements on
TxBuilder
. #1312
What's Changed
- Add
map_anchors
forTxGraph
by @yanganto in #1325 - ci: Remove jobserver pin by @danielabrozzoni in #1357
- tx_builder: Relax generic constraints on TxBuilder by @stevenroose in #1344
- Fix
KeychainTxOutIndex::lookahead_to_target
by @evanlinjin in #1349 - Bump bdk version to 1.0.0-alpha.7 by @notmandatory in #1365
New Contributors
Full Changelog: v1.0.0-alpha.6...v1.0.0-alpha.7
Release 1.0.0-alpha.6
Summary
This small bi-weekly release fixes TxBuilder to support setting explicit nSequence for foreign inputs and a bug in tx_graph::ChangeSet::is_empty where is returns true even when it wasn't empty 🙈. We also added a new option for Esplora APIs to include floating TxOuts in pudates for fee calculations.
Changelog
Fixed
- TxBuilder now supports setting explicit nSequence for foreign inputs. #1316
- Fix bug in tx_graph::ChangeSet::is_empty where is returns true even when it wasn't empty. #1335
Added
- New Option for Esplora APIs to include floating TxOuts in updates for fee calculation. #1308
What's Changed
- Clean up clippy allows by @ValuedMammal in #1186
- chore: typos by @storopoli in #1319
- tx_builder: Support setting explicit nSequence for foreign inputs by @stevenroose in #1316
- feat(esplora): include previous
TxOut
s for fee calculation by @LagginTimes in #1308 - Reorder fields in ConfirmationHeightAnchor fields so Ord DWIM by @LLFourn in #1334
- fix(chain): tx_graph::ChangeSet::is_empty by @LLFourn in #1335
- Bump bdk version to 1.0.0-alpha.6 by @notmandatory in #1347
New Contributors
- @stevenroose made their first contribution in #1316
Full Changelog: v1.0.0-alpha.5...v1.0.0-alpha.6
Release 1.0.0-alpha.5
Summary
This release introduces a block-by-block API to bdk::Wallet and adds a RPC wallet example, improves performance of bdk_file_store::EntryIter, and simplifies Esplora::update_local_chain with additional tests. See release notes for all the details.
Changelog
Fixed
InsertTxError
now implementsstd::error::Error
. #1172- Simplified
EsploraExt::update_local_chain
logic. #1267
Changed
EntryIter
performance is improved by reducing syscalls. #1270- Changed to implement
ElectrumExt
for all that implementsElectrumApi
. #1306
Added
Wallet
methods to apply full blocks (apply_block
andapply_block_connected_to
) and a method to apply a batch of unconfirmed transactions (apply_unconfirmed_txs
). #1172CheckPoint::from_block_ids
convenience method. #1172LocalChain
methods to apply a block header (apply_header
andapply_header_connected_to
). #1172- Test to show that
LocalChain
can apply updates that are shorter than original. This will happen during reorgs if we sync wallet withbdk_bitcoind_rpc::Emitter
. #1172
What's Changed
- Introduce block-by-block API to
bdk::Wallet
and add RPC wallet example by @vladimirfomene in #1172 - fix(store): Remove lifetime by @LLFourn in #1292
- doc(wallet): improve docs for
Wallet::sent_and_received
by @ValuedMammal in #1285 - doc(esplora): fix broken link in README by @ValuedMammal in #1288
- doc(chain,esplora): minor documentation improvements by @ValuedMammal in #1291
- doc(electrum_ext): fix docs for `RelevantTxids::into_confirmation_tim… by @ValuedMammal in #1289
- fix(readme): update examples by @storopoli in #1277
- Remove deprecated checksum routines by @theStack in #1253
- Expose
SpkIterator::new_with_range
by @evanlinjin in #1294 - Improve performance of
bdk_file_store::EntryIter
by @evanlinjin in #1270 - chain: set
DEFAULT_LOOKAHEAD
to 25 by @yukibtc in #1296 - Fix
ConfirmationTime
conversion fromChainPosition
by @evanlinjin in #1301 - fix(file_store): rm lifetime from
FileError
by @evanlinjin in #1299 - doc(example_cli): add missing cli docs by @ValuedMammal in #1290
- doc(store): update doc for
Store::aggregate_changesets
by @ValuedMammal in #1287 - Filter duplicate coins before coin selection by @evanlinjin in #1279
- Simplify
Esplora::update_local_chain
and add tests by @evanlinjin in #1267 - Implement
ElectrumExt
for all that implementsElectrumApi
by @evanlinjin in #1306 - Bump version to 1.0.0-alpha.5 by @notmandatory in #1307
New Contributors
Full Changelog: v1.0.0-alpha.4...v1.0.0-alpha.5