commit 770ae6d8785c5deaa1ba3b827ed27d10522e141a
parent bda9a407d9b7bd1bcf6c5510b09502692c7c4294
Author: SomberNight <somber.night@protonmail.com>
Date: Fri, 22 Nov 2019 22:11:56 +0100
fix tests
Diffstat:
1 file changed, 1 insertion(+), 0 deletions(-)
diff --git a/electrum/lnpeer.py b/electrum/lnpeer.py
@@ -1132,6 +1132,7 @@ class Peer(Logger):
if chan.get_state() != channel_states.OPEN:
raise PaymentFailure('Channel not open')
assert amount_msat > 0, "amount_msat is not greater zero"
+ await asyncio.wait_for(self.initialized.wait(), LN_P2P_NETWORK_TIMEOUT)
# create onion packet
final_cltv = self.network.get_local_height() + min_final_cltv_expiry
hops_data, amount_msat, cltv = calc_hops_data_for_payment(route, amount_msat, final_cltv)