-
Notifications
You must be signed in to change notification settings - Fork 959
Closed
Description
Issue and Steps to Reproduce
$ newaddr=$(lightning-cli newaddr | jq -r .bech32)
$ lightning-cli withdraw "${newaddr}" all 3333perkb 0 '["(my txid):(vout)"]'
{
"code": 301,
"message": "Cannot afford transaction with 138sat sats of fees"
}
Attempting the same withdrawal a second time yields:
{
"code": -32602,
"message": "No matching utxo was found from the wallet. You can get a list of the wallet utxos with the `listfunds` RPC call."
}
Indeed, the specified <txid>:<vout>
is no longer returned in lightning-cli listfunds
. The UTxO does appear again after a dev-rescan-outputs
, but obviously this is risky and shouldn't be needed.
So there are really two problems here:
- C-Lightning should not be marking UTxOs as spent if it didn't actually spend them.
- C-Lightning apparently doesn't understand how to spend
all
of a specified set of UTxOs while deducting enough from their total value to satisfy the specified fee rate.
getinfo
output
$ lightning-cli getinfo | jq '{binding, version, blockheight, network, "lightning-dir"}'
{
"binding": [
{
"type": "ipv6",
"address": "::",
"port": 9735
},
{
"type": "ipv4",
"address": "0.0.0.0",
"port": 9735
}
],
"version": "0.8.1",
"blockheight": 621608,
"network": "bitcoin",
"lightning-dir": "/var/lib/lightning/bitcoin"
}
Metadata
Metadata
Assignees
Labels
No labels