From ef6ccf2bcd102390ddfd77c30f82eafb8859f028 Mon Sep 17 00:00:00 2001 From: Michael Wozniak Date: Sat, 2 Aug 2014 23:41:27 -0400 Subject: [PATCH] Fix dialog for cancelled TX on Trezor --- plugins/trezor.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/plugins/trezor.py b/plugins/trezor.py index d2410115..360eb78c 100644 --- a/plugins/trezor.py +++ b/plugins/trezor.py @@ -175,8 +175,12 @@ class TrezorWallet(NewWallet): inputs = self.tx_inputs(tx) outputs = self.tx_outputs(tx) - signed_tx = self.get_client().sign_tx('Bitcoin', inputs, outputs)[1] - gl_emitter.emit(SIGNAL('trezor_done')) + try: + signed_tx = self.get_client().sign_tx('Bitcoin', inputs, outputs)[1] + except Exception, e: + raise e + finally: + gl_emitter.emit(SIGNAL('trezor_done')) values = [i['value'] for i in tx.inputs] raw = signed_tx.encode('hex') tx.update(raw)