mirror of
https://github.com/aljazceru/lightning.git
synced 2025-12-20 07:34:24 +01:00
pytest: make sure we wait for node announcements in line_graph too.
Occasional failure in test_fulfill_incoming_first where the channel closed before the final message from dev_disonnect was read. Cause was the peer writing a gossip msg and failing due to ECONNRESET, before it read the final message. (Managed to reproduce under strace -f, FTW). This is really a symptom of the fact that line_graph's announce=True didn't wait for node announcements. Let's do that. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
committed by
Christian Decker
parent
ae4f358711
commit
0bc80c4687
@@ -833,6 +833,11 @@ class NodeFactory(object):
|
|||||||
wait_for(lambda: both_dirs_ready(nodes[0], scids[-1]))
|
wait_for(lambda: both_dirs_ready(nodes[0], scids[-1]))
|
||||||
wait_for(lambda: both_dirs_ready(nodes[-1], scids[0]))
|
wait_for(lambda: both_dirs_ready(nodes[-1], scids[0]))
|
||||||
|
|
||||||
|
# Make sure we have all node announcements, too (just check ends)
|
||||||
|
for n in nodes:
|
||||||
|
for end in (nodes[0], nodes[-1]):
|
||||||
|
wait_for(lambda: 'alias' in only_one(end.rpc.listnodes(n.info['id'])['nodes']))
|
||||||
|
|
||||||
return nodes
|
return nodes
|
||||||
|
|
||||||
def killall(self, expected_successes):
|
def killall(self, expected_successes):
|
||||||
|
|||||||
Reference in New Issue
Block a user