]> Untitled Git - bdk/log
bdk
18 hours agoMerge bitcoindevkit/bdk#2262: fix(chain): let the indexer decide how far to rescan master github/master
merge-script [Wed, 2 Sep 2026 00:52:43 +0000 (00:52 +0000)]
Merge bitcoindevkit/bdk#2262: fix(chain): let the indexer decide how far to rescan

f08eeac1547e4a4585933989573ede4db4dcb9ba fix(chain): let the indexer decide how far to rescan (LLFourn)

Pull request description:

  ### Description

  `IndexedTxGraph::reindex` was a single pass over `TxGraph::full_txs`, which iterates a `HashMap`. That made it **nondeterministic**: the same graph reindexed twice could produce two different `last_revealed` results.

  Each match inside `KeychainTxOutIndex::_index_txout` bumps `last_revealed` and then calls `replenish_inner_index`, whose stop index is `last_revealed + 1 + lookahead`. So a match *widens the derived window the remaining outputs are judged against*. An output far enough out to need that widening was skipped if it happened to be visited first, and no pass revisited it.

  Concretely, with `lookahead` 1000 and an empty frontier the derived set is `0..1001`. Given one tx paying index 900 and another paying 1850: visited 900-first, the window grows to 1901 and both are found; visited 1850-first, 1850 is missed and stays missed. Same inputs, different index, decided by `HashMap` iteration order.

  The usual objection — that callers should reveal before reindexing — does not hold. The lookahead exists precisely to catch indices the persisted frontier does not know about: a restored wallet, another signer on the same descriptor, an externally built PSBT paying one of our far indices. Whenever the lookahead does its job the frontier moves mid-walk, so the order dependence is present in the intended use, not just in misuse.

  ### The change

  Add `Indexer::rescan`, handed the whole `TxGraph` and returning the indexing it produced:

  ```rust
  fn rescan<A>(&mut self, graph: &TxGraph<A>) -> Self::ChangeSet
  where
      Self::ChangeSet: Merge,
  ```

  The default implementation offers every full transaction and floating output to `index_tx` / `index_txout` exactly once — all an indexer needs when what it recognizes is fixed up front — and `IndexedTxGraph::reindex` becomes a call to it. `KeychainTxOutIndex` overrides it and looks repeatedly, stopping when a pass leaves its revealed frontier unmoved.

  Whether to look more than once belongs to the indexer, because the indexer is the only thing that knows whether its recognition set can still grow. Two things follow from putting it there rather than in `IndexedTxGraph`:

  - **An indexer that does not widen what it matches is walked exactly once**, as today. `SpkTxOutIndex` is unaffected. There is no convergence requirement imposed on implementors, and no way for a third-party indexer to be spun forever by a loop it never asked for.
  - **`KeychainTxOutIndex` can key the loop on its own frontier** rather than on whether a changeset came back empty. That matters: the changeset also carries staged spk cache entries, which move *without* the frontier moving. A `changeset.is_empty()` loop therefore spends an extra full walk on the ordinary restore path. I measured this — with `persist_spks = true`, restoring via `from_changeset` with a correct frontier takes **1 pass** keyed on the frontier versus **2** keyed on changeset emptiness.

  ### Notes to the reviewers

  **On the test shape.** The regression test uses **one** transaction with two of our outputs rather than two transactions. A two-transaction test would depend on graph walk order — the very thing that is unreliable — and so would pass a single-pass implementation about half the time, which is a test that fails to fail. `index_tx` walks `tx.output`, a `Vec`, in vout order, so a single tx paying a far index at vout 0 and a near one at vout 1, against an empty frontier, misses the far output on every pass on every run. It is deterministic by construction; I verified it fails against the old implementation on five consecutive runs (`left: Some(9)`, `right: Some(15)`).

  **On cost.** `KeychainTxOutIndex::rescan` re-walks the whole graph per look, so it is O(looks × txs), with looks bounded by the number of distinct frontier advances plus one. Measured: the settled/restore case is 1 look; the recovery case in the test (empty frontier, far output only reachable after the near one lands) is 3. Making a later look re-examine only the outputs that did not already match would need the indexer to say *what* to re-offer rather than just *whether*, which is a bigger change than this fix.

  **Trait change.** `rescan` is a defaulted method, so existing `Indexer` implementations keep compiling unchanged. It is generic over the anchor `A`, which makes `Indexer` no longer object-safe — nothing in the workspace uses `dyn Indexer`.

  **Known adjacent gap, not addressed here.** `index_tx_graph_changeset` — used by `insert_tx`, `insert_txout`, `apply_update` and `apply_block_relevant` — is still a single pass and has the same order dependence. Feeding the one-transaction case above through `insert_tx` yields `last_revealed = Some(9)` and only one of the two outpoints, so a live wallet can drop the far UTXO until the next restart re-runs `reindex`. It needs the incremental paths to go through the same mechanism rather than their own copy; I kept this PR to `reindex` to stay reviewable, and am happy to follow up.

  ### Changelog notice

  - Added: `Indexer::rescan`, which indexes an entire `TxGraph` and lets an implementation decide how many looks that takes. Defaulted, so existing implementations are unaffected.
  - Fixed: `IndexedTxGraph::reindex` no longer depends on `HashMap` iteration order. It previously made a single pass and could miss outputs at derivation indices that only came into range after another output in the same walk advanced the lookahead; `KeychainTxOutIndex` now looks until its revealed frontier stops moving.

  ### Checklists

  #### All Submissions:

  * [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk/blob/master/CONTRIBUTING.md)

  #### New Features:

  * [x] I've added tests for the new feature
  * [x] I've added docs for the new feature

  #### Bugfixes:

  * [ ] This pull request breaks the existing API
  * [x] I've added tests to reproduce the issue which are now passing

ACKs for top commit:
  evanlinjin:
    ACK f08eeac1547e4a4585933989573ede4db4dcb9ba

Tree-SHA512: 0c5496805655a2c0f060e26bacd05a48adb2866961a9b785b53b444572a5b2e7f78ad0ddbcb737a308be5e1958bb0c49c09ed1e56fb30d029e06661f9e10a953

18 hours agofix(chain): let the indexer decide how far to rescan
LLFourn [Wed, 19 Aug 2026 05:15:39 +0000 (15:15 +1000)]
fix(chain): let the indexer decide how far to rescan

`IndexedTxGraph::reindex` was a single pass over `TxGraph::full_txs`,
which iterates a `HashMap`, so the same graph reindexed twice could
produce two different `last_revealed` results. Each match inside
`KeychainTxOutIndex::_index_txout` bumps `last_revealed` and replenishes
the lookahead, widening the derived window the remaining outputs are
judged against. An output far enough out to need that widening was
skipped whenever it happened to be visited first, and no pass revisited
it.

This is not merely misuse of the API. The lookahead exists precisely to
catch indices the persisted frontier does not know about -- a restored
wallet, another signer on the same descriptor, an externally built PSBT
paying one of our far indices -- so whenever it does its job the frontier
moves mid-walk, and the order dependence is present in the intended use.

Add `Indexer::rescan`, which is handed the whole graph and returns what
indexing it produced. The default implementation offers every full
transaction and floating output once, which is all an indexer needs when
what it recognizes is fixed up front; `reindex` becomes a call to it.
`KeychainTxOutIndex` overrides it and looks repeatedly, stopping when a
pass leaves its revealed frontier unmoved.

Putting the loop behind the trait rather than in `IndexedTxGraph` keeps
the decision where the knowledge is. An indexer that does not widen
what it matches is walked exactly once, as before, so the looping
cannot leak into implementations that have no use for it. And
`KeychainTxOutIndex` can key the loop on its own frontier instead of on
whether a changeset came back empty: the changeset also carries staged
spk cache entries, which move without the frontier moving, so an
emptiness test spends an extra full walk on the ordinary restore path.

The regression test uses a single transaction with both outputs rather
than two transactions, because the graph's walk order is a `HashMap`
order: a two-transaction test would pass a single-pass implementation
about half the time. `index_tx` walks `tx.output` in vout order, so the
far index at vout 0 is always judged against the initial window and
always missed until the near index at vout 1 lifts the frontier.

2 weeks agoMerge bitcoindevkit/bdk#2257: fix: fix command order for importing GPG key
merge-script [Mon, 17 Aug 2026 07:49:39 +0000 (07:49 +0000)]
Merge bitcoindevkit/bdk#2257: fix: fix command order for importing GPG key

3474e0c6d02e527c1f8a38660191e243026dac0d fix: fix command order for importing GPG key (Carlos Marques)

Pull request description:

  ### Fix

  Options order wrong. `--recv-keys` eat everything after as key IDs.
  Put `--keyserver` first.

ACKs for top commit:
  thunderbiscuit:
    ACK 3474e0c6d02e527c1f8a38660191e243026dac0d. Tested and our current line is indeed incorrect; proposed fix works.
  luisschwab:
    ACK 3474e0c6d02e527c1f8a38660191e243026dac0d
  evanlinjin:
    ACK 3474e0c6d02e527c1f8a38660191e243026dac0d

Tree-SHA512: 6f31c18a21507260fd207757bf06fb4660459a35002f3020ac1b1651c4441389495564a84317a25046d49f5af8458a56e9874a0b1d32b729b791c18ab138b4ce

3 weeks agofix: fix command order for importing GPG key
Carlos Marques [Tue, 11 Aug 2026 13:54:19 +0000 (14:54 +0100)]
fix: fix command order for importing GPG key

3 weeks agoMerge bitcoindevkit/bdk#2255: Add GH security advisory link on SECURITY.md
merge-script [Wed, 5 Aug 2026 22:02:30 +0000 (19:02 -0300)]
Merge bitcoindevkit/bdk#2255: Add GH security advisory link on SECURITY.md

a98ab189340c6ed2a2fbc91ee6d8178950e09b6b chore(doc): add GH security advisory link on SECURITY.md (Luis Schwab)

Pull request description:

  Link to GitHub's security advisory page on `SECURITY.md`

ACKs for top commit:
  oleonardolima:
    ACK a98ab189340c6ed2a2fbc91ee6d8178950e09b6b

Tree-SHA512: 2e25062934d717f05c6a567d33ca27445594eafbb6aeefc648c5108a0d7631f4cac30861e857f28d88fb501ac72ef24f4fef6814144e659c60edbde7657108ec

3 weeks agochore(doc): add GH security advisory link on SECURITY.md
Luis Schwab [Wed, 5 Aug 2026 20:03:54 +0000 (17:03 -0300)]
chore(doc): add GH security advisory link on SECURITY.md

5 weeks agoMerge bitcoindevkit/bdk#2240: fix(chain): skip evicted txs in leftover canonicalization
merge-script [Fri, 24 Jul 2026 10:10:25 +0000 (10:10 +0000)]
Merge bitcoindevkit/bdk#2240: fix(chain): skip evicted txs in leftover canonicalization

2a8512b15706e3f05a4a506af0293c2d33d12581 fix(chain): skip evicted leftover transactions (Noah Joeris)
9e404720bbc0ba462a661141c01325815aa6c180 feat(chain): add TxNode::is_evicted (Noah Joeris)

Pull request description:

  ### Description

  `CanonicalStage::LeftOverTxs` doesn't filter evicted txs and can mark them canonical. So a stale-anchored tx that was evicted/replaced could still show as unconfirmed.

  Example: a tx confirms, then a reorg leaves only a stale anchor. Leftover treats it as unconfirmed. If it's later RBF'd or missing from the mempool, leftover still marks it unconfirmed.

  ### Changelog notice
  - Add `TxNode::is_evicted()` for determining mempool eviction state.
  - Skip evicted transactions during leftover canonicalization.

  ### Checklists

  #### All Submissions:

  * [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk/blob/master/CONTRIBUTING.md)

  #### Bugfixes:

  * [ ] This pull request breaks the existing API
  * [x] I've added tests to reproduce the issue which are now passing
  * [ ] I'm linking the issue being fixed by this PR

ACKs for top commit:
  evanlinjin:
    ACK 2a8512b15706e3f05a4a506af0293c2d33d12581

Tree-SHA512: 615a46406600115210a272668b01e9a85a6d6fbbcc9d055cf83617fcc5c6e742f845b57e34277e26ecdffe41f39b01576ae038cd7eed5ce916fcb505b58fc8e8

6 weeks agofix(chain): skip evicted leftover transactions
Noah Joeris [Wed, 22 Jul 2026 19:23:11 +0000 (22:23 +0300)]
fix(chain): skip evicted leftover transactions

6 weeks agofeat(chain): add TxNode::is_evicted
Noah Joeris [Wed, 22 Jul 2026 19:22:54 +0000 (22:22 +0300)]
feat(chain): add TxNode::is_evicted

7 weeks agoMerge bitcoindevkit/bdk#2209: ci: individual package tests
merge-script [Mon, 13 Jul 2026 21:08:22 +0000 (17:08 -0400)]
Merge bitcoindevkit/bdk#2209: ci: individual package tests

2185dcbb31d512d708e8c117c5b1a429ff52ce81 ci: Update cont_integration.yml (valued mammal)

Pull request description:

  Close #1944

  ### Description

  Replaces the monolithic `build-test` matrix job (which ran a 2-toolchain × 2-feature-set matrix across the whole workspace) with dedicated per-crate build jobs. Each crate uses named steps for every meaningful feature combination, making it easy to identify which specific crate and feature set broke in CI.

  **Changes:**

  - **Per-crate jobs**: `build-core`, `build-chain`, `build-bitcoind-rpc`, `build-electrum`, `build-esplora`, `build-file-store`, `build-testenv` — each with per-feature `cargo build` steps and a `cargo test --all-features` step
  - **`msrv` job**: Simplified from a matrix to a single flat job targeting 1.85.0; runs `cargo build --workspace --all-targets` and `cargo test --workspace --lib --tests --all-features`
  - **`check-no-std`**: Updated to check `bdk_core` and `bdk_chain` with no default features + with `hashbrown` and `miniscript`; cross-compilation against `thumbv6m-none-eabi` is stubbed out as usual to be addressed in a separate PR

Top commit has no ACKs.

Tree-SHA512: d912a967ded7eb23bb25dbe6c59f11361b34e2cd77d1c6f3971b02261b4169ec96ab69bf68e6b667530120d8f75610bd85bfbc7da47d9d8cdf79d54ba4b1cb01

7 weeks agoci: Update cont_integration.yml
valued mammal [Fri, 15 May 2026 21:47:34 +0000 (17:47 -0400)]
ci: Update cont_integration.yml

Added workspace level MSRV job.

Added per-crate jobs to build meaningful feature
combinations and test all features.

Removed build-test job.

7 weeks agoMerge bitcoindevkit/bdk#2210: docs(rpc): add Emitter::next_block and Emitter::mempool...
merge-script [Sat, 11 Jul 2026 22:50:43 +0000 (18:50 -0400)]
Merge bitcoindevkit/bdk#2210: docs(rpc): add Emitter::next_block and Emitter::mempool examples

30fa17955b16d6a5a435bea8e2b9728e9e0b3701 docs(rpc): add Emitter::next_block and Emitter::mempool examples (Kyle 🐆)

Pull request description:

  Adds `# Example` rustdoc to `Emitter::next_block` and `Emitter::mempool`, which were flagged as missing in the #2006 review.

  Originally this PR also removed `example_bitcoind_rpc_polling`, but #2006 has since merged and removed all example crates, so that part is dropped after rebase. Only the doc additions remain.

  Part of the #2006 follow-up to document the components previously covered by the `examples/` crates.

ACKs for top commit:
  ValuedMammal:
    ACK 30fa17955b16d6a5a435bea8e2b9728e9e0b3701

Tree-SHA512: 28ade24c33f9714f94282a4594024bff9ed304c461b477b7ba5e95de64fbc5951c23a6a93ee623cc764e1e31971aaccac3aaebe4f615637d5b2de6d56bc32b56

7 weeks agodocs(rpc): add Emitter::next_block and Emitter::mempool examples
Kyle 🐆 [Sat, 23 May 2026 18:59:47 +0000 (14:59 -0400)]
docs(rpc): add Emitter::next_block and Emitter::mempool examples

2 months agoMerge bitcoindevkit/bdk#2203: ci: automated update to rustc 1.96.0
merge-script [Mon, 15 Jun 2026 17:49:37 +0000 (14:49 -0300)]
Merge bitcoindevkit/bdk#2203: ci: automated update to rustc 1.96.0

c1cffa3fd6b55f2fc0c862fd059ca1fa427a025c ci: automated update to rustc 1.96.0 (Github Action)

Pull request description:

  Automated update to Github CI workflow `cont_integration.yml` by [create-pull-request](https://github.com/peter-evans/create-pull-request) GitHub action

ACKs for top commit:
  oleonardolima:
    ACK c1cffa3fd6b55f2fc0c862fd059ca1fa427a025c

Tree-SHA512: 28f681fe56bfee891c06c8d324cc89b6af9fb40af976ad5eebfe89e8ee0c2ea7d5ad0c9ad1d2849d77c4fc202474b8032285bf4b42a5f8f544a86e5e6a115c71

2 months agoci: automated update to rustc 1.96.0
Github Action [Mon, 15 Jun 2026 03:43:59 +0000 (03:43 +0000)]
ci: automated update to rustc 1.96.0

2 months agoMerge bitcoindevkit/bdk#2038: refactor(chain,core)!: replace `CanonicalIter` with...
merge-script [Mon, 15 Jun 2026 12:42:14 +0000 (09:42 -0300)]
Merge bitcoindevkit/bdk#2038: refactor(chain,core)!: replace `CanonicalIter` with sans-IO `CanonicalTask` + `ChainQuery` trait

555f774169ea934dbb2934f2fbe6763908e86670 fix(chain): position resolution for assumed txs (Leonardo Lima)
4f10cdef4d55139ee7f608d9cf90ff8d9c0b3037 chore(chain,example)!: remove `ChainOracle`, update docs (志宇)
a3c73e4685f3381b5b1ae799c2279009b6f7d1ea refactor(chain)!: split `canonical_view` into `canonical`,`canonical_view_task` (志宇)
22b04c33dc0b75e5a247f99087ad36f41e99a0ed refactor(chain)!: split canonicalization into two tasks with generic `Canonical<A, P>` (志宇)
a9f5ca4415af36b42cca43551414ad0644d627b8 refactor(chain)!: remove `CanonicalIter` APIs (Leonardo Lima)
bb83da8260fb167fa548f31c12710153095e9064 chore(workspace): use new `LocalChain::canonical_view` API (Leonardo Lima)
987da73fce7b7f4e015aa05cc8fa4e36deebf4df feat(core,chain): introduce `CanonicalizationTask` and `ChainQuery` (Leonardo Lima)

Pull request description:

  fixes #1816

  ### Description

  Replaces the iterator-based `CanonicalIter` with a two-phase sans-IO canonicalization pipeline, and introduces a generic `ChainQuery` trait in `bdk_core` to decouple canonicalization from chain sources.

  **Old API:**
  ```rust
  // Direct coupling between canonicalization logic and ChainOracle
  let view = tx_graph.canonical_view(&chain, chain_tip, params)?;
  ```

  **New API:**
  ```rust
  // Option A: Two-phase (full control)
  let canonical_txs = chain.canonicalize(tx_graph.canonical_task(tip, params));
  let view = chain.canonicalize(canonical_txs.view_task(&tx_graph));

  // Option B: Convenience method
  let view = chain.canonical_view(&tx_graph, tip, params);
  ```

  #### Phase 1: `CanonicalTask`
  Determines which transactions are canonical by processing them in stages:
  1. **Assumed txs** — transactions assumed canonical via `CanonicalParams`
  2. **Anchored txs** — transactions anchored in the best chain (descending height)
  3. **Seen txs** — unconfirmed transactions by descending last-seen time
  4. **Remaining txs** — leftover anchored transactions not in the best chain

  Produces a `CanonicalTxs<A>` containing each canonical transaction with its `CanonicalReason`.

  #### Phase 2: `CanonicalViewTask`
  Resolves `CanonicalReason`s into concrete `ChainPosition`s (confirmed height or unconfirmed with last-seen), producing the final `CanonicalView<A>`.

  Both phases implement the `ChainQuery` trait, so any chain source can drive them via the same `next_query`/`resolve_query` loop.

  #### Key structural changes

  - **`ChainQuery` trait** added to `bdk_core` — a generic sans-IO interface (`next_query` → `resolve_query` → `finish`) for any algorithm that needs to verify blocks against a chain source.
  - **`ChainOracle` trait removed** — replaced by `ChainQuery`. `LocalChain::canonicalize()` now drives any `ChainQuery` implementor.
  - **`Canonical<A, P>` generic container** — `CanonicalTxs<A>` (phase 1 output) and `CanonicalView<A>` (phase 2 output) are type aliases over `Canonical<A, P>`.
  - **Module split** — `canonical_view.rs` split into `canonical.rs` (types: `Canonical`, `CanonicalTx`, `CanonicalTxOut`) and `canonical_view_task.rs` (phase 2 task). `canonical_iter.rs` replaced by `canonical_task.rs`.

  ### Notes to the reviewers

  The changes are split into multiple commits for easier review. Also depends on #2029.

  ### Changelog notice

  ```
    ### Added
    - `bdk_core::ChainQuery` trait — generic sans-IO interface for chain verification queries
    - `bdk_core::ChainRequest` / `ChainResponse` type aliases
    - `CanonicalTask` — phase 1 sans-IO canonicalization (determines canonical txs)
    - `CanonicalViewTask` — phase 2 sans-IO canonicalization (resolves chain positions)
    - `Canonical<A, P>` generic container with `CanonicalTxs<A>` and `CanonicalView<A>` aliases
    - `LocalChain::canonicalize()` — drives any `ChainQuery` implementor
    - `LocalChain::canonical_view()` — convenience method for full two-phase canonicalization

    ### Changed
    - **Breaking:** Replace `TxGraph::canonical_iter()` / `TxGraph::canonical_view()` with `TxGraph::canonical_task()`
    - **Breaking:** Canonicalization now uses a two-phase sans-IO process via `ChainQuery`
    - **Breaking:** `ChainQuery`, `ChainRequest`, `ChainResponse` have no generics (use `BlockId` directly)
    - **Breaking:** Chain tip moved from `ChainRequest` to `ChainQuery::tip()`

    ### Removed
    - **Breaking:** `ChainOracle` trait and all implementations
    - **Breaking:** `CanonicalIter` type and `canonical_iter` module
    - **Breaking:** `TxGraph::try_canonical_view()` and `TxGraph::canonical_view()` methods
    - **Breaking:** `CanonicalView::new()` public constructor
  ```

  ### Checklists

  #### All Submissions:

  * [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk/blob/master/CONTRIBUTING.md)

  #### New Features:

  * [x] I've added tests for the new feature
  * [x] I've added docs for the new feature

ACKs for top commit:
  evanlinjin:
    ACK 555f774169ea934dbb2934f2fbe6763908e86670

Tree-SHA512: ce466a623a1f8df20dedd3e4e68460892bd369567db44e6ba391c3d9ae1d10bca6204ebdcdb7b1376a9c97f3155b89e991846af4122e200d1fa15d998deb7830

2 months agofix(chain): position resolution for assumed txs
Leonardo Lima [Mon, 16 Mar 2026 23:01:22 +0000 (20:01 -0300)]
fix(chain): position resolution for assumed txs

- add new `test_canonical_view_task.rs` to handle different scenarios
  of chain position resolution.
- fixes the assumed canonical txs chain position resolution, especially for transitively
  assumed canonical transactions, where there's an anchored/confirmed descendant.

2 months agochore(chain,example)!: remove `ChainOracle`, update docs
志宇 [Sun, 8 Mar 2026 23:50:34 +0000 (23:50 +0000)]
chore(chain,example)!: remove `ChainOracle`, update docs

2 months agorefactor(chain)!: split `canonical_view` into `canonical`,`canonical_view_task`
志宇 [Fri, 13 Feb 2026 14:43:13 +0000 (14:43 +0000)]
refactor(chain)!: split `canonical_view` into `canonical`,`canonical_view_task`

It moves the shared types: `CanonicalTx`, `Canonical`, `CanonicalView`,
`CanonicalTxs` and other convenience methods into `canonical.rs`.

Keep the phase-2 task (`CanonicalViewTask` in `canonical_view_task.rs`.

Also, rename `FullTxOut` to `CanonicalTxOut`, and move it to
`canonical.rs`.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2 months agorefactor(chain)!: split canonicalization into two tasks with generic `Canonical<A...
志宇 [Fri, 13 Feb 2026 12:57:39 +0000 (12:57 +0000)]
refactor(chain)!: split canonicalization into two tasks with generic `Canonical<A, P>`

Separate concerns by splitting `CanonicalizationTask` into two phases:

1. `CanonicalTask` determines which transactions are canonical and why
   (`CanonicalReason`), outputting `CanonicalTxs<A>`.
2. `CanonicalViewTask` resolves reasons into `ChainPosition`s (confirmed
   vs unconfirmed), outputting `CanonicalView<A>`.

Make `Canonical<A, P>`, `CanonicalTx<P>`, and `FullTxOut<P>` generic over
the position type so the same structs serve both phases. Add
`LocalChain::canonical_view()` convenience method for the common two-step
pipeline.

Renames:

- `CanonicalizationTask` -> `CanonicalTask`
- `CanonicalizationParams` -> `CanonicalParams`
- `canonicalization_task()` -> `canonical_task()`
- `FullTxOut::chain_position` -> `FullTxOut::pos`

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2 months agorefactor(chain)!: remove `CanonicalIter` APIs
Leonardo Lima [Tue, 19 May 2026 19:32:39 +0000 (16:32 -0300)]
refactor(chain)!: remove `CanonicalIter` APIs

The codebase has been updated to the new `LocalChain::canonical_view`
method. It's now safe to remove the `CanonicalIter` it's the old APIs
relying on it, eg. `try_canonical_view`.

2 months agochore(workspace): use new `LocalChain::canonical_view` API
Leonardo Lima [Tue, 19 May 2026 18:56:26 +0000 (15:56 -0300)]
chore(workspace): use new `LocalChain::canonical_view` API

Updates the codebase to use the new convenience
`LocalChain::canonical_view` method in order to generate the
`CanonicalView`. Internally the convenience method follows the `sans-IO` approach,
separating the canonicalization algorithm from i/o operations, and it's
used as follows:

1. Create a new `CanonicalizationTask` with a `TxGraph`, by calling:
   `graph.canonicalization_task(params)`
2. Execute the canonicalization process with a chain oracle (e.g
   `LocalChain`, which implements `ChainOracle` trait), by calling:
   `chain.canonicalize(task, chain_tip)`

3 months agofeat(core,chain): introduce `CanonicalizationTask` and `ChainQuery`
Leonardo Lima [Tue, 19 May 2026 18:53:10 +0000 (15:53 -0300)]
feat(core,chain): introduce `CanonicalizationTask` and `ChainQuery`

It introduces the new `CanonicalizationTask` that's implements the
canonicalization algorithm through a request/response pattern.

Also, it introduces the new `ChainQuery` trait in `bdk_core`, which
provides an interface for blockchain source/oracle query-based operations.
Allowing sans-IO patterns for algorithm that needs a blockchain oracle,
without the need for directly implement/handle I/O.

Adds new API methods into `LocalChain`: `canonicalize` and `canonical_view`,
adding same features as the existing `CanonicalIter` and it's APIs.

Co-Authored-By: Claude <noreply@anthropic.com>
3 months agoMerge bitcoindevkit/bdk#2006: refactor: replace examples with focused rustdoc examples
merge-script [Mon, 25 May 2026 14:55:22 +0000 (10:55 -0400)]
Merge bitcoindevkit/bdk#2006: refactor: replace examples with focused rustdoc examples

522e441a1a4511860a90c43c3932cd45a8797c15 chore: Remove example_cli (Kyle 🐆)

Pull request description:

  Closes #1973

  The PR is now scoped to the first step of the work discussed in #1973:

  - Remove the unmaintained example binaries in examples/
  - Remove the related workspace members from Cargo.toml
  - Clean up docs and CI references that pointed to the removed examples

ACKs for top commit:
  ValuedMammal:
    ACK 522e441a1a4511860a90c43c3932cd45a8797c15

Tree-SHA512: 217bbe23c0798903046eaf3f8638099d721c59bc26902fa5d9c3a0e3c3bcc6738b9a7e9b6e6ca82e3c1758aaffd69bec3e91cf00e5a6bf7e1da7c53cf23f1288

3 months agochore: Remove example_cli
Kyle 🐆 [Mon, 25 May 2026 00:22:17 +0000 (20:22 -0400)]
chore: Remove example_cli

Remove the standalone example crates under examples/ and clean up
workspace, docs, and CI references that depended on them.

This commit only does the removal and cleanup. Adding targeted
rustdoc examples is deferred to follow-up PRs.

3 months agoMerge bitcoindevkit/bdk#2048: feat(core): add skiplist to CheckPoint for faster traversal
merge-script [Fri, 15 May 2026 19:55:48 +0000 (19:55 +0000)]
Merge bitcoindevkit/bdk#2048: feat(core): add skiplist to CheckPoint for faster traversal

e095266afa2d80be0c6d2ef9d140ba2c67078a1d feat(core): Optimize `CheckPointIter` using pskip (志宇)
0257c549d0602bfcf016be713f281443a0d85a78 feat(core)!: Remove unused methods of `CheckPointEntry` (志宇)
86c052e5cb1096cb282b78b72e4df8fa9d76b4c6 test(core): add random-access skiplist benchmark (志宇)
d9ce149db413c44c31d8719580876f7bbc31d277 feat(core): add skiplist to CheckPoint for faster traversal (志宇)
08d1bdee2fae549610abed2db705586305231e0c feat(chain,electrum): Make clippy happy (志宇)

Pull request description:

  ### Description

  #### Summary

  Add a skiplist to `CheckPoint` using Bitcoin Core's `CBlockIndex::pskip` pattern, adapted to operate on checkpoint indices rather than block heights. Result: O(log n) lookups for `get`, `floor_at`, and `range`, with no tuning constant. Per-node memory is unchanged — `Option<Arc<CPInner>>` is niche-optimized to 8 bytes whether or not it's populated.

  The pskip approach was suggested by @ValuedMammal in https://github.com/bitcoindevkit/bdk/pull/2048#issuecomment-4328710770 and prototyped in https://github.com/ValuedMammal/block-graph/blob/master/block-graph/src/checkpoint.rs. Credit for the core idea goes there. This PR takes a different implementation path; the rationale is below.

  #### Design

  Every `CheckPoint` node carries one Arc skip pointer to a deterministically chosen ancestor at index `skip_index(i)`. The chosen targets give skip distances that grow exponentially as you walk back, yielding O(log n) traversal — ~17 hops at 1M blocks vs ~1M for a linear walk.

  `get`, `floor_at`, and `range` all reduce to "walk back to the highest checkpoint at or below `target_height`", factored into one private `walk_to_floor` helper. Each public method is a thin wrapper.

  #### Bench numbers (criterion)

  Absolute pskip times, with a linear-walk baseline at 1M blocks for scale:

  ```
  get_1000_middle             227 ns
  get_10000_near_end          397 ns
  floor_at_10000              565 ns
  random_access_skiplist_1m   1.36 µs   (vs 3.84 ms linear walk over the same chain)
  ```

  #### Caveats

  - Insert is ~50 ns slower per push than a non-skiplist `CheckPoint` because every push wires its skip pointer via an O(log n) `ancestor_by_index` walk. For real-world per-block chain extension this is negligible (well under 1 µs/block), but bulk-rebuild paths (`insert_sparse_1000` → ~3.5 µs for 1000 sequential pushes) pay it linearly.

  ### Notes to the reviewers

  #### History

  This PR went through three design iterations. Including the rationale here so reviewers don't have to reconstruct it from the commit graph:

  **1. Fixed-stride skiplist (initial proposal).** First version added a single skip pointer every `CHECKPOINT_SKIP_INTERVAL` indices, each pointing exactly that many positions back. `INTERVAL` was originally `100`, then bumped to `1000` after benchmarking — at mainnet-scale chains (~1M blocks) the cost-optimal stride for an O(n/k + k) walk is `k ≈ √n ≈ 1000`. This delivered ~50–80× speedups over linear walks but still left lookups at O(√n) (~2,000 hops at 1M blocks) and forced a tuning constant.

  **2. Bitcoin Core's `pskip` (current).** @ValuedMammal pointed out that Bitcoin Core's `CBlockIndex::pskip` pattern achieves O(log n) lookups with no tuning constant by giving every node a single skip pointer to a *deterministically chosen* ancestor (computed from the index's bit pattern). Crucially, this comes at no extra per-node memory cost: `Option<Arc<CPInner>>` was already 8 bytes per node thanks to niche-optimization, so populating the field on every node uses the same space as populating it on every 1000th. Switched to this approach; the synthetic skiplist benches went from ~80% improvement to ~94% over linear, and the tuning constant disappeared.

  **3. Reuse the pskip walker.** Once `ancestor_by_index` (the O(log n) walk underlying pskip) existed, it became natural to plug it into anywhere `CheckPoint`/`CheckPointIter` was advancing through the chain by a known amount. `get`, `range`, `floor_at`, `floor_below`, and `Iterator::nth` / `last` all use it now; `count` and `size_hint` derive from the `index` counter directly. Unused traversal methods on `CheckPointEntry` were removed in the same pass since they were duplicating `CheckPoint`'s own surface and had no callers in the workspace.

  #### Diffs from @ValuedMammal's prototype

  The [block-graph prototype](https://github.com/ValuedMammal/block-graph/blob/master/block-graph/src/checkpoint.rs) gets the high-level idea right (every node carries one deterministic skip pointer; index-based formula so sparse chains work) but has a few choices I wanted to address differently:

  **1. `n & (n - 1)` underflow.** The prototype handles it by converting `u32 → i32 → u32` with `try_into().expect(...)`, relying on signed two's-complement to give `0 & -1 == 0`. This PR uses `n & n.wrapping_sub(1)` directly on `u32`, which produces the same `0 & u32::MAX == 0` result without the round-trip conversion.

  **2. Traversal heuristic.** The prototype's `get` uses simple greedy ("take skip if it doesn't undershoot, else prev"). That's correct but **not genuinely O(log n)** — for targets near genesis on a long chain, it degrades to many small geometric descents stacked end-to-end. This PR uses Bitcoin Core's `GetAncestor` heuristic verbatim: take skip unless the *predecessor's* skip would have been a strictly bigger jump that still doesn't undershoot.

  **3. Single internal helper for `get`/`range`/`floor_at`.** The public surface (`get`, `range`, `floor_at`) all reduces to "walk back to the highest checkpoint at or below `target_height`". This PR factors that into one private `walk_to_floor` function; each public method becomes a thin wrapper. The prototype duplicates the skip-walk logic.

  **4. `Drop` cleanup.** With every node holding a skip Arc, the manual unwind loop in `Drop for CPInner` (existing fix for #1634) is extended with `node.skip.take()` so skip-pointer drops happen on the manual loop rather than triggering ancestor drops via the implicit recursive path.

  ### Changelog

  ```md
  Added:
  - `O(log n)` skiplist on `CheckPoint` (Bitcoin Core's pskip pattern). Speeds up `get`, `floor_at`, `range`, and full-chain iteration.
  - `Iterator::nth` / `last` / `count` / `size_hint` overrides on `CheckPointIter` and `CheckPointEntryIter`, plus `ExactSizeIterator` impls. `nth` and `last` are now `O(log n)`; `count` and `size_hint` are `O(1)`.

  Removed:
  - Unused traversal methods on `CheckPointEntry`: `iter`, `get`, `range`, `floor_at`, `floor_below`. They had no callers in the workspace and duplicated `CheckPoint`'s own surface.
  ```

  ### Checklists

  #### All Submissions:

  * [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk/blob/master/CONTRIBUTING.md)

  #### New Features:

  * [x] I've added tests for the new feature
  * [x] I've added docs for the new feature

ACKs for top commit:
  nymius:
    ACK e095266afa2d80be0c6d2ef9d140ba2c67078a1d

Tree-SHA512: 15d71abe5959d4928d44bd60cbd323f24197b3fb8de36f774f4f45e517fe67b470df7193f69b7d95e3854bf921c55659236009fd3569289e0063b227e66b0cbf

3 months agofeat(core): Optimize `CheckPointIter` using pskip
志宇 [Fri, 15 May 2026 18:22:26 +0000 (18:22 +0000)]
feat(core): Optimize `CheckPointIter` using pskip

3 months agofeat(core)!: Remove unused methods of `CheckPointEntry`
志宇 [Mon, 4 May 2026 09:08:23 +0000 (09:08 +0000)]
feat(core)!: Remove unused methods of `CheckPointEntry`

3 months agotest(core): add random-access skiplist benchmark
志宇 [Thu, 23 Apr 2026 16:19:24 +0000 (16:19 +0000)]
test(core): add random-access skiplist benchmark

Addresses review feedback from @nymius: existing benches use fixed
targets, which can land favorably or unfavorably relative to skip
pointer positions and don't reflect real query patterns. The new
bench draws 256 targets from a deterministic xorshift sequence and
runs both a skiplist-enhanced get() and a plain linear walk over
a 100k-node chain, so the same query stream exercises both paths.

Also changed benchmarks to reflect checkpoint full chains and removed
unhelpful benchmarks.

3 months agofeat(core): add skiplist to CheckPoint for faster traversal
志宇 [Thu, 25 Sep 2025 07:20:43 +0000 (07:20 +0000)]
feat(core): add skiplist to CheckPoint for faster traversal

Adds a skip pointer and an index field to CheckPoint to accelerate
get(), floor_at(), and range(). push() and insert() maintain the
index/skip invariants on the rebuilt chain.

The skip pointer follows Bitcoin Core's `CBlockIndex::pskip` pattern,
adapted to operate on checkpoint indices (not heights) so it works on
sparse chains. Skip distances grow exponentially as you walk back,
yielding O(log n) traversal.

3 months agofeat(chain,electrum): Make clippy happy
志宇 [Fri, 1 May 2026 10:33:08 +0000 (10:33 +0000)]
feat(chain,electrum): Make clippy happy

3 months agoMerge bitcoindevkit/bdk#2144: ci: switch from coveralls to codecov for coverage reporting
merge-script [Fri, 8 May 2026 19:13:25 +0000 (16:13 -0300)]
Merge bitcoindevkit/bdk#2144: ci: switch from coveralls to codecov for coverage reporting

2a42f2517036325588c7681b5efc90b3c725a119 ci(coverage): use `codecov` instead of `coveralls` (Shubham Shinde)

Pull request description:

  closes #2093

  ### Description

  Migrates code coverage reporting from Coveralls to Codecov.

  - **Replaced coverage service**: Switched from `coverallsapp/github-action` to `codecov/codecov-action@v5.5.2` (pinned commit SHA for security)
  - **Added permissions**: Added `contents: read` and `pull-requests: write` to enable Codecov PR comments
  - **Codecov configuration**: Added `flags: rust` and `name: codecov-bdk` for better organization

  ### Changelog notice

  ```
  ### Changed
  - chore(ci): switch from coveralls to codecov
  ```
  #### All Submissions:

  * [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk/blob/master/CONTRIBUTING.md)

ACKs for top commit:
  oleonardolima:
    self-ACK 2a42f2517036325588c7681b5efc90b3c725a119
  notmandatory:
    ACK 2a42f2517036325588c7681b5efc90b3c725a119

Tree-SHA512: 53dd898fefb973fc4a884fbfb34335d5f03992d30c676841b66db8dcc5a4d3a8e5178d5886cb91308df873f25fe6703457dc27aa5b45451f828bfcded612cace

3 months agoMerge bitcoindevkit/bdk#2195: fix(electrum): do not pick unindexed outputs for histor...
merge-script [Fri, 8 May 2026 18:49:43 +0000 (15:49 -0300)]
Merge bitcoindevkit/bdk#2195: fix(electrum): do not pick unindexed outputs for history lookup

2e3d52e80fdc504c718426b9255a30fc24b7ceda fix(electrum): do not pick unindexed outputs for history lookup (Zoe Faltibà)

Pull request description:

  ### Description

  `BdkElectrumClient::populate_with_txids` queries each transaction's confirmation status by calling `script_get_history` on the script of one of its outputs. It currently picks the first output unconditionally. This breaks for transactions which first output is an `OP_RETURN`, because Electrum servers don't index `OP_RETURN` scripts and will return an empty history. This is a real-world scenario: protocols like RGB place an `OP_RETURN` commitment as the first output of every transaction.

  ### Notes to the reviewers

  The fix selects the first output which script is not `OP_RETURN` or a `OP_FALSE OP_RETURN`. If a transaction has only `OP_RETURN`/`OP_FALSE OP_RETURN` outputs, we fall back to the script of any input's previous output to query history. The only case still skipped is a coinbase with all unindexed outputs, since coinbases have no parent to fall back on.

  ### Changelog notice

  ```
  Fixed:
  - `BdkElectrumClient::sync` now correctly retrieves confirmation status for transactions which first output is an `OP_RETURN` or `OP_FALSE OP_RETURN`
  ```

  ### Checklists

  #### All Submissions:

  * [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk/blob/master/CONTRIBUTING.md)

ACKs for top commit:
  oleonardolima:
    ACK 2e3d52e80fdc504c718426b9255a30fc24b7ceda
  evanlinjin:
    ACK 2e3d52e80fdc504c718426b9255a30fc24b7ceda

Tree-SHA512: d87a0580c0db4e86ee6fce84a82ac56ef70378b46405bb54ca33f1a2a643feba6fa769c0ba2a9e01c77cc6308c777ccc34f89d548e46a1bbf036e31d8c3ddcd0

3 months agoci(coverage): use `codecov` instead of `coveralls`
Shubham Shinde [Mon, 9 Mar 2026 22:13:37 +0000 (03:43 +0530)]
ci(coverage): use `codecov` instead of `coveralls`

- update the `code_coverage.yml` CI job to use codecov instead of
  coveralls, copied from `bdk_wallet` repository.

3 months agoMerge bitcoindevkit/bdk#2171: Add `SECURITY.md`
merge-script [Tue, 5 May 2026 14:02:57 +0000 (11:02 -0300)]
Merge bitcoindevkit/bdk#2171: Add `SECURITY.md`

122207f099bd1c7085701dd0d905b3ccd8c46bad feat(doc): add `SECURITY.md` (Luis Schwab)

Pull request description:

  Closes #2168

  ## Changelog
  ```
  - Add `SECURITY.md` listing the PGP key to be used for vulnerability disclosures
  ```

ACKs for top commit:
  oleonardolima:
    ACK 122207f099bd1c7085701dd0d905b3ccd8c46bad
  notmandatory:
    ACK 122207f099bd1c7085701dd0d905b3ccd8c46bad

Tree-SHA512: 22e5d05ee4497a1c4e40e1aedb25739c8e2ab954e876f4305175697ee366b17d18d44aeb22ef81558e0515cc056bd828358116c6af0567f9ca17d4183b21bf3c

4 months agoMerge bitcoindevkit/bdk#2193: [testenv] Bump `electrsd` to v0.38.0
merge-script [Fri, 1 May 2026 14:07:51 +0000 (11:07 -0300)]
Merge bitcoindevkit/bdk#2193: [testenv] Bump `electrsd` to v0.38.0

7ba31dd8ecdfa72732654a74d144fa4a2d9c18d0 chore(deps)!: bump `electrsd` to v0.38.0 (Luis Schwab)

Pull request description:

  Closes #2183

  ## Changelog
  ```
  ### Changed
  Bump `electrsd` to v0.38.0
  ```

ACKs for top commit:
  oleonardolima:
    ACK 7ba31dd8ecdfa72732654a74d144fa4a2d9c18d0
  tvpeter:
    tACK 7ba31dd8ecdfa72732654a74d144fa4a2d9c18d0
  ValuedMammal:
    ACK 7ba31dd8ecdfa72732654a74d144fa4a2d9c18d0

Tree-SHA512: 53a9800e74dc63ff532a13fc7eabe123dd1a60cc6b9d81109e5bac63f85d0babf308b2dd9fb0021abde956a4e7aa567f42cec20b626e4e6a360a14cc7139d7f9

4 months agofix(electrum): do not pick unindexed outputs for history lookup
Zoe Faltibà [Wed, 29 Apr 2026 09:50:23 +0000 (11:50 +0200)]
fix(electrum): do not pick unindexed outputs for history lookup

4 months agochore(deps)!: bump `electrsd` to v0.38.0
Luis Schwab [Wed, 29 Apr 2026 01:31:25 +0000 (22:31 -0300)]
chore(deps)!: bump `electrsd` to v0.38.0

4 months agoMerge bitcoindevkit/bdk#2190: Remove unused `start-core.sh` script
merge-script [Wed, 29 Apr 2026 11:16:43 +0000 (11:16 +0000)]
Merge bitcoindevkit/bdk#2190: Remove unused `start-core.sh` script

ae0e826c378377e589f0f606c215cb61976f0d0d chore: remove unused `start-core.sh` script (Luis Schwab)

Pull request description:

  ## Changelog
  ```
  - Remove the unused `ci/start-core.sh` script
  ```

ACKs for top commit:
  oleonardolima:
    ACK ae0e826c378377e589f0f606c215cb61976f0d0d
  evanlinjin:
    ACK ae0e826c378377e589f0f606c215cb61976f0d0d

Tree-SHA512: af9205cfb0de497f16fa10d49afd2f87291f79e19157a784b7e97ec8cf75bdffc1c4c5a71f755f0c16074b2afa96560001951551554749ff5ae57e3898202908

4 months agoMerge bitcoindevkit/bdk#2194: ci: Fix pin-msrv
merge-script [Wed, 29 Apr 2026 10:43:47 +0000 (10:43 +0000)]
Merge bitcoindevkit/bdk#2194: ci: Fix pin-msrv

24e23e3a7d1f9a64dcf499f894c93af104a98bb9 ci: Fix pin-msrv (志宇)

Pull request description:

  ### Description

  MSRV broke again.

  ### Checklists

  #### All Submissions:

  * [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk/blob/master/CONTRIBUTING.md)

ACKs for top commit:
  LLFourn:
    ACK 24e23e3a7d1f9a64dcf499f894c93af104a98bb9

Tree-SHA512: 8e94f2eddabc1a403d227a4466bf94a55ee2fe06c1f97d581fe6a7a1039b4bfa156e08559e1b2263ee2cf205352eb1fe2ec819a76d7b081d2995f2804511f2db

4 months agoci: Fix pin-msrv
志宇 [Tue, 28 Apr 2026 15:31:00 +0000 (15:31 +0000)]
ci: Fix pin-msrv

4 months agofeat(doc): add `SECURITY.md`
Luis Schwab [Fri, 10 Apr 2026 19:27:30 +0000 (16:27 -0300)]
feat(doc): add `SECURITY.md`

Add a `SECURITY.md` listing the security PGP key to be used for disclosures

4 months agochore: remove unused `start-core.sh` script
Luis Schwab [Sat, 25 Apr 2026 15:43:30 +0000 (12:43 -0300)]
chore: remove unused `start-core.sh` script

4 months agoMerge bitcoindevkit/bdk#2167: fix(bitcoind_rpc): emit invalidated heights when start_...
merge-script [Fri, 24 Apr 2026 06:23:36 +0000 (06:23 +0000)]
Merge bitcoindevkit/bdk#2167: fix(bitcoind_rpc): emit invalidated heights when start_height is above agreement point

76b653007d63803a33668dcd51f23085b71c3911 fix(bitcoind_rpc): emit invalidated heights when start_height is above agreement point (志宇)

Pull request description:

  ### Description

  When a reorg drops the agreement point below `start_height`, the emitter would skip directly to `start_height`, producing a checkpoint that could not connect with the caller's local chain (`CannotConnectError`).

  This affects callers that create a new `Emitter` on each sync with `start_height = tip_height` — a common pattern.

  **Fix:** Override `start_height` to the agreement height when a reorg is detected (agreement point below both `start_height` and `last_cp`), so the emitter revisits the invalidated block heights.

  Context: https://discord.com/channels/753336465005608961/753367451319926827/1489544612094808235

  cc @stevenroose

  ### Notes to the reviewers

  The key change is in `poll()` in `crates/bitcoind_rpc/src/lib.rs`: when `AgreementFound` is handled and the agreement point is below both `start_height` and `last_cp.height()`, we lower `start_height` to the agreement height. This ensures the emitter emits the invalidated blocks instead of skipping over them.

  ### Changelog notice

  ```md
  Fixed:
  - `Emitter` producing un-connectable checkpoints when `start_height` is above the agreement point after a reorg.
  ```

  ### Checklists

  #### All Submissions:

  * [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk/blob/master/CONTRIBUTING.md)

  #### Bugfixes:

  * [ ] This pull request breaks the existing API
  * [x] I've added tests to reproduce the issue which are now passing
  * [x] I'm linking the issue being fixed by this PR

ACKs for top commit:
  luisschwab:
    ACK 76b653007d63803a33668dcd51f23085b71c3911

Tree-SHA512: ec9c382e8619b56284ee8ac934e5934dab3b067c0f33f79f4aa3b1a8877750093a6aeff939fe51add73dd1f71d4ce786af57a905730c150b3c112ac62ff210a8

4 months agoMerge bitcoindevkit/bdk#2182: fix: full_scan covers revealed range before applying...
merge-script [Fri, 24 Apr 2026 06:20:23 +0000 (06:20 +0000)]
Merge bitcoindevkit/bdk#2182: fix: full_scan covers revealed range before applying stop_gap

187b00747ab978a3bba21df5d14835ec31ed9fa3 test(esplora): allow(dead_code) at file level in common (Noah Joeris)
79d1f4501443559016de737fee8bdc572a99e248 fix: full_scan covers revealed range before applying stop_gap (Noah Joeris)

Pull request description:

  Fixes #2057. `full_scan` now always covers the revealed range before applying the stop_gap

  ### Notes to the reviewers

  Replaces #2181. That PR unified full_scan and sync into one path; per @evanlinjin's feedback we're keeping them separate and doing the minimal fix here instead

  ### Changelog notice

  Fixed: full_scan now always scans the full revealed range before applying stop_gap past last_revealed.

  ### Checklists

  #### All Submissions:

  * [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk/blob/master/CONTRIBUTING.md)

  #### New Features:

  * [x] I've added tests for the new feature
  * [x] I've added docs for the new feature

  #### Bugfixes:

  * [ ] This pull request breaks the existing API
  * [x] I've added tests to reproduce the issue which are now passing
  * [x] I'm linking the issue being fixed by this PR

ACKs for top commit:
  evanlinjin:
    ACK 187b00747ab978a3bba21df5d14835ec31ed9fa3

Tree-SHA512: 9899e5d857d3cc3e86d35fd0e6a49204d4029053893b98fe1d8eb2bbdb9ea85b204997d87a72c9d485544286a0107936f048e54a7c152ab66b2106c897a1d900

4 months agoMerge bitcoindevkit/bdk#2188: fix(electrum): verify txid of server-returned transactions
merge-script [Fri, 24 Apr 2026 04:35:57 +0000 (04:35 +0000)]
Merge bitcoindevkit/bdk#2188: fix(electrum): verify txid of server-returned transactions

d101a0973bc19ac1b64809c0d9f0cd3516e263d8 fix(electrum): verify txid of server-returned transactions (Elias Rohrer)

Pull request description:

  ### Description

  An Electrum server could return an arbitrary transaction when `fetch_tx()` requests a specific txid. The returned transaction was cached and used without verifying that its computed txid matches the requested one.

  Add a verification check that `tx.compute_txid() == txid` after fetching from the server, returning an error on mismatch. Include a unit test with a mock Electrum client that exercises both the mismatch rejection and the matching-txid happy path.

ACKs for top commit:
  evanlinjin:
    ACK d101a0973bc19ac1b64809c0d9f0cd3516e263d8

Tree-SHA512: aecb729fd7d92bf75ec2877b1717eaeed824178d81a5c769a738314326d4a1acddeded3b37837f3af84ca6c69b7c73bff46d901697a8f2125ea1d4c34bef6096

4 months agotest(esplora): allow(dead_code) at file level in common
Noah Joeris [Thu, 23 Apr 2026 17:52:04 +0000 (20:52 +0300)]
test(esplora): allow(dead_code) at file level in common

4 months agofix: full_scan covers revealed range before applying stop_gap
Noah Joeris [Sun, 19 Apr 2026 20:55:13 +0000 (23:55 +0300)]
fix: full_scan covers revealed range before applying stop_gap

4 months agofix(electrum): verify txid of server-returned transactions
Elias Rohrer [Thu, 23 Apr 2026 16:54:52 +0000 (18:54 +0200)]
fix(electrum): verify txid of server-returned transactions

An Electrum server could return an arbitrary transaction when
`fetch_tx()` requests a specific txid. The returned transaction was
cached and used without verifying that its computed txid matches the
requested one.

Add a verification check that `tx.compute_txid() == txid` after
fetching from the server, returning an error on mismatch.

Signed-off-by: Elias Rohrer <dev@tnull.de>
4 months agofix(bitcoind_rpc): emit invalidated heights when start_height is above agreement...
志宇 [Mon, 6 Apr 2026 16:24:12 +0000 (16:24 +0000)]
fix(bitcoind_rpc): emit invalidated heights when start_height is above agreement point

When a reorg drops the agreement point below `start_height`, the emitter
would skip directly to `start_height`, producing a checkpoint that could
not connect with the caller's local chain (`CannotConnectError`).

Fix: override `start_height` to the agreement height when a reorg is
detected (agreement point below both `start_height` and `last_cp`), so
the emitter revisits the invalidated block heights.

4 months agoMerge bitcoindevkit/bdk#2180: fix(chain): prevent integer overflow in `SpkIterator...
merge-script [Thu, 23 Apr 2026 15:41:11 +0000 (15:41 +0000)]
Merge bitcoindevkit/bdk#2180: fix(chain): prevent integer overflow in `SpkIterator::new_with_range`

b340e96f0221f6c3088fe5daf2b87c56b3bf4010 fix(chain): prevent integer overflow in `SpkIterator::new_with_range` (Elias Rohrer)

Pull request description:

  ### Description

  The start and end bound calculations used unchecked addition which
  overflows when given `u32::MAX`, causing the iterator to silently produce
  wrong results (e.g., an empty iterator for `0..=u32::MAX` in release
  mode). Use `saturating_add` to handle the boundary correctly.

  ### Checklists

  #### All Submissions:

  * [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk/blob/master/CONTRIBUTING.md)

  #### Bugfixes:

  * [ ] This pull request breaks the existing API
  * [x] I've added tests to reproduce the issue which are now passing
  * [ ] I'm linking the issue being fixed by this PR

ACKs for top commit:
  luisschwab:
    ACK b340e96f0221f6c3088fe5daf2b87c56b3bf4010

Tree-SHA512: f28ebcdb8f8b269d64c4d7bb4e38e8fcdc85864c35b0c287bc0d41d740d6b78bd2491533585f85805cc4f1c63ce4024c677081e7fa283f8f1ad0e18d0728d44f

4 months agofix(chain): prevent integer overflow in `SpkIterator::new_with_range`
Elias Rohrer [Wed, 8 Apr 2026 09:42:39 +0000 (11:42 +0200)]
fix(chain): prevent integer overflow in `SpkIterator::new_with_range`

The start and end bound calculations used unchecked addition which
overflows when given `u32::MAX`, causing the iterator to silently produce
wrong results (e.g., an empty iterator for `0..=u32::MAX` in release
mode). Use `saturating_add` to handle the boundary correctly.

Co-Authored-By: HAL 9000
Signed-off-by: Elias Rohrer <dev@tnull.de>
4 months agoMerge bitcoindevkit/bdk#2115: Add `prev_blockhash` validation to `CheckPoint`
merge-script [Wed, 22 Apr 2026 06:34:21 +0000 (06:34 +0000)]
Merge bitcoindevkit/bdk#2115: Add `prev_blockhash` validation to `CheckPoint`

c486ba75865806bbe1d88c646385ac57df611ef5 docs: address review feedback on `prev_blockhash` validation (志宇)
031b30fb3fbc19894c85dccc0d6a5515442e5bce docs(core): address review feedback on docs and tests (志宇)
ef35b199376b3b88bc7b8985aa1afa6c81bda5c1 fix(chain)!: make genesis immutable in `merge_chains` (志宇)
d8cb41f2c22ed684fe493b29c86de02ddc921423 test(core): address review feedback on checkpoint tests (志宇)
9c0453c7d9767002b6722c888ac1f694c792c0d2 docs(core): Add module-level docs for `checkpoint_entry` (志宇)
3ef6ed866d364d6f8c9136d0b6696f2b90e572be feat(chain)!: Add `ApplyBlockError` for `prev_blockhash` validation (志宇)
bf6541b43d3d65f20a7c081129197337f09d25b6 feat(chain)!: Relax the generic parameter for `LocalChain<D>` (志宇)
19b900648f9308d671849c927abf4084d6843942 test(core): add tests for CheckPoint::push and insert methods (志宇)
9971fda5367cfa69917445a11c4b8c9d6de3f713 test(chain): Test `apply_update` with a single `CheckPoint<Header>` (valued mammal)
3df06096f9209a0ed12e109e0d809174a7b1a73b test(chain): make `TestLocalChain` generic and add `prev_blockhash` test (志宇)
c314b2567b2574da38e060bb57c02c9929082c08 fix(chain): `merge_chains` now takes account of `prev_blockhash`es (志宇)
f10ba0ecb1e60aef40820298a357eb394bc190e9 fix(core): `Checkpoint::insert` now evicts on `prev_blockhash` mismatch (志宇)
046a771b7842dac74d5cb82a56b28fbbbbe1a33a fix(core): `push` now errors on `prev_blockhash` mismatch (志宇)
68d1ef4466cf64104b0338a3feed902080a35e05 feat(core): Initial work on `CheckPointEntry` (志宇)
d4bdff08f7de754461d9364302b7e8371e3d234e feat(core): Add `prev_blockhash` method to `ToBlockHash` trait (志宇)

Pull request description:

  Closes #2021
  Related to #2076
  Replaces #2024
  Replaces #2091

  ### Description

  This PR adds `prev_blockhash` awareness to `CheckPoint`, enabling proper chain validation when merging checkpoint chains that store block headers or similar data with previous block hash information.

  ### Notes to the reviewers

  This PR replaces some prior attempts:

  * #2024 - where we made the `CheckPoint::data` optional - however this resulted in internal complexity and an API with annoying edge cases. The tests from this PR were still useful.

  * #2091 - This second attempt had some good ideas, but was distracted from the goal of #2021. I mostly reused the `CheckPoint::insert` implementation of that PR.

  ### Changelog notice

  ```md
  Added:
  - `ToBlockHash::prev_blockhash()` - optional method to expose previous block hash
  - `CheckPointEntry` - new type for iterating with `prev_blockhash` awareness, yielding "placeholder" entries for heights inferred from `prev_blockhash`
  - `ApplyBlockError` - this is a new error type with two variants; `MissingGenesis` and `PrevBlockhashMismatch`. The second variant is a new error case introduced by `prev_blockhash` awareness.

  Changed:
  - `CheckPoint::push` - now errors when `prev_blockhash` conflicts with current tip (contiguous heights)
  - `CheckPoint::insert` - now evicts/displaces checkpoints on `prev_blockhash` conflict
  - `merge_chains` - now validates `prev_blockhash` consistency when merging
  - `LocalChain<D>` generic parameter - relaxed constraint to `D: Clone` instead of `D: Copy`.

  Fixed:
  - `merge_chains` no longer replaces the genesis block.
  ```

  ### Checklists

  #### All Submissions:

  * [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk/blob/master/CONTRIBUTING.md)

  #### New Features:

  * [x] I've added tests for the new feature
  * [x] I've added docs for the new feature

ACKs for top commit:
  evanlinjin:
    self-ACK c486ba75865806bbe1d88c646385ac57df611ef5

Tree-SHA512: 5622a8a418034443931c8b5938e708c2222c42c05efbdac71d47a4e0ce1b4f4b0b7bcd2e1e14e2f295cc056e12c03e5750b40b1a1313cdbdf59a009d81d0b8a1

4 months agodocs: address review feedback on `prev_blockhash` validation
志宇 [Wed, 22 Apr 2026 06:28:04 +0000 (06:28 +0000)]
docs: address review feedback on `prev_blockhash` validation

- Clarify `CheckPoint::insert` eviction semantics when `data.prev_blockhash`
  conflicts with the checkpoint at `height - 1`.
- Explain placeholder handling in `merge_chains` conflict branch where
  `u.data()` may legitimately insert `None`.
- Preserve mismatch height in `merge_chains`' fallback so release-mode
  callers get a useful `try_include_height` instead of `0`.
- Reframe the "update displaces invalid block" test comment to make the
  best-effort recovery intent explicit.
- Derive `PartialEq` on `CheckPointEntry` and fix a broken intra-doc link.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
4 months agodocs(core): address review feedback on docs and tests
志宇 [Thu, 5 Mar 2026 06:03:40 +0000 (06:03 +0000)]
docs(core): address review feedback on docs and tests

Address suggestions by @nymius:
- Add `Returns` and `Errors` doc sections to `CheckPoint::from_blocks`
- Add test assertions for chain integrity after failed push and chain
  length after successful push

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
4 months agofix(chain)!: make genesis immutable in `merge_chains`
志宇 [Wed, 18 Feb 2026 17:33:29 +0000 (17:33 +0000)]
fix(chain)!: make genesis immutable in `merge_chains`

Prevent `merge_chains` from replacing the genesis block when original
and update disagree on the genesis hash. This aligns with
`CheckPoint::insert` which already panics on genesis replacement.

Also update the "fix blockhash before agreement point" test to operate
at a non-genesis height and add a new test for conflicting genesis.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
4 months agotest(core): address review feedback on checkpoint tests
志宇 [Wed, 18 Feb 2026 17:07:19 +0000 (17:07 +0000)]
test(core): address review feedback on checkpoint tests

- Clarify displaced vs purged terminology in assertion messages
- Add explicit checkpoint verification instead of only counting
- Remove redundant block_1 from genesis panic tests

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
4 months agodocs(core): Add module-level docs for `checkpoint_entry`
志宇 [Sat, 7 Feb 2026 10:12:00 +0000 (10:12 +0000)]
docs(core): Add module-level docs for `checkpoint_entry`

Explain the purpose of `CheckPointEntry` and its two variants:
- `Occupied`: real checkpoint at this height
- `Placeholder`: implied by `prev_blockhash` from checkpoint above

Also fix typo: "atleast" → "at least"

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
4 months agofeat(chain)!: Add `ApplyBlockError` for `prev_blockhash` validation
志宇 [Fri, 6 Feb 2026 15:19:50 +0000 (15:19 +0000)]
feat(chain)!: Add `ApplyBlockError` for `prev_blockhash` validation

Introduce `ApplyBlockError` enum with two variants:
- `MissingGenesis`: genesis block is missing or would be altered
- `PrevBlockhashMismatch`: block's `prev_blockhash` doesn't match expected

This replaces `MissingGenesisError` in several `LocalChain` methods:
- `from_blocks`
- `from_changeset`
- `apply_changeset`

Also adds test cases for `merge_chains` with `prev_blockhash` scenarios:
- Update displaces invalid block below point of agreement
- Update fills gap with matching `prev_blockhash`
- Cascading eviction through multiple blocks

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
4 months agofeat(chain)!: Relax the generic parameter for `LocalChain<D>`
志宇 [Fri, 6 Feb 2026 09:37:26 +0000 (09:37 +0000)]
feat(chain)!: Relax the generic parameter for `LocalChain<D>`

Use `D: Clone` instead of `D: Copy`.

4 months agotest(core): add tests for CheckPoint::push and insert methods
志宇 [Thu, 25 Sep 2025 02:24:27 +0000 (02:24 +0000)]
test(core): add tests for CheckPoint::push and insert methods

Add comprehensive tests for CheckPoint::push error cases:
- Push fails when height is not greater than current
- Push fails when prev_blockhash conflicts with self
- Push succeeds when prev_blockhash matches

Include tests for CheckPoint::insert conflict handling:
- Insert with conflicting prev_blockhash
- Insert purges conflicting tail
- Insert between conflicting checkpoints

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
Co-Authored-By: valued mammal <valuedmammal@protonmail.com>
4 months agotest(chain): Test `apply_update` with a single `CheckPoint<Header>`
valued mammal [Thu, 15 Jan 2026 02:16:57 +0000 (21:16 -0500)]
test(chain): Test `apply_update` with a single `CheckPoint<Header>`

4 months agotest(chain): make `TestLocalChain` generic and add `prev_blockhash` test
志宇 [Wed, 4 Feb 2026 15:29:40 +0000 (15:29 +0000)]
test(chain): make `TestLocalChain` generic and add `prev_blockhash` test

Make `TestLocalChain` and `ExpectedResult` generic over checkpoint data
type `D`, allowing the same test infrastructure to work with both
`BlockHash` and `TestBlock` types.

Add `merge_chains_with_prev_blockhash` test to verify that `prev_blockhash`
correctly invalidates conflicting blocks and connects disjoint chains.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
4 months agofix(chain): `merge_chains` now takes account of `prev_blockhash`es
志宇 [Wed, 14 Jan 2026 09:53:18 +0000 (17:53 +0800)]
fix(chain): `merge_chains` now takes account of `prev_blockhash`es

4 months agofix(core): `Checkpoint::insert` now evicts on `prev_blockhash` mismatch
志宇 [Tue, 13 Jan 2026 13:33:48 +0000 (21:33 +0800)]
fix(core): `Checkpoint::insert` now evicts on `prev_blockhash` mismatch

Additionally, `insert` now panics if the genesis block gets displaced (if
it existed in the first place).

Co-authored-by: valued mammal <valuedmammal@protonmail.com>
4 months agofix(core): `push` now errors on `prev_blockhash` mismatch
志宇 [Tue, 13 Jan 2026 06:02:00 +0000 (14:02 +0800)]
fix(core): `push` now errors on `prev_blockhash` mismatch

4 months agofeat(core): Initial work on `CheckPointEntry`
志宇 [Fri, 9 Jan 2026 09:26:07 +0000 (17:26 +0800)]
feat(core): Initial work on `CheckPointEntry`

4 months agofeat(core): Add `prev_blockhash` method to `ToBlockHash` trait
志宇 [Fri, 9 Jan 2026 09:09:03 +0000 (17:09 +0800)]
feat(core): Add `prev_blockhash` method to `ToBlockHash` trait

4 months agoMerge bitcoindevkit/bdk#2157: ci: automated update to rustc 1.94.1
merge-script [Tue, 21 Apr 2026 16:41:39 +0000 (12:41 -0400)]
Merge bitcoindevkit/bdk#2157: ci: automated update to rustc 1.94.1

0de9f011a81c15d250883ff6bdcd1ec05322e2bf ci: automated update to rustc 1.94.1 (Github Action)

Pull request description:

  Automated update to Github CI workflow `cont_integration.yml` by [create-pull-request](https://github.com/peter-evans/create-pull-request) GitHub action

ACKs for top commit:
  ValuedMammal:
    ACK 0de9f011a81c15d250883ff6bdcd1ec05322e2bf

Tree-SHA512: 118d67c1897d1967a8568fe1a39c3acdd27795c4a67dcc81d455f346f31b26cf1560365fa0df9b9d27f7a8f0edd617a612015e9fb2d7713f297babb27c5b4436

4 months agoci: automated update to rustc 1.94.1
Github Action [Wed, 15 Apr 2026 02:04:29 +0000 (02:04 +0000)]
ci: automated update to rustc 1.94.1

5 months agoMerge bitcoindevkit/bdk#2118: chore(deps): bump peter-evans/create-pull-request from...
merge-script [Thu, 2 Apr 2026 15:33:01 +0000 (12:33 -0300)]
Merge bitcoindevkit/bdk#2118: chore(deps): bump peter-evans/create-pull-request from 8.0.0 to 8.1.0

758a755e26317150b3af1f83155daac64f0bab2e chore(deps): bump peter-evans/create-pull-request from 8.0.0 to 8.1.0 (dependabot[bot])

Pull request description:

  Bumps [peter-evans/create-pull-request](https://github.com/peter-evans/create-pull-request) from 8.0.0 to 8.1.0.
  <details>
  <summary>Release notes</summary>
  <p><em>Sourced from <a href="https://github.com/peter-evans/create-pull-request/releases">peter-evans/create-pull-request's releases</a>.</em></p>
  <blockquote>
  <h2>Create Pull Request v8.1.0</h2>
  <h2>What's Changed</h2>
  <ul>
  <li>README.md: bump given GitHub actions to their latest versions by <a href="https://github.com/deining"><code>@deining</code></a> in <a href="https://redirect.github.com/peter-evans/create-pull-request/pull/4265">peter-evans/create-pull-request#4265</a></li>
  <li>build(deps): bump the github-actions group with 2 updates by <a href="https://github.com/dependabot"><code>@dependabot</code></a>[bot] in <a href="https://redirect.github.com/peter-evans/create-pull-request/pull/4273">peter-evans/create-pull-request#4273</a></li>
  <li>build(deps-dev): bump the npm group with 2 updates by <a href="https://github.com/dependabot"><code>@dependabot</code></a>[bot] in <a href="https://redirect.github.com/peter-evans/create-pull-request/pull/4274">peter-evans/create-pull-request#4274</a></li>
  <li>build(deps-dev): bump undici from 6.22.0 to 6.23.0 by <a href="https://github.com/dependabot"><code>@dependabot</code></a>[bot] in <a href="https://redirect.github.com/peter-evans/create-pull-request/pull/4284">peter-evans/create-pull-request#4284</a></li>
  <li>Update distribution by <a href="https://github.com/actions-bot"><code>@actions-bot</code></a> in <a href="https://redirect.github.com/peter-evans/create-pull-request/pull/4289">peter-evans/create-pull-request#4289</a></li>
  <li>fix: Handle remote prune failures gracefully on self-hosted runners by <a href="https://github.com/peter-evans"><code>@peter-evans</code></a> in <a href="https://redirect.github.com/peter-evans/create-pull-request/pull/4295">peter-evans/create-pull-request#4295</a></li>
  <li>feat: add <code>@octokit/plugin-retry</code> to handle retriable server errors by <a href="https://github.com/peter-evans"><code>@peter-evans</code></a> in <a href="https://redirect.github.com/peter-evans/create-pull-request/pull/4298">peter-evans/create-pull-request#4298</a></li>
  </ul>
  <h2>New Contributors</h2>
  <ul>
  <li><a href="https://github.com/deining"><code>@deining</code></a> made their first contribution in <a href="https://redirect.github.com/peter-evans/create-pull-request/pull/4265">peter-evans/create-pull-request#4265</a></li>
  </ul>
  <p><strong>Full Changelog</strong>: <a href="https://github.com/peter-evans/create-pull-request/compare/v8.0.0...v8.1.0">https://github.com/peter-evans/create-pull-request/compare/v8.0.0...v8.1.0</a></p>
  </blockquote>
  </details>
  <details>
  <summary>Commits</summary>
  <ul>
  <li><a href="https://github.com/peter-evans/create-pull-request/commit/c0f553fe549906ede9cf27b5156039d195d2ece0"><code>c0f553f</code></a> feat: add <code>@octokit/plugin-retry</code> to handle retriable server errors (<a href="https://redirect.github.com/peter-evans/create-pull-request/issues/4298">#4298</a>)</li>
  <li><a href="https://github.com/peter-evans/create-pull-request/commit/70001242bfa9ec7844891e620fdda69a2a2a06c7"><code>7000124</code></a> fix: Handle remote prune failures gracefully (<a href="https://redirect.github.com/peter-evans/create-pull-request/issues/4295">#4295</a>)</li>
  <li><a href="https://github.com/peter-evans/create-pull-request/commit/34aa40e9cf0bb8b5be745a552003fdeb25e4dd3a"><code>34aa40e</code></a> build: update distribution (<a href="https://redirect.github.com/peter-evans/create-pull-request/issues/4289">#4289</a>)</li>
  <li><a href="https://github.com/peter-evans/create-pull-request/commit/641099ddca097df58c3369dd5e1f33322b223029"><code>641099d</code></a> build(deps-dev): bump undici from 6.22.0 to 6.23.0 (<a href="https://redirect.github.com/peter-evans/create-pull-request/issues/4284">#4284</a>)</li>
  <li><a href="https://github.com/peter-evans/create-pull-request/commit/2271f1ddcf09437ed8f019733eb5cfba58ac76f0"><code>2271f1d</code></a> build(deps-dev): bump the npm group with 2 updates (<a href="https://redirect.github.com/peter-evans/create-pull-request/issues/4274">#4274</a>)</li>
  <li><a href="https://github.com/peter-evans/create-pull-request/commit/437c31a11dd02128dd37633ad8d3832853477e7a"><code>437c31a</code></a> build(deps): bump the github-actions group with 2 updates (<a href="https://redirect.github.com/peter-evans/create-pull-request/issues/4273">#4273</a>)</li>
  <li><a href="https://github.com/peter-evans/create-pull-request/commit/0979079bc20c05bbbb590a56c21c4e2b1d1f1bbe"><code>0979079</code></a> docs: update readme</li>
  <li><a href="https://github.com/peter-evans/create-pull-request/commit/5b751cdf403b4f0314c656b2618939e4c8bdf824"><code>5b751cd</code></a> README.md: bump given GitHub actions to their latest versions (<a href="https://redirect.github.com/peter-evans/create-pull-request/issues/4265">#4265</a>)</li>
  <li>See full diff in <a href="https://github.com/peter-evans/create-pull-request/compare/98357b18bf14b5342f975ff684046ec3b2a07725...c0f553fe549906ede9cf27b5156039d195d2ece0">compare view</a></li>
  </ul>
  </details>
  <br />

ACKs for top commit:
  oleonardolima:
    ACK 758a755e26317150b3af1f83155daac64f0bab2e
  luisschwab:
    ACK 758a755e26317150b3af1f83155daac64f0bab2e

Tree-SHA512: c88e8ec28dc6c075fec295d4c0c0556e20f6472e85feceecefe4ab18a6abff48e901b16a80eafb4e8bc257a17ff1fd1338ccaa4cce5a221a376cf53e59e1a5f7

5 months agochore(deps): bump peter-evans/create-pull-request from 8.0.0 to 8.1.0 github/dependabot/github_actions/peter-evans/create-pull-request-8.1.0
dependabot[bot] [Thu, 2 Apr 2026 15:17:28 +0000 (15:17 +0000)]
chore(deps): bump peter-evans/create-pull-request from 8.0.0 to 8.1.0

Bumps [peter-evans/create-pull-request](https://github.com/peter-evans/create-pull-request) from 8.0.0 to 8.1.0.
- [Release notes](https://github.com/peter-evans/create-pull-request/releases)
- [Commits](https://github.com/peter-evans/create-pull-request/compare/98357b18bf14b5342f975ff684046ec3b2a07725...c0f553fe549906ede9cf27b5156039d195d2ece0)

---
updated-dependencies:
- dependency-name: peter-evans/create-pull-request
  dependency-version: 8.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
5 months agoMerge bitcoindevkit/bdk#2166: fix(ci): pin required `icu_*` deps for 1.85.0
merge-script [Thu, 2 Apr 2026 15:14:27 +0000 (12:14 -0300)]
Merge bitcoindevkit/bdk#2166: fix(ci): pin required `icu_*` deps for 1.85.0

cc7cac95dd5f88510b578cf88ae894199cf9183b fix(ci): pin required `icu_*` deps for 1.85.0 (Leonardo Lima)

Pull request description:

  ### Description

  It fixes the 1.85.0 MSRV CI step, by pinning the following:

  - icu_normalizer to "2.1.1"
  - icu_provider to "2.1.1"
  - icu_locale_core to "2.1.1"

  ### Changelog notice

  ```
  ### Changed

  - fix(ci): pin required `icu_*` dependencies for 1.85.0 supported MSRV.

  ```

  ### Checklists

  #### All Submissions:

  * [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk/blob/master/CONTRIBUTING.md)

ACKs for top commit:
  luisschwab:
    ACK cc7cac95dd5f88510b578cf88ae894199cf9183b

Tree-SHA512: 707a6ca21662fd63a7f8896e55d763df2c006baf3efb2759abf64eb0414d4d3cdcadbb054d88104f270eb3987cb1c90ae5a5e18707ef426b8ecefe6b569d16e2

5 months agofix(ci): pin required `icu_*` deps for 1.85.0
Leonardo Lima [Thu, 2 Apr 2026 14:53:33 +0000 (11:53 -0300)]
fix(ci): pin required `icu_*` deps for 1.85.0

5 months agoMerge bitcoindevkit/bdk#2131: chore(deps): bump actions/upload-artifact from 6 to 7
merge-script [Thu, 26 Mar 2026 21:05:57 +0000 (18:05 -0300)]
Merge bitcoindevkit/bdk#2131: chore(deps): bump actions/upload-artifact from 6 to 7

24af63015c526e571a1f0a74fe291e08be8e1fa3 chore(deps): bump actions/upload-artifact from 6 to 7 (dependabot[bot])

Pull request description:

  Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 6 to 7.
  <details>
  <summary>Release notes</summary>
  <p><em>Sourced from <a href="https://github.com/actions/upload-artifact/releases">actions/upload-artifact's releases</a>.</em></p>
  <blockquote>
  <h2>v7.0.0</h2>
  <h2>v7 What's new</h2>
  <h3>Direct Uploads</h3>
  <p>Adds support for uploading single files directly (unzipped). Callers can set the new <code>archive</code> parameter to <code>false</code> to skip zipping the file during upload. Right now, we only support single files. The action will fail if the glob passed resolves to multiple files. The <code>name</code> parameter is also ignored with this setting. Instead, the name of the artifact will be the name of the uploaded file.</p>
  <h3>ESM</h3>
  <p>To support new versions of the <code>@actions/*</code> packages, we've upgraded the package to ESM.</p>
  <h2>What's Changed</h2>
  <ul>
  <li>Add proxy integration test by <a href="https://github.com/Link"><code>@Link</code></a>- in <a href="https://redirect.github.com/actions/upload-artifact/pull/754">actions/upload-artifact#754</a></li>
  <li>Upgrade the module to ESM and bump dependencies by <a href="https://github.com/danwkennedy"><code>@danwkennedy</code></a> in <a href="https://redirect.github.com/actions/upload-artifact/pull/762">actions/upload-artifact#762</a></li>
  <li>Support direct file uploads by <a href="https://github.com/danwkennedy"><code>@danwkennedy</code></a> in <a href="https://redirect.github.com/actions/upload-artifact/pull/764">actions/upload-artifact#764</a></li>
  </ul>
  <h2>New Contributors</h2>
  <ul>
  <li><a href="https://github.com/Link"><code>@Link</code></a>- made their first contribution in <a href="https://redirect.github.com/actions/upload-artifact/pull/754">actions/upload-artifact#754</a></li>
  </ul>
  <p><strong>Full Changelog</strong>: <a href="https://github.com/actions/upload-artifact/compare/v6...v7.0.0">https://github.com/actions/upload-artifact/compare/v6...v7.0.0</a></p>
  </blockquote>
  </details>
  <details>
  <summary>Commits</summary>
  <ul>
  <li><a href="https://github.com/actions/upload-artifact/commit/bbbca2ddaa5d8feaa63e36b76fdaad77386f024f"><code>bbbca2d</code></a> Support direct file uploads (<a href="https://redirect.github.com/actions/upload-artifact/issues/764">#764</a>)</li>
  <li><a href="https://github.com/actions/upload-artifact/commit/589182c5a4cec8920b8c1bce3e2fab1c97a02296"><code>589182c</code></a> Upgrade the module to ESM and bump dependencies (<a href="https://redirect.github.com/actions/upload-artifact/issues/762">#762</a>)</li>
  <li><a href="https://github.com/actions/upload-artifact/commit/47309c993abb98030a35d55ef7ff34b7fa1074b5"><code>47309c9</code></a> Merge pull request <a href="https://redirect.github.com/actions/upload-artifact/issues/754">#754</a> from actions/Link-/add-proxy-integration-tests</li>
  <li><a href="https://github.com/actions/upload-artifact/commit/02a8460834e70dab0ce194c64360c59dc1475ef0"><code>02a8460</code></a> Add proxy integration test</li>
  <li>See full diff in <a href="https://github.com/actions/upload-artifact/compare/v6...v7">compare view</a></li>
  </ul>
  </details>
  <br />

  [![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=actions/upload-artifact&package-manager=github_actions&previous-version=6&new-version=7)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

  Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`.

  [//]: # (dependabot-automerge-start)
  [//]: # (dependabot-automerge-end)

  ---

  <details>
  <summary>Dependabot commands and options</summary>
  <br />

  You can trigger Dependabot actions by commenting on this PR:
  - `@dependabot rebase` will rebase this PR
  - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
  - `@dependabot show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency
  - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

  </details>

ACKs for top commit:
  oleonardolima:
    ACK 24af63015c526e571a1f0a74fe291e08be8e1fa3

Tree-SHA512: ed0e3f31292d68968803e41516e6cc822e7b4f4274479920a1963acb847e2abb76ca034fce3167445b8ebd33ae7274fc1fbfe7bcf2382cd65afdc2f343788b1e

5 months agoMerge bitcoindevkit/bdk#2158: ci: check-docs for all workspace packages
merge-script [Thu, 26 Mar 2026 20:47:45 +0000 (17:47 -0300)]
Merge bitcoindevkit/bdk#2158: ci: check-docs for all workspace packages

9c8b564fb4d9fc0ecf6a03f1cd6668de73555eb3 fix(docs): in keychain_txout.rs and spk_client.rs (shinigami-777)
19d1269f814f445b0337d6c66cd694358afede18 ci: add new check-docs job, justfile recipe and documentation (shinigami-777)

Pull request description:

  fixes #2152

  ### Description

  This PR adds new CI job `check-docs` to validate that documentation builds for all workspace packages, also adds a new justfile recipe `just doc`.

  It also fixes the existing errors in `bdk_chain` and `bdk_core`.

  ### Changelog notice

  ```
  ### Added

  - ci: add new `check-docs` job.

  ### Changed

  - fix(docs): in `keychain_txout.rs` and `spk_client.rs`
  ```

  ### Checklists

  #### All Submissions:

  * [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk/blob/master/CONTRIBUTING.md)

  #### New Features:

  * [ ] I've added tests for the new feature
  * [x] I've added docs for the new feature

  #### Bugfixes:

  * [ ] This pull request breaks the existing API
  * [ ] I've added tests to reproduce the issue which are now passing
  * [x] I'm linking the issue being fixed by this PR

ACKs for top commit:
  oleonardolima:
    ACK 9c8b564fb4d9fc0ecf6a03f1cd6668de73555eb3

Tree-SHA512: ce072647410ba577f28317f1f64c28576517ad29115db09e8231cb756a0e70dcbbe162592b7ab2cad73a67b0db8f727d48dc775817c2530d9f3c83f75832d859

5 months agofix(docs): in keychain_txout.rs and spk_client.rs
shinigami-777 [Wed, 18 Mar 2026 21:50:18 +0000 (03:20 +0530)]
fix(docs): in keychain_txout.rs and spk_client.rs

5 months agoci: add new check-docs job, justfile recipe and documentation
shinigami-777 [Sun, 15 Mar 2026 20:48:52 +0000 (02:18 +0530)]
ci: add new check-docs job, justfile recipe and documentation

5 months agoMerge bitcoindevkit/bdk#2104: fix(esplora): deduplicate missing txids in fetch_txs_wi...
merge-script [Fri, 20 Mar 2026 01:01:20 +0000 (22:01 -0300)]
Merge bitcoindevkit/bdk#2104: fix(esplora): deduplicate missing txids in fetch_txs_with_outpoints

3b6b3ba710492056677349686568f2b2f6c23ee7 fix(esplora): deduplicate missing txids in fetch_txs_with_outpoints (phrwlk)

Pull request description:

  ### Description

  Previously `fetch_txs_with_outpoints` collected spend txids into a Vec, so the same txid could be pushed multiple times when one transaction spent several input outpoints. This caused redundant `get_tx_info` calls to Esplora for the same transaction, wasting network and CPU without changing the resulting `TxUpdate`.

  Use `HashSet<Txid>` for `missing_txs` in both async and blocking `fetch_txs_with_outpoints,` so each txid is only requested once while keeping the observable behaviour of `SyncResponse` / `TxUpdate` unchanged.

  ### Changelog notice

  ```

  ### Changed
  - Use `HashSet` instead of `Vec` to track `missing_txs` in bdk_esplora, it deduplicates txids.

  ```

  ### Checklists

  #### All Submissions:

  * [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk/blob/master/CONTRIBUTING.md)

  #### New Features:

  * [ ] I've added tests for the new feature
  * [ ] I've added docs for the new feature

  #### Bugfixes:

  * [ ] This pull request breaks the existing API
  * [ ] I've added tests to reproduce the issue which are now passing
  * [ ] I'm linking the issue being fixed by this PR

ACKs for top commit:
  oleonardolima:
    ACK 3b6b3ba710492056677349686568f2b2f6c23ee7
  luisschwab:
    ACK 3b6b3ba710492056677349686568f2b2f6c23ee7

Tree-SHA512: 9f1c48c8576abef5ac7b4cc5a64ae9238617fb06cd726e37021f9052931454f920aaaa1c7b1d81acfbb5a80cc46c9f39153e086941aacc8fc259c2d74b4c66b9

5 months agofix(esplora): deduplicate missing txids in fetch_txs_with_outpoints
phrwlk [Tue, 27 Jan 2026 13:10:00 +0000 (13:10 +0000)]
fix(esplora): deduplicate missing txids in fetch_txs_with_outpoints

5 months agoMerge bitcoindevkit/bdk#2160: chore(deps): bump actions/create-github-app-token from...
merge-script [Thu, 19 Mar 2026 21:43:47 +0000 (18:43 -0300)]
Merge bitcoindevkit/bdk#2160: chore(deps): bump actions/create-github-app-token from 2 to 3

9f9d5434249321637a133dfd838edf2051cc3e44 chore(deps): bump actions/create-github-app-token from 2 to 3 (dependabot[bot])

Pull request description:

  Bumps [actions/create-github-app-token](https://github.com/actions/create-github-app-token) from 2 to 3.
  <details>
  <summary>Release notes</summary>
  <p><em>Sourced from <a href="https://github.com/actions/create-github-app-token/releases">actions/create-github-app-token's releases</a>.</em></p>
  <blockquote>
  <h2>v3.0.0</h2>
  <h1><a href="https://github.com/actions/create-github-app-token/compare/v2.2.2...v3.0.0">3.0.0</a> (2026-03-14)</h1>
  <ul>
  <li>feat!: node 24 support (<a href="https://redirect.github.com/actions/create-github-app-token/issues/275">#275</a>) (<a href="https://github.com/actions/create-github-app-token/commit/2e564a0bb8e7cc2b907b2401a2afe177882d4325">2e564a0</a>)</li>
  <li>fix!: require <code>NODE_USE_ENV_PROXY</code> for proxy support (<a href="https://redirect.github.com/actions/create-github-app-token/issues/342">#342</a>) (<a href="https://github.com/actions/create-github-app-token/commit/4451bcbc139f8124b0bf04f968ea2586b17df458">4451bcb</a>)</li>
  </ul>
  <h3>Bug Fixes</h3>
  <ul>
  <li>remove custom proxy handling (<a href="https://redirect.github.com/actions/create-github-app-token/issues/143">#143</a>) (<a href="https://github.com/actions/create-github-app-token/commit/dce0ab05f36f30b22fd14289fd36655c618e4e8e">dce0ab0</a>)</li>
  </ul>
  <h3>BREAKING CHANGES</h3>
  <ul>
  <li>Custom proxy handling has been removed. If you use HTTP_PROXY or HTTPS_PROXY, you must now also set NODE_USE_ENV_PROXY=1 on the action step.</li>
  <li>Requires <a href="https://github.com/actions/runner/releases/tag/v2.327.1">Actions Runner v2.327.1</a> or later if you are using a self-hosted runner.</li>
  </ul>
  <h2>v3.0.0-beta.6</h2>
  <h1><a href="https://github.com/actions/create-github-app-token/compare/v3.0.0-beta.5...v3.0.0-beta.6">3.0.0-beta.6</a> (2026-03-13)</h1>
  <h3>Bug Fixes</h3>
  <ul>
  <li><strong>deps:</strong> bump <code>@actions/core</code> from 1.11.1 to 3.0.0 (<a href="https://redirect.github.com/actions/create-github-app-token/issues/337">#337</a>) (<a href="https://github.com/actions/create-github-app-token/commit/b04413352d4644ac2131b9a90c074f5e93ca18a1">b044133</a>)</li>
  <li><strong>deps:</strong> bump minimatch from 9.0.5 to 9.0.9 (<a href="https://redirect.github.com/actions/create-github-app-token/issues/335">#335</a>) (<a href="https://github.com/actions/create-github-app-token/commit/5cbc65624c9ddc4589492bda7c8b146223e8c3e4">5cbc656</a>)</li>
  <li><strong>deps:</strong> bump the production-dependencies group with 4 updates (<a href="https://redirect.github.com/actions/create-github-app-token/issues/336">#336</a>) (<a href="https://github.com/actions/create-github-app-token/commit/6bda5bc1410576b9a0879ce6076d53345485bba9">6bda5bc</a>)</li>
  <li><strong>deps:</strong> bump undici from 7.16.0 to 7.18.2 (<a href="https://redirect.github.com/actions/create-github-app-token/issues/323">#323</a>) (<a href="https://github.com/actions/create-github-app-token/commit/b4f638f48ee0dcdbb0bc646c48e4cb2a2de847fe">b4f638f</a>)</li>
  </ul>
  <h2>v3.0.0-beta.5</h2>
  <h1><a href="https://github.com/actions/create-github-app-token/compare/v3.0.0-beta.4...v3.0.0-beta.5">3.0.0-beta.5</a> (2026-03-13)</h1>
  <ul>
  <li>fix!: require <code>NODE_USE_ENV_PROXY</code> for proxy support (<a href="https://redirect.github.com/actions/create-github-app-token/issues/342">#342</a>) (<a href="https://github.com/actions/create-github-app-token/commit/d53a1cdfde844c958786293adcaf739ecb8b5eb9">d53a1cd</a>)</li>
  </ul>
  <h3>BREAKING CHANGES</h3>
  <ul>
  <li>Custom proxy handling has been removed. If you use HTTP_PROXY or HTTPS_PROXY, you must now also set NODE_USE_ENV_PROXY=1 on the action step.</li>
  </ul>
  <h2>v3.0.0-beta.4</h2>
  <h1><a href="https://github.com/actions/create-github-app-token/compare/v3.0.0-beta.3...v3.0.0-beta.4">3.0.0-beta.4</a> (2026-03-13)</h1>
  <h3>Bug Fixes</h3>
  <ul>
  <li><strong>deps:</strong> bump <code>@octokit/auth-app</code> from 7.2.1 to 8.0.1 (<a href="https://redirect.github.com/actions/create-github-app-token/issues/257">#257</a>) (<a href="https://github.com/actions/create-github-app-token/commit/bef1eaf1c0ac2b148ee2a0a74c65fbe6db0631f1">bef1eaf</a>)</li>
  <li><strong>deps:</strong> bump <code>@octokit/request</code> from 9.2.3 to 10.0.2 (<a href="https://redirect.github.com/actions/create-github-app-token/issues/256">#256</a>) (<a href="https://github.com/actions/create-github-app-token/commit/5d7307be63501c0070c634b0ae8fec74e8208130">5d7307b</a>)</li>
  <li><strong>deps:</strong> bump glob from 10.4.5 to 10.5.0 (<a href="https://redirect.github.com/actions/create-github-app-token/issues/305">#305</a>) (<a href="https://github.com/actions/create-github-app-token/commit/5480f4325a18c025ee16d7e081413854624e9edc">5480f43</a>)</li>
  <li><strong>deps:</strong> bump p-retry from 6.2.1 to 7.1.0 (<a href="https://redirect.github.com/actions/create-github-app-token/issues/294">#294</a>) (<a href="https://github.com/actions/create-github-app-token/commit/dce3be8b284f45e65caed11a610e2bef738d15b4">dce3be8</a>)</li>
  </ul>
  <!-- raw HTML omitted -->
  </blockquote>
  <p>... (truncated)</p>
  </details>
  <details>
  <summary>Commits</summary>
  <ul>
  <li><a href="https://github.com/actions/create-github-app-token/commit/f8d387b68d61c58ab83c6c016672934102569859"><code>f8d387b</code></a> build(release): 3.0.0 [skip ci]</li>
  <li><a href="https://github.com/actions/create-github-app-token/commit/d2129bd463d4feb8723edeea9437baa7db58e41e"><code>d2129bd</code></a> style: remove extra blank line in release workflow</li>
  <li><a href="https://github.com/actions/create-github-app-token/commit/77b94efc3e5f99a45abdd163fe04a4ebb95e98d6"><code>77b94ef</code></a> build: refresh generated artifacts</li>
  <li><a href="https://github.com/actions/create-github-app-token/commit/3ab4c6689898955f913a485593b36b197c6dbbdc"><code>3ab4c66</code></a> chore: move undici to devDependencies</li>
  <li><a href="https://github.com/actions/create-github-app-token/commit/739cf66feb937a443e4b6b7626bedd98f9fef6df"><code>739cf66</code></a> docs: update README action versions</li>
  <li><a href="https://github.com/actions/create-github-app-token/commit/db40289976a36527816d4f6f45765fdee71f134b"><code>db40289</code></a> build(deps): bump actions versions in test.yml</li>
  <li><a href="https://github.com/actions/create-github-app-token/commit/496a7ac4eb472eeac44d67818d1ce7f5e9e5fc97"><code>496a7ac</code></a> test: migrate from AVA to Node.js native test runner (<a href="https://redirect.github.com/actions/create-github-app-token/issues/346">#346</a>)</li>
  <li><a href="https://github.com/actions/create-github-app-token/commit/3870dc3051e3f1fc3a2faa17bcbb00f31fe1dd6c"><code>3870dc3</code></a> Rename end-to-end proxy job in test workflow</li>
  <li><a href="https://github.com/actions/create-github-app-token/commit/4451bcbc139f8124b0bf04f968ea2586b17df458"><code>4451bcb</code></a> fix!: require <code>NODE_USE_ENV_PROXY</code> for proxy support (<a href="https://redirect.github.com/actions/create-github-app-token/issues/342">#342</a>)</li>
  <li><a href="https://github.com/actions/create-github-app-token/commit/dce0ab05f36f30b22fd14289fd36655c618e4e8e"><code>dce0ab0</code></a> fix: remove custom proxy handling (<a href="https://redirect.github.com/actions/create-github-app-token/issues/143">#143</a>)</li>
  <li>Additional commits viewable in <a href="https://github.com/actions/create-github-app-token/compare/v2...v3">compare view</a></li>
  </ul>
  </details>
  <br />

  [![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=actions/create-github-app-token&package-manager=github_actions&previous-version=2&new-version=3)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

  Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`.

  [//]: # (dependabot-automerge-start)
  [//]: # (dependabot-automerge-end)

  ---

  <details>
  <summary>Dependabot commands and options</summary>
  <br />

  You can trigger Dependabot actions by commenting on this PR:
  - `@dependabot rebase` will rebase this PR
  - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
  - `@dependabot show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency
  - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

  </details>

ACKs for top commit:
  oleonardolima:
    ACK 9f9d5434249321637a133dfd838edf2051cc3e44

Tree-SHA512: a7bbe2aee115419d2e1cd40e9a9733672dc5624633c435541f38532867db7336b5decf15d200ba2eea0b83104328fa151b924f69db54b8686714dd39ce26f647

5 months agoMerge bitcoindevkit/bdk#2159: chore(deps): bump Swatinem/rust-cache from 2.8.2 to...
merge-script [Thu, 19 Mar 2026 21:27:03 +0000 (18:27 -0300)]
Merge bitcoindevkit/bdk#2159: chore(deps): bump Swatinem/rust-cache from 2.8.2 to 2.9.1

88d5683f3f16dcc701c9762734a0641660fe06ec chore(deps): bump Swatinem/rust-cache from 2.8.2 to 2.9.1 (dependabot[bot])

Pull request description:

  Bumps [Swatinem/rust-cache](https://github.com/swatinem/rust-cache) from 2.8.2 to 2.9.1.
  <details>
  <summary>Release notes</summary>
  <p><em>Sourced from <a href="https://github.com/swatinem/rust-cache/releases">Swatinem/rust-cache's releases</a>.</em></p>
  <blockquote>
  <h2>v2.9.1</h2>
  <p>Fix regression in hash calculation</p>
  <p><strong>Full Changelog</strong>: <a href="https://github.com/Swatinem/rust-cache/compare/v2.9.0...v2.9.1">https://github.com/Swatinem/rust-cache/compare/v2.9.0...v2.9.1</a></p>
  <h2>v2.9.0</h2>
  <h2>What's Changed</h2>
  <ul>
  <li>Add support for running rust-cache commands from within a Nix shell by <a href="https://github.com/marc0246"><code>@marc0246</code></a> in <a href="https://redirect.github.com/Swatinem/rust-cache/pull/290">Swatinem/rust-cache#290</a></li>
  <li>Bump taiki-e/install-action from 2.62.57 to 2.62.60 in the actions group by <a href="https://github.com/dependabot"><code>@dependabot</code></a>[bot] in <a href="https://redirect.github.com/Swatinem/rust-cache/pull/291">Swatinem/rust-cache#291</a></li>
  <li>Bump the actions group across 1 directory with 5 updates by <a href="https://github.com/dependabot"><code>@dependabot</code></a>[bot] in <a href="https://redirect.github.com/Swatinem/rust-cache/pull/296">Swatinem/rust-cache#296</a></li>
  <li>Bump the prd-major group with 3 updates by <a href="https://github.com/dependabot"><code>@dependabot</code></a>[bot] in <a href="https://redirect.github.com/Swatinem/rust-cache/pull/294">Swatinem/rust-cache#294</a></li>
  <li>Bump <code>@types/node</code> from 24.10.1 to 25.0.2 in the dev-major group by <a href="https://github.com/dependabot"><code>@dependabot</code></a>[bot] in <a href="https://redirect.github.com/Swatinem/rust-cache/pull/295">Swatinem/rust-cache#295</a></li>
  <li>Consider all installed toolchains in cache key by <a href="https://github.com/tamird"><code>@tamird</code></a> in <a href="https://redirect.github.com/Swatinem/rust-cache/pull/293">Swatinem/rust-cache#293</a></li>
  <li>Compare case-insenitively for full cache key match by <a href="https://github.com/kbriggs"><code>@kbriggs</code></a> in <a href="https://redirect.github.com/Swatinem/rust-cache/pull/303">Swatinem/rust-cache#303</a></li>
  <li>Migrate to <code>node24</code> runner by <a href="https://github.com/rhysd"><code>@rhysd</code></a> in <a href="https://redirect.github.com/Swatinem/rust-cache/pull/314">Swatinem/rust-cache#314</a></li>
  <li>Bump the actions group across 1 directory with 7 updates by <a href="https://github.com/dependabot"><code>@dependabot</code></a>[bot] in <a href="https://redirect.github.com/Swatinem/rust-cache/pull/312">Swatinem/rust-cache#312</a></li>
  <li>Bump the prd-minor group across 1 directory with 2 updates by <a href="https://github.com/dependabot"><code>@dependabot</code></a>[bot] in <a href="https://redirect.github.com/Swatinem/rust-cache/pull/307">Swatinem/rust-cache#307</a></li>
  <li>Bump <code>@types/node</code> from 25.0.2 to 25.2.2 in the dev-minor group by <a href="https://github.com/dependabot"><code>@dependabot</code></a>[bot] in <a href="https://redirect.github.com/Swatinem/rust-cache/pull/309">Swatinem/rust-cache#309</a></li>
  </ul>
  <h2>New Contributors</h2>
  <ul>
  <li><a href="https://github.com/marc0246"><code>@marc0246</code></a> made their first contribution in <a href="https://redirect.github.com/Swatinem/rust-cache/pull/290">Swatinem/rust-cache#290</a></li>
  <li><a href="https://github.com/tamird"><code>@tamird</code></a> made their first contribution in <a href="https://redirect.github.com/Swatinem/rust-cache/pull/293">Swatinem/rust-cache#293</a></li>
  <li><a href="https://github.com/kbriggs"><code>@kbriggs</code></a> made their first contribution in <a href="https://redirect.github.com/Swatinem/rust-cache/pull/303">Swatinem/rust-cache#303</a></li>
  </ul>
  <p><strong>Full Changelog</strong>: <a href="https://github.com/Swatinem/rust-cache/compare/v2.8.2...v2.9.0">https://github.com/Swatinem/rust-cache/compare/v2.8.2...v2.9.0</a></p>
  </blockquote>
  </details>
  <details>
  <summary>Changelog</summary>
  <p><em>Sourced from <a href="https://github.com/Swatinem/rust-cache/blob/master/CHANGELOG.md">Swatinem/rust-cache's changelog</a>.</em></p>
  <blockquote>
  <h1>Changelog</h1>
  <h2>2.9.1</h2>
  <ul>
  <li>Fix regression in hash calculation</li>
  </ul>
  <h2>2.9.0</h2>
  <ul>
  <li>Update to <code>node24</code></li>
  <li>Support running from within a <code>nix</code> shell</li>
  <li>Consider all installed toolchains for cache key</li>
  <li>Use case-insensitive comparison to determine exact cache hit</li>
  </ul>
  <h2>2.8.2</h2>
  <ul>
  <li>Don't overwrite env for cargo-metadata call</li>
  </ul>
  <h2>2.8.1</h2>
  <ul>
  <li>Set empty <code>CARGO_ENCODED_RUSTFLAGS</code> when retrieving metadata</li>
  <li>Various dependency updates</li>
  </ul>
  <h2>2.8.0</h2>
  <ul>
  <li>Add support for <code>warpbuild</code> cache provider</li>
  <li>Add new <code>cache-workspace-crates</code> feature</li>
  </ul>
  <h2>2.7.8</h2>
  <ul>
  <li>Include CPU arch in the cache key</li>
  </ul>
  <h2>2.7.7</h2>
  <ul>
  <li>Also cache <code>cargo install</code> metadata</li>
  </ul>
  <h2>2.7.6</h2>
  <ul>
  <li>Allow opting out of caching $CARGO_HOME/bin</li>
  <li>Add runner OS in cache key</li>
  <li>Adds an option to do lookup-only of the cache</li>
  </ul>
  <h2>2.7.5</h2>
  <ul>
  <li>Support Cargo.lock format cargo-lock v4</li>
  <li>Only run macOsWorkaround() on macOS</li>
  </ul>
  <h2>2.7.3</h2>
  <ul>
  <li>Work around upstream problem that causes cache saving to hang for minutes.</li>
  </ul>
  <!-- raw HTML omitted -->
  </blockquote>
  <p>... (truncated)</p>
  </details>
  <details>
  <summary>Commits</summary>
  <ul>
  <li><a href="https://github.com/Swatinem/rust-cache/commit/c19371144df3bb44fab255c43d04cbc2ab54d1c4"><code>c193711</code></a> 2.9.1</li>
  <li><a href="https://github.com/Swatinem/rust-cache/commit/781e8d91ab29deb65464798965e49853f963b561"><code>781e8d9</code></a> try reverting pipeline change</li>
  <li><a href="https://github.com/Swatinem/rust-cache/commit/3d1fa4654a5786f5537b1d31acd0f35e56de9924"><code>3d1fa46</code></a> add changelog</li>
  <li><a href="https://github.com/Swatinem/rust-cache/commit/c676846f29d98ff6b0106d3608c7ffd4048af17b"><code>c676846</code></a> 2.9.0</li>
  <li><a href="https://github.com/Swatinem/rust-cache/commit/bf71d02c11df9d5253618f39943e9dd59f7fd5a9"><code>bf71d02</code></a> bump dependencies and rebuild</li>
  <li><a href="https://github.com/Swatinem/rust-cache/commit/8a02ed5e290d8afc7e587930243f3016b3223f50"><code>8a02ed5</code></a> Bump <code>@types/node</code> from 25.0.2 to 25.2.2 in the dev-minor group (<a href="https://redirect.github.com/swatinem/rust-cache/issues/309">#309</a>)</li>
  <li><a href="https://github.com/Swatinem/rust-cache/commit/390157d4874246aff722dd7f77e641fcae197678"><code>390157d</code></a> Bump the prd-minor group across 1 directory with 2 updates (<a href="https://redirect.github.com/swatinem/rust-cache/issues/307">#307</a>)</li>
  <li><a href="https://github.com/Swatinem/rust-cache/commit/68500c182e89a3f56d9b1de095d7e62f0ea5b8bf"><code>68500c1</code></a> Bump the actions group across 1 directory with 7 updates (<a href="https://redirect.github.com/swatinem/rust-cache/issues/312">#312</a>)</li>
  <li><a href="https://github.com/Swatinem/rust-cache/commit/1a8384176d7ed15c323a201c65073983cdb5a5be"><code>1a83841</code></a> Migrate to <code>node24</code> runner (<a href="https://redirect.github.com/swatinem/rust-cache/issues/314">#314</a>)</li>
  <li><a href="https://github.com/Swatinem/rust-cache/commit/11da8522bc3856a8fbc565f1d1530989c793d67d"><code>11da852</code></a> Compare case-insenitively for full cache key match (<a href="https://redirect.github.com/swatinem/rust-cache/issues/303">#303</a>)</li>
  <li>Additional commits viewable in <a href="https://github.com/swatinem/rust-cache/compare/779680da715d629ac1d338a641029a2f4372abb5...c19371144df3bb44fab255c43d04cbc2ab54d1c4">compare view</a></li>
  </ul>
  </details>
  <br />

  [![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=Swatinem/rust-cache&package-manager=github_actions&previous-version=2.8.2&new-version=2.9.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

  Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`.

  [//]: # (dependabot-automerge-start)
  [//]: # (dependabot-automerge-end)

  ---

  <details>
  <summary>Dependabot commands and options</summary>
  <br />

  You can trigger Dependabot actions by commenting on this PR:
  - `@dependabot rebase` will rebase this PR
  - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
  - `@dependabot show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency
  - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

  </details>

ACKs for top commit:
  oleonardolima:
    ACK 88d5683f3f16dcc701c9762734a0641660fe06ec

Tree-SHA512: 400bb47c45956f5ad0e73c50ff5a0878093839d52e13bec4b4afefefe5809a9410601d2d7dc190be4d88c8add14b5e7a42007b2cd1abaaa2f4cd17691c79ef6f

5 months agochore(deps): bump actions/create-github-app-token from 2 to 3 github/dependabot/github_actions/actions/create-github-app-token-3
dependabot[bot] [Mon, 16 Mar 2026 05:46:57 +0000 (05:46 +0000)]
chore(deps): bump actions/create-github-app-token from 2 to 3

Bumps [actions/create-github-app-token](https://github.com/actions/create-github-app-token) from 2 to 3.
- [Release notes](https://github.com/actions/create-github-app-token/releases)
- [Commits](https://github.com/actions/create-github-app-token/compare/v2...v3)

---
updated-dependencies:
- dependency-name: actions/create-github-app-token
  dependency-version: '3'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
5 months agochore(deps): bump Swatinem/rust-cache from 2.8.2 to 2.9.1 github/dependabot/github_actions/Swatinem/rust-cache-2.9.1
dependabot[bot] [Mon, 16 Mar 2026 05:46:54 +0000 (05:46 +0000)]
chore(deps): bump Swatinem/rust-cache from 2.8.2 to 2.9.1

Bumps [Swatinem/rust-cache](https://github.com/swatinem/rust-cache) from 2.8.2 to 2.9.1.
- [Release notes](https://github.com/swatinem/rust-cache/releases)
- [Changelog](https://github.com/Swatinem/rust-cache/blob/master/CHANGELOG.md)
- [Commits](https://github.com/swatinem/rust-cache/compare/779680da715d629ac1d338a641029a2f4372abb5...c19371144df3bb44fab255c43d04cbc2ab54d1c4)

---
updated-dependencies:
- dependency-name: Swatinem/rust-cache
  dependency-version: 2.9.1
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
5 months agoMerge bitcoindevkit/bdk#2135: docs: Document TxUpdate temporal context requirements...
merge-script [Thu, 12 Mar 2026 14:45:19 +0000 (14:45 +0000)]
Merge bitcoindevkit/bdk#2135: docs: Document TxUpdate temporal context requirements (supports Wizardsardine audit recommendation)

b69d7bfce32d20a5849052a2e61bf8d8bff813a6 docs: document TxUpdate temporal context requirements (Rafael Turon)

Pull request description:

  Closes #2133

  This introduces clear temporal context **documentation** to the `TxUpdate` struct, explicitly stating that entries must have either `anchors` or `seen_ats` to be considered canonical and contribute to wallet balances.

  It also explicitly documents the `seen_ats` HashSet signature to prevent usage errors when writing custom chain sources.

  This fulfills the recommendation outlined in the Wizardsardine BDK Audit Report (Q4 2024).

  ### Description
  This primarily affects developers building **custom chain sources** — anyone constructing `Update` structs outside of `bdk_electrum`/`bdk_esplora`/`bdk_bitcoind_rpc`.
  As the ecosystem grows (streaming Electrum, Nostr relay sync, compact block filters, custom backends), more developers will encounter this undocumented contract.

  ### What I Changed

  *1. Doc comment on `TxUpdate` struct*
  * **`anchors` or `seen_ats`** are stored in the graph but do not affect the balance.
  * **`seen_ats` collection type**: `TxUpdate::seen_ats` is a `BTreeSet<(Txid, u64)>`, requiring `.insert((txid, timestamp))`.

  *2. Doc comment on `Wallet::apply_update()`*
  * **TxGraph `apply_update`**: transactions without temporal context note.
  * **IndexedTxGraph `apply_update`**: transactions without temporal context note.

  ### Impact
  This is just a documentation fix - no code changes, no breaking changes.

  ### Checklists

  #### All Submissions:

  * [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk/blob/master/CONTRIBUTING.md)

ACKs for top commit:
  evanlinjin:
    ACK b69d7bfce32d20a5849052a2e61bf8d8bff813a6

Tree-SHA512: 669fbd2c23f7615c697d550ab448b3fd72955223cef4146d6719e2d0c26b959253ce987eebf737366968cb88e5477a897289274ddf78c1ffd338be4e5d795f4b

5 months agodocs: document TxUpdate temporal context requirements
Rafael Turon [Thu, 5 Mar 2026 21:02:06 +0000 (18:02 -0300)]
docs: document TxUpdate temporal context requirements

This introduces clear temporal context documentation to the `TxUpdate`
struct, explicitly stating that entries must have either `anchors` or
`seen_ats` to be considered canonical and contribute to wallet balances.

This fulfills the recommendation outlined in the Wizardsardine
BDK Audit Report (Q4 2024).

Signed-off-by: Rafael Turon <3598269+rafaelturon@users.noreply.github.com>
5 months agoMerge bitcoindevkit/bdk#2120: fix(chain): forward `confirmation_height_upper_bound...
merge-script [Fri, 6 Mar 2026 23:03:08 +0000 (18:03 -0500)]
Merge bitcoindevkit/bdk#2120: fix(chain): forward `confirmation_height_upper_bound` in `Anchor` implementation for `&A`

5d97e136ae89854c53add90d9da9131fec56c4a0 fix(chain): forward `confirmation_height_upper_bound` in `Anchor` impl for `&A` (志宇)

Pull request description:

  ### Description

  The blanket `Anchor` impl for `&A` was missing the `confirmation_height_upper_bound` method, causing it to fall back to the default implementation instead of delegating to the inner type.

  ### Changelog notice

  ```md
  Fixed:

  - The `Anchor::confirmation_height_upper_bound` impl was missing for `&A`, causing it to fallback to the default impl.
  ```

  ### Checklists

  #### All Submissions:

  * [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk/blob/master/CONTRIBUTING.md)

  #### Bugfixes:

  ~~* [ ] This pull request breaks the existing API~~
  ~~* [ ] I've added tests to reproduce the issue which are now passing~~
  ~~* [ ] I'm linking the issue being fixed by this PR~~

ACKs for top commit:
  ValuedMammal:
    ACK 5d97e136ae89854c53add90d9da9131fec56c4a0
  Dmenec:
    tACK 5d97e136ae89854c53add90d9da9131fec56c4a0

Tree-SHA512: baea97e5adb6fb1953e570339ec6826aa1ed84ff7914c56a4b1480c7df9218c782d7343a458e4f0e2427c12487dddd89cf067f722f868ca0c6584b44d731e56b

5 months agofix(chain): forward `confirmation_height_upper_bound` in `Anchor` impl for `&A`
志宇 [Sat, 14 Feb 2026 00:21:20 +0000 (00:21 +0000)]
fix(chain): forward `confirmation_height_upper_bound` in `Anchor` impl for `&A`

The blanket `Anchor` impl for `&A` was missing the
`confirmation_height_upper_bound` method, causing it to fall back to
the default implementation instead of delegating to the inner type.

5 months agoMerge bitcoindevkit/bdk#2137: Replace `std::error::Error` with `core::error::Error`
merge-script [Fri, 6 Mar 2026 06:49:38 +0000 (06:49 +0000)]
Merge bitcoindevkit/bdk#2137: Replace `std::error::Error` with `core::error::Error`

2a92fd365ea7f45e56b3027989b5cdf79ef4773a chore: use `core::error::Error` (Luis Schwab)

Pull request description:

  Closes #2132

  The `Error` trait is stable as of 1.81.0, so import it from `core` instead.

ACKs for top commit:
  evanlinjin:
    ACK 2a92fd365ea7f45e56b3027989b5cdf79ef4773a

Tree-SHA512: ce843843a932815b0991b4f5d064471876f103a4d2d8f12ac47eecfd1263ff79a833e937e81f1a98303f9002115dc792b6f4837d8752f49c6ab080762d510ee4

5 months agoMerge bitcoindevkit/bdk#2136: Fix `bdk_esplora` compilation error by bumping `esplora...
merge-script [Fri, 6 Mar 2026 06:37:50 +0000 (06:37 +0000)]
Merge bitcoindevkit/bdk#2136: Fix `bdk_esplora` compilation error by bumping `esplora_client` version

1804699d372ade32825e444c9939626b94731596 fix(esplora): Bump `esplora-client` to `0.12.3` (志宇)

Pull request description:

  ### Description

  I didn't realize #2053 didn't actually compile when I merged it. This PR fixes this by bumping `esplora_client` to `0.12.3` so that the `.get_block_infos` method is always available.

  ### Changelog

  ```md
  Fixed:
  - Bump `esplora_client` to `0.12.3` so that the `.get_block_infos` method is always available.
  ```

  ### Checklists

  #### All Submissions:

  * [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk/blob/master/CONTRIBUTING.md)

ACKs for top commit:
  oleonardolima:
    ACK 1804699d372ade32825e444c9939626b94731596
  luisschwab:
    ACK 1804699d372ade32825e444c9939626b94731596

Tree-SHA512: 1d80cab1173a77286b8946da9c89dce5e86b5d91bca4cb9a6e30b7b0dabcefb6b3ced858c8b235198970a1a7ce368db74ce85735e0a30ae02f95ea3c0c75ef76

5 months agochore: use `core::error::Error`
Luis Schwab [Fri, 6 Mar 2026 01:02:06 +0000 (22:02 -0300)]
chore: use `core::error::Error`

The `Error` trait is stable as of 1.81.0, so import it from `core` instead.

5 months agofix(esplora): Bump `esplora-client` to `0.12.3`
志宇 [Thu, 5 Mar 2026 23:23:14 +0000 (23:23 +0000)]
fix(esplora): Bump `esplora-client` to `0.12.3`

This is required for `.get_block_infos` to be available.

5 months agoMerge bitcoindevkit/bdk#2100: Make mining more flexible in `bdk_testenv`
merge-script [Thu, 5 Mar 2026 22:49:33 +0000 (22:49 +0000)]
Merge bitcoindevkit/bdk#2100: Make mining more flexible in `bdk_testenv`

9b1111fd18eed69839ca10e8cacb3b513a8a7aa4 feat(testenv): add `mine_block` with custom timestamp and coinbase address (志宇)

Pull request description:

  ### Description

  Add `mine_block` to `bdk_testenv::Env` with custom timestamp and coinbase address. This allows us to test timelocked transactions.

  ### Changelog notice

  ```md
  Added
  - `mine_block` method to `bdk_testenv::Env` with custom `MineParams`. Blocks can be mined with no transactions, contain custom timestamp and custom coinbase address.
  - `min_time_for_next_block` and `get_block_template` helper methods.
  ```

  ### Checklists

  #### All Submissions:

  * [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk/blob/master/CONTRIBUTING.md)

  #### New Features:

  * [x] I've added tests for the new feature
  * [x] I've added docs for the new feature

ACKs for top commit:
  oleonardolima:
    ACK 9b1111fd18eed69839ca10e8cacb3b513a8a7aa4

Tree-SHA512: 97d839a2c57fef1fab354ce082d309c1ffd4166cacc437454e0baddd9b682dabdfe4aac99f1095e2da6ec0f520c6e84825b9a719f764ea4435deeac61524e33d

5 months agofeat(testenv): add `mine_block` with custom timestamp and coinbase address
志宇 [Sat, 24 Jan 2026 10:20:23 +0000 (10:20 +0000)]
feat(testenv): add `mine_block` with custom timestamp and coinbase address

Refactor block mining in `TestEnv` to use `getblocktemplate` RPC properly:

- Add `MineParams` struct to configure mining (empty blocks, custom
  timestamp, custom coinbase address)
- Add `mine_block()` method that builds blocks from the template with
  proper BIP34 coinbase scriptSig, witness commitment, and merkle root
- Add `min_time_for_next_block()` and `get_block_template()` helpers
- Refactor `mine_empty_block()` to use the new `mine_block()` API
- Include mempool transactions when `empty: false`

6 months agoMerge bitcoindevkit/bdk#2053: Remove panic from stop gap scan loop
merge-script [Tue, 3 Mar 2026 03:41:59 +0000 (03:41 +0000)]
Merge bitcoindevkit/bdk#2053: Remove panic from stop gap scan loop

745f805068ce33ee830b497c28fd37eb4c1aafb1 fix: remove panic from stop gap scan loop (Matthew)

Pull request description:

  <!-- You can erase any parts of this template not applicable to your Pull Request. -->

  ### Description

  This PR addresses a panic path in stop gap scan loop. Removes `expect` used to compute gap boundary and instead tracks `consecutive_unused` with `gap_limit = stop_gap.max(1)` to decide when to stop scanning.

  Spurred by trying to address https://github.com/bitcoindevkit/bdk_wallet/issues/30 for Esplora

  ### Notes to the reviewers

  Open to any and all feedback on this.

  Behavior is unchanged for typical cases, it just avoids a panic in the control flow.

  ### Changelog notice

  ```
  ### Fix:
  - Avoid a panic in the Esplora stop‑gap scan loop by tracking consecutive unused scripts to compute the gap boundary.
  ```

  ### Checklists

  #### All Submissions:

  * [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk/blob/master/CONTRIBUTING.md)

  #### New Features:

  * [ ] I've added tests for the new feature
  * [ ] I've added docs for the new feature

  #### Bugfixes:

  * [ ] This pull request breaks the existing API
  * [ ] I've added tests to reproduce the issue which are now passing
  * [ ] I'm linking the issue being fixed by this PR

ACKs for top commit:
  luisschwab:
    ACK 745f805068ce33ee830b497c28fd37eb4c1aafb1
  evanlinjin:
    ACK 745f805068ce33ee830b497c28fd37eb4c1aafb1

Tree-SHA512: 50b45955d7807996d871453dac61caf1ce25e85d31e261ebd670749b6370e92318d43070147aa67df5b4a904bd9b353b08711e043007c79a125cfd7d9a108da3

6 months agochore(deps): bump actions/upload-artifact from 6 to 7 github/dependabot/github_actions/actions/upload-artifact-7
dependabot[bot] [Mon, 2 Mar 2026 05:51:02 +0000 (05:51 +0000)]
chore(deps): bump actions/upload-artifact from 6 to 7

Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 6 to 7.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](https://github.com/actions/upload-artifact/compare/v6...v7)

---
updated-dependencies:
- dependency-name: actions/upload-artifact
  dependency-version: '7'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
6 months agoMerge bitcoindevkit/bdk#2130: fix(bdk_esplora): use `get_blocks_infos` instead of...
merge-script [Tue, 24 Feb 2026 17:32:12 +0000 (14:32 -0300)]
Merge bitcoindevkit/bdk#2130: fix(bdk_esplora): use `get_blocks_infos` instead of `get_blocks`

a88017009b193d0f56dd0e6aac0efd8d31112e88 fix(bdk_esplora): use `get_blocks_infos` instead of `get_blocks` (Leonardo Lima)

Pull request description:

  ### Description

  The `get_blocks` method from `esplora-client` has been deprecated on the latest release `v0.12.3`. I'm updating it to use newly added one: `get_blocks_infos` in order to fix the deprecation warning.

  ### Changelog notice

  ```
  ### Changed
  - fix(bdk_esplora): use `get_block_infos` instead of deprecated `get_blocks`
  ```

  ### Checklists

  #### All Submissions:

  * [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk/blob/master/CONTRIBUTING.md)

  #### New Features:

  * [x] I've added tests for the new feature
  * [x] I've added docs for the new feature

ACKs for top commit:
  luisschwab:
    ACK a88017009b193d0f56dd0e6aac0efd8d31112e88
  reez:
    ACK a88017009b193d0f56dd0e6aac0efd8d31112e88

Tree-SHA512: 21afb07a10b1c6da519b414cd6c23aeff42d4e9f2b76ecf4c1a6f9abee1a2609c9ff6e6c81608c2497eb9831faf1687355c9428e0f3c48ca4efaa3a2003355a8

6 months agofix(bdk_esplora): use `get_blocks_infos` instead of `get_blocks`
Leonardo Lima [Tue, 24 Feb 2026 14:22:03 +0000 (11:22 -0300)]
fix(bdk_esplora): use `get_blocks_infos` instead of `get_blocks`

6 months agofix: remove panic from stop gap scan loop
Matthew [Mon, 29 Sep 2025 21:00:47 +0000 (16:00 -0500)]
fix: remove panic from stop gap scan loop

6 months agoMerge bitcoindevkit/bdk#2123: ci: automated update to rustc 1.93.1
merge-script [Fri, 20 Feb 2026 15:42:14 +0000 (09:42 -0600)]
Merge bitcoindevkit/bdk#2123: ci: automated update to rustc 1.93.1

b8642d477a583aee08207bb5e24641400c2d94a2 ci: automated update to rustc 1.93.1 (Github Action)

Pull request description:

  Automated update to Github CI workflow `cont_integration.yml` by [create-pull-request](https://github.com/peter-evans/create-pull-request) GitHub action

ACKs for top commit:
  notmandatory:
    ACK b8642d477a583aee08207bb5e24641400c2d94a2

Tree-SHA512: 35a10e9f751f00093344e65bfdf9869c6373c878ad556927c8856605f08f01362d9615e9e26f386c94e69f62285e28edd411f7c3460827415489846c535fd35f