Skip to content

deps: bdk_wallet 2.0.0-beta #777

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jun 9, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 16 additions & 18 deletions bdk-ffi/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 4 additions & 5 deletions bdk-ffi/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,10 @@ path = "uniffi-bindgen.rs"
default = ["uniffi/cli"]

[dependencies]
bdk_wallet = { version = "1.2.0", features = ["all-keys", "keys-bip39", "rusqlite"] }
bdk_core = { version = "0.4.1" }
bdk_esplora = { version = "0.20.1", default-features = false, features = ["std", "blocking", "blocking-https-rustls"] }
bdk_electrum = { version = "0.21.0", default-features = false, features = ["use-rustls-ring"] }
bdk_kyoto = { version = "0.10.0" }
bdk_wallet = { version = "2.0.0-beta.0", features = ["all-keys", "keys-bip39", "rusqlite"] }
bdk_esplora = { version = "0.22.0", default-features = false, features = ["std", "blocking", "blocking-https-rustls"] }
bdk_electrum = { version = "0.23.0", default-features = false, features = ["use-rustls-ring"] }
bdk_kyoto = { version = "0.11.0" }

uniffi = { version = "=0.29.1" }
thiserror = "1.0.58"
Expand Down
12 changes: 6 additions & 6 deletions bdk-ffi/src/electrum.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,19 +3,19 @@ use crate::error::ElectrumError;
use crate::types::Update;
use crate::types::{FullScanRequest, SyncRequest};

use bdk_core::spk_client::FullScanRequest as BdkFullScanRequest;
use bdk_core::spk_client::FullScanResponse as BdkFullScanResponse;
use bdk_core::spk_client::SyncRequest as BdkSyncRequest;
use bdk_core::spk_client::SyncResponse as BdkSyncResponse;
use bdk_electrum::electrum_client::HeaderNotification as BdkHeaderNotification;
use bdk_electrum::electrum_client::ServerFeaturesRes as BdkServerFeaturesRes;
use bdk_electrum::BdkElectrumClient as BdkBdkElectrumClient;
use bdk_wallet::bitcoin::Transaction as BdkTransaction;
use bdk_wallet::chain::spk_client::FullScanRequest as BdkFullScanRequest;
use bdk_wallet::chain::spk_client::FullScanResponse as BdkFullScanResponse;
use bdk_wallet::chain::spk_client::SyncRequest as BdkSyncRequest;
use bdk_wallet::chain::spk_client::SyncResponse as BdkSyncResponse;
use bdk_wallet::KeychainKind;
use bdk_wallet::Update as BdkUpdate;

use bdk_core::bitcoin::hex::{Case, DisplayHex};
use bdk_electrum::electrum_client::ElectrumApi;
use bdk_wallet::bitcoin::hex::{Case, DisplayHex};
use std::collections::BTreeMap;
use std::sync::Arc;

Expand Down Expand Up @@ -191,7 +191,7 @@ pub struct ServerFeaturesRes {
impl From<BdkServerFeaturesRes> for ServerFeaturesRes {
fn from(value: BdkServerFeaturesRes) -> ServerFeaturesRes {
let hash_str = value.genesis_hash.to_hex_string(Case::Lower);
let blockhash = hash_str.parse::<bdk_core::bitcoin::BlockHash>().unwrap();
let blockhash = hash_str.parse::<bdk_wallet::bitcoin::BlockHash>().unwrap();
ServerFeaturesRes {
server_version: value.server_version,
genesis_hash: Arc::new(BlockHash(blockhash)),
Expand Down
5 changes: 4 additions & 1 deletion bdk-ffi/src/error.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
use crate::OutPoint;

use bdk_core::bitcoin::script::PushBytesError;
use bdk_electrum::electrum_client::Error as BdkElectrumError;
use bdk_esplora::esplora_client::Error as BdkEsploraError;
use bdk_wallet::bitcoin::address::ParseError as BdkParseError;
Expand All @@ -13,6 +12,7 @@ use bdk_wallet::bitcoin::hex::DisplayHex;
use bdk_wallet::bitcoin::psbt::Error as BdkPsbtError;
use bdk_wallet::bitcoin::psbt::ExtractTxError as BdkExtractTxError;
use bdk_wallet::bitcoin::psbt::PsbtParseError as BdkPsbtParseError;
use bdk_wallet::bitcoin::script::PushBytesError;
use bdk_wallet::chain::local_chain::CannotConnectError as BdkCannotConnectError;
use bdk_wallet::chain::rusqlite::Error as BdkSqliteError;
use bdk_wallet::chain::tx_graph::CalculateFeeError as BdkCalculateFeeError;
Expand Down Expand Up @@ -1047,6 +1047,9 @@ impl From<BuildFeeBumpError> for CreateTxError {
BuildFeeBumpError::FeeRateUnavailable => CreateTxError::FeeRateTooLow {
required: "unavailable".to_string(),
},
BuildFeeBumpError::InvalidOutputIndex(outpoint) => CreateTxError::UnknownUtxo {
outpoint: outpoint.to_string(),
},
}
}
}
Expand Down
12 changes: 8 additions & 4 deletions bdk-ffi/src/types.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,10 @@ use crate::bitcoin::{
use crate::descriptor::Descriptor;
use crate::error::{CreateTxError, RequestBuilderError};

use bdk_core::bitcoin::absolute::LockTime as BdkLockTime;
use bdk_core::spk_client::SyncItem;
use bdk_core::{BlockId as BdkBlockId, Merge};
use bdk_wallet::bitcoin::absolute::LockTime as BdkLockTime;
use bdk_wallet::chain::spk_client::SyncItem;
use bdk_wallet::chain::BlockId as BdkBlockId;
use bdk_wallet::chain::Merge;

use bdk_wallet::bitcoin::Transaction as BdkTransaction;
use bdk_wallet::chain::spk_client::FullScanRequest as BdkFullScanRequest;
Expand Down Expand Up @@ -81,7 +82,7 @@ impl From<BdkChainPosition<BdkConfirmationBlockTime>> for ChainPosition {
transitively: transitively.map(|t| Arc::new(Txid(t))),
}
}
BdkChainPosition::Unconfirmed { last_seen } => ChainPosition::Unconfirmed {
BdkChainPosition::Unconfirmed { last_seen, .. } => ChainPosition::Unconfirmed {
timestamp: last_seen,
},
}
Expand Down Expand Up @@ -784,6 +785,7 @@ impl From<IndexerChangeSet> for bdk_wallet::chain::indexer::keychain_txout::Chan
}
Self {
last_revealed: changes,
spk_cache: Default::default(),
}
}
}
Expand Down Expand Up @@ -918,6 +920,8 @@ impl From<TxGraphChangeSet> for bdk_wallet::chain::tx_graph::ChangeSet<BdkConfir
txouts,
anchors,
last_seen,
first_seen: Default::default(),
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just a comment here: Would we want to update TxGraphChangeSet to also have first_seen and last_evicted ? I see they are present for ChangeSet in bdk_wallet. Or maybe that can wait for later.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good idea! I think we should do that. Let's do it in a separate PR? I'm thinking of this PR as a straight update of the dependency, and then doing follow up PR for something like exposing the new TxDetails, so if you want to do a follow up PR

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok. Understood! 👍

last_evicted: Default::default(),
}
}
}
Expand Down
Loading