Skip to content

Commit 7de3bce

Browse files
authored
Merge pull request #17 from synonymdev/feat/onchain-events
Feat/onchain events
2 parents 61c57d3 + 0e86cfe commit 7de3bce

File tree

17 files changed

+2920
-156
lines changed

17 files changed

+2920
-156
lines changed

CHANGELOG.md

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,27 @@
1+
# Unreleased
2+
3+
## Feature and API updates
4+
- Added reactive event system for wallet monitoring without polling:
5+
- **Onchain Transaction Events** (fully implemented):
6+
- `OnchainTransactionReceived`: Emitted when a new unconfirmed transaction is
7+
first detected in the mempool (instant notification for incoming payments!)
8+
- `OnchainTransactionConfirmed`: Emitted when a transaction receives confirmations
9+
- `OnchainTransactionUnconfirmed`: Emitted when a previously confirmed transaction
10+
becomes unconfirmed (blockchain reorg)
11+
- **Sync Completion Event** (fully implemented):
12+
- `SyncCompleted`: Emitted when onchain wallet sync finishes successfully
13+
- **Balance Change Event** (fully implemented):
14+
- `BalanceChanged`: Emitted when onchain or Lightning balances change, allowing
15+
applications to update balance displays immediately without polling
16+
- Added `TransactionContext` enum to onchain transaction events, which provides
17+
information about whether a transaction is related to channel funding, channel
18+
closure, or regular wallet activity. Applications can cross-reference with
19+
`ChannelPending` and `ChannelClosed` events to identify channel-related
20+
transactions.
21+
- Added `SyncType` enum to distinguish between onchain wallet sync, Lightning
22+
wallet sync, and fee rate cache updates.
23+
- Balance tracking is now persisted in `NodeMetrics` to detect changes across restarts.
24+
125
# 0.6.2 - Aug. 14, 2025
226
This patch release fixes a panic that could have been hit when syncing to a
327
TLS-enabled Electrum server, as well as some minor issues when shutting down

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ lightning-liquidity = { version = "0.1.0", features = ["std"] }
6464
bdk_chain = { version = "0.23.0", default-features = false, features = ["std"] }
6565
bdk_esplora = { version = "0.22.0", default-features = false, features = ["async-https-rustls", "tokio"]}
6666
bdk_electrum = { version = "0.23.0", default-features = false, features = ["use-rustls"]}
67-
bdk_wallet = { version = "2.0.0", default-features = false, features = ["std", "keys-bip39"]}
67+
bdk_wallet = { version = "2.2.0", default-features = false, features = ["std", "keys-bip39"]}
6868

6969
reqwest = { version = "0.12", default-features = false, features = ["json", "rustls-tls"] }
7070
rustls = { version = "0.23", default-features = false }

0 commit comments

Comments
 (0)