Commit Graph

1147 Commits

Author SHA1 Message Date
Steve Myers
4f7355ec82 [ci] Fix all-keys and cli-utils tests 2020-10-28 21:34:04 -07:00
Steve Myers
7b9df5bbe5 [ci] Enable clippy and test for optional features 2020-10-28 17:51:03 -07:00
Steve Myers
8d04128c74 [ci] Fix or ignore clippy warnings for all optional features except compact_filters 2020-10-28 17:50:12 -07:00
Murch
457e70e70f Rename get_must_may_use_utxos to preselect_utxos 2020-10-27 23:24:03 -04:00
Murch
84aee3baab Rename may_use_utxos to optional_uxtos 2020-10-27 23:24:03 -04:00
Alekos Filini
297e92a829 Merge commit 'refs/pull/115/head' of github.com:bitcoindevkit/bdk 2020-10-27 11:04:00 +01:00
Steve Myers
8927d68a69 [descriptor] Comment out incomplete ExtractPolicy trait tests 2020-10-26 12:48:31 -07:00
Steve Myers
3a80e87ccb [descriptor] Fix compile errors after rebase 2020-10-26 12:48:27 -07:00
Steve Myers
e31f5306d2 [descriptor] Add descriptor macro tests 2020-10-26 12:48:23 -07:00
Steve Myers
9fa9a304b9 [descriptor] Add get_checksum tests, cleanup tests 2020-10-26 12:48:19 -07:00
Steve Myers
bc0e9c9831 [descriptor] Add ExtractPolicy trait tests 2020-10-26 12:48:15 -07:00
Murch
43a51a1ec3 Rename must_use_utxos to required_utxos 2020-10-26 14:40:44 -04:00
Murch
b2ec6e3683 Rename DumbCS to LargestFirstCoinSelection 2020-10-26 14:20:44 -04:00
LLFourn
8d65581825 Incorporate RBF rules into utxo selection function 2020-10-23 13:54:59 +11:00
LLFourn
a6b70af2fb [wallet] Stop implicitly enforcing manaul selection by .add_utxo
This makes it possible to choose a UTXO manually without having to
choose them *all* manually. I introduced the `manually_selected_only`
option to enforce that only manually selected utxos can be used.

To stop the cli semantics changing I made the `utxos` keep the old
behaviour by calling `manually_selected_only`.
2020-10-23 13:54:59 +11:00
LLFourn
b87c7c5dc7 [wallet] Make 'unspendable' into a HashSet
to avoid awkwardly later on.
2020-10-23 13:54:59 +11:00
LLFourn
c549281ace [wallet] Replace ChangeSpendPolicy::filter_utxos with a predicate
To make composing it with other filtering conditions easier.
2020-10-23 13:54:59 +11:00
Richard Ulrich
365a91f805 Merging two match expressions for fee calculation 2020-10-22 13:41:26 +02:00
Richard Ulrich
49894ffa6d Implementing review suggestions from afilini 2020-10-22 09:11:58 +02:00
Richard Ulrich
759f6eac43 complying with clippy from the github CI 2020-10-20 18:22:37 +02:00
Richard Ulrich
27890cfcff allow to definie static fees for transactions Fixes #137 2020-10-20 18:10:59 +02:00
Alekos Filini
872d55cb4c [wallet] Default to SIGHASH_ALL if not specified
Closes #133
2020-10-16 15:40:30 +02:00
Alekos Filini
12635e603f [wallet] Refactor Wallet::bump_fee() 2020-10-16 14:49:05 +02:00
Alekos Filini
a5713a8348 [wallet] Improve CoinSelectionAlgorithm
Implement the improvements described in issue #121.

Closes #121, closes #131.
2020-10-16 14:30:44 +02:00
LLFourn
17f7294c8e [wallet] Make coin_select take may/must use utxo lists
so that in the future you can add a UTXO that you *must* spend and let
the coin selection fill in the rest.

This partially addresses #121
2020-10-16 14:28:22 +02:00
LLFourn
64b4cfe308 Use collect to avoid iter unwrapping Options 2020-10-15 13:41:36 +11:00
Alekos Filini
0caad5f3d9 [blockchain] Fix receiving a coinbase using Electrum/Esplora
Closes #107
2020-10-13 11:56:59 +02:00
Alekos Filini
848b52c50e [keys]: Re-export tiny-bip39
Closes #104
2020-10-13 10:57:40 +02:00
Alekos Filini
100f0aaa0a Bump rust-bitcoin to 0.25, fix Cargo dependencies
Closes #112, closes #113, closes #124
2020-10-13 10:39:48 +02:00
Steve Myers
69ef56cfed [ci] Remove travis.yml 2020-10-12 09:30:20 -07:00
Steve Myers
070d481849 [ci] Fix clippy warnings for 1.47.0 2020-10-10 10:31:08 -07:00
Steve Myers
98803b2573 [ci] Use bitcoindevkit/electrs base image for electrum tests 2020-10-10 10:31:08 -07:00
Steve Myers
aea9abff8a [ci] Fix clippy warnings, enable clippy checks 2020-10-10 10:31:07 -07:00
Steve Myers
6402fd07c2 [ci] Consolidate build, test, clippy jobs 2020-10-10 10:31:07 -07:00
Alekos Filini
8e7b195e93 Add a Discord badge to the README 2020-10-07 10:00:06 +02:00
Steve Myers
56bcbc4aff [ci] add CI github actions 2020-10-05 09:35:54 -07:00
Alekos Filini
1faf0ed0a0 Fix the recovery of a descriptor given a PSBT
This commit upgrades `rust-miniscript` with a fix to only return the prefix that
matches a `hd_keypath` instead of the full derivation path, and then adapts the
signer code accordingly.

This commit closes #108 and #109.
2020-10-02 17:52:11 +02:00
LLFourn
490c88934e [keys] Less convoluted entropy generation
Since const generics aren't in rust yet you have to find some awkward
workarounds. This improves the workaround for specifying entropy length.
2020-09-30 20:05:17 +10:00
Steve Myers
eae15563d8 [descriptor] add ToWalletDescriptor trait tests 2020-09-25 22:21:11 -07:00
Alekos Filini
82251a8de4 [keys] Fix entropy generation 2020-09-24 15:59:46 +02:00
Alekos Filini
b294b11c54 [keys] Add a trait for keys that can be generated 2020-09-24 09:53:56 +02:00
Alekos Filini
c93cd1414a [descriptor] Add descriptor templates, add DerivableKey 2020-09-24 09:53:54 +02:00
Alekos Filini
c51ba4a99f [keys] Add a way to restrict the networks in which keys are valid
Thanks to the `ToWalletDescriptor` trait we can also very easily validate the checksum
for descriptors that are loaded from strings, if they contain one. Fixes #20.
2020-09-24 09:53:51 +02:00
Alekos Filini
bc8acaf088 [keys] Take ScriptContext into account when converting keys 2020-09-24 09:53:48 +02:00
Alekos Filini
ab9d964868 [keys] Add BIP39 support 2020-09-24 09:53:46 +02:00
Alekos Filini
751a553925 [descriptor] Improve the descriptor macro, add traits for key and descriptor types 2020-09-24 09:53:42 +02:00
Alekos Filini
9832ecb660 [descriptor] Add a macro to write descriptors from code 2020-09-24 09:53:41 +02:00
willcl-ark
4970d1e522 Add CONTRIBUTING.md
Add a CONTRIBUTING.md file based on a template taken from the
rust-lightning project.
2020-09-23 10:19:53 +01:00
willcl-ark
844820dcfa Prettify README examples on github 2020-09-21 15:32:38 +01:00
Alekos Filini
33a5ba6cd2 [signer] Fix signing for ShWpkh inputs 2020-09-16 17:50:54 +02:00