diff --git a/aioesphomeapi/reconnect_logic.py b/aioesphomeapi/reconnect_logic.py index f6cbd4e..199b6fe 100644 --- a/aioesphomeapi/reconnect_logic.py +++ b/aioesphomeapi/reconnect_logic.py @@ -413,16 +413,11 @@ class ReconnectLogic(zeroconf.RecordUpdateListener): self._cli.log_name, record_update.new, ) - # We can't stop the zeroconf listener here because we are in the middle of - # a zeroconf callback which is iterating the listeners. - # - # So we schedule a stop for the next event loop iteration as well as the - # connect attempt. # # If we scheduled the connect attempt immediately, the listener could fire # again before the connect attempt and we cancel and reschedule the connect # attempt again. # - self.loop.call_soon(self._connect_from_zeroconf) + self._connect_from_zeroconf() self._accept_zeroconf_records = False return diff --git a/requirements.txt b/requirements.txt index e09dac0..b5035ab 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,7 +1,7 @@ aiohappyeyeballs>=2.3.0 async-interrupt>=1.1.1 protobuf>=3.19.0 -zeroconf>=0.128.4,<1.0 +zeroconf>=0.132.1,<1.0 chacha20poly1305-reuseable>=0.12.1 cryptography>=42.0.2 noiseprotocol>=0.3.1,<1.0