Skip to content
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
24 changes: 12 additions & 12 deletions Cargo.lock

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

16 changes: 8 additions & 8 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -49,14 +49,14 @@ members = [
]

[workspace.dependencies]
dashcore = { git = "https://github.com/dashpay/rust-dashcore", rev = "58d61ea50ac4c217c8e1350b57363b351a0b99d4" }
dash-network-seeds = { git = "https://github.com/dashpay/rust-dashcore", rev = "58d61ea50ac4c217c8e1350b57363b351a0b99d4" }
dash-spv = { git = "https://github.com/dashpay/rust-dashcore", rev = "58d61ea50ac4c217c8e1350b57363b351a0b99d4" }
key-wallet = { git = "https://github.com/dashpay/rust-dashcore", rev = "58d61ea50ac4c217c8e1350b57363b351a0b99d4" }
key-wallet-ffi = { git = "https://github.com/dashpay/rust-dashcore", rev = "58d61ea50ac4c217c8e1350b57363b351a0b99d4" }
key-wallet-manager = { git = "https://github.com/dashpay/rust-dashcore", rev = "58d61ea50ac4c217c8e1350b57363b351a0b99d4" }
dash-network = { git = "https://github.com/dashpay/rust-dashcore", rev = "58d61ea50ac4c217c8e1350b57363b351a0b99d4" }
dashcore-rpc = { git = "https://github.com/dashpay/rust-dashcore", rev = "58d61ea50ac4c217c8e1350b57363b351a0b99d4" }
dashcore = { git = "https://github.com/dashpay/rust-dashcore", rev = "eb889af13f667ed39c35e8e8a0830eeedf523476" }
dash-network-seeds = { git = "https://github.com/dashpay/rust-dashcore", rev = "eb889af13f667ed39c35e8e8a0830eeedf523476" }
dash-spv = { git = "https://github.com/dashpay/rust-dashcore", rev = "eb889af13f667ed39c35e8e8a0830eeedf523476" }
key-wallet = { git = "https://github.com/dashpay/rust-dashcore", rev = "eb889af13f667ed39c35e8e8a0830eeedf523476" }
key-wallet-ffi = { git = "https://github.com/dashpay/rust-dashcore", rev = "eb889af13f667ed39c35e8e8a0830eeedf523476" }
key-wallet-manager = { git = "https://github.com/dashpay/rust-dashcore", rev = "eb889af13f667ed39c35e8e8a0830eeedf523476" }
dash-network = { git = "https://github.com/dashpay/rust-dashcore", rev = "eb889af13f667ed39c35e8e8a0830eeedf523476" }
dashcore-rpc = { git = "https://github.com/dashpay/rust-dashcore", rev = "eb889af13f667ed39c35e8e8a0830eeedf523476" }

# Optimize heavy crypto crates even in dev/test builds so that
# Halo 2 proof generation and verification run at near-release speed.
Expand Down
18 changes: 12 additions & 6 deletions packages/rs-platform-wallet-ffi/src/spv.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@ use std::ffi::CStr;
use std::os::raw::c_char;

use dashcore::sml::llmq_type::LlmqDevnetParams;
use platform_wallet::spv::{ClientConfig, ProgressPercentage, SyncProgress, SyncState};
use platform_wallet::spv::{
ClientConfig, DevnetConfig, ProgressPercentage, SyncProgress, SyncState,
};

use crate::error::*;
use crate::handle::*;
Expand Down Expand Up @@ -314,11 +316,15 @@ pub unsafe extern "C" fn platform_wallet_manager_spv_start(
config.peers.push(addr);
}
}
if llmq_devnet_size > 0 {
config.llmq_devnet_params = Some(LlmqDevnetParams {
size: llmq_devnet_size,
threshold: llmq_devnet_threshold,
});
if let Some(name) = devnet_name_str.as_deref() {
let mut devnet = DevnetConfig::new(name);
if llmq_devnet_size > 0 {
devnet.llmq_params = Some(LlmqDevnetParams {
size: llmq_devnet_size,
threshold: llmq_devnet_threshold,
});
}
config.devnet = Some(devnet);
}

let _guard = runtime().enter();
Expand Down
2 changes: 1 addition & 1 deletion packages/rs-platform-wallet/src/spv/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,5 @@ pub use dash_spv::sync::{
BlockHeadersProgress, FilterHeadersProgress, FiltersProgress, MasternodesProgress,
ProgressPercentage, SyncProgress, SyncState,
};
pub use dash_spv::ClientConfig;
pub use dash_spv::{ClientConfig, DevnetConfig};
pub use tokio_util::sync::CancellationToken;
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ use async_trait::async_trait;
use dashcore::ephemerealdata::chain_lock::ChainLock;
use dashcore::ephemerealdata::instant_lock::InstantLock;
use dashcore::prelude::CoreBlockHeight;
use dashcore::{Address as DashAddress, Transaction, Txid};
use dashcore::{Address as DashAddress, ScriptBuf, Transaction, Txid};

use key_wallet::account::AccountType;
use key_wallet::bip32::ExtendedPubKey;
Expand Down Expand Up @@ -97,6 +97,10 @@ impl WalletInfoInterface for PlatformWalletInfo {
self.core_wallet.monitored_addresses()
}

fn monitored_script_pubkeys(&self) -> Vec<ScriptBuf> {
self.core_wallet.monitored_script_pubkeys()
}

fn utxos(&self) -> BTreeSet<&Utxo> {
self.core_wallet.utxos()
}
Expand Down
Loading