ElementsProject / ElementsProject/lightning

[bug]: splice script resulting in CLN crash

Open
#8,250 2 comments 0 reactions 0 assignees View on GitHub
Dominant language
C
Stars
3.1k
Forks
1k
Avg merge
4d 10h
Merged PRs (30d)
13

Description

trying to make a splice between two v25.02.2 nodes results in a crash:

```
admin@rpi:~ ₿ cl getinfo
{
"id": "",
"alias": "",
"color": "",
"num_peers": 10,
"num_pending_channels": 0,
"num_active_channels": 4,
"num_inactive_channels": 0,
"address": [
{
"type": "torv3",
"address": ".onion",
"port": 9736
}
],
"binding": [
{
"type": "ipv4",
"address": "127.0.0.1",
"port": 9736
}
],
"version": "v25.02.2",
"blockheight": 894504,
"network": "bitcoin",
"fees_collected_msat": 2977391,
"lightning-dir": "/home/bitcoin/.lightning/bitcoin",
"our_features": {
"init": "8008a0882a8a59a1",
"node": "8088a0882a8a59a1",
"channel": "",
"invoice": "02000002024100"
}
}
admin@rpi:~ ₿ cl dev-splice '350000sat -> 5d9cd24'
{
"code": -32602,
"message": "Splice script compile failed",
"compiler_error": [
"Script as written has insufficent funds to be completed",
"350000sat -> 5d9cd24",
" ^",
"Compiler phase: calculate_amounts"
]
}
admin@rpi:~ ₿ cl dev-splice 'wallet -> 350000sat; 350000sat -> 5d9cd24;'
{
"psbt": "",
"txid": "4781c7a6df6cbed8b4b2d8e23ebad0fc4313a9b3400080d326677b360ac8580a"
}
admin@rpi:~ ₿ bitcoin-cli analyzepsbt "redacted"
{
"inputs": [
{
"has_utxo": true,
"is_final": true,
"next": "extractor"
},
{
"has_utxo": true,
"is_final": false,
"next": "updater",
"missing": {
"witnessscript": ""
}
},
{
"has_utxo": true,
"is_final": true,
"next": "extractor"
},
{
"has_utxo": true,
"is_final": true,
"next": "extractor"
}
],
"fee": 0.00000680,
"next": "updater"
}
~~~~~~~~[hours later]~~~~~~~
admin@rpi:~ ₿
admin@rpi:~ ₿ cl splice_signed ""
{
"code": 358,
"message": "Can't accept a signed splice PSBT because this channel hasn't begun a splice."
}
admin@rpi:~ ₿ cl dev-splice 'wallet -> 350000sat; 350000sat -> 5d9cd24;'
{
"code": -4,
"message": "Plugin terminated before replying to RPC call."
}
admin@rpi:~ ₿
admin@rpi:~ ₿ cllog
2025-04-30T01:46:09.202Z DEBUG 03012fb82a49cd8efeda55bba83e9725ef0a47d6efdd64d7ca337982e543bf28b3-channeld-chan#33: Sending peer that we want to STFU.
2025-04-30T01:46:09.206Z DEBUG 03012fb82a49cd8efeda55bba83e9725ef0a47d6efdd64d7ca337982e543bf28b3-channeld-chan#33: peer_out WIRE_STFU
2025-04-30T01:46:09.982Z DEBUG 03012fb82a49cd8efeda55bba83e9725ef0a47d6efdd64d7ca337982e543bf28b3-channeld-chan#33: peer_in WIRE_STFU
2025-04-30T01:46:09.986Z DEBUG 03012fb82a49cd8efeda55bba83e9725ef0a47d6efdd64d7ca337982e543bf28b3-channeld-chan#33: STFU initiator local.
2025-04-30T01:46:09.986Z UNUSUAL 03012fb82a49cd8efeda55bba83e9725ef0a47d6efdd64d7ca337982e543bf28b3-channeld-chan#33: STFU complete: we are quiescent
2025-04-30T01:46:09.995Z UNUSUAL 03012fb82a49cd8efeda55bba83e9725ef0a47d6efdd64d7ca337982e543bf28b3-channeld-chan#33: STFU complete: setting stfu_wait_single_msg = true
2025-04-30T01:46:09.995Z INFO 03012fb82a49cd8efeda55bba83e9725ef0a47d6efdd64d7ca337982e543bf28b3-chan#33: lightningd got confirmed stfu from channeld, channel_id count: 1
2025-04-30T01:46:09.996Z INFO 03012fb82a49cd8efeda55bba83e9725ef0a47d6efdd64d7ca337982e543bf28b3-chan#33: lightningd found channel_id in command and removed it
2025-04-30T01:46:09.996Z INFO 03012fb82a49cd8efeda55bba83e9725ef0a47d6efdd64d7ca337982e543bf28b3-chan#33: Finished processing confirmed stfu, channel_id count: 0
2025-04-30T01:46:09.996Z DEBUG 03012fb82a49cd8efeda55bba83e9725ef0a47d6efdd64d7ca337982e543bf28b3-channeld-chan#33: peer_in WIRE_ANNOUNCEMENT_SIGNATURES
2025-04-30T01:46:09.996Z DEBUG 03012fb82a49cd8efeda55bba83e9725ef0a47d6efdd64d7ca337982e543bf28b3-channeld-chan#33: peer_out WIRE_WARNING
2025-04-30T01:46:09.996Z DEBUG 03012fb82a49cd8efeda55bba83e9725ef0a47d6efdd64d7ca337982e543bf28b3-channeld-chan#33: billboard perm: Got invalid message during STFU mode: WIRE_ANNOUNCEMENT_SIGNATURES
2025-04-30T01:46:09.996Z INFO 03012fb82a49cd8efeda55bba83e9725ef0a47d6efdd64d7ca337982e543bf28b3-chan#33: Peer transient failure in CHANNELD_NORMAL: channeld sent Got invalid message during STFU mode: WIRE_ANNOUNCEMENT_SIGNATURES
2025-04-30T01:46:10.007Z INFO plugin-spenderp: Killing plugin: exited during normal operation
2025-04-30T01:46:10.007Z **BROKEN** plugin-spenderp: Plugin marked as important, shutting down lightningd!
2025-04-30T01:46:10.007Z DEBUG lightningd: io_break: lightningd_exit
2025-04-30T01:46:10.007Z DEBUG lightningd: io_loop_with_timers: main
2025-04-30T01:46:10.016Z DEBUG 03012fb82a49cd8efeda55bba83e9725ef0a47d6efdd64d7ca337982e543bf28b3-connectd: disconnect_peer
2025-04-30T01:46:10.017Z DEBUG connectd: drain_peer
2025-04-30T01:46:10.017Z DEBUG 03012fb82a49cd8efeda55bba83e9725ef0a47d6efdd64d7ca337982e543bf28b3-lightningd: peer_disconnect_done
2025-04-30T01:46:10.017Z DEBUG 03012fb82a49cd8efeda55bba83e9725ef0a47d6efdd64d7ca337982e543bf28b3-connectd: Will try reconnect in 1 seconds
2025-04-30T01:46:10.017Z DEBUG connectd: REPLY WIRE_CONNECTD_START_SHUTDOWN_REPLY with 0 fds
2025-04-30T01:46:10.021Z DEBUG lightningd: io_break: connectd_start_shutdown_reply
2025-04-30T01:46:10.022Z DEBUG 03fd105d7df6595d5a36f016b8ff9ca74e5474e29593c4bba85f4d7ad4663bc5ee-channeld-chan#32: Status closed, but not exited. Killing
2025-04-30T01:46:10.023Z INFO 03fd105d7df6595d5a36f016b8ff9ca74e5474e29593c4bba85f4d7ad4663bc5ee-chan#32: Peer transient failure in CHANNELD_NORMAL: channeld: Owning subdaemon channeld died (9)
2025-04-30T01:46:10.025Z INFO 02740c62f38896511eb98479036b06907fcac283f62d08b756a1e25fb55e3f6772-chan#22: Peer transient failure in CHANNELD_NORMAL: channeld: Owning subdaemon channeld died (256)
2025-04-30T01:46:10.025Z DEBUG 03afa7a8196dbca763ee6f9a34b634a7adc03f154e5d6979fe654db5606b5fb2b1-channeld-chan#25: Status closed, but not exited. Killing
2025-04-30T01:46:10.027Z INFO 03afa7a8196dbca763ee6f9a34b634a7adc03f154e5d6979fe654db5606b5fb2b1-chan#25: Peer transient failure in CHANNELD_NORMAL: channeld: Owning subdaemon channeld died (9)
2025-04-30T01:46:10.360Z DEBUG connectd: maybe_free_peer freeing peer!
2025-04-30T01:46:10.725Z INFO plugin-cln-nip47: Completely disconnected from 'wss://relay.getalby.com/v1'
2025-04-30T01:46:10.775Z DEBUG plugin-cln-nip47: Killing plugin: exited during normal operation
2025-04-30T01:46:10.830Z DEBUG plugin-clnrest: Killing plugin: exited during normal operation
2025-04-30T01:46:10.830Z DEBUG lightningd: io_break: destroy_plugin
2025-04-30T01:46:10.830Z DEBUG connectd: Shutting down
2025-04-30T01:46:10.847Z DEBUG gossipd: Shutting down
2025-04-30T01:46:10.902Z DEBUG hsmd: Shutting down
admin@rpi:~ ₿
admin@rpi:~ ₿ cl dev-splice 'wallet -> 350000sat; 350000sat -> 5d9cd24;'
{
"code": -4,
"message": "Plugin terminated before replying to RPC call."
}
admin@rpi:~ ₿
admin@rpi:~ ₿
admin@rpi:~ ₿
admin@rpi:~ ₿ cllog
2025-04-30T01:58:17.689Z DEBUG 03012fb82a49cd8efeda55bba83e9725ef0a47d6efdd64d7ca337982e543bf28b3-channeld-chan#33: Sending peer that we want to STFU.
2025-04-30T01:58:17.689Z DEBUG 03012fb82a49cd8efeda55bba83e9725ef0a47d6efdd64d7ca337982e543bf28b3-channeld-chan#33: peer_out WIRE_STFU
2025-04-30T01:58:20.631Z DEBUG 03012fb82a49cd8efeda55bba83e9725ef0a47d6efdd64d7ca337982e543bf28b3-channeld-chan#33: peer_in WIRE_STFU
2025-04-30T01:58:20.631Z DEBUG 03012fb82a49cd8efeda55bba83e9725ef0a47d6efdd64d7ca337982e543bf28b3-channeld-chan#33: STFU initiator local.
2025-04-30T01:58:20.631Z UNUSUAL 03012fb82a49cd8efeda55bba83e9725ef0a47d6efdd64d7ca337982e543bf28b3-channeld-chan#33: STFU complete: we are quiescent
2025-04-30T01:58:20.631Z UNUSUAL 03012fb82a49cd8efeda55bba83e9725ef0a47d6efdd64d7ca337982e543bf28b3-channeld-chan#33: STFU complete: setting stfu_wait_single_msg = true
2025-04-30T01:58:20.631Z INFO 03012fb82a49cd8efeda55bba83e9725ef0a47d6efdd64d7ca337982e543bf28b3-chan#33: lightningd got confirmed stfu from channeld, channel_id count: 1
2025-04-30T01:58:20.631Z INFO 03012fb82a49cd8efeda55bba83e9725ef0a47d6efdd64d7ca337982e543bf28b3-chan#33: lightningd found channel_id in command and removed it
2025-04-30T01:58:20.631Z INFO 03012fb82a49cd8efeda55bba83e9725ef0a47d6efdd64d7ca337982e543bf28b3-chan#33: Finished processing confirmed stfu, channel_id count: 0
2025-04-30T01:58:20.633Z INFO plugin-spenderp: Killing plugin: exited during normal operation
2025-04-30T01:58:20.633Z **BROKEN** plugin-spenderp: Plugin marked as important, shutting down lightningd!
2025-04-30T01:58:20.634Z DEBUG lightningd: io_break: lightningd_exit
2025-04-30T01:58:20.634Z DEBUG lightningd: io_loop_with_timers: main
2025-04-30T01:58:20.637Z DEBUG connectd: REPLY WIRE_CONNECTD_START_SHUTDOWN_REPLY with 0 fds
2025-04-30T01:58:20.637Z DEBUG lightningd: io_break: connectd_start_shutdown_reply
2025-04-30T01:58:20.637Z DEBUG 03012fb82a49cd8efeda55bba83e9725ef0a47d6efdd64d7ca337982e543bf28b3-channeld-chan#33: Status closed, but not exited. Killing
2025-04-30T01:58:20.638Z INFO 03012fb82a49cd8efeda55bba83e9725ef0a47d6efdd64d7ca337982e543bf28b3-chan#33: Peer transient failure in CHANNELD_NORMAL: channeld: Owning subdaemon channeld died (9)
2025-04-30T01:58:20.638Z DEBUG 03fd105d7df6595d5a36f016b8ff9ca74e5474e29593c4bba85f4d7ad4663bc5ee-channeld-chan#32: Status closed, but not exited. Killing
2025-04-30T01:58:20.639Z INFO 03fd105d7df6595d5a36f016b8ff9ca74e5474e29593c4bba85f4d7ad4663bc5ee-chan#32: Peer transient failure in CHANNELD_NORMAL: channeld: Owning subdaemon channeld died (9)
2025-04-30T01:58:20.640Z DEBUG 02740c62f38896511eb98479036b06907fcac283f62d08b756a1e25fb55e3f6772-channeld-chan#22: Status closed, but not exited. Killing
2025-04-30T01:58:20.642Z INFO 02740c62f38896511eb98479036b06907fcac283f62d08b756a1e25fb55e3f6772-chan#22: Peer transient failure in CHANNELD_NORMAL: channeld: Owning subdaemon channeld died (9)
2025-04-30T01:58:20.643Z DEBUG 03afa7a8196dbca763ee6f9a34b634a7adc03f154e5d6979fe654db5606b5fb2b1-channeld-chan#25: Status closed, but not exited. Killing
2025-04-30T01:58:20.645Z INFO 03afa7a8196dbca763ee6f9a34b634a7adc03f154e5d6979fe654db5606b5fb2b1-chan#25: Peer transient failure in CHANNELD_NORMAL: channeld: Owning subdaemon channeld died (9)
2025-04-30T01:58:20.689Z DEBUG plugin-clnrest: Killing plugin: exited during normal operation
2025-04-30T01:58:20.699Z DEBUG plugin-cln-nip47: Killing plugin: exited during normal operation
2025-04-30T01:58:20.700Z DEBUG lightningd: io_break: destroy_plugin
2025-04-30T01:58:20.701Z DEBUG connectd: Shutting down
2025-04-30T01:58:20.710Z DEBUG gossipd: Shutting down
2025-04-30T01:58:20.710Z DEBUG hsmd: Shutting down
admin@rpi:~ ₿
admin@rpi:~ ₿
admin@rpi:~ ₿
admin@rpi:~ ₿ sudo systemctl restart lightningd
admin@rpi:~ ₿
```

cc @ddustin

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.