Background
2 issues, but one is caused by the other
- when a channel is opened and the transaction fails to broadcast, lnd will keep the channel in the pending channels, but it can know it wont ever confirm
- when a wallet is restored, the mempool is not scanned
Your environment
- version of
lnd: lnd version 0.15.99-beta commit=tlv/v1.1.0-104-gef8cf73d4 (today's master)
- which operating system (
uname -a on *Nix) archlinux
- version of
btcd, bitcoind, or other backend bitcoin core v24.0.1
- any other relevant environment details
Steps to reproduce
- create a new wallet
- send coins to it
- wait for 1 confirmation
- spend the coins (at 1 sat/vB)
- delete the wallet
- restore the wallet
- if the spend of step 4 confirmed start over
- open a channel (at 1 sat/vB)
Expected behaviour
mempool is scanned after restore, the spending transaction is seen in the mempool and lnd will not try to reuse it
if for some reason a channel open fails, lnd should handle the error
Actual behaviour
lnd tried to open a channel with a utxo that was already spent in the mempool and did not provide enough fee for rbf, and thus got rejected by bitcoind
Background
2 issues, but one is caused by the other
Your environment
lnd: lnd version 0.15.99-beta commit=tlv/v1.1.0-104-gef8cf73d4 (today's master)uname -aon *Nix) archlinuxbtcd,bitcoind, or other backend bitcoin core v24.0.1Steps to reproduce
Expected behaviour
mempool is scanned after restore, the spending transaction is seen in the mempool and lnd will not try to reuse it
if for some reason a channel open fails, lnd should handle the error
Actual behaviour
lnd tried to open a channel with a utxo that was already spent in the mempool and did not provide enough fee for rbf, and thus got rejected by bitcoind