From a56c20ae45d58b437b72c4f1fb521f47d8a6d924 Mon Sep 17 00:00:00 2001 From: codingp110 Date: Sat, 13 Jun 2026 15:18:21 +0530 Subject: [PATCH] build: bump redb version and MSRV Because of redb 4.1.0 requires at least rustc 1.89 --- .github/workflows/cont_integration.yml | 2 +- Cargo.toml | 12 ++++++------ clippy.toml | 2 +- rust-version | 2 +- src/lib.rs | 15 +++++++-------- 5 files changed, 16 insertions(+), 17 deletions(-) diff --git a/.github/workflows/cont_integration.yml b/.github/workflows/cont_integration.yml index e034620..72c281b 100644 --- a/.github/workflows/cont_integration.yml +++ b/.github/workflows/cont_integration.yml @@ -31,7 +31,7 @@ jobs: rust: - version: ${{ needs.prepare.outputs.rust_version }} clippy: true - - version: 1.85.0 # Overall MSRV + - version: 1.89.0 # Overall MSRV features: - --no-default-features - --all-features diff --git a/Cargo.toml b/Cargo.toml index 537a364..6e5d6d8 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,28 +1,28 @@ [package] name = "bdk_redb" -version = "0.2.0" +version = "0.3.0" edition = "2024" license = "MIT OR Apache-2.0" description = "Persistence backend for bdk using redb" repository = "https://github.com/110CodingP/bdk_redb" readme = "README.md" -rust-version = "1.85.0" +rust-version = "1.89.0" [dependencies] bdk_wallet = {version = "3", optional = true} bdk_chain = {version = "0.23", features = ["serde"]} ciborium = "0.2.2" -redb = "2.5.0" -thiserror = "2.0.12" +redb = "4" +thiserror = "2" [features] default = ["wallet"] wallet = ["bdk_wallet"] [dev-dependencies] -anyhow = "1.0.98" +anyhow = "1.0" bdk_testenv = { version = "0.13.0" } -tempfile = "3.20.0" +tempfile = "3.20" [lints.rust] unexpected_cfgs = { level = "warn", check-cfg = ['cfg(coverage,coverage_nightly)'] } \ No newline at end of file diff --git a/clippy.toml b/clippy.toml index f3bd183..2cf0b65 100644 --- a/clippy.toml +++ b/clippy.toml @@ -1 +1 @@ -msrv="1.85.0" \ No newline at end of file +msrv="1.89.0" \ No newline at end of file diff --git a/rust-version b/rust-version index 2db3303..a0f550d 100644 --- a/rust-version +++ b/rust-version @@ -1 +1 @@ -1.85.0 \ No newline at end of file +1.89.0 \ No newline at end of file diff --git a/src/lib.rs b/src/lib.rs index d4bc3c6..d054a60 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -12,10 +12,7 @@ //! //! ```toml //! [dependencies] -//! anyhow = "1.0.98" -//! bdk_redb = "0.1.1" -//! bdk_wallet = "2.0.0" -//! tempfile = "3.20.0" +//! bdk_redb = "0.3.0" //! ``` //! //! Now: @@ -27,6 +24,7 @@ //! use bdk_wallet::{KeychainKind, Wallet}; //! use std::sync::Arc; //! use tempfile::NamedTempFile; +//! use bdk_redb::{redb::Database, Store}; //! //! use anyhow::Result; //! @@ -38,13 +36,12 @@ //! fn main() -> Result<()> { //! let network = Network::Signet; //! let file_path = NamedTempFile::new()?; -//! let db = Arc::new(bdk_redb::redb::Database::create(file_path.path())?); -//! let mut store = bdk_redb::Store::new(db, "wallet1".to_string())?; +//! let db = Arc::new(Database::create(file_path.path())?); +//! let mut store = Store::new(db, "wallet1".to_string())?; //! //! let wallet_opt = Wallet::load() //! .descriptor(KeychainKind::External, Some(EXTERNAL_DESCRIPTOR)) //! .descriptor(KeychainKind::Internal, Some(INTERNAL_DESCRIPTOR)) -//! .extract_keys() //! .check_network(network) //! .load_wallet(&mut store)?; //! @@ -88,7 +85,9 @@ use bdk_chain::{BlockId, DescriptorId, keychain_txout, local_chain, tx_graph}; #[cfg(feature = "wallet")] use bdk_wallet::{ChangeSet, WalletPersister}; use error::StoreError; -use redb::{Database, ReadTransaction, ReadableTable, TableDefinition, WriteTransaction}; +use redb::{ + Database, ReadTransaction, ReadableDatabase, ReadableTable, TableDefinition, WriteTransaction, +}; use std::collections::{BTreeMap, BTreeSet}; use std::str::FromStr; use std::sync::Arc;