URI: 
       tMerge pull request #3362 from SomberNight/dbb_py3_hid_send - electrum - Electrum Bitcoin wallet
  HTML git clone https://git.parazyd.org/electrum
   DIR Log
   DIR Files
   DIR Refs
   DIR Submodules
       ---
   DIR commit 355e77b39daff67c682e35b630fc6801cda92730
   DIR parent 9edffd17542de5773e7284a8c8a2673c766bb3c3
  HTML Author: ThomasV <thomasv@electrum.org>
       Date:   Thu, 23 Nov 2017 19:32:39 +0100
       
       Merge pull request #3362 from SomberNight/dbb_py3_hid_send
       
       fix: py3 digitalbitbox hid_send
       Diffstat:
         M plugins/digitalbitbox/digitalbitbo… |       4 +++-
       
       1 file changed, 3 insertions(+), 1 deletion(-)
       ---
   DIR diff --git a/plugins/digitalbitbox/digitalbitbox.py b/plugins/digitalbitbox/digitalbitbox.py
       t@@ -11,7 +11,7 @@ try:
            from electrum.i18n import _
            from electrum.keystore import Hardware_KeyStore
            from ..hw_wallet import HW_PluginBase
       -    from electrum.util import print_error
       +    from electrum.util import print_error, to_string
        
            import time
            import hid
       t@@ -365,6 +365,7 @@ class DigitalBitbox_Client():
                        r = self.hid_read_frame()
                    r = r.rstrip(b' \t\r\n\0')
                    r = r.replace(b"\0", b'')
       +            r = to_string(r, 'utf8')
                    reply = json.loads(r)
                except Exception as e:
                    print_error('Exception caught ' + str(e))
       t@@ -379,6 +380,7 @@ class DigitalBitbox_Client():
                    reply = self.hid_send_plain(msg)
                    if 'ciphertext' in reply:
                        reply = DecodeAES(secret, ''.join(reply["ciphertext"]))
       +                reply = to_string(reply, 'utf8')
                        reply = json.loads(reply)
                    if 'error' in reply:
                        self.password = None