diff --git a/aioesphomeapi/connection.py b/aioesphomeapi/connection.py index ec767a3..6b08bc8 100644 --- a/aioesphomeapi/connection.py +++ b/aioesphomeapi/connection.py @@ -355,9 +355,9 @@ class APIConnection: self._connection_state = ConnectionState.CLOSED self._cleanup() raise - else: - self._connection_state = ConnectionState.CONNECTED - self._connect_complete = True + + self._connection_state = ConnectionState.CONNECTED + self._connect_complete = True async def login(self, check_connected: bool = True) -> None: """Send a login (ConnectRequest) and await the response.""" diff --git a/aioesphomeapi/model.py b/aioesphomeapi/model.py index 832598c..94d8a05 100644 --- a/aioesphomeapi/model.py +++ b/aioesphomeapi/model.py @@ -773,7 +773,7 @@ class UserService(APIModelBase): def _join_split_uuid(value: List[int]) -> str: """Convert a high/low uuid into a single string.""" - return str(UUID(int=((value[0] << 64) | value[1]))) + return str(UUID(int=(value[0] << 64) | value[1])) # value is likely a google.protobuf.pyext._message.RepeatedScalarContainer diff --git a/requirements_test.txt b/requirements_test.txt index 23f4278..9ac9fcd 100644 --- a/requirements_test.txt +++ b/requirements_test.txt @@ -1,4 +1,4 @@ -pylint==2.15.10 +pylint==2.16.1 black==22.12.0 flake8==6.0.0 isort==5.11.4