mirror of
https://github.com/XiaoMi/ha_xiaomi_home.git
synced 2025-08-05 14:58:52 +08:00
feat: support devices filter & devices changed notify (#332)
* feat: add devices filter page * doc: update translations and i18n * fix: cancel miot http timer * feat: improve devices filter * doc: update translations/de * fix: i18n type error * feat: config flow support device filter * fix: fix mdns type error * fix: fix miot client i18n logic * feat: add connect type * doc: update translations and i18n * feat: update auth info save logic * feat: improve config flow devices filter * fix: fix some type error * doc: update translations for option flow * fix: fix option flow type error * feat: support option flow devices filter * doc: update option flow tranlations * feat: update webhook handle func to private * feat: update config flow translations * doc: update tranlations text * feat: custom display device changed notify * feat: device changed notify logical refinement * doc: update translations content
This commit is contained in:
@ -254,6 +254,13 @@ class MIoTHttpClient:
|
||||
self._session = aiohttp.ClientSession(loop=self._main_loop)
|
||||
|
||||
async def deinit_async(self) -> None:
|
||||
if self._get_prop_timer:
|
||||
self._get_prop_timer.cancel()
|
||||
self._get_prop_timer = None
|
||||
for item in self._get_prop_list.values():
|
||||
fut: asyncio.Future = item.get('fut')
|
||||
fut.cancel()
|
||||
self._get_prop_list.clear()
|
||||
if self._session and not self._session.closed:
|
||||
await self._session.close()
|
||||
|
||||
|
Reference in New Issue
Block a user