Browse Source

aiosafe: define user visible exception class

dependabot/pip/contrib/deterministic-build/ecdsa-0.13.3
ThomasV 6 years ago
parent
commit
6b9de278d4
  1. 2
      electrum/gui/qt/channels_list.py
  2. 3
      electrum/lnbase.py

2
electrum/gui/qt/channels_list.py

@ -113,9 +113,7 @@ class ChannelsList(MyTreeWidget):
self.main_window.protect(self.open_channel, (connect_contents, local_amt, push_amt))
def open_channel(self, *args, **kwargs):
import traceback, sys
try:
self.parent.wallet.lnworker.open_channel(*args, **kwargs)
except Exception as e:
traceback.print_exc(file=sys.stderr)
self.parent.show_error('Cannot open channel: %s' % str(e))

3
electrum/lnbase.py

@ -21,7 +21,7 @@ from . import ecc
from .ecc import sig_string_from_r_and_s, get_r_and_s_from_sig_string
from .crypto import sha256
from . import constants
from .util import PrintError, bh2u, print_error, bfh, aiosafe
from .util import PrintError, bh2u, print_error, bfh, log_exceptions
from .transaction import Transaction, TxOutput
from .lnonion import new_onion_packet, OnionHopsDataSingle, OnionPerHop, decode_onion_error, ONION_FAILURE_CODE_MAP
from .lnaddr import lndecode
@ -524,6 +524,7 @@ class Peer(PrintError):
per_commitment_secret_seed = keypair_generator(LnKeyFamily.REVOCATION_ROOT).privkey
return local_config, per_commitment_secret_seed
@log_exceptions
async def channel_establishment_flow(self, password, funding_sat, push_msat, temp_channel_id):
await self.initialized
local_config, per_commitment_secret_seed = self.make_local_config(funding_sat, push_msat, LOCAL)

Loading…
Cancel
Save