Use builtin TimeoutError [a-d] (#109678)
This commit is contained in:
parent
41a256a3ff
commit
c82933175d
63 changed files with 97 additions and 137 deletions
|
@ -175,7 +175,7 @@ class APIEventStream(HomeAssistantView):
|
|||
msg = f"data: {payload}\n\n"
|
||||
_LOGGER.debug("STREAM %s WRITING %s", id(stop_obj), msg.strip())
|
||||
await response.write(msg.encode("UTF-8"))
|
||||
except asyncio.TimeoutError:
|
||||
except TimeoutError:
|
||||
await to_write.put(STREAM_PING_PAYLOAD)
|
||||
|
||||
except asyncio.CancelledError:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue