Browse Source

wait for peer.initialized in channel_establishment_flow

regtest_lnd
SomberNight 7 years ago
parent
commit
0a77bac351
No known key found for this signature in database GPG Key ID: B33B5F232C6271E9
  1. 1
      lib/lnbase.py
  2. 1
      lib/lnworker.py

1
lib/lnbase.py

@ -781,6 +781,7 @@ class Peer(PrintError):
self.writer.close()
async def channel_establishment_flow(self, wallet, config, password, funding_sat, push_msat, temp_channel_id):
await self.initialized
# see lnd/keychain/derivation.go
keyfamilymultisig = 0
keyfamilyrevocationbase = 1

1
lib/lnworker.py

@ -180,6 +180,7 @@ class LNWorker(PrintError):
def open_channel(self, node_id, local_amt_sat, push_amt_sat, pw):
coro = self._open_channel_coroutine(node_id, local_amt_sat, push_amt_sat, None if pw == "" else pw)
# FIXME this is blocking the GUI
return asyncio.run_coroutine_threadsafe(coro, self.network.asyncio_loop).result()
def pay(self, invoice):

Loading…
Cancel
Save