From 5feb76f6032de952c587e316c73595130404789c Mon Sep 17 00:00:00 2001 From: matejcik Date: Fri, 11 Dec 2020 11:43:48 +0100 Subject: [PATCH] fix(python): do not log "resumed session" if there is no id --- python/src/trezorlib/client.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/python/src/trezorlib/client.py b/python/src/trezorlib/client.py index fb888b404..a75be139a 100644 --- a/python/src/trezorlib/client.py +++ b/python/src/trezorlib/client.py @@ -297,7 +297,7 @@ class TrezorClient: if not isinstance(resp, messages.Features): raise exceptions.TrezorException("Unexpected response to Initialize") - if resp.session_id == self.session_id: + if self.session_id is not None and resp.session_id == self.session_id: LOG.info("Successfully resumed session") elif session_id is not None: LOG.info("Failed to resume session")