diff --git a/python/src/trezorlib/client.py b/python/src/trezorlib/client.py index cd8768f00e..d612610294 100644 --- a/python/src/trezorlib/client.py +++ b/python/src/trezorlib/client.py @@ -47,8 +47,8 @@ Or visit https://suite.trezor.io/ class ProtocolVersion(IntEnum): - PROTOCOL_V1 = 0x01 # Codec - PROTOCOL_V2 = 0x02 # THP + V1 = 0x01 # Codec + V2 = 0x02 # THP class TrezorClient: @@ -88,7 +88,7 @@ class TrezorClient: self.protocol.mapping = self.mapping if isinstance(self.protocol, ProtocolV1Channel): - self._protocol_version = ProtocolVersion.PROTOCOL_V1 + self._protocol_version = ProtocolVersion.V1 else: raise Exception("Unknown protocol version") diff --git a/python/src/trezorlib/debuglink.py b/python/src/trezorlib/debuglink.py index 99835efbdc..a883726f57 100644 --- a/python/src/trezorlib/debuglink.py +++ b/python/src/trezorlib/debuglink.py @@ -1438,7 +1438,7 @@ class TrezorClientDebugLink(TrezorClient): # Start by canceling whatever is on screen. This will work to cancel T1 PIN # prompt, which is in TINY mode and does not respond to `Ping`. - if self.protocol_version is ProtocolVersion.PROTOCOL_V1: + if self.protocol_version is ProtocolVersion.V1: assert isinstance(self.protocol, ProtocolV1Channel) self.protocol.write(messages.Cancel()) resp = self.protocol.read()