• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

bitcoindevkit / bdk / 10832170342
79%

Build:
DEFAULT BRANCH: master
Ran 12 Sep 2024 01:53PM UTC
Jobs 1
Files 47
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

12 Sep 2024 01:46PM UTC coverage: 82.58% (+0.7%) from 81.887%
10832170342

push

github

evanlinjin
Merge bitcoindevkit/bdk#1581: Allow custom fallback algorithm for bnb

65be4ead0 test(coin_selection): add test for deterministic utxo selection (Steve Myers)
c18204d05 feat(wallet)!: allow custom fallback algorithm for bnb (志宇)

Pull request description:

  ### Description

  This allows the caller to set a custom fallback algorithm when using `BranchAndBoundCoinSelection`. Previously, you were forced into using `SingleRandomDraw`.

  Signature of `CoinSelectionAlgorithm::coin_select` has been changed to take in a `&mut RangCore`. This allows us to pass the random number generator directly to the cs algorithm.

  Single random draw is now it's own type `SingleRandomDraw` and impls `CoinSelectionAlgorithm`.

  `BranchAndBoundCoinSelection` now handles it's own fallback algorithm internally, and a generic type parameter is added to specify the fallback algorithm.

  `coin_selection::Error` is renamed to `InsufficientFunds` and the BnB error variants are removed. The BnB error variants are no longer needed since those cases are handled internally by `BranchAndBoundCoinSelection` (via calling the fallback algorithm).

  ### Notes to the reviewers

  This is breaking change. Not sure how useful this is for our users. If it's deemed useful, consider including in beta.

  ### Changelog notice

  * Changed `CoinSelectionAlgorithm::coin_select` to take in an additional `&mut RangCore` variable. This allows us to pass a random number generator directly to the cs algorithm.
  * Added `SingeRandomDraw` type which impls `CoinSelectAlgorithm`.
  * Changed `BranchAndBoundCoinSelection` to call the fallback internally. An additional generic parameter is added set this.
  * Changed `coin_selection::Error` to `coin_selection::InsufficientFunds` (which is now a struct) and therefore removing bnb error variants.

  ### Checklists

  #### All Submissions:

  * [x] I've signed all my commits
  * [x] I followed ... (continued)

245 of 258 new or added lines in 3 files covered. (94.96%)

2 existing lines in 1 file now uncovered.

11316 of 13703 relevant lines covered (82.58%)

13651.38 hits per line

Jobs
ID Job ID Ran Files Coverage
1 10832170342.1 12 Sep 2024 01:53PM UTC 0
82.58
GitHub Action Run
Source Files on build 10832170342
Detailed source file information is not available for this build.
  • Back to Repo
  • 1b50d88e on github
  • Prev Build on master (#10818492517)
  • Next Build on master (#10838824920)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc