Skip to content

Commit 2240f09

Browse files
SimonVrouwerustyrussell
authored andcommitted
testing: fix test_closing_higherfee
shutdown_subdaemons frees the channel and calls destroy_close_command_on_channel_destroy, see gdb: 0 destroy_close_command_on_channel_destroy (_=0x55db6ca38e18, cc=0x55db6ca43338) at lightningd/closing_control.c:94 1 0x000055db6a8181b5 in notify (ctx=0x55db6ca38df0, type=TAL_NOTIFY_FREE, info=0x55db6ca38e18, saved_errno=0) at ccan/ccan/tal/tal.c:237 2 0x000055db6a8186bb in del_tree (t=0x55db6ca38df0, orig=0x55db6ca38e18, saved_errno=0) at ccan/ccan/tal/tal.c:402 3 0x000055db6a818a47 in tal_free (ctx=0x55db6ca38e18) at ccan/ccan/tal/tal.c:486 4 0x000055db6a73fffa in shutdown_subdaemons (ld=0x55db6c8b4ca8) at lightningd/lightningd.c:543 5 0x000055db6a741098 in main (argc=21, argv=0x7ffffa3e8048) at lightningd/lightningd.c:1192 Before this PR, there was no io_loop after shutdown_subdaemons and client side raised a general `Connection to RPC server lost.` Now we test the more specific `Channel forgotten before proper close.`, which is good! BTW, this test was added recently in PR #4599.
1 parent 89cbdf4 commit 2240f09

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

tests/test_closing.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -3099,7 +3099,7 @@ def test_closing_higherfee(node_factory, bitcoind, executor):
30993099
l1.daemon.wait_for_log(r'deriving max fee from rate 30000 -> 16440sat \(not 1000000sat\)')
31003100

31013101
# This will fail because l1 restarted!
3102-
with pytest.raises(RpcError, match=r'Connection to RPC server lost.'):
3102+
with pytest.raises(RpcError, match=r'Channel forgotten before proper close.'):
31033103
fut.result(TIMEOUT)
31043104

31053105
# But we still complete negotiation!

0 commit comments

Comments
 (0)