Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Kasa HS200 devices not working #121452

Closed
addboy58 opened this issue Jul 7, 2024 · 26 comments
Closed

Kasa HS200 devices not working #121452

addboy58 opened this issue Jul 7, 2024 · 26 comments

Comments

@addboy58
Copy link

addboy58 commented Jul 7, 2024

The problem

I have 5 KASA devices not are not working in HA but work in the KASA app and in Alexa. I have reinstalled, rebooted the router and HA.

What version of Home Assistant Core has the issue?

2024.7.1

What was the last working version of Home Assistant Core?

2024.5.1

What type of installation are you running?

Home Assistant OS

Integration causing the issue

TPLink

Link to integration documentation on our website

No response

Diagnostics information

No response

Example YAML snippet

No response

Anything in the logs that might be useful for us?

No response

Additional information

No response

@home-assistant
Copy link

home-assistant bot commented Jul 7, 2024

Hey there @rytilahti, @bdraco, @sdb9696, mind taking a look at this issue as it has been labeled with an integration (tplink) you are listed as a code owner for? Thanks!

Code owner commands

Code owners of tplink can trigger bot actions by commenting:

  • @home-assistant close Closes the issue.
  • @home-assistant rename Awesome new title Renames the issue.
  • @home-assistant reopen Reopen the issue.
  • @home-assistant unassign tplink Removes the current integration label and assignees on the issue, add the integration domain after the command.
  • @home-assistant add-label needs-more-information Add a label (needs-more-information, problem in dependency, problem in custom component) to the issue.
  • @home-assistant remove-label needs-more-information Remove a label (needs-more-information, problem in dependency, problem in custom component) on the issue.

(message by CodeOwnersMention)


tplink documentation
tplink source
(message by IssueLinks)

@sdb9696
Copy link
Contributor

sdb9696 commented Jul 7, 2024

Can you give more details please like device models and some logs from core?

@addboy58
Copy link
Author

addboy58 commented Jul 7, 2024 via email

@MaikWagner
Copy link

MaikWagner commented Jul 8, 2024

Hi, I'm suffering from the same issues. Here are some log lines from HA core:
2024-07-08 14:14:26.424 ERROR (MainThread) [homeassistant.components.tplink.coordinator] Error fetching 192.168.178.62 data: get_device_info not found in {'get_connect_cloud_state': {'status': -1018}, 'get_device_info': <SmartErrorCode.JSON_ENCODE_FAIL_ERROR: -1004>, 'get_device_usage': {'time_usage': {'today': 0, 'past7': 42, 'past30': 134}, 'power_usage': {'today': 0, 'past7': 1, 'past30': 7}, 'saved_power': {'today': 0, 'past7': 41, 'past30': 127}}, 'get_latest_fw': {'type': 0, 'fw_ver': '1.3.0 Build 20230831 Rel. 75926', 'release_date': '', 'release_note': '', 'fw_size': 0, 'hw_id': '', 'oem_id': '', 'need_to_upgrade': False}, 'get_dynamic_light_effect_rules': {'enable': False, 'sum': 2, 'start_index': 0, 'rule_list': []}, 'get_preset_rules': {'states': [{'hue': 100, 'saturation': 100, 'color_temp': 6000, 'brightness': 50}, {'hue': 240, 'saturation': 100, 'color_temp': 0, 'brightness': 100}, {'hue': 0, 'saturation': 100, 'color_temp': 0, 'brightness': 100}, {'hue': 60, 'saturation': 100, 'color_temp': 0, 'brightness': 100}, {'hue': 120, 'saturation': 100, 'color_temp': 0, 'brightness': 100}, {'hue': 277, 'saturation': 86, 'color_temp': 0, 'brightness': 100}, {'hue': 180, 'saturation': 100, 'color_temp': 0, 'brightness': 100}]}, 'get_on_off_gradually_info': {'enable': False}, 'get_device_time': {'timestamp': 1720440866, 'time_diff': 60, 'region': 'Europe/Berlin'}} for device 192.168.178.62 2024-07-08 14:15:06.283 ERROR (MainThread) [homeassistant.components.tplink.coordinator] Unexpected error fetching 192.168.178.62 data File "/usr/src/homeassistant/homeassistant/components/tplink/coordinator.py", line 49, in _async_update_data 2024-07-08 14:24:03.661 ERROR (MainThread) [homeassistant.components.tplink.coordinator] Error fetching 192.168.178.62 data: ('Unable to query the device, timed out: 192.168.178.62: ', TimeoutError())

Logger: kasa.klaptransport
Source: components/tplink/coordinator.py:49
First occurred: 14:14:56 (73 occurrences)
Last logged: 14:17:30

Query failed after successful authentication Host is 192.168.178.62, Sequence is 14903534, Response status is 403, Request was {"method":"get_connect_cloud_state","params":null,"requestID":1259966581564379136,"request_time_milis":1720441042092,"terminal_uuid":"8mtJgACutrBTr1XTHQN7PQ=="}
Query failed after successful authentication Host is 192.168.178.62, Sequence is -2134412481, Response status is 403, Request was {"method":"get_connect_cloud_state","params":null,"requestID":1259966586408800256,"request_time_milis":1720441043247,"terminal_uuid":"8mtJgACutrBTr1XTHQN7PQ=="}
Query failed after successful authentication Host is 192.168.178.62, Sequence is -48037013, Response status is 403, Request was {"method":"get_connect_cloud_state","params":null,"requestID":1259966591051894784,"request_time_milis":1720441044354,"terminal_uuid":"8mtJgACutrBTr1XTHQN7PQ=="}
Query failed after successful authentication Host is 192.168.178.62, Sequence is -1179692543, Response status is 403, Request was {"method":"get_connect_cloud_state","params":null,"requestID":1259966595657240576,"request_time_milis":1720441045452,"terminal_uuid":"8mtJgACutrBTr1XTHQN7PQ=="}
Query failed after successful authentication Host is 192.168.178.62, Sequence is 1279245881, Response status is 403, Request was {"method":"get_connect_cloud_state","params":null,"requestID":1259966615114616832,"request_time_milis":1720441050091,"terminal_uuid":"8mtJgACutrBTr1XTHQN7PQ=="}

2024-07-08 14:06:17.308 WARNING (MainThread) [kasa.smartprotocol] Received unknown error code: -1011 2024-07-08 14:06:30.631 WARNING (MainThread) [kasa.smartprotocol] Received unknown error code: -1011 2024-07-08 14:07:39.058 WARNING (MainThread) [kasa.smartprotocol] Received unknown error code: -1011 2024-07-08 14:07:52.548 WARNING (MainThread) [kasa.smartprotocol] Received unknown error code: -1011 2024-07-08 14:09:00.773 WARNING (MainThread) [kasa.smartprotocol] Received unknown error code: -1011 2024-07-08 14:09:14.365 WARNING (MainThread) [kasa.smartprotocol] Received unknown error code: -1011 2024-07-08 14:10:22.253 WARNING (MainThread) [kasa.smartprotocol] Received unknown error code: -1011 2024-07-08 14:10:36.282 WARNING (MainThread) [kasa.smartprotocol] Received unknown error code: -1011 2024-07-08 14:11:43.795 WARNING (MainThread) [kasa.smartprotocol] Received unknown error code: -1011 2024-07-08 14:11:45.767 WARNING (MainThread) [kasa.smartprotocol] Received unknown error code: -1011 2024-07-08 14:11:52.677 WARNING (MainThread) [kasa.smartprotocol] Received unknown error code: -1011 2024-07-08 14:11:57.895 ERROR (MainThread) [kasa.klaptransport] Query failed after successful authentication Host is 192.168.178.62, Sequence is 1497501979, Response status is 403, Request was {"method":"multipleRequest","params":{"requests":[{"method":"component_nego","params":null},{"method":"get_device_info","params":null},{"method":"get_connect_cloud_state","params":null}]},"requestID":1259965221087350784,"request_time_milis":1720440717729,"terminal_uuid":"Od5h5/AGf+T8sIchhhy96Q=="} 2024-07-08 14:11:58.959 ERROR (MainThread) [kasa.klaptransport] Query failed after successful authentication Host is 192.168.178.62, Sequence is 148363018, Response status is 403, Request was {"method":"multipleRequest","params":{"requests":[{"method":"component_nego","params":null},{"method":"get_device_info","params":null},{"method":"get_connect_cloud_state","params":null}]},"requestID":1259965225986297856,"request_time_milis":1720440718897,"terminal_uuid":"Od5h5/AGf+T8sIchhhy96Q=="} 2024-07-08 14:12:00.023 ERROR (MainThread) [kasa.klaptransport] Query failed after successful authentication Host is 192.168.178.62, Sequence is 1437831252, Response status is 403, Request was {"method":"multipleRequest","params":{"requests":[{"method":"component_nego","params":null},{"method":"get_device_info","params":null},{"method":"get_connect_cloud_state","params":null}]},"requestID":1259965230444843008,"request_time_milis":1720440719960,"terminal_uuid":"Od5h5/AGf+T8sIchhhy96Q=="} 2024-07-08 14:12:01.075 ERROR (MainThread) [kasa.klaptransport] Query failed after successful authentication Host is 192.168.178.62, Sequence is -1885710864, Response status is 403, Request was {"method":"multipleRequest","params":{"requests":[{"method":"component_nego","params":null},{"method":"get_device_info","params":null},{"method":"get_connect_cloud_state","params":null}]},"requestID":1259965234907582464,"request_time_milis":1720440721024,"terminal_uuid":"Od5h5/AGf+T8sIchhhy96Q=="} 2024-07-08 14:12:04.140 ERROR (MainThread) [kasa.klaptransport] Query failed after successful authentication Host is 192.168.178.62, Sequence is 2035845502, Response status is 403, Request was {"method":"multipleRequest","params":{"requests":[{"method":"component_nego","params":null},{"method":"get_device_info","params":null},{"method":"get_connect_cloud_state","params":null}]},"requestID":1259965247561797632,"request_time_milis":1720440724041,"terminal_uuid":"eOqKGM3I0LCiSBBfSfxs+g=="} 2024-07-08 14:12:05.347 ERROR (MainThread) [kasa.klaptransport] Query failed after successful authentication Host is 192.168.178.62, Sequence is -1691844937, Response status is 403, Request was {"method":"multipleRequest","params":{"requests":[{"method":"component_nego","params":null},{"method":"get_device_info","params":null},{"method":"get_connect_cloud_state","params":null}]},"requestID":1259965252179726336,"request_time_milis":1720440725142,"terminal_uuid":"eOqKGM3I0LCiSBBfSfxs+g=="} 2024-07-08 14:12:06.408 ERROR (MainThread) [kasa.klaptransport] Query failed after successful authentication Host is 192.168.178.62, Sequence is 1478768597, Response status is 403, Request was {"method":"multipleRequest","params":{"requests":[{"method":"component_nego","params":null},{"method":"get_device_info","params":null},{"method":"get_connect_cloud_state","params":null}]},"requestID":1259965257238056960,"request_time_milis":1720440726348,"terminal_uuid":"eOqKGM3I0LCiSBBfSfxs+g=="} 2024-07-08 14:12:07.469 ERROR (MainThread) [kasa.klaptransport] Query failed after successful authentication Host is 192.168.178.62, Sequence is 1802690768, Response status is 403, Request was {"method":"multipleRequest","params":{"requests":[{"method":"component_nego","params":null},{"method":"get_device_info","params":null},{"method":"get_connect_cloud_state","params":null}]},"requestID":1259965261688213504,"request_time_milis":1720440727409,"terminal_uuid":"eOqKGM3I0LCiSBBfSfxs+g=="} 2024-07-08 14:12:21.442 ERROR (MainThread) [kasa.klaptransport] Query failed after successful authentication Host is 192.168.178.62, Sequence is -1858808881, Response status is 403, Request was {"method":"multipleRequest","params":{"requests":[{"method":"component_nego","params":null},{"method":"get_device_info","params":null},{"method":"get_connect_cloud_state","params":null}]},"requestID":1259965320215531520,"request_time_milis":1720440741363,"terminal_uuid":"ge4sGfyV3WY1fvzfk7SgTQ=="} 2024-07-08 14:12:22.511 ERROR (MainThread) [kasa.klaptransport] Query failed after successful authentication Host is 192.168.178.62, Sequence is 360909894, Response status is 403, Request was {"method":"multipleRequest","params":{"requests":[{"method":"component_nego","params":null},{"method":"get_device_info","params":null},{"method":"get_connect_cloud_state","params":null}]},"requestID":1259965324745379840,"request_time_milis":1720440742443,"terminal_uuid":"ge4sGfyV3WY1fvzfk7SgTQ=="} 2024-07-08 14:12:23.585 ERROR (MainThread) [kasa.klaptransport] Query failed after successful authentication Host is 192.168.178.62, Sequence is 1426125905, Response status is 403, Request was {"method":"multipleRequest","params":{"requests":[{"method":"component_nego","params":null},{"method":"get_device_info","params":null},{"method":"get_connect_cloud_state","params":null}]},"requestID":1259965329233285120,"request_time_milis":1720440743513,"terminal_uuid":"ge4sGfyV3WY1fvzfk7SgTQ=="} 2024-07-08 14:12:24.639 ERROR (MainThread) [kasa.klaptransport] Query failed after successful authentication Host is 192.168.178.62, Sequence is -431845425, Response status is 403, Request was {"method":"multipleRequest","params":{"requests":[{"method":"component_nego","params":null},{"method":"get_device_info","params":null},{"method":"get_connect_cloud_state","params":null}]},"requestID":1259965333733773312,"request_time_milis":1720440744586,"terminal_uuid":"ge4sGfyV3WY1fvzfk7SgTQ=="} 2024-07-08 14:13:23.453 ERROR (MainThread) [kasa.smartprotocol] Device 192.168.178.62 returned empty results list for method get_dynamic_light_effect_rules 2024-07-08 14:13:23.480 WARNING (MainThread) [kasa.smartprotocol] Received unknown error code: -1011 2024-07-08 14:14:26.424 ERROR (MainThread) [homeassistant.components.tplink.coordinator] Error fetching 192.168.178.62 data: get_device_info not found in {'get_connect_cloud_state': {'status': -1018}, 'get_device_info': <SmartErrorCode.JSON_ENCODE_FAIL_ERROR: -1004>, 'get_device_usage': {'time_usage': {'today': 0, 'past7': 42, 'past30': 134}, 'power_usage': {'today': 0, 'past7': 1, 'past30': 7}, 'saved_power': {'today': 0, 'past7': 41, 'past30': 127}}, 'get_latest_fw': {'type': 0, 'fw_ver': '1.3.0 Build 20230831 Rel. 75926', 'release_date': '', 'release_note': '', 'fw_size': 0, 'hw_id': '', 'oem_id': '', 'need_to_upgrade': False}, 'get_dynamic_light_effect_rules': {'enable': False, 'sum': 2, 'start_index': 0, 'rule_list': []}, 'get_preset_rules': {'states': [{'hue': 100, 'saturation': 100, 'color_temp': 6000, 'brightness': 50}, {'hue': 240, 'saturation': 100, 'color_temp': 0, 'brightness': 100}, {'hue': 0, 'saturation': 100, 'color_temp': 0, 'brightness': 100}, {'hue': 60, 'saturation': 100, 'color_temp': 0, 'brightness': 100}, {'hue': 120, 'saturation': 100, 'color_temp': 0, 'brightness': 100}, {'hue': 277, 'saturation': 86, 'color_temp': 0, 'brightness': 100}, {'hue': 180, 'saturation': 100, 'color_temp': 0, 'brightness': 100}]}, 'get_on_off_gradually_info': {'enable': False}, 'get_device_time': {'timestamp': 1720440866, 'time_diff': 60, 'region': 'Europe/Berlin'}} for device 192.168.178.62 2024-07-08 14:14:56.434 ERROR (MainThread) [kasa.klaptransport] Query failed after successful authentication Host is 192.168.178.62, Sequence is 535856492, Response status is 403, Request was {"method":"get_dynamic_light_effect_rules","params":{"start_index":0},"requestID":1259965970538172416,"request_time_milis":1720440896412,"terminal_uuid":"8mtJgACutrBTr1XTHQN7PQ=="} 2024-07-08 14:14:57.910 ERROR (MainThread) [kasa.klaptransport] Query failed after successful authentication Host is 192.168.178.62, Sequence is 1338912013, Response status is 403, Request was {"method":"get_dynamic_light_effect_rules","params":{"start_index":0},"requestID":1259965976636690432,"request_time_milis":1720440897866,"terminal_uuid":"8mtJgACutrBTr1XTHQN7PQ=="} 2024-07-08 14:14:59.514 ERROR (MainThread) [kasa.klaptransport] Query failed after successful authentication Host is 192.168.178.62, Sequence is 1957046594, Response status is 403, Request was {"method":"get_dynamic_light_effect_rules","params":{"start_index":0},"requestID":1259965983473405952,"request_time_milis":1720440899496,"terminal_uuid":"8mtJgACutrBTr1XTHQN7PQ=="} 2024-07-08 14:15:01.395 ERROR (MainThread) [kasa.klaptransport] Query failed after successful authentication Host is 192.168.178.62, Sequence is -370553262, Response status is 403, Request was {"method":"get_dynamic_light_effect_rules","params":{"start_index":0},"requestID":1259965991362891776,"request_time_milis":1720440901377,"terminal_uuid":"8mtJgACutrBTr1XTHQN7PQ=="} 2024-07-08 14:15:06.283 ERROR (MainThread) [homeassistant.components.tplink.coordinator] Unexpected error fetching 192.168.178.62 data Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 312, in _async_refresh self.data = await self._async_update_data() ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/components/tplink/coordinator.py", line 49, in _async_update_data await self.device.update(update_children=False) File "/usr/local/lib/python3.12/site-packages/kasa/smart/smartdevice.py", line 165, in update self._last_update = resp = await self.protocol.query(req) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/kasa/smartprotocol.py", line 68, in query return await self._query(request, retry_count) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/kasa/smartprotocol.py", line 73, in _query return await self._execute_query( ^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/kasa/smartprotocol.py", line 202, in _execute_query return await self._execute_multiple_query(request, retry_count) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/kasa/smartprotocol.py", line 129, in _execute_multiple_query resp = await self._transport.send(req) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/kasa/klaptransport.py", line 356, in send decrypted_response = self._encryption_session.decrypt(response_data) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/kasa/klaptransport.py", line 495, in decrypt return plaintextbytes.decode() ^^^^^^^^^^^^^^^^^^^^^^^ UnicodeDecodeError: 'utf-8' codec can't decode byte 0xfc in position 0: invalid start byte 2024-07-08 14:15:11.217 WARNING (MainThread) [kasa.smartprotocol] Received unknown error code: None

@sdb9696
Copy link
Contributor

sdb9696 commented Jul 8, 2024

Hi, I'm suffering from the same issues. Here are some log lines from HA core:

What model is this device?

@sdb9696
Copy link
Contributor

sdb9696 commented Jul 8, 2024

The item is a tplink hs 200. I tried send log file but keep getting an error.

All 5 devices not working are hs200? Have they ever worked in HA?

If you upload the logs via the github issue webpage it should work. Maybe you are trying to send them via email?

@sdb9696
Copy link
Contributor

sdb9696 commented Jul 8, 2024

@home-assistant rename Kasa HS200 devices not working

@home-assistant home-assistant bot changed the title Kasa devices not workin. Kasa HS200 devices not working Jul 8, 2024
@MaikWagner
Copy link

These are all my TP-Link devices: 1x Tapo L530E light bulb and 4x Tapo P100 power plugs. None of them work over home assistant but with Amazon Echo and the Tapo app. WLAN connection is basically established. It worked until the latest HA core update.

Currently running:
Core 2024.7.1 Supervisor 2024.06.2 Operating System 12.4 Frontend 20240705.0

@sdb9696
Copy link
Contributor

sdb9696 commented Jul 8, 2024

These are all my TP-Link devices: 1x Tapo L530E light bulb and 4x Tapo P100 power plugs. None of them work over home assistant but with Amazon Echo and the Tapo app. WLAN connection is basically established. It worked until the latest HA core update.

The log you posted earlier is for which device model? Can you get the hardware and firmware versions from the tapo app for the L530E?

@MaikWagner
Copy link

The log you posted earlier is for which device model? Can you get the hardware and firmware versions from the tapo app for the L530E?

192.168.178.62 is the light bulb: Hardware version 1.0, Firmware version 1.3.0

(btw the plugs are all on 1.5.5 Build 20230927 Rel. 40646, Hardware version 1.20.0)

@MaikWagner
Copy link

And latest traceback shown in the logs:
2024-07-08 16:22:25.002 ERROR (MainThread) [homeassistant.config_entries] Error setting up entry Küchentisch L530 Series for tplink Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/config_entries.py", line 586, in async_setup result = await component.async_setup_entry(hass, self) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/components/tplink/__init__.py", line 165, in async_setup_entry device: Device = await Device.connect(config=config) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/kasa/device.py", line 233, in connect return await connect(host=host, config=config) # type: ignore[arg-type] ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/kasa/device_factory.py", line 71, in connect return await _connect(config, protocol) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/kasa/device_factory.py", line 110, in _connect await device.update() File "/usr/local/lib/python3.12/site-packages/kasa/smart/smartdevice.py", line 156, in update await self._negotiate() File "/usr/local/lib/python3.12/site-packages/kasa/smart/smartdevice.py", line 132, in _negotiate resp = await self.protocol.query(initial_query) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/kasa/smartprotocol.py", line 68, in query return await self._query(request, retry_count) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/kasa/smartprotocol.py", line 73, in _query return await self._execute_query( ^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/kasa/smartprotocol.py", line 202, in _execute_query return await self._execute_multiple_query(request, retry_count) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/kasa/smartprotocol.py", line 129, in _execute_multiple_query resp = await self._transport.send(req) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/kasa/klaptransport.py", line 356, in send decrypted_response = self._encryption_session.decrypt(response_data) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/kasa/klaptransport.py", line 493, in decrypt plaintextbytes = unpadder.update(dp) + unpadder.finalize() ^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/cryptography/hazmat/primitives/padding.py", line 160, in finalize result = _byte_unpadding_check( ^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/cryptography/hazmat/primitives/padding.py", line 102, in _byte_unpadding_check raise ValueError("Invalid padding bytes.") ValueError: Invalid padding bytes.

@sdb9696
Copy link
Contributor

sdb9696 commented Jul 8, 2024

The log you posted earlier is for which device model? Can you get the hardware and firmware versions from the tapo app for the L530E?

192.168.178.62 is the light bulb: Hardware version 1.0, Firmware version 1.3.0

So for the L530E HW 1.0, FW 1.3.0 there is an issue open here: #121362 which you can track.

(btw the plugs are all on 1.5.5 Build 20230927 Rel. 40646, Hardware version 1.20.0)

For the P100 HW1.20 FW 1.5.5 there is an open issue here: #121384 which you can track.

Ideally we'll keep this issue specifically for the HS200s as that looks like it's a different root cause.

@MaikWagner
Copy link

Ok, I thought it may be related. Thanks for your effort!

@sdb9696
Copy link
Contributor

sdb9696 commented Jul 9, 2024

@home-assistant add-label needs-more-information

@sdb9696
Copy link
Contributor

sdb9696 commented Jul 9, 2024

@MaikWagner we have a potential fix for both the L530E and P100 issues. Ping me on discord if you want to help get it tested. Handle is the same, sdb9696.

@sdb9696
Copy link
Contributor

sdb9696 commented Jul 10, 2024

@addboy58 still hoping you can upload some logs for the HS200 issue you originally reported. Not sure what error you're getting but you should be able to enable debug logging from the tplink integration page and then after a while download from settings > system the core logs.

@Hubbsjp
Copy link

Hubbsjp commented Jul 11, 2024

I have had similar issues with 5 KS205 Kasa devices. They always needed repair after going to HA Core 6, but mostly still worked. I just upgraded to HA Core 7 (straight to 7.2) and now all 5 are unavailable. I turned on debug logs for the tp link integration, and tried to reload, but am not sure where to look for any generated logs. The HA Core logs don't reveal anything.

@sdb9696
Copy link
Contributor

sdb9696 commented Jul 11, 2024

You can enable debug logging on the tplink integration page and then reload them to get logs.

@Hubbsjp
Copy link

Hubbsjp commented Jul 11, 2024

right @sdb9696 - indeed I did do that. Admittedly I never look at logs or work with logs, but I just searched the logs and there are only two small references that have anything to do with TP-Link or KS205. They honestly don't look to be helpful but I could be wrong.

@sdb9696
Copy link
Contributor

sdb9696 commented Jul 11, 2024

If the logs were switched on while you reloaded the config entry they will be extremely helpful. If not, keep them on and then do a reload and send them. Without them we cannot do much.

@Hubbsjp
Copy link

Hubbsjp commented Jul 11, 2024

Thanks @sdb9696 . I turned debugging on this morning and then reloaded all 5 devices, but I am certainly willing to do it again. I will try again after work today when I can.

@Hubbsjp
Copy link

Hubbsjp commented Jul 12, 2024

Hey Steve - I must be doing something wrong - there must be something more than this. The 3 items you see listed below are all KS205s

Logger: homeassistant.helpers.service
Source: helpers/service.py:301
First occurred: 6:10:36 AM (112 occurrences)
Last logged: 6:27:19 PM

Referenced entities light.entry_bathroom are missing or not currently available
Referenced entities light.laundry are missing or not currently available
Referenced entities light.hallway_light are missing or not currently available

@Hubbsjp
Copy link

Hubbsjp commented Jul 13, 2024

@sdb9696 - I finally had a little more time this morning to look into the devices and the integration. I guess when I originally added the tp-link integration my ks205s integrated and I went with it. As it turns out those devices have matter, so I simply switched them over to matter integration. Thanks for watching the thread, and hope you all are able to resolve all issues.

@ivanchaukn
Copy link

Hi, I just installed two new HS220 switches this morning. I was able to add it to the tapo app but not discoverable in HA.

Hardware version: 3.0
Firmware version: 1.0.11

@sdb9696
Copy link
Contributor

sdb9696 commented Jul 16, 2024

Closing this issue as I have no logs from the OP to investigate the HS200 issue.

Anyone else on this thread still having issues please open a fresh issue specific to your devices and include some debug logs and full issue descriptions for investigation. Thanks

@sdb9696
Copy link
Contributor

sdb9696 commented Jul 16, 2024

@home-assistant close

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

8 participants