mac-zhou / midea-ac-py

Home Assistant Custom Integration for Midea Group(Hualing, Senville, Klimaire, AirCon, Century, Pridiom, Thermocore, Comfee, Toshiba, Carrier, Goodman, Friedrich, Samsung, Kenmore, Trane, Lennox, LG and much more) Air Conditioners via LAN.
MIT License
519 stars 101 forks source link

Home Assistant hangs on Configuration validation with midea_ac #129

Closed KhArtNJava closed 2 years ago

KhArtNJava commented 2 years ago

Describe the bug (描述一下问题) Hello. I am trying to integrate "sysplit wall smart 12 v2 evo hp q" AC to HA. I've cloned this repo, copied midea_ac to \homeassistant\config\custom_components\midea_ac. Restarted HA. It restarted very well.

After that I added to my configuration.yaml

climate:
  - platform: midea_ac
    host: 192.168.1.104
    id: 35184372114367
    # v3 need token and k1(key)
    token: 9A3CB87A6A9408E25DBDA11FDDCE4C6BC53DF0F7898A09AB903E35DBA22D6B5DE3B15332697D696EAEA5B1AB2C0DE075ACE704E44D6D10521F07A0C4658CDB40
    k1: 19604B64DBD34B53928A5AFDC0EA1141AD64728B12694DEA8F7C37C046AEF4D0

After that I've tried to run Configuration validation, but after I pressed "Check configuration" button, validation process hangs infinitely. Also, nothing new came to HA logs, looks like midea_ac cutom component hangs HA config validation process.

Any idea how to fix this issue?..

Screenshots / Logs / Pcap File(屏幕截图/日志/抓包文件) If applicable, add screenshots or your home-assistant log file or pcap file to help explain your problem. 请提交相关截图,日志,抓包让开发者能够更快的解决问题

c:\Python310\Scripts>midea-discover
INFO:msmart.cli:msmart version: 0.2.0 Currently only supports ac devices.
ERROR:msmart.security:authentication failed
INFO:msmart.lan:Got TCP key for 192.168.0.107:50367 -> 192.168.0.104:6444 retries: 0 time: 0.34 4c384fb227064b98630b5734e56d9e8e8e09fb45db07c52745673c0d79347f1c
INFO:msmart.cli:*** Found a device: ←[94m←[1m{'type': 'ac', 'support': True, 'version': 3, 'ip': '192.168.0.104', 'id': 35184372114367, 'port': 6444, 'token': '9A3CB87A6A9408E25DBDA11FDDCE4C6BC53DF0F7898A09AB903E35DBA22D6B5DE3B15332697D696EAEA5B1AB2C0DE075ACE704E44D6D10521F07A0C4658CDB40', 'key': '19604B64DBD34B53928A5AFDC0EA1141AD64728B12694DEA8F7C37C046AEF4D0', 'ssid': 'net_ac_093C'} ←[0m

Versions (版本信息)

KhArtNJava commented 2 years ago

Solved by installing HACS on my HA instance. After that, installed midea_ac component correctly