Skip to content

Commit 2fa18a0

Browse files
committed
Merge #174: feature: update bdk-cli to use bdk_wallet v1
e0bd147 fix: clippy errors (Steve Myers) 524562c fix: signing / finalizing `psbt` (Vihiga Tyonum) fb7232f rpc: print status during full_scan and sync (Steve Myers) 4a66557 ci: remove WASM job, fix more clippy errors (Steve Myers) eb947fc ci: with msrv 1.75 pin minreq to 2.13.2 (Steve Myers) efc5fc5 ci: fix clippy errors (Steve Myers) 92cabb1 ci: update actions checkout and cache to v4, simplify matrix features (Steve Myers) cb10873 refactor: fix error handling (Vihiga Tyonum) 8307db0 feat: re-enable `rpc` feature (Vihiga Tyonum) 8ac2529 ci: update the CI workflow (Vihiga Tyonum) a2ad6b3 feat: add ci test for features (Vihiga Tyonum) 50a6a60 refactor: remove rpc, cbf, cleanup features (Steve Myers) 0be8453 refactor: update onlinewalletsubcommands (Vihiga Tyonum) 440bd36 refactor: update creating_backend fn (Vihiga Tyonum) 58f07a1 refactor: update nodes.rs file (Vihiga Tyonum) cb4450b refactor: update imports and reserves feature (Vihiga Tyonum) 50233dd refactor: replace bdk::error with custom error (Vihiga Tyonum) b8d2357 feat: add custom error enum (Vihiga Tyonum) 6f263bf feat!: replace bdk with bdk_wallet & update deps (Vihiga Tyonum) b56c023 refactor: update imports from bdk to bd_wallet (Vihiga Tyonum) 91f5918 refactor: update imports from bdk to bdk_wallet (Vihiga Tyonum) ddce50d refactor: update imports from bdk to bdk_wallet (Vihiga Tyonum) 4c89cbf refactor:update imports from bdk to use bdk_wallet (Vihiga Tyonum) 890cb45 refactor: add bdk_wallet (Vihiga Tyonum) Pull request description: <!-- You can erase any parts of this template not applicable to your Pull Request. --> ### Description <!-- Describe the purpose of this PR, what's being adding and/or fixed --> This PR update `bdk-cli` to use `bdk_wallet` v1 Issue: #172 (comment) ### Notes to the reviewers - replaced `list_transactions` with `transactions` - set `enable_rbf` to be `true` by default - update creating and serializing Psbts - update `new_wallet` to return `PersistedWallet<Connection>` - default fee_rate to use FeeRate::BROADCAST_MIN - update `zeroize` to version `1.8.1` from `<1.4.0` - update `bdk-reserves` from `0.27.1` to `0.29.0` - replace `bdk/electrum` with `bdk_electrum` for the `electrum` feature - add `bdk_esplora` for the `bdk/use-esplora-ureq` and `bdk/use-esplora-reqwest` features - add `bdk_bitcoind_rpc` lib to replace `bdk/rpc` feature - add `hwi` library to replace `bdk/hardware-signer` feature <!-- In this section you can include notes directed to the reviewers, like explaining why some parts of the PR were done in a specific way --> ## Changelog notice - set `enable_rbf` to be `true` by default - update using `PartiallySignedTransaction` to `Psbt` - default fee_rate to use FeeRate::BROADCAST_MIN - update `zeroize` to version `1.8.1` from `<1.4.0` - update `bdk-reserves` from `0.27.1` to `0.29.0` - replace `bdk/electrum` with `bdk_electrum` for the `electrum` feature - replace `bdk/use-esplora-ureq` and `bdk/use-esplora-reqwest` with `bdk_esplora` lib - replace `bdk/rpc` with `bdk_bitcoind_rpc` lib - replace `bdk/hardware-signer` with `hwi` lib <!-- Notice the release manager should include in the release tag message changelog --> <!-- See https://keepachangelog.com/en/1.0.0/ for examples --> ### Checklists #### All Submissions: * [x] I've signed all my commits * [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk-cli/blob/master/CONTRIBUTING.md) * [x] I ran `cargo fmt` and `cargo clippy` before committing #### Bugfixes: * [x] This pull request breaks the existing API * [x] I'm linking the issue being fixed by this PR ACKs for top commit: notmandatory: ACK e0bd147 Tree-SHA512: cd548805327b55a66be26aa0402ef7a4512a0a75ffdcefa243c86d838d82215a5e4605989436903c135c31902e84cebf8d88197db18df9193d1fc0cb9e0f567f
2 parents 6f61d2e + e0bd147 commit 2fa18a0

17 files changed

+2171
-4267
lines changed

.github/workflows/audit.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ jobs:
1313
security_audit:
1414
runs-on: ubuntu-20.04
1515
steps:
16-
- uses: actions/checkout@v2
17-
- uses: actions-rs/audit-check@v1
16+
- uses: actions/checkout@v4
17+
- uses: actions-rust-lang/audit@v1
1818
with:
1919
token: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/code_coverage.yml

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ jobs:
1414

1515
steps:
1616
- name: Checkout
17-
uses: actions/checkout@v2
17+
uses: actions/checkout@v4
1818

1919
- name: Install rustup
2020
run: curl https://sh.rustup.rs -sSf | sh -s -- -y
@@ -32,11 +32,8 @@ jobs:
3232
- name: Test Electrum
3333
run: cargo test --features electrum
3434

35-
- name: Test Esplora-Ureq
36-
run: cargo test --features esplora-ureq
37-
38-
- name: Test Esplora-reqwest
39-
run: cargo test --features esplora-reqwest
35+
- name: Test Esplora
36+
run: cargo test --features esplora
4037

4138
# Temporarily disable compact filters
4239
#- name: Test Compact Filters

.github/workflows/cont_integration.yml

Lines changed: 50 additions & 65 deletions
Original file line numberDiff line numberDiff line change
@@ -10,31 +10,19 @@ jobs:
1010
strategy:
1111
matrix:
1212
rust:
13-
- 1.65.0 # STABLE
14-
- 1.57.0 # MSRV
13+
- stable # STABLE
14+
- 1.75.0 # MSRV
1515
features:
16-
- default
17-
- electrum,sqlite-db
18-
- electrum,key-value-db
19-
- electrum
20-
- esplora-ureq,sqlite-db
21-
- esplora-reqwest,sqlite-db
22-
- compiler,sqlite-db
23-
#- compact_filters,sqlite-db # Compact Filters temporarily disabled
24-
- rpc,sqlite-db
25-
- reserves,electrum,sqlite-db
26-
- electrum,verify,sqlite-db
27-
# regtest-* features are experimental and not fully usable
28-
- regtest-bitcoin,sqlite-db
29-
- regtest-electrum,sqlite-db
30-
16+
- --features default
17+
- --no-default-features
18+
- --all-features
3119
steps:
3220
- name: Checkout
33-
uses: actions/checkout@v2
21+
uses: actions/checkout@v4
3422
- name: Generate cache key
3523
run: echo "${{ matrix.rust }} ${{ matrix.features }}" | tee .cache_key
3624
- name: Cache
37-
uses: actions/cache@v2
25+
uses: actions/cache@v4
3826
with:
3927
path: |
4028
~/.cargo/registry
@@ -48,65 +36,62 @@ jobs:
4836
profile: minimal
4937
override: true
5038
components: rustfmt, clippy
51-
- name: Pin dependencies for MSRV
52-
if: matrix.rust == '1.57.0'
39+
- name: If Rust 1.75 remove and update Cargo.lock
40+
if: matrix.rust == '1.75.0'
5341
run: |
42+
rm Cargo.lock
5443
cargo update
55-
cargo update -p log --precise 0.4.18
56-
cargo update -p hashlink --precise 0.8.0
57-
cargo update -p tempfile --precise 3.6.0
58-
cargo update -p base64ct --precise 1.5.3
59-
cargo update -p cc --precise 1.0.81
60-
cargo update -p tokio --precise 1.29.1
61-
cargo update -p flate2 --precise 1.0.26
44+
- name: If Rust 1.75 pin dependencies
45+
if: matrix.rust == '1.75.0'
46+
run: ./ci/pin-msrv.sh
6247
- name: Build
63-
run: cargo build --no-default-features --features repl,${{ matrix.features }} --locked
48+
run: cargo build ${{ matrix.features }}
6449
- name: Clippy
6550
run: cargo clippy -- -D warnings
6651
- name: Test
67-
run: cargo test --no-default-features --features repl,${{ matrix.features }}
52+
run: cargo test ${{ matrix.features }}
6853

69-
wasm-build:
70-
name: Build WASM
71-
runs-on: ubuntu-latest
72-
env:
73-
CC: clang-10
74-
CFLAGS: -I/usr/include
75-
steps:
76-
- name: Checkout
77-
uses: actions/checkout@v2
78-
- name: Generate cache key
79-
run: echo "Build WASM" | tee .cache_key
80-
- name: Cache
81-
uses: actions/cache@v2
82-
with:
83-
path: |
84-
~/.cargo/registry
85-
~/.cargo/git
86-
target
87-
key: ${{ runner.os }}-cargo-${{ hashFiles('.cache_key') }}-${{ hashFiles('**/Cargo.toml','**/Cargo.lock') }}
88-
# Install a recent version of clang that supports wasm32
89-
- run: wget -O - https://apt.llvm.org/llvm-snapshot.gpg.key | sudo apt-key add - || exit 1
90-
- run: sudo apt-add-repository "deb http://apt.llvm.org/focal/ llvm-toolchain-focal-10 main" || exit 1
91-
- run: sudo apt-get update || exit 1
92-
- run: sudo apt-get install -y libclang-common-10-dev clang-10 libc6-dev-i386 || exit 1
93-
- name: Set default toolchain
94-
run: rustup default 1.65.0
95-
- name: Set profile
96-
run: rustup set profile minimal
97-
- name: Add target wasm32
98-
run: rustup target add wasm32-unknown-unknown
99-
- name: Update toolchain
100-
run: rustup update
101-
- name: Build
102-
run: cargo build --target wasm32-unknown-unknown --no-default-features --features esplora-reqwest,async-interface,compiler,dev-getrandom-wasm
54+
# TODO: fix or remove this
55+
# wasm-build:
56+
# name: Build WASM
57+
# runs-on: ubuntu-20.04
58+
# env:
59+
# CC: clang-10
60+
# CFLAGS: -I/usr/include
61+
# steps:
62+
# - name: Checkout
63+
# uses: actions/checkout@v4
64+
# - name: Generate cache key
65+
# run: echo "Build WASM" | tee .cache_key
66+
# - name: Cache
67+
# uses: actions/cache@v4
68+
# with:
69+
# path: |
70+
# ~/.cargo/registry
71+
# ~/.cargo/git
72+
# target
73+
# key: ${{ runner.os }}-cargo-${{ hashFiles('.cache_key') }}-${{ hashFiles('**/Cargo.toml','**/Cargo.lock') }}
74+
# # Install a recent version of clang that supports wasm32
75+
# - run: wget -O - https://apt.llvm.org/llvm-snapshot.gpg.key | sudo apt-key add - || exit 1
76+
# - run: sudo apt-get update || exit 1
77+
# - run: sudo apt-get install -y libclang-common-10-dev clang-10 libc6-dev-i386 || exit 1
78+
# - name: Set default toolchain
79+
# run: rustup default stable
80+
# - name: Set profile
81+
# run: rustup set profile minimal
82+
# - name: Add target wasm32
83+
# run: rustup target add wasm32-unknown-unknown
84+
# - name: Update toolchain
85+
# run: rustup update
86+
# - name: Build
87+
# run: cargo build --target wasm32-unknown-unknown --no-default-features --features esplora,compiler,dev-getrandom-wasm
10388

10489
fmt:
10590
name: Rust fmt
10691
runs-on: ubuntu-latest
10792
steps:
10893
- name: Checkout
109-
uses: actions/checkout@v2
94+
uses: actions/checkout@v4
11095
- name: Setup Rust Toolchain
11196
uses: actions-rs/toolchain@v1
11297
with:

0 commit comments

Comments
 (0)