From 71aac7e38d06c3fbd87a0646280fbb933fbefbeb Mon Sep 17 00:00:00 2001 From: Elias Rohrer Date: Mon, 28 Apr 2025 14:08:40 +0200 Subject: [PATCH 1/4] Update `CHANGELOG.md` for v0.5.0 --- CHANGELOG.md | 57 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 57 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 384fa0f0f..931b98f28 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,60 @@ +# 0.5.0 - Apr. 29, 2025 +Besides numerous API improvements and bugfixes this fifth minor release notably adds support for sourcing chain and fee rate data from an Electrum backend, requesting channels via the [bLIP-51 / LSPS1](https://github.com/lightning/blips/blob/master/blip-0051.md) protocol, as well as experimental support for operating as a [bLIP-52 / LSPS2](https://github.com/lightning/blips/blob/master/blip-0052.md) service. + +## Feature and API updates +- The `PaymentSuccessful` event now exposes a `payment_preimage` field (#392). +- The node now emits `PaymentForwarded` events for forwarded payments (#404). +- The ability to send custom TLVs as part of spontaneous payments has been added (#411). +- The ability to override the used fee rates for on-chain sending has been added (#434). +- The ability to set a description hash when creating a BOLT11 invoice has been added (#438). +- The ability to export pathfinding scores has been added (#458). +- The ability to request inbound channels from an LSP via the bLIP-51 / LSPS1 protocol has been added (#418). +- The `ChannelDetails` returned by `Node::list_channels` now exposes fields for the channel's SCIDs (#444). +- Lightning peer-to-peer gossip data is now being verified when syncing from a Bitcoin Core RPC backend (#428). +- The logging sub-system was reworked to allow logging to backends using the Rust [`log`](https://crates.io/crates/log) facade, as well as via a custom logger trait (#407, #450, #454). +- On-chain transactions are now added to the internal payment store and exposed via `Node::list_payments` (#432). +- Inbound announced channels are now rejected if not all requirements for operating as a forwarding node (set listening addresses and node alias) have been met (#467). +- Initial support for operating as an bLIP-52 / LSPS2 service has been added (#420). + - **Note**: bLIP-52 / LSPS2 support is considered 'alpha'/'experimental' and should *not* yet be used in production. +- The `Builder::set_entropy_seed_bytes` method now takes an array rather than a `Vec` (#493). +- The builder will now return a `NetworkMismatch` error in case of network switching (#485). +- The `Bolt11Jit` payment variant now exposes a field telling how much fee the LSP withheld (#497). +- The ability to disable syncing Lightning and on-chain wallets in the background has been added. If it is disabled, the user is responsible for running `Node::sync_wallets` manually (#508). +- The ability to configure the node's announcement addresses independently from the listening addresses has been added (#484). +- The ability to choose whether to honor the Anchor reserves when calling `send_all_to_address` has been added (#345). +- The ability to sync the node via an Electrum backend has been added (#486). + +## Bug Fixes and Improvements +- When syncing from Bitcoin Core RPC, syncing mempool entries has been made more efficient (#410, #465). +- We now ensure the our configured fallback rates are used when the configured chain source would return huge bogus values during fee estimation (#430). +- We now re-enabled trying to bump Anchor channel transactions for trusted counterparties in the `ContentiousClaimable` case to reduce the risk of losing funds in certain edge cases (#461). +- An issue that would potentially have us panic on retrying the chain listening initialization when syncing from Bitcoin Core RPC has been fixed (#471). +- The `Node::remove_payment` now also removes the respective entry from the in-memory state, not only from the persisted payment store (#514). + +## Compatibility Notes +- The filesystem logger was simplified and its default path changed to `ldk_node.log` in the configured storage directory (#394). +- The BDK dependency has been bumped to `bdk_wallet` v1.0 (#426). +- The LDK dependency has been bumped to `lightning` v0.1 (#426). +- The `rusqlite` dependency has been bumped to v0.31 (#403). +- The minimum supported Rust version (MSRV) has been bumped to v1.75 (#429). + +In total, this release features 53 files changed, 6147 insertions, 1193 deletions, in 191 commits from 14 authors in alphabetical order: + +- alexanderwiederin +- Andrei +- Artur Gontijo +- Ayla Greystone +- Elias Rohrer +- elnosh +- Enigbe Ochekliye +- Evan Feenstra +- G8XSU +- Joost Jager +- maan2003 +- moisesPompilio +- Rob N +- Vincenzo Palazzo + # 0.4.3 - Jan. 23, 2025 This patch release fixes the broken Rust build resulting from `cargo` treating the recent v0.1.0 release of `lightning-liquidity` as API-compatible with the previous v0.1.0-alpha.6 release (even though it's not). From f2d04669a3ddfb51a91318599158ce8bc3fac9e6 Mon Sep 17 00:00:00 2001 From: Elias Rohrer Date: Tue, 29 Apr 2025 09:58:09 +0200 Subject: [PATCH 2/4] Bump Rust version number --- Cargo.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Cargo.toml b/Cargo.toml index 4363509ac..4087ca285 100755 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "ldk-node" -version = "0.5.0-rc.1" +version = "0.5.0" authors = ["Elias Rohrer "] homepage = "https://lightningdevkit.org/" license = "MIT OR Apache-2.0" From ff73462d89e08a051ef19cc647ad3316f53f00de Mon Sep 17 00:00:00 2001 From: Elias Rohrer Date: Tue, 29 Apr 2025 09:58:30 +0200 Subject: [PATCH 3/4] Bump Kotlin/Swift/Python version numbers --- Package.swift | 2 +- bindings/kotlin/ldk-node-android/gradle.properties | 2 +- bindings/kotlin/ldk-node-jvm/gradle.properties | 2 +- bindings/python/pyproject.toml | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Package.swift b/Package.swift index 059052492..248339c93 100644 --- a/Package.swift +++ b/Package.swift @@ -3,7 +3,7 @@ import PackageDescription -let tag = "v0.4.2" +let tag = "v0.5.0" let checksum = "95ea5307eb3a99203e39cfa21d962bfe3e879e62429e8c7cdf5292cae5dc35cc" let url = "https://github.com/lightningdevkit/ldk-node/releases/download/\(tag)/LDKNodeFFI.xcframework.zip" diff --git a/bindings/kotlin/ldk-node-android/gradle.properties b/bindings/kotlin/ldk-node-android/gradle.properties index 44a51cfaf..1976b7123 100644 --- a/bindings/kotlin/ldk-node-android/gradle.properties +++ b/bindings/kotlin/ldk-node-android/gradle.properties @@ -2,4 +2,4 @@ org.gradle.jvmargs=-Xmx1536m android.useAndroidX=true android.enableJetifier=true kotlin.code.style=official -libraryVersion=0.4.2 +libraryVersion=0.5.0 diff --git a/bindings/kotlin/ldk-node-jvm/gradle.properties b/bindings/kotlin/ldk-node-jvm/gradle.properties index 338b60d96..62d660235 100644 --- a/bindings/kotlin/ldk-node-jvm/gradle.properties +++ b/bindings/kotlin/ldk-node-jvm/gradle.properties @@ -1,3 +1,3 @@ org.gradle.jvmargs=-Xmx1536m kotlin.code.style=official -libraryVersion=0.4.2 +libraryVersion=0.5.0 diff --git a/bindings/python/pyproject.toml b/bindings/python/pyproject.toml index 781542ec3..8af86d2bb 100644 --- a/bindings/python/pyproject.toml +++ b/bindings/python/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "ldk_node" -version = "0.4.2" +version = "0.5.0" authors = [ { name="Elias Rohrer", email="dev@tnull.de" }, ] From d8dd81db0a5ea6866836920ecf32cb6c8992c1f7 Mon Sep 17 00:00:00 2001 From: Elias Rohrer Date: Mon, 28 Apr 2025 15:04:51 +0200 Subject: [PATCH 4/4] Use `stable` Rust toolchain for Swift builds --- scripts/uniffi_bindgen_generate_swift.sh | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/scripts/uniffi_bindgen_generate_swift.sh b/scripts/uniffi_bindgen_generate_swift.sh index ba2d84d2a..ce1151a3b 100755 --- a/scripts/uniffi_bindgen_generate_swift.sh +++ b/scripts/uniffi_bindgen_generate_swift.sh @@ -1,4 +1,6 @@ #!/bin/bash +set -eox pipefail + BINDINGS_DIR="./bindings/swift" UNIFFI_BINDGEN_BIN="cargo run --manifest-path bindings/uniffi-bindgen/Cargo.toml" @@ -8,11 +10,11 @@ $UNIFFI_BINDGEN_BIN generate bindings/ldk_node.udl --language swift -o "$BINDING mkdir -p $BINDINGS_DIR # Install rust target toolchains -rustup install 1.73.0 -rustup component add rust-src --toolchain 1.73.0 -rustup target add aarch64-apple-ios x86_64-apple-ios --toolchain 1.73.0 -rustup target add aarch64-apple-ios-sim --toolchain 1.73.0 -rustup target add aarch64-apple-darwin x86_64-apple-darwin --toolchain 1.73.0 +rustup upgrade stable +rustup component add rust-src --toolchain stable +rustup target add aarch64-apple-ios x86_64-apple-ios --toolchain stable +rustup target add aarch64-apple-ios-sim --toolchain stable +rustup target add aarch64-apple-darwin x86_64-apple-darwin --toolchain stable # Build rust target libs cargo build --profile release-smaller --features uniffi || exit 1 @@ -20,7 +22,7 @@ cargo build --profile release-smaller --features uniffi --target x86_64-apple-da cargo build --profile release-smaller --features uniffi --target aarch64-apple-darwin || exit 1 cargo build --profile release-smaller --features uniffi --target x86_64-apple-ios || exit 1 cargo build --profile release-smaller --features uniffi --target aarch64-apple-ios || exit 1 -cargo +1.73.0 build --release --features uniffi --target aarch64-apple-ios-sim || exit 1 +cargo +stable build --release --features uniffi --target aarch64-apple-ios-sim || exit 1 # Combine ios-sim and apple-darwin (macos) libs for x86_64 and aarch64 (m1) mkdir -p target/lipo-ios-sim/release-smaller || exit 1