fix: fix type error, wrong use of any and Any (#338)

* fix: fix type error, wrong use of any and Any

* fix: wrong use of session close

* fix: fix test_lan type error

* fix: remove __del__

* feat: oauth, http add deinit_async
This commit is contained in:
Paul Shawn
2024-12-22 10:46:58 +08:00
committed by GitHub
parent afef709839
commit c1867e2baf
18 changed files with 237 additions and 173 deletions

View File

@ -1,5 +1,6 @@
# -*- coding: utf-8 -*-
"""Unit test for miot_lan.py."""
from typing import Any
import pytest
import asyncio
from zeroconf import IPVersion
@ -79,7 +80,7 @@ async def test_lan_async(test_devices: dict):
evt_push_unavailable = asyncio.Event()
await miot_lan.vote_for_lan_ctrl_async(key='test', vote=True)
async def device_state_change(did: str, state: dict, ctx: any):
async def device_state_change(did: str, state: dict, ctx: Any):
print('device state change, ', did, state)
if did != test_did:
return