tConstruct base classes in right order - electrum - Electrum Bitcoin wallet
HTML git clone https://git.parazyd.org/electrum
DIR Log
DIR Files
DIR Refs
DIR Submodules
---
DIR commit 98aef8418cf7fdc3e3333ce40d2303af0c1a97f4
DIR parent abdb7f847028dd2863e2dbd9f9190d2f8b3530e9
HTML Author: Neil Booth <kyuupichan@gmail.com>
Date: Sat, 16 Jan 2016 10:19:48 +0900
Construct base classes in right order
Fixed #1632
Diffstat:
M plugins/keepkey/client.py | 2 +-
M plugins/trezor/client.py | 2 +-
M plugins/trezor/clientbase.py | 1 +
3 files changed, 3 insertions(+), 2 deletions(-)
---
DIR diff --git a/plugins/keepkey/client.py b/plugins/keepkey/client.py
t@@ -3,9 +3,9 @@ from ..trezor.clientbase import TrezorClientBase
class KeepKeyClient(TrezorClientBase, ProtocolMixin, BaseClient):
def __init__(self, transport, handler, plugin, hid_id):
- TrezorClientBase.__init__(self, handler, plugin, hid_id, proto)
BaseClient.__init__(self, transport)
ProtocolMixin.__init__(self, transport)
+ TrezorClientBase.__init__(self, handler, plugin, hid_id, proto)
def recovery_device(self, *args):
ProtocolMixin.recovery_device(self, True, *args)
DIR diff --git a/plugins/trezor/client.py b/plugins/trezor/client.py
t@@ -3,9 +3,9 @@ from clientbase import TrezorClientBase
class TrezorClient(TrezorClientBase, ProtocolMixin, BaseClient):
def __init__(self, transport, handler, plugin, hid_id):
- TrezorClientBase.__init__(self, handler, plugin, hid_id, proto)
BaseClient.__init__(self, transport)
ProtocolMixin.__init__(self, transport)
+ TrezorClientBase.__init__(self, handler, plugin, hid_id, proto)
TrezorClientBase.wrap_methods(TrezorClient)
DIR diff --git a/plugins/trezor/clientbase.py b/plugins/trezor/clientbase.py
t@@ -65,6 +65,7 @@ class GuiMixin(object):
class TrezorClientBase(GuiMixin, PrintError):
def __init__(self, handler, plugin, hid_id, proto):
+ assert hasattr(self, 'tx_api') # ProtocolMixin already constructed?
self.proto = proto
self.device = plugin.device
self.handler = handler