MCPcopy Create free account
hub / github.com/ElementsProject/lightning / wait_bwatch_caught_up

Function wait_bwatch_caught_up

tests/test_plugin.py:40–50  ·  view source on GitHub ↗

Wait until bwatch has caught up to the chain tip and is idle. After restart, height replayed from the datastore skips the "First poll" debug line; both paths eventually emit "No block change" once idle.

(node, timeout=TIMEOUT)

Source from the content-addressed store, hash-verified

38
39
40def wait_bwatch_caught_up(node, timeout=TIMEOUT):
41 """Wait until bwatch has caught up to the chain tip and is idle.
42
43 After restart, height replayed from the datastore skips the "First poll"
44 debug line; both paths eventually emit "No block change" once idle.
45 """
46 node.daemon.wait_for_log(
47 r'First poll: init at block|No block change, current_height remains',
48 timeout=timeout,
49 )
50 node.daemon.wait_for_log(r'No block change', timeout=timeout)
51
52
53def test_option_passthrough(node_factory, directory):

Calls 1

wait_for_logMethod · 0.80

Tested by

no test coverage detected