-
Notifications
You must be signed in to change notification settings - Fork 419
Description
Describe the bug
- Alice has an empty wallet
- Alice receives a transaction (called
tx1a) from Bob and observes it in the mempool. - Bob double-spends
tx1acreatingtx1b - A block is mined containing
tx1b - Alice observes
tx1bin a block.
Alice will still consider tx1a as a pending transaction.
To Reproduce
See this https://github.com/ErikDeSmedt/bdk-gists/blob/master/tests/wallet.rs
Expected behavior
I would expect that Alice her wallet wouldn't use tx1a anymore. The output
- should not be used for coin-selection
- should not be part of the balance (untrusted_pending)
Build environment
- BDK tag/commit:
1.0.0-beta.5 - OS+version: debian
- Rust/Cargo version: cargo 1.79.0 (ffa9cf99a 2024-06-03)
Additional context
I discovered this bug in a test-case where the entire wallet was unusable.
stevenroose, buffrr, evanlinjin and oleonardolima
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working
Type
Projects
Status
Done