Git Product home page Git Product logo

ha-tplink-deco's People

Contributors

amosyuen avatar anonymoesje avatar az01101001 avatar bsimmo avatar cvroque avatar danieldotnl avatar dependabot[bot] avatar gdiepen avatar geck64 avatar github-actions[bot] avatar icebotyt avatar leandroissa avatar misa1515 avatar peterjuras avatar viper5000 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

ha-tplink-deco's Issues

Wrong download value in the attributes

Hi!
I noticed you send twice the upload instead of sending the download.
Units seems to to bauds, can we convert them to ko/s or mo/s?

@property def extra_state_attributes(self): """Return extra state attributes.""" return { "connection_type": self._client.connection_type, "interface": self._client.interface, "down_kb_per_s": self._client.up_kb_per_s, "up_kb_per_s": self._client.up_kb_per_s, }

Internal Server Error when installing

Version of the custom_component

v 1.1.0

Configuration

Installed via UI

Describe the bug

After installing via HACS, I restart and then install into Integrations. This succeeds, but does not ask for the room the device should be placed into.

Looking at the integration in the "Integrations" screen, the top RH icon is red and the following words show beside a red exclamation mark:

Retrying setup: 500, message='Internal Server Error', url=URL('http://192.168.1.164/cgi-bin/luci/;stok=d9c97996f1408896e09ae8a68e1937bc/admin/client?

The Deco is a P9 which I appreciated you have listed as untested, but I have this working perfectly with P9's on my HA setup (this problem is on my mum's). Her HA setup is near identical to mine and I set hers up for her.

Debug log

~/docker/containers/homeassistant/home-assistant.log:253: 2022-02-27 15:01:37 INFO (MainThread) [custom_components.tplink_deco]
~/docker/containers/homeassistant/home-assistant.log:262: 2022-02-27 15:01:37 DEBUG (MainThread) [custom_components.tplink_deco] aes_key=5878763926190932
~/docker/containers/homeassistant/home-assistant.log:263: 2022-02-27 15:01:37 DEBUG (MainThread) [custom_components.tplink_deco] aes_iv=5054754915571358
~/docker/containers/homeassistant/home-assistant.log:627: 2022-02-27 15:01:38 DEBUG (MainThread) [custom_components.tplink_deco] password_rsa_n=147400152213047990727033136147004346733103031985288458332450458806859242043605003404150174090446171651650480460233560027136327325663456109096372971869531130727197464059178168406922984183008755410378326074461124456947748570215827915280709053787014995116751665099191965014918961216467473409603919228363587361789
~/docker/containers/homeassistant/home-assistant.log:628: 2022-02-27 15:01:38 DEBUG (MainThread) [custom_components.tplink_deco] password_rsa_e=65537
~/docker/containers/homeassistant/home-assistant.log:1323: 2022-02-27 15:01:38 DEBUG (MainThread) [custom_components.tplink_deco] sign_rsa_n=9222668582450864527349884863635659688756164649926143641377500824189909977565676090883918368863588222791899652270784974568051485123791159681979623781824571
~/docker/containers/homeassistant/home-assistant.log:1324: 2022-02-27 15:01:38 DEBUG (MainThread) [custom_components.tplink_deco] sign_rsa_e=65537
~/docker/containers/homeassistant/home-assistant.log:1325: 2022-02-27 15:01:38 DEBUG (MainThread) [custom_components.tplink_deco] seq=759404514
~/docker/containers/homeassistant/home-assistant.log:2055: 2022-02-27 15:01:42 DEBUG (MainThread) [custom_components.tplink_deco] cookie=sysauth=235ecad930b67123e62707ae0343964b
~/docker/containers/homeassistant/home-assistant.log:2056: 2022-02-27 15:01:42 DEBUG (MainThread) [custom_components.tplink_deco] stok=1ccab8fb6edcb5f732520555f2ffc469
~/docker/containers/homeassistant/home-assistant.log:2081: 2022-02-27 15:01:45 ERROR (MainThread) [custom_components.tplink_deco] List Clients client response error: 500, message='Internal Server Error', url=URL('http://192.168.1.164/cgi-bin/luci/;stok=1ccab8fb6edcb5f732520555f2ffc469/admin/client?form=client_list')
~/docker/containers/homeassistant/home-assistant.log:2082: 2022-02-27 15:01:45 DEBUG (MainThread) [custom_components.tplink_deco] Finished fetching tplink_deco data in 7.388 seconds (success: False)
~/docker/containers/homeassistant/home-assistant.log:2346: 2022-02-27 15:01:45 DEBUG (MainThread) [custom_components.tplink_deco] aes_key=1932231821718039
~/docker/containers/homeassistant/home-assistant.log:2347: 2022-02-27 15:01:45 DEBUG (MainThread) [custom_components.tplink_deco] aes_iv=6174267334428049
~/docker/containers/homeassistant/home-assistant.log:2427: 2022-02-27 15:01:45 DEBUG (MainThread) [custom_components.tplink_deco] password_rsa_n=147400152213047990727033136147004346733103031985288458332450458806859242043605003404150174090446171651650480460233560027136327325663456109096372971869531130727197464059178168406922984183008755410378326074461124456947748570215827915280709053787014995116751665099191965014918961216467473409603919228363587361789
~/docker/containers/homeassistant/home-assistant.log:2428: 2022-02-27 15:01:45 DEBUG (MainThread) [custom_components.tplink_deco] password_rsa_e=65537
~/docker/containers/homeassistant/home-assistant.log:2439: 2022-02-27 15:01:45 DEBUG (MainThread) [custom_components.tplink_deco] sign_rsa_n=9222668582450864527349884863635659688756164649926143641377500824189909977565676090883918368863588222791899652270784974568051485123791159681979623781824571
~/docker/containers/homeassistant/home-assistant.log:2440: 2022-02-27 15:01:45 DEBUG (MainThread) [custom_components.tplink_deco] sign_rsa_e=65537
~/docker/containers/homeassistant/home-assistant.log:2441: 2022-02-27 15:01:45 DEBUG (MainThread) [custom_components.tplink_deco] seq=260549946
~/docker/containers/homeassistant/home-assistant.log:2535: 2022-02-27 15:01:48 DEBUG (MainThread) [custom_components.tplink_deco] cookie=sysauth=e6a8b458d9551a11aff12d7203219dfc
~/docker/containers/homeassistant/home-assistant.log:2536: 2022-02-27 15:01:48 DEBUG (MainThread) [custom_components.tplink_deco] stok=f2ed626f1cb0c245e9646fff74e74815
~/docker/containers/homeassistant/home-assistant.log:2552: 2022-02-27 15:01:51 ERROR (MainThread) [custom_components.tplink_deco] List Clients client response error: 500, message='Internal Server Error', url=URL('http://192.168.1.164/cgi-bin/luci/;stok=f2ed626f1cb0c245e9646fff74e74815/admin/client?form=client_list')
~/docker/containers/homeassistant/home-assistant.log:2553: 2022-02-27 15:01:51 DEBUG (MainThread) [custom_components.tplink_deco] Finished fetching tplink_deco data in 5.696 seconds (success: False)
~/docker/containers/homeassistant/home-assistant.log:2657: 2022-02-27 15:02:01 DEBUG (MainThread) [custom_components.tplink_deco] aes_key=5611462108845989
~/docker/containers/homeassistant/home-assistant.log:2658: 2022-02-27 15:02:01 DEBUG (MainThread) [custom_components.tplink_deco] aes_iv=8608510133879081
~/docker/containers/homeassistant/home-assistant.log:2659: 2022-02-27 15:02:01 DEBUG (MainThread) [custom_components.tplink_deco] password_rsa_n=147400152213047990727033136147004346733103031985288458332450458806859242043605003404150174090446171651650480460233560027136327325663456109096372971869531130727197464059178168406922984183008755410378326074461124456947748570215827915280709053787014995116751665099191965014918961216467473409603919228363587361789
~/docker/containers/homeassistant/home-assistant.log:2660: 2022-02-27 15:02:01 DEBUG (MainThread) [custom_components.tplink_deco] password_rsa_e=65537
~/docker/containers/homeassistant/home-assistant.log:2661: 2022-02-27 15:02:01 DEBUG (MainThread) [custom_components.tplink_deco] sign_rsa_n=9222668582450864527349884863635659688756164649926143641377500824189909977565676090883918368863588222791899652270784974568051485123791159681979623781824571
~/docker/containers/homeassistant/home-assistant.log:2662: 2022-02-27 15:02:01 DEBUG (MainThread) [custom_components.tplink_deco] sign_rsa_e=65537
~/docker/containers/homeassistant/home-assistant.log:2663: 2022-02-27 15:02:01 DEBUG (MainThread) [custom_components.tplink_deco] seq=941153295
~/docker/containers/homeassistant/home-assistant.log:2664: 2022-02-27 15:02:03 DEBUG (MainThread) [custom_components.tplink_deco] cookie=sysauth=b6d56261ac1b9e562a7f25c04d55f9cd
~/docker/containers/homeassistant/home-assistant.log:2665: 2022-02-27 15:02:03 DEBUG (MainThread) [custom_components.tplink_deco] stok=dfd942d942d5b6423fcad207ea22dda3
~/docker/containers/homeassistant/home-assistant.log:2668: 2022-02-27 15:02:06 ERROR (MainThread) [custom_components.tplink_deco] List Clients client response error: 500, message='Internal Server Error', url=URL('http://192.168.1.164/cgi-bin/luci/;stok=dfd942d942d5b6423fcad207ea22dda3/admin/client?form=client_list')
~/docker/containers/homeassistant/home-assistant.log:2669: 2022-02-27 15:02:06 DEBUG (MainThread) [custom_components.tplink_deco] Finished fetching tplink_deco data in 4.979 seconds (success: False)
~/docker/containers/homeassistant/home-assistant.log:2740: 2022-02-27 15:02:26 DEBUG (MainThread) [custom_components.tplink_deco] aes_key=6012133605915452
~/docker/containers/homeassistant/home-assistant.log:2741: 2022-02-27 15:02:26 DEBUG (MainThread) [custom_components.tplink_deco] aes_iv=9891343056059976
~/docker/containers/homeassistant/home-assistant.log:2742: 2022-02-27 15:02:26 DEBUG (MainThread) [custom_components.tplink_deco] password_rsa_n=147400152213047990727033136147004346733103031985288458332450458806859242043605003404150174090446171651650480460233560027136327325663456109096372971869531130727197464059178168406922984183008755410378326074461124456947748570215827915280709053787014995116751665099191965014918961216467473409603919228363587361789
~/docker/containers/homeassistant/home-assistant.log:2743: 2022-02-27 15:02:26 DEBUG (MainThread) [custom_components.tplink_deco] password_rsa_e=65537
~/docker/containers/homeassistant/home-assistant.log:2744: 2022-02-27 15:02:26 DEBUG (MainThread) [custom_components.tplink_deco] sign_rsa_n=9222668582450864527349884863635659688756164649926143641377500824189909977565676090883918368863588222791899652270784974568051485123791159681979623781824571
~/docker/containers/homeassistant/home-assistant.log:2745: 2022-02-27 15:02:26 DEBUG (MainThread) [custom_components.tplink_deco] sign_rsa_e=65537
~/docker/containers/homeassistant/home-assistant.log:2746: 2022-02-27 15:02:26 DEBUG (MainThread) [custom_components.tplink_deco] seq=385262583
~/docker/containers/homeassistant/home-assistant.log:2747: 2022-02-27 15:02:28 DEBUG (MainThread) [custom_components.tplink_deco] cookie=sysauth=1a69bbff965ca688c850d3bbd5ac0841
~/docker/containers/homeassistant/home-assistant.log:2748: 2022-02-27 15:02:28 DEBUG (MainThread) [custom_components.tplink_deco] stok=3894fd6c1de4f55af8bd4343782fc4a7
~/docker/containers/homeassistant/home-assistant.log:2749: 2022-02-27 15:02:31 ERROR (MainThread) [custom_components.tplink_deco] List Clients client response error: 500, message='Internal Server Error', url=URL('http://192.168.1.164/cgi-bin/luci/;stok=3894fd6c1de4f55af8bd4343782fc4a7/admin/client?form=client_list')
~/docker/containers/homeassistant/home-assistant.log:2750: 2022-02-27 15:02:31 DEBUG (MainThread) [custom_components.tplink_deco] Finished fetching tplink_deco data in 5.482 seconds (success: False)
~/docker/containers/homeassistant/home-assistant.log:2905: 2022-02-27 15:03:11 DEBUG (MainThread) [custom_components.tplink_deco] aes_key=8526992696814501
~/docker/containers/homeassistant/home-assistant.log:2906: 2022-02-27 15:03:11 DEBUG (MainThread) [custom_components.tplink_deco] aes_iv=6284115538123805
~/docker/containers/homeassistant/home-assistant.log:2907: 2022-02-27 15:03:11 DEBUG (MainThread) [custom_components.tplink_deco] password_rsa_n=147400152213047990727033136147004346733103031985288458332450458806859242043605003404150174090446171651650480460233560027136327325663456109096372971869531130727197464059178168406922984183008755410378326074461124456947748570215827915280709053787014995116751665099191965014918961216467473409603919228363587361789
~/docker/containers/homeassistant/home-assistant.log:2908: 2022-02-27 15:03:11 DEBUG (MainThread) [custom_components.tplink_deco] password_rsa_e=65537
~/docker/containers/homeassistant/home-assistant.log:2909: 2022-02-27 15:03:11 DEBUG (MainThread) [custom_components.tplink_deco] sign_rsa_n=9222668582450864527349884863635659688756164649926143641377500824189909977565676090883918368863588222791899652270784974568051485123791159681979623781824571
~/docker/containers/homeassistant/home-assistant.log:2910: 2022-02-27 15:03:11 DEBUG (MainThread) [custom_components.tplink_deco] sign_rsa_e=65537
~/docker/containers/homeassistant/home-assistant.log:2911: 2022-02-27 15:03:11 DEBUG (MainThread) [custom_components.tplink_deco] seq=298854699
~/docker/containers/homeassistant/home-assistant.log:2912: 2022-02-27 15:03:13 DEBUG (MainThread) [custom_components.tplink_deco] cookie=sysauth=0976471bfe71cc5d113a8904c76f1ea5
~/docker/containers/homeassistant/home-assistant.log:2913: 2022-02-27 15:03:14 DEBUG (MainThread) [custom_components.tplink_deco] stok=617820cc6ad42bc6f5720c043dd08ff6
~/docker/containers/homeassistant/home-assistant.log:2916: 2022-02-27 15:03:16 ERROR (MainThread) [custom_components.tplink_deco] List Clients client response error: 500, message='Internal Server Error', url=URL('http://192.168.1.164/cgi-bin/luci/;stok=617820cc6ad42bc6f5720c043dd08ff6/admin/client?form=client_list')
~/docker/containers/homeassistant/home-assistant.log:2917: 2022-02-27 15:03:16 DEBUG (MainThread) [custom_components.tplink_deco] Finished fetching tplink_deco data in 4.996 seconds (success: False)
~/docker/containers/homeassistant/home-assistant.log:3122: 2022-02-27 15:04:36 DEBUG (MainThread) [custom_components.tplink_deco] aes_key=9585459300716975
~/docker/containers/homeassistant/home-assistant.log:3123: 2022-02-27 15:04:36 DEBUG (MainThread) [custom_components.tplink_deco] aes_iv=2502026658863869
~/docker/containers/homeassistant/home-assistant.log:3124: 2022-02-27 15:04:36 DEBUG (MainThread) [custom_components.tplink_deco] password_rsa_n=147400152213047990727033136147004346733103031985288458332450458806859242043605003404150174090446171651650480460233560027136327325663456109096372971869531130727197464059178168406922984183008755410378326074461124456947748570215827915280709053787014995116751665099191965014918961216467473409603919228363587361789
~/docker/containers/homeassistant/home-assistant.log:3125: 2022-02-27 15:04:36 DEBUG (MainThread) [custom_components.tplink_deco] password_rsa_e=65537
~/docker/containers/homeassistant/home-assistant.log:3126: 2022-02-27 15:04:37 DEBUG (MainThread) [custom_components.tplink_deco] sign_rsa_n=9222668582450864527349884863635659688756164649926143641377500824189909977565676090883918368863588222791899652270784974568051485123791159681979623781824571
~/docker/containers/homeassistant/home-assistant.log:3127: 2022-02-27 15:04:37 DEBUG (MainThread) [custom_components.tplink_deco] sign_rsa_e=65537
~/docker/containers/homeassistant/home-assistant.log:3128: 2022-02-27 15:04:37 DEBUG (MainThread) [custom_components.tplink_deco] seq=818146096
~/docker/containers/homeassistant/home-assistant.log:3169: 2022-02-27 15:04:39 DEBUG (MainThread) [custom_components.tplink_deco] cookie=sysauth=b403834df87bce36fb21f86ffb84d802
~/docker/containers/homeassistant/home-assistant.log:3170: 2022-02-27 15:04:39 DEBUG (MainThread) [custom_components.tplink_deco] stok=727f4855c4e46129210a7e54ef741589
~/docker/containers/homeassistant/home-assistant.log:3189: 2022-02-27 15:04:42 ERROR (MainThread) [custom_components.tplink_deco] List Clients client response error: 500, message='Internal Server Error', url=URL('http://192.168.1.164/cgi-bin/luci/;stok=727f4855c4e46129210a7e54ef741589/admin/client?form=client_list')
~/docker/containers/homeassistant/home-assistant.log:3190: 2022-02-27 15:04:42 DEBUG (MainThread) [custom_components.tplink_deco] Finished fetching tplink_deco data in 5.920 seconds (success: False)
~/docker/containers/homeassistant/home-assistant.log:3727: 2022-02-27 15:06:02 DEBUG (MainThread) [custom_components.tplink_deco] aes_key=2855726575865462
~/docker/containers/homeassistant/home-assistant.log:3728: 2022-02-27 15:06:02 DEBUG (MainThread) [custom_components.tplink_deco] aes_iv=1570920847810654
~/docker/containers/homeassistant/home-assistant.log:3729: 2022-02-27 15:06:02 DEBUG (MainThread) [custom_components.tplink_deco] password_rsa_n=147400152213047990727033136147004346733103031985288458332450458806859242043605003404150174090446171651650480460233560027136327325663456109096372971869531130727197464059178168406922984183008755410378326074461124456947748570215827915280709053787014995116751665099191965014918961216467473409603919228363587361789
~/docker/containers/homeassistant/home-assistant.log:3730: 2022-02-27 15:06:02 DEBUG (MainThread) [custom_components.tplink_deco] password_rsa_e=65537
~/docker/containers/homeassistant/home-assistant.log:3731: 2022-02-27 15:06:02 DEBUG (MainThread) [custom_components.tplink_deco] sign_rsa_n=9222668582450864527349884863635659688756164649926143641377500824189909977565676090883918368863588222791899652270784974568051485123791159681979623781824571
~/docker/containers/homeassistant/home-assistant.log:3732: 2022-02-27 15:06:02 DEBUG (MainThread) [custom_components.tplink_deco] sign_rsa_e=65537
~/docker/containers/homeassistant/home-assistant.log:3733: 2022-02-27 15:06:02 DEBUG (MainThread) [custom_components.tplink_deco] seq=373044756
~/docker/containers/homeassistant/home-assistant.log:3734: 2022-02-27 15:06:04 DEBUG (MainThread) [custom_components.tplink_deco] cookie=sysauth=aae75eadc6530dd0106fd9a2137888d0
~/docker/containers/homeassistant/home-assistant.log:3735: 2022-02-27 15:06:04 DEBUG (MainThread) [custom_components.tplink_deco] stok=4d76d9cf5320b8e9c9fb901c1cc6eddd
~/docker/containers/homeassistant/home-assistant.log:3743: 2022-02-27 15:06:07 ERROR (MainThread) [custom_components.tplink_deco] List Clients client response error: 500, message='Internal Server Error', url=URL('http://192.168.1.164/cgi-bin/luci/;stok=4d76d9cf5320b8e9c9fb901c1cc6eddd/admin/client?form=client_list')
~/docker/containers/homeassistant/home-assistant.log:3744: 2022-02-27 15:06:07 DEBUG (MainThread) [custom_components.tplink_deco] Finished fetching tplink_deco data in 4.850 seconds (success: False)

searching for [custom_components.tplink_deco]
~/docker/containers/homeassistant/home-assistant.log:253: 2022-02-27 15:01:37 INFO (MainThread) [custom_components.tplink_deco]
~/docker/containers/homeassistant/home-assistant.log:262: 2022-02-27 15:01:37 DEBUG (MainThread) [custom_components.tplink_deco] aes_key=5878763926190932
~/docker/containers/homeassistant/home-assistant.log:263: 2022-02-27 15:01:37 DEBUG (MainThread) [custom_components.tplink_deco] aes_iv=5054754915571358
~/docker/containers/homeassistant/home-assistant.log:627: 2022-02-27 15:01:38 DEBUG (MainThread) [custom_components.tplink_deco] password_rsa_n=147400152213047990727033136147004346733103031985288458332450458806859242043605003404150174090446171651650480460233560027136327325663456109096372971869531130727197464059178168406922984183008755410378326074461124456947748570215827915280709053787014995116751665099191965014918961216467473409603919228363587361789
~/docker/containers/homeassistant/home-assistant.log:628: 2022-02-27 15:01:38 DEBUG (MainThread) [custom_components.tplink_deco] password_rsa_e=65537
~/docker/containers/homeassistant/home-assistant.log:1323: 2022-02-27 15:01:38 DEBUG (MainThread) [custom_components.tplink_deco] sign_rsa_n=9222668582450864527349884863635659688756164649926143641377500824189909977565676090883918368863588222791899652270784974568051485123791159681979623781824571
~/docker/containers/homeassistant/home-assistant.log:1324: 2022-02-27 15:01:38 DEBUG (MainThread) [custom_components.tplink_deco] sign_rsa_e=65537
~/docker/containers/homeassistant/home-assistant.log:1325: 2022-02-27 15:01:38 DEBUG (MainThread) [custom_components.tplink_deco] seq=759404514
~/docker/containers/homeassistant/home-assistant.log:2055: 2022-02-27 15:01:42 DEBUG (MainThread) [custom_components.tplink_deco] cookie=sysauth=235ecad930b67123e62707ae0343964b
~/docker/containers/homeassistant/home-assistant.log:2056: 2022-02-27 15:01:42 DEBUG (MainThread) [custom_components.tplink_deco] stok=1ccab8fb6edcb5f732520555f2ffc469
~/docker/containers/homeassistant/home-assistant.log:2081: 2022-02-27 15:01:45 ERROR (MainThread) [custom_components.tplink_deco] List Clients client response error: 500, message='Internal Server Error', url=URL('http://192.168.1.164/cgi-bin/luci/;stok=1ccab8fb6edcb5f732520555f2ffc469/admin/client?form=client_list')
~/docker/containers/homeassistant/home-assistant.log:2082: 2022-02-27 15:01:45 DEBUG (MainThread) [custom_components.tplink_deco] Finished fetching tplink_deco data in 7.388 seconds (success: False)
~/docker/containers/homeassistant/home-assistant.log:2346: 2022-02-27 15:01:45 DEBUG (MainThread) [custom_components.tplink_deco] aes_key=1932231821718039
~/docker/containers/homeassistant/home-assistant.log:2347: 2022-02-27 15:01:45 DEBUG (MainThread) [custom_components.tplink_deco] aes_iv=6174267334428049
~/docker/containers/homeassistant/home-assistant.log:2427: 2022-02-27 15:01:45 DEBUG (MainThread) [custom_components.tplink_deco] password_rsa_n=147400152213047990727033136147004346733103031985288458332450458806859242043605003404150174090446171651650480460233560027136327325663456109096372971869531130727197464059178168406922984183008755410378326074461124456947748570215827915280709053787014995116751665099191965014918961216467473409603919228363587361789
~/docker/containers/homeassistant/home-assistant.log:2428: 2022-02-27 15:01:45 DEBUG (MainThread) [custom_components.tplink_deco] password_rsa_e=65537
~/docker/containers/homeassistant/home-assistant.log:2439: 2022-02-27 15:01:45 DEBUG (MainThread) [custom_components.tplink_deco] sign_rsa_n=9222668582450864527349884863635659688756164649926143641377500824189909977565676090883918368863588222791899652270784974568051485123791159681979623781824571
~/docker/containers/homeassistant/home-assistant.log:2440: 2022-02-27 15:01:45 DEBUG (MainThread) [custom_components.tplink_deco] sign_rsa_e=65537
~/docker/containers/homeassistant/home-assistant.log:2441: 2022-02-27 15:01:45 DEBUG (MainThread) [custom_components.tplink_deco] seq=260549946
~/docker/containers/homeassistant/home-assistant.log:2535: 2022-02-27 15:01:48 DEBUG (MainThread) [custom_components.tplink_deco] cookie=sysauth=e6a8b458d9551a11aff12d7203219dfc
~/docker/containers/homeassistant/home-assistant.log:2536: 2022-02-27 15:01:48 DEBUG (MainThread) [custom_components.tplink_deco] stok=f2ed626f1cb0c245e9646fff74e74815
~/docker/containers/homeassistant/home-assistant.log:2552: 2022-02-27 15:01:51 ERROR (MainThread) [custom_components.tplink_deco] List Clients client response error: 500, message='Internal Server Error', url=URL('http://192.168.1.164/cgi-bin/luci/;stok=f2ed626f1cb0c245e9646fff74e74815/admin/client?form=client_list')
~/docker/containers/homeassistant/home-assistant.log:2553: 2022-02-27 15:01:51 DEBUG (MainThread) [custom_components.tplink_deco] Finished fetching tplink_deco data in 5.696 seconds (success: False)
~/docker/containers/homeassistant/home-assistant.log:2657: 2022-02-27 15:02:01 DEBUG (MainThread) [custom_components.tplink_deco] aes_key=5611462108845989
~/docker/containers/homeassistant/home-assistant.log:2658: 2022-02-27 15:02:01 DEBUG (MainThread) [custom_components.tplink_deco] aes_iv=8608510133879081
~/docker/containers/homeassistant/home-assistant.log:2659: 2022-02-27 15:02:01 DEBUG (MainThread) [custom_components.tplink_deco] password_rsa_n=147400152213047990727033136147004346733103031985288458332450458806859242043605003404150174090446171651650480460233560027136327325663456109096372971869531130727197464059178168406922984183008755410378326074461124456947748570215827915280709053787014995116751665099191965014918961216467473409603919228363587361789
~/docker/containers/homeassistant/home-assistant.log:2660: 2022-02-27 15:02:01 DEBUG (MainThread) [custom_components.tplink_deco] password_rsa_e=65537
~/docker/containers/homeassistant/home-assistant.log:2661: 2022-02-27 15:02:01 DEBUG (MainThread) [custom_components.tplink_deco] sign_rsa_n=9222668582450864527349884863635659688756164649926143641377500824189909977565676090883918368863588222791899652270784974568051485123791159681979623781824571
~/docker/containers/homeassistant/home-assistant.log:2662: 2022-02-27 15:02:01 DEBUG (MainThread) [custom_components.tplink_deco] sign_rsa_e=65537
~/docker/containers/homeassistant/home-assistant.log:2663: 2022-02-27 15:02:01 DEBUG (MainThread) [custom_components.tplink_deco] seq=941153295
~/docker/containers/homeassistant/home-assistant.log:2664: 2022-02-27 15:02:03 DEBUG (MainThread) [custom_components.tplink_deco] cookie=sysauth=b6d56261ac1b9e562a7f25c04d55f9cd
~/docker/containers/homeassistant/home-assistant.log:2665: 2022-02-27 15:02:03 DEBUG (MainThread) [custom_components.tplink_deco] stok=dfd942d942d5b6423fcad207ea22dda3
~/docker/containers/homeassistant/home-assistant.log:2668: 2022-02-27 15:02:06 ERROR (MainThread) [custom_components.tplink_deco] List Clients client response error: 500, message='Internal Server Error', url=URL('http://192.168.1.164/cgi-bin/luci/;stok=dfd942d942d5b6423fcad207ea22dda3/admin/client?form=client_list')
~/docker/containers/homeassistant/home-assistant.log:2669: 2022-02-27 15:02:06 DEBUG (MainThread) [custom_components.tplink_deco] Finished fetching tplink_deco data in 4.979 seconds (success: False)
~/docker/containers/homeassistant/home-assistant.log:2740: 2022-02-27 15:02:26 DEBUG (MainThread) [custom_components.tplink_deco] aes_key=6012133605915452
~/docker/containers/homeassistant/home-assistant.log:2741: 2022-02-27 15:02:26 DEBUG (MainThread) [custom_components.tplink_deco] aes_iv=9891343056059976
~/docker/containers/homeassistant/home-assistant.log:2742: 2022-02-27 15:02:26 DEBUG (MainThread) [custom_components.tplink_deco] password_rsa_n=147400152213047990727033136147004346733103031985288458332450458806859242043605003404150174090446171651650480460233560027136327325663456109096372971869531130727197464059178168406922984183008755410378326074461124456947748570215827915280709053787014995116751665099191965014918961216467473409603919228363587361789
~/docker/containers/homeassistant/home-assistant.log:2743: 2022-02-27 15:02:26 DEBUG (MainThread) [custom_components.tplink_deco] password_rsa_e=65537
~/docker/containers/homeassistant/home-assistant.log:2744: 2022-02-27 15:02:26 DEBUG (MainThread) [custom_components.tplink_deco] sign_rsa_n=9222668582450864527349884863635659688756164649926143641377500824189909977565676090883918368863588222791899652270784974568051485123791159681979623781824571
~/docker/containers/homeassistant/home-assistant.log:2745: 2022-02-27 15:02:26 DEBUG (MainThread) [custom_components.tplink_deco] sign_rsa_e=65537
~/docker/containers/homeassistant/home-assistant.log:2746: 2022-02-27 15:02:26 DEBUG (MainThread) [custom_components.tplink_deco] seq=385262583
~/docker/containers/homeassistant/home-assistant.log:2747: 2022-02-27 15:02:28 DEBUG (MainThread) [custom_components.tplink_deco] cookie=sysauth=1a69bbff965ca688c850d3bbd5ac0841
~/docker/containers/homeassistant/home-assistant.log:2748: 2022-02-27 15:02:28 DEBUG (MainThread) [custom_components.tplink_deco] stok=3894fd6c1de4f55af8bd4343782fc4a7
~/docker/containers/homeassistant/home-assistant.log:2749: 2022-02-27 15:02:31 ERROR (MainThread) [custom_components.tplink_deco] List Clients client response error: 500, message='Internal Server Error', url=URL('http://192.168.1.164/cgi-bin/luci/;stok=3894fd6c1de4f55af8bd4343782fc4a7/admin/client?form=client_list')
~/docker/containers/homeassistant/home-assistant.log:2750: 2022-02-27 15:02:31 DEBUG (MainThread) [custom_components.tplink_deco] Finished fetching tplink_deco data in 5.482 seconds (success: False)
~/docker/containers/homeassistant/home-assistant.log:2905: 2022-02-27 15:03:11 DEBUG (MainThread) [custom_components.tplink_deco] aes_key=8526992696814501
~/docker/containers/homeassistant/home-assistant.log:2906: 2022-02-27 15:03:11 DEBUG (MainThread) [custom_components.tplink_deco] aes_iv=6284115538123805
~/docker/containers/homeassistant/home-assistant.log:2907: 2022-02-27 15:03:11 DEBUG (MainThread) [custom_components.tplink_deco] password_rsa_n=147400152213047990727033136147004346733103031985288458332450458806859242043605003404150174090446171651650480460233560027136327325663456109096372971869531130727197464059178168406922984183008755410378326074461124456947748570215827915280709053787014995116751665099191965014918961216467473409603919228363587361789
~/docker/containers/homeassistant/home-assistant.log:2908: 2022-02-27 15:03:11 DEBUG (MainThread) [custom_components.tplink_deco] password_rsa_e=65537
~/docker/containers/homeassistant/home-assistant.log:2909: 2022-02-27 15:03:11 DEBUG (MainThread) [custom_components.tplink_deco] sign_rsa_n=9222668582450864527349884863635659688756164649926143641377500824189909977565676090883918368863588222791899652270784974568051485123791159681979623781824571
~/docker/containers/homeassistant/home-assistant.log:2910: 2022-02-27 15:03:11 DEBUG (MainThread) [custom_components.tplink_deco] sign_rsa_e=65537
~/docker/containers/homeassistant/home-assistant.log:2911: 2022-02-27 15:03:11 DEBUG (MainThread) [custom_components.tplink_deco] seq=298854699
~/docker/containers/homeassistant/home-assistant.log:2912: 2022-02-27 15:03:13 DEBUG (MainThread) [custom_components.tplink_deco] cookie=sysauth=0976471bfe71cc5d113a8904c76f1ea5
~/docker/containers/homeassistant/home-assistant.log:2913: 2022-02-27 15:03:14 DEBUG (MainThread) [custom_components.tplink_deco] stok=617820cc6ad42bc6f5720c043dd08ff6
~/docker/containers/homeassistant/home-assistant.log:2916: 2022-02-27 15:03:16 ERROR (MainThread) [custom_components.tplink_deco] List Clients client response error: 500, message='Internal Server Error', url=URL('http://192.168.1.164/cgi-bin/luci/;stok=617820cc6ad42bc6f5720c043dd08ff6/admin/client?form=client_list')
~/docker/containers/homeassistant/home-assistant.log:2917: 2022-02-27 15:03:16 DEBUG (MainThread) [custom_components.tplink_deco] Finished fetching tplink_deco data in 4.996 seconds (success: False)
~/docker/containers/homeassistant/home-assistant.log:3122: 2022-02-27 15:04:36 DEBUG (MainThread) [custom_components.tplink_deco] aes_key=9585459300716975
~/docker/containers/homeassistant/home-assistant.log:3123: 2022-02-27 15:04:36 DEBUG (MainThread) [custom_components.tplink_deco] aes_iv=2502026658863869
~/docker/containers/homeassistant/home-assistant.log:3124: 2022-02-27 15:04:36 DEBUG (MainThread) [custom_components.tplink_deco] password_rsa_n=147400152213047990727033136147004346733103031985288458332450458806859242043605003404150174090446171651650480460233560027136327325663456109096372971869531130727197464059178168406922984183008755410378326074461124456947748570215827915280709053787014995116751665099191965014918961216467473409603919228363587361789
~/docker/containers/homeassistant/home-assistant.log:3125: 2022-02-27 15:04:36 DEBUG (MainThread) [custom_components.tplink_deco] password_rsa_e=65537
~/docker/containers/homeassistant/home-assistant.log:3126: 2022-02-27 15:04:37 DEBUG (MainThread) [custom_components.tplink_deco] sign_rsa_n=9222668582450864527349884863635659688756164649926143641377500824189909977565676090883918368863588222791899652270784974568051485123791159681979623781824571
~/docker/containers/homeassistant/home-assistant.log:3127: 2022-02-27 15:04:37 DEBUG (MainThread) [custom_components.tplink_deco] sign_rsa_e=65537
~/docker/containers/homeassistant/home-assistant.log:3128: 2022-02-27 15:04:37 DEBUG (MainThread) [custom_components.tplink_deco] seq=818146096
~/docker/containers/homeassistant/home-assistant.log:3169: 2022-02-27 15:04:39 DEBUG (MainThread) [custom_components.tplink_deco] cookie=sysauth=b403834df87bce36fb21f86ffb84d802
~/docker/containers/homeassistant/home-assistant.log:3170: 2022-02-27 15:04:39 DEBUG (MainThread) [custom_components.tplink_deco] stok=727f4855c4e46129210a7e54ef741589
~/docker/containers/homeassistant/home-assistant.log:3189: 2022-02-27 15:04:42 ERROR (MainThread) [custom_components.tplink_deco] List Clients client response error: 500, message='Internal Server Error', url=URL('http://192.168.1.164/cgi-bin/luci/;stok=727f4855c4e46129210a7e54ef741589/admin/client?form=client_list')
~/docker/containers/homeassistant/home-assistant.log:3190: 2022-02-27 15:04:42 DEBUG (MainThread) [custom_components.tplink_deco] Finished fetching tplink_deco data in 5.920 seconds (success: False)
~/docker/containers/homeassistant/home-assistant.log:3727: 2022-02-27 15:06:02 DEBUG (MainThread) [custom_components.tplink_deco] aes_key=2855726575865462
~/docker/containers/homeassistant/home-assistant.log:3728: 2022-02-27 15:06:02 DEBUG (MainThread) [custom_components.tplink_deco] aes_iv=1570920847810654
~/docker/containers/homeassistant/home-assistant.log:3729: 2022-02-27 15:06:02 DEBUG (MainThread) [custom_components.tplink_deco] password_rsa_n=147400152213047990727033136147004346733103031985288458332450458806859242043605003404150174090446171651650480460233560027136327325663456109096372971869531130727197464059178168406922984183008755410378326074461124456947748570215827915280709053787014995116751665099191965014918961216467473409603919228363587361789
~/docker/containers/homeassistant/home-assistant.log:3730: 2022-02-27 15:06:02 DEBUG (MainThread) [custom_components.tplink_deco] password_rsa_e=65537
~/docker/containers/homeassistant/home-assistant.log:3731: 2022-02-27 15:06:02 DEBUG (MainThread) [custom_components.tplink_deco] sign_rsa_n=9222668582450864527349884863635659688756164649926143641377500824189909977565676090883918368863588222791899652270784974568051485123791159681979623781824571
~/docker/containers/homeassistant/home-assistant.log:3732: 2022-02-27 15:06:02 DEBUG (MainThread) [custom_components.tplink_deco] sign_rsa_e=65537
~/docker/containers/homeassistant/home-assistant.log:3733: 2022-02-27 15:06:02 DEBUG (MainThread) [custom_components.tplink_deco] seq=373044756
~/docker/containers/homeassistant/home-assistant.log:3734: 2022-02-27 15:06:04 DEBUG (MainThread) [custom_components.tplink_deco] cookie=sysauth=aae75eadc6530dd0106fd9a2137888d0
~/docker/containers/homeassistant/home-assistant.log:3735: 2022-02-27 15:06:04 DEBUG (MainThread) [custom_components.tplink_deco] stok=4d76d9cf5320b8e9c9fb901c1cc6eddd
~/docker/containers/homeassistant/home-assistant.log:3743: 2022-02-27 15:06:07 ERROR (MainThread) [custom_components.tplink_deco] List Clients client response error: 500, message='Internal Server Error', url=URL('http://192.168.1.164/cgi-bin/luci/;stok=4d76d9cf5320b8e9c9fb901c1cc6eddd/admin/client?form=client_list')
~/docker/containers/homeassistant/home-assistant.log:3744: 2022-02-27 15:06:07 DEBUG (MainThread) [custom_components.tplink_deco] Finished fetching tplink_deco data in 4.850 seconds (success: False)

Add your logs here.

Logger: custom_components.tplink_deco

Source: custom_components/tplink_deco/api.py:290
Integration: TP-Link Deco (documentation, issues)
First occurred: 14:41:34 (2 occurrences)

Last logged: 14:41:45
• List Clients client response error: 500, message='Internal Server Error', url=URL('http://192.168.1.164/cgi-bin/luci/;stok=b25f1cb1bfdb92b476c77c0bcf2aea47/admin/client?form=client_list')
• List Clients client response error: 500, message='Internal Server Error', url=URL('http://192.168.1.164/cgi-bin/luci/;stok=836129c808a47a6b849ef7617d528c36/admin/client?form=client_list')

'utf-8' codec can't decode byte 0xb8 in position 0: invalid start byte

Describe the bug

Error setting up config from @Scoopien

Debug log

ste erro teve origem numa integração personalizada.

Logger: custom_components.tplink_deco
Source: custom_components/tplink_deco/api.py:198
Integration: TP-Link Deco (documentation, issues)
First occurred: 23:56:36 (3 occurrences)
Last logged: 23:57:44

Unexpected error fetching tplink_deco-clients data: 'utf-8' codec can't decode byte 0xb8 in position 0: invalid start byte
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 187, in _async_refresh
self.data = await self._async_update_data()
File "/config/custom_components/tplink_deco/coordinator.py", line 236, in _async_update_data
deco_client_responses = await asyncio.gather(
File "/config/custom_components/tplink_deco/coordinator.py", line 39, in async_call_with_retry
return await func(*args)
File "/config/custom_components/tplink_deco/api.py", line 198, in async_list_clients
client["name"] = base64.b64decode(client["name"]).decode()
UnicodeDecodeError: 'utf-8' codec can't decode byte 0xb8 in position 0: invalid start byte

Este erro teve origem numa integração personalizada.

Logger: custom_components.tplink_deco
Source: custom_components/tplink_deco/config_flow.py:57
Integration: TP-Link Deco (documentation, issues)
First occurred: 23:57:44 (1 occurrences)
Last logged: 23:57:44

Error testing credentials: 'utf-8' codec can't decode byte 0xb8 in position 0: invalid start byte

Timeout fetching data, most devices disabled

Version of the custom_component

ha-tplink-deco v0.0.1
running on a pi 4b with armv7
home assistant version: core-2022.2.0.dev20220118
Installation Type | Home Assistant Container
Python Version | 3.9.7

Timeout/nonetype issue logs

This error originated from a custom integration.

Logger: custom_components.tplink_deco
Source: helpers/update_coordinator.py:193
Integration: TP-Link Deco (documentation, issues)
First occurred: 8:11:05 AM (1 occurrences)
Last logged: 8:11:05 AM

Timeout fetching tplink_deco data

custom component logs

This error originated from a custom integration.

Logger: custom_components.tplink_deco
Source: custom_components/tplink_deco/coordinator.py:119
Integration: TP-Link Deco (documentation, issues)
First occurred: 8:11:25 AM (1 occurrences)
Last logged: 8:11:25 AM

Error calling on_close function <function async_dispatcher_connect.<locals>.async_remove_dispatcher at 0xa99e4ad8>: object NoneType can't be used in 'await' expression

Describe the bug

The integration on 0.0.1 will successfully install through hacs and looks like it successfully configures on the integrations page but then immediately after the success message, the list of devices on my deco will be pulled but almost all devices are disabled. I have 40 entities but only 14 devices because so many devices on my wifi have been found but are disabled, seemingly from this timeout. There are no other errors popping up except these. I'm interested in helping with the fix but I'm not sure where to start

UNKNOWN ip address error after switching to access point as operation mode

Version of the custom_component

1.1.0

Configuration

core-2022.3.0
supervisor-2022.01.1
HACS 1.23.0

Describe the bug

I'm using Deco X68 with this integration and every thing was working fine, until I changed the operation mode from wireless router to access point.

after the changing to access point, I started getting this error:

Exception in _async_process_device_data when dispatching 'device_tracker_connected_device_registered': ({'ip': 'UNKNOWN', 'mac': 'B4-C9-B9-A0-69-FE', 'host_name': '192.168.121.113'},) Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/components/dhcp/init.py", line 373, in _async_process_device_data self.async_process_client(ip_address, hostname, _format_mac(mac_address)) File "/usr/src/homeassistant/homeassistant/components/dhcp/init.py", line 177, in async_process_client made_ip_address = make_ip_address(ip_address) File "/usr/local/lib/python3.9/ipaddress.py", line 53, in ip_address raise ValueError('%r does not appear to be an IPv4 or IPv6 address' % ValueError: 'UNKNOWN' does not appear to be an IPv4 or IPv6 address

192.168.121.113 in the main router IP address.

Debug log


Exception in _async_process_device_data when dispatching 'device_tracker_connected_device_registered': ({'ip': 'UNKNOWN', 'mac': 'B4-C9-B9-A0-69-FE', 'host_name': '192.168.121.113'},) Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/components/dhcp/__init__.py", line 373, in _async_process_device_data self.async_process_client(ip_address, hostname, _format_mac(mac_address)) File "/usr/src/homeassistant/homeassistant/components/dhcp/__init__.py", line 177, in async_process_client made_ip_address = make_ip_address(ip_address) File "/usr/local/lib/python3.9/ipaddress.py", line 53, in ip_address raise ValueError('%r does not appear to be an IPv4 or IPv6 address' % ValueError: 'UNKNOWN' does not appear to be an IPv4 or IPv6 address 

Integration -> Device -> Entities Hierarchy

Is your feature request related to a problem? Please describe.
Nope, feature suggestion

Describe the solution you'd like
At present the integration has only an entity level and no umbrella device. This makes it hard to add the entities to cards as there is no connection in the naming, other than device_tracker. In the case of phones I already have device trackers set up which is confusing.

Describe alternatives you've considered
I can manually rename all of the entities with a prefix of "Deco - " but that needs to be done for each and every new client discovered.

Additional context
To be honest I'm not sure what other people are using this for but I'd just like there to be a Deco device, with all of the entities listed from there. Failing that perhaps just prefix the entities with deco automatically, e.g. "device_tracker_samsung_phone" becomes "device_tracker_tplink_deco_samsung_phone" or similar.

Thanks

Incompatible with Firmware 1.6.0 on M9Plus

Hi,

Just on the off-chance it's not been noticed. The v1.60 firmware that's currently in public beta for the M9's has significant rewrites and the Luci web API calls have either been blocked, moved or removed ("Illegal URL" in the Router's logs). It's a show stopper unfortunately. The M5's and M4's all have similar code so some re-writes are ahead :-(

This link below should show the forums entries for items tagged with "New Firmware" in case you want to have a look.

https://community.tp-link.com/en/home/forum/39?tagId=672&labelIds=8214

If I can work out how, I'll try and unpack an image :-)

Regards,
Keith

Devices from other integrations

It looks like a lot of devices gets multiple integrations somehow.
When checking for TP-link Deco device integration, I get a lot of different devices as well.
I only have 3 TP-link devices, but it looks like I have 15 in the overview
image

When checking the details, I see that a lot of other integrations/devices are mixed in here as well..?
image

Error testing credentials

Excuse me for being a noob. Tried following the instructions by loggin in using the admin credentials of Deco M9 Plus leaving the user name as admin. I am unable to setup the device on HA with the following error from the HA log:

<This error originated from a custom integration.

Logger: custom_components.tplink_deco
Source: custom_components/tplink_deco/config_flow.py:57
Integration: TP-Link Deco (documentation, issues)
First occurred: 10:52:45 AM (6 occurrences)
Last logged: 11:02:54 AM

Error testing credentials:

node red and reboot deco bug

Versions

ha-tplink-deco: 2.1
core: 2022.3.8
supervisor: 2022.03.5
Home Assistant OS: 7.6

Describe the bug

with home assistant automation I can use reboot 1 deco without problem but with node red I get an error "Call-service error. expected a list for dictionary value @ data['entity_id']", but when I set 2 decos in node red I don't get that error and it reboot the decos, not sure what the problem.

Deco S7 - Fetch keys 401 unauthorized

Version of the custom_component

v2.2.3

Deco Model

Deco S7 (1.3.0 Build 20220609 Rel. 64814)

Describe the bug

Just got 2 different Deco networks and I'm trying to add them to 2 different HA instances (one of them is fresh).
I get the same result, I am using the settings below.
The IP of the root node is correct, the password is correct.
At my main HA instance I got some 2-3 second delay the first time I tried to add it and then it was an immediate error afterwards
Checked the logs and they don't provide any meaningful info for me, just straight 401's

I saw the other issue, however my error messages are different and that's why I'm opening a new issue.

image

Debug log

image

[Warning] Error testing credentials: 401, message='Unauthorized', url=URL('http://192.168.1.2/cgi-bin/luci/;stok=/login?form=keys')
[Error] Fetch keys client response error: 401, message='Unauthorized', url=URL('http://192.168.1.2/cgi-bin/luci/;stok=/login?form=keys')

List Clients timed out

Version of the custom_component

Configuration

Add your logs here.

Describe the bug

When I try to add the integration i get an "unknown error occurred" which appears after a minute or so.

A clear and concise description of what the bug is.

Debug log


Add your logs here.

image

Data incorrect when the device is disconnected.

Here, the device is disconnected, the connection_type is wired?
The deco_device is null, which is correct. (could it be not_connected?)

image

and here, the device is also disconnected, but the connection_type is band5.

image

So, probably the connection_type needs to be cleared if the device is not connected?

Unexpected error

Version of the custom_component

v2.2.3

Deco Model

Deco S7 (1.3.0 Build 20220609 Rel. 64814)

Describe the bug

Just got 2 different Deco networks and I'm trying to add them to 2 different HA instances (one of them is fresh).
I get the same result, I am using the settings below.
The IP of the root node is correct, the password is correct.
At my main HA instance I got some 2-3 second delay the first time I tried to add it and then it was an immediate error afterwards
Checked the logs and they don't provide any meaningful info for me, just straight 401's

I saw the other issue, however my error messages are different and that's why I'm opening a new issue.

image

Debug log

image

[Warning] Error testing credentials: 401, message='Unauthorized', url=URL('http://192.168.1.2/cgi-bin/luci/;stok=/login?form=keys')
[Error] Fetch keys client response error: 401, message='Unauthorized', url=URL('http://192.168.1.2/cgi-bin/luci/;stok=/login?form=keys')

Update and search for connected devices

Hi, I'm running your custom component with 3 Deco P9 connect and detect the device_trackers.
But when a device disconnects and then reconnects, the state of the device does not change until I open the HA app.
It's normal?

Version

HA 2022.3.3
ha-tplink-deco 2.0.2

Configuration, I also waited for the time indicated in the configuration.

Schermata 2022-03-11 alle 13 18 27

Ping work

Schermata 2022-03-11 alle 13 18 51

But state is not_home

Schermata 2022-03-11 alle 13 19 30

Error while processing event

Repeated errors because, apparently, there IP addresses are left empty.

Version of the custom_component

2.1.1

Deco Model

M5

Describe the bug

Error while processing event

Debug log

Logger: homeassistant.helpers.event
Source: components/dhcp/init.py:155
First occurred: 09:33:45 (1 occurrences)
Last logged: 09:33:45

Error while processing event <Event state_changed[L]: entity_id=device_tracker.wlan0_3, old_state=None, new_state=<state device_tracker.wlan0_3=home; source_type=router, ip=, mac=38-1F-8D-34-A0-B7, connection_type=band2_4, interface=main, down_kilobytes_per_s=0.0, up_kilobytes_per_s=0.0, deco_device=Living Room, deco_mac=74-DA-88-FE-C5-34, device_class=client, icon=mdi:lan-connect, friendly_name=wlan0 @ 2022-07-19T09:33:44.895347+02:00>> for domain device_tracker
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/event.py", line 419, in _async_dispatch_domain_event
hass.async_run_hass_job(job, event)
File "/usr/src/homeassistant/homeassistant/core.py", line 546, in async_run_hass_job
hassjob.target(*args)
File "/usr/src/homeassistant/homeassistant/components/dhcp/init.py", line 311, in _async_process_device_event
self._async_process_device_state(event.data["new_state"])
File "/usr/src/homeassistant/homeassistant/components/dhcp/init.py", line 331, in _async_process_device_state
self.async_process_client(ip_address, hostname, _format_mac(mac_address))
File "/usr/src/homeassistant/homeassistant/components/dhcp/init.py", line 155, in async_process_client
made_ip_address = make_ip_address(ip_address)
File "/usr/local/lib/python3.10/ipaddress.py", line 54, in ip_address
raise ValueError(f'{address!r} does not appear to be an IPv4 or IPv6 address')
ValueError: '' does not appear to be an IPv4 or IPv6 address

Name: 'utf-8' codec can't decode bytes

Version of the custom_component

v2.2.3

Deco Model

Deco X60

Describe the bug

On integration setup, after entering in credentials/host/etc (checked multiple times), the integration fails with an error message "Unexpected error"

Based on the surrounding log messages, it looks like auth was successful, client lists are being pulled successfully, but there's issue parsing.

In the logs below, I didn't include the long client list in the error because it looks like it has private info there (lots of mac addresses, names encoded in some way), so I didn't want to include it broadly here...

Debug log

2022-12-04 22:04:32.563 ERROR (MainThread) [custom_components.tplink_deco] List Clients C0-C9-E3-03-18-B4 parse response error='utf-8' codec can't decode bytes in position 1-3: invalid continuation byte, data={//data omitted since it looks to have private info}

2022-12-04 22:04:32.573 ERROR (MainThread) [custom_components.tplink_deco] Unexpected error fetching tplink_deco-clients data: 'utf-8' codec can't decode bytes in position 1-3: invalid continuation byte
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 205, in _async_refresh
self.data = await self._async_update_data()
File "/config/custom_components/tplink_deco/coordinator.py", line 242, in _async_update_data
deco_client_responses = await asyncio.gather(
File "/config/custom_components/tplink_deco/coordinator.py", line 45, in async_call_with_retry
return await func(*args)
File "/config/custom_components/tplink_deco/api.py", line 216, in async_list_clients
raise err
File "/config/custom_components/tplink_deco/api.py", line 211, in async_list_clients
client["name"] = base64.b64decode(client["name"]).decode()
UnicodeDecodeError: 'utf-8' codec can't decode bytes in position 1-3: invalid continuation byte


Installation fails for M9+

Describe the bug

Unexpected error occurs when trying to add ne integration to my HA system. I have M9Plus (version2, latest firmware) router and Deco's own Ui is only asking for password, not username.

Debug log

I tried with 3 different option

Host: 192.168.68.1, then http://192.168.68.1 and last https://192.168.68.1 and they all gave this same error message

2022-03-21 19:40:44 WARNING (MainThread) [custom_components.tplink_deco] Error testing credentials: Cannot connect to host 192.168.68.1:80 ssl:default [Connect call failed ('192.168.68.1', 80)]
2022-03-21 19:41:03 ERROR (MainThread) [custom_components.tplink_deco] Fetch keys client error: Cannot connect to host http:80 ssl:default [Try again]
2022-03-21 19:41:03 WARNING (MainThread) [custom_components.tplink_deco] Error testing credentials: Cannot connect to host http:80 ssl:default [Try again]
2022-03-21 19:41:13 ERROR (MainThread) [custom_components.tplink_deco] Fetch keys client error: Cannot connect to host https:80 ssl:default [Try again]
2022-03-21 19:41:13 WARNING (MainThread) [custom_components.tplink_deco] Error testing credentials: Cannot connect to host https:80 ssl:default [Try again]

Add your logs here.

2022-03-21 19:50:56 WARNING (MainThread) [custom_components.tplink_deco] Error testing credentials: Cannot connect to host https:80 ssl:default [Try again]
2022-03-21 19:51:02 DEBUG (MainThread) [custom_components.tplink_deco] aes_key=3138964353424714
2022-03-21 19:51:02 DEBUG (MainThread) [custom_components.tplink_deco] aes_iv=1693287201126418
2022-03-21 19:51:02 ERROR (MainThread) [custom_components.tplink_deco] Fetch keys client error: Cannot connect to host 192.168.68.1:80 ssl:default [Connect call failed ('192.168.68.1', 80)]
2022-03-21 19:51:02 DEBUG (MainThread) [custom_components.tplink_deco] Finished fetching tplink_deco-decos data in 0.041 seconds (success: False)

Testing Deco P9

I am testing the operation on deco P9.

  • the integration is added successfully on my HA 2022.3.0

Cant find the add-on on integrations after install

Version of the custom_component

Deco Model

Describe the bug

A clear and concise description of what the bug is.

Debug log


Add your debug logs here.

I tried install manually and also with Hacs and the integration cannot be found.
I am on vesion Home Assistant 2022.9.0

Device without IP, but friendly_name as IP

Version of the custom_component

2.2.0

Deco Model

P9

Describe the bug

I have 2xP9 setup. Both working as APs and meshing each other.

One of the devices on the connected devices list has friendly_name as the ip.

image

I know it seems that Deco is doing something weird. But I'm not sure how to proceed with that problem. Any help?

Debug log

That causes the integration to fail with:

2022-08-27 16:10:04.445 ERROR (MainThread) [homeassistant.helpers.event] Error while processing event <Event state_changed[L]: entity_id=device_tracker.4069446681, old_state=None, new_state=<state device_tracker.4069446681=home; source_type=router, ip=4069446681, mac=34-EA-E7-E5-17-40, connection_type=band2_4, interface=main, down_kilobytes_per_s=0.0, up_kilobytes_per_s=0.0, deco_device=Living Room 1, deco_mac=B0-95-75-F3-D8-FE, device_class=client, icon=mdi:lan-connect, friendly_name=4069446681 @ 2022-08-27T18:10:04.440862+02:00>> for domain device_tracker
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/event.py", line 419, in _async_dispatch_domain_event
    hass.async_run_hass_job(job, event)
  File "/usr/src/homeassistant/homeassistant/core.py", line 546, in async_run_hass_job
    hassjob.target(*args)
  File "/usr/src/homeassistant/homeassistant/components/dhcp/__init__.py", line 311, in _async_process_device_event
    self._async_process_device_state(event.data["new_state"])
  File "/usr/src/homeassistant/homeassistant/components/dhcp/__init__.py", line 331, in _async_process_device_state
    self.async_process_client(ip_address, hostname, _format_mac(mac_address))
  File "/usr/src/homeassistant/homeassistant/components/dhcp/__init__.py", line 155, in async_process_client
    made_ip_address = make_ip_address(ip_address)
  File "/usr/local/lib/python3.10/ipaddress.py", line 54, in ip_address
    raise ValueError(f'{address!r} does not appear to be an IPv4 or IPv6 address')
ValueError: '4069446681' does not appear to be an IPv4 or IPv6 address

List of planned features and to-do's

Is your feature request related to a problem? Please describe.
In the readme that you say "currently the only feature implemented is..." so I'm wondering what else you had in mind for functionality

Describe the solution you'd like
A readme section with a list of features and functions that you'd like to implement - to inspire contributors

Possible to monitor client connected to AP?

Hi,

I'm using this integration but I'd like to know if it's possible to monitor a specific client to see to which Access point
he/she's connected. I have 5 AP's but sometimes have complaints about slow wifi.
When monitoring Deco, I see my wife's iPhone is connected to a remote AP while a new unit is nearby.
I know this is a Roaming / Firmware issue but like to use Home Assist to get a better picture of my house.
Maybe this module can help me achieving this with repositioning Access Points or buying extra.

"Error testing credentials:" Unable to reinstall integration

Version of the custom_component

v2.2.3

Deco Model

Deco M5: 1.6.1 Build 20220818 Rel. 36456 (latest firmware)

Describe the bug

Was previously able to get the integration working, and it's beautiful. Works like a charm.

Unfortunately a small user error by yours truly meant that a device I wanted to track (my phone) was accidentally deleted. I tried a few things to fix (including disabling, reenabling, a few other bugs) and finally decided to uninstall and reinstall the plugin.

Big mistake, now unable to set up at all 😢

When trying to set up the integration I get a very short error message:

Logger: custom_components.tplink_deco
Source: custom_components/tplink_deco/config_flow.py:81
Integration: tplink_deco ([documentation](https://github.com/amosyuen/ha-tplink-deco), [issues](https://github.com/amosyuen/ha-tplink-deco/issues))
First occurred: 3:32:29 PM (2 occurrences)
Last logged: 3:36:53 PM

Error testing credentials:

Following your advanced debugging section I've found a call to the Login page timing out and failing (http://192.168.68.1/cgi-bin/luci/;stok=/login?form=login):

image

Decrypted the data parameter from the console:

{
  "params": {
    "password": "97a5d007666c0d...<REDACTED... I'm guessing this is my password 😅 >"
  },
  "operation": "login"
}

Debug log

Debug log (scoped to tplink deco messages):

2022-10-28 15:35:52.114 DEBUG (MainThread) [custom_components.tplink_deco] aes_key=6762967653732700
2022-10-28 15:35:52.114 DEBUG (MainThread) [custom_components.tplink_deco] aes_iv=3548724372328245
2022-10-28 15:35:53.048 DEBUG (MainThread) [custom_components.tplink_deco] password_rsa_n=147400152213047990727033136147004346733103031985288458332450458806859242043605003404150174090446171651650480460233560027136327325663456109096372971869531130727197464059178168406922984183008755410378326074461124456947748570215827915280709053787014995116751665099191965014918961216467473409603919228363587361789
2022-10-28 15:35:53.049 DEBUG (MainThread) [custom_components.tplink_deco] password_rsa_e=65537
2022-10-28 15:35:53.140 DEBUG (MainThread) [custom_components.tplink_deco] sign_rsa_n=10270509159678023536690531829183371164472315091780561773171067592979882271187997298658589573506963286979882874649392461709050784859714539788510794987667191
2022-10-28 15:35:53.140 DEBUG (MainThread) [custom_components.tplink_deco] sign_rsa_e=65537
2022-10-28 15:35:53.140 DEBUG (MainThread) [custom_components.tplink_deco] seq=370994173
2022-10-28 15:36:23.153 DEBUG (MainThread) [custom_components.tplink_deco] Login timed out
2022-10-28 15:36:53.161 DEBUG (MainThread) [custom_components.tplink_deco] Login timed out
2022-10-28 15:36:53.161 DEBUG (MainThread) [custom_components.tplink_deco] Finished fetching tplink_deco-decos data in 61.047 seconds (success: False)
2022-10-28 15:36:53.161 WARNING (MainThread) [custom_components.tplink_deco] Error testing credentials:
2022-10-28 15:42:50.842 DEBUG (MainThread) [homeassistant.components.websocket_api.http.connection] [139962917372112] Received {'type': 'manifest/get', 'integration': 'tplink_deco', 'id': 68}
2022-10-28 15:42:50.843 DEBUG (MainThread) [homeassistant.components.websocket_api.http.connection] [139962917372112] Sending {"id":68,"type":"result","success":true,"result":{"domain":"tplink_deco","name":"TP-Link Deco","documentation":"https://github.com/amosyuen/ha-tplink-deco","issue_tracker":"https://github.com/amosyuen/ha-tplink-deco/issues","iot_class":"local_polling","version":"2.2.3","config_flow":true,"dependencies":[],"codeowners":["@amosyuen"],"requirements":["pycryptodome>=3.12.0"],"is_built_in":false}}
2022-10-28 15:42:53.470 DEBUG (MainThread) [homeassistant.components.websocket_api.http.connection] [139962917372112] Sending {"id":69,"type":"result","success":true,"result":[{ "name": "custom_components.tplink_deco", "message": [ "Error testing credentials: " ], "level": "WARNING", "source": [ "custom_components/tplink_deco/config_flow.py", 81 ], "timestamp": 1666931813.1618946, "exception": "", "count": 2, "first_occurred": 1666931549.928189 }]}
2022-10-28 15:42:54.877 DEBUG (MainThread) [homeassistant.components.websocket_api.http.connection] [139962917372112] Received {'type': 'manifest/get', 'integration': 'tplink_deco', 'id': 70}
2022-10-28 15:42:54.877 DEBUG (MainThread) [homeassistant.components.websocket_api.http.connection] [139962917372112] Sending {"id":70,"type":"result","success":true,"result":{"domain":"tplink_deco","name":"TP-Link Deco","documentation":"https://github.com/amosyuen/ha-tplink-deco","issue_tracker":"https://github.com/amosyuen/ha-tplink-deco/issues","iot_class":"local_polling","version":"2.2.3","config_flow":true,"dependencies":[],"codeowners":["@amosyuen"],"requirements":["pycryptodome>=3.12.0"],"is_built_in":false}}

Error testing credentials: Login error_code=-5003

TP-Link Deco HA Error LOG .txt

Error:
Unexpected error fetching tplink_deco-decos data: Login error_code=-5003
Login error_code=-5003, data={'result': {'failureCount': 10, 'attemptsAllowed': 0}, 'error_code': -5003}

Main deco mode: M5(1.0)
Firmware: 1.6.1 Build 20220818 Rel. 36456

Tried:
Direct browser access to 192.168.178.128 with no username (asume this is admin) and my deco password.
This succeeds with no problems.

Test with both Enable and Disable SSL, same result.

S7 support

Hi I have recently added 2off S7 units to my mesh (m4R) and have made an S7 the main unit.

In order to add S7 support to your integration I assume you need some samples of traffic,etc?

Please advise what you need.I'm happy to provide.

Deco S4 - Feedback

Using a TP-Link S4. v1. 50 firmware
HA on RPi3-64
core-2021.12.7
supervisor-2021.12.2

Other than needing a reboot and remembering the Deco password.
It seems to be running OK.
(Side note: Upnp/igp also sees it and is giving data stats)

A lot of device trackers created.

Only Exposing Desired Devices as Entities

Is your feature request related to a problem? Please describe.
This is just a feature request/suggestion.

Describe the solution you'd like
By default, the integration shares all of the connected devices as entities in home assistant. It would be nice to instead manually expose only the devices you wish to track. I'm not sure of the overhead on Home Assistant by having all devices show up, but I do know that it adds a lot of unnecessary devices that will never leave the house!

Describe alternatives you've considered
I have manually selected all of the entities and 'disabled' them. I have also disabled the 'enable newly added entities' option to prevent any new devices being automatically added to home assistant. These options cause me issues with the integration being able to get updates from the devices left enabled.

No longer on HACS?

Seems the repository is no longer on HACS?

I tried manually adding it but searching for it under integrations does not find it

Retrying setup: Cannot connect to host none:80 ssl:default [Name does not resolve]

Version of the custom_component

v2.1.1

Deco Model

3 x M4(v2)
Main (Cabinet)
Second (Landing)
Third (Kitchen)

Describe the bug

Initial setup went fine, configured and found all devices, needed to restart HACS and HA to update other integrations and found that the error below was present on the HA Integrations page.

Retrying setup: Cannot connect to host none:80 ssl:default [Name does not resolve]

When I checked the config, the main host had defaulted back to the original address 192.168.0.1 and the password had disappeared. Have tried several times to reset configuration which it seems to do (says finished successfully) but the error remains and the config entries are still missing.

Home Assistant log

Log Details (ERROR)
This error originated from a custom integration.
Logger: custom_components.tplink_deco
Source: custom_components/tplink_deco/api.py:390
Integration: TP-Link Deco (documentation, issues)
First occurred: 21:41:46 (8 occurrences)
Last logged: 21:47:14

Fetch keys client error: Cannot connect to host none:80 ssl:default [Name does not resolve]

Log Details (WARNING)
Logger: homeassistant.config_entries
Source: config_entries.py:366
First occurred: 21:50:52 (1 occurrences)
Last logged: 21:50:52

Config entry 'WiFi Network' for tplink_deco integration not ready yet: Cannot connect to host none:80 ssl:default [Name does not resolve]; Retrying in background

possible json decode buffer overflow caused by v2.2.1 with lots of log errors

Version of the custom_component

v2.2.1
v2.2.0 working ok

Deco Model

m4r mostly

Describe the bug

home assistant logging 1000+ lines of error every 30 seconds if I disable the deco integration it stops logging or I go back a version of the deco integration it stops logging errors

Debug log

2022-09-14 15:19:36.804 ERROR (MainThread) [homeassistant.components.websocket_api.messages] Unable to serialize to JSON. Bad data found at $.event.a.device_tracker.hallway_deco.a.ip=172.16.10.197(<class 'ipaddress.IPv4Address'>
2022-09-14 15:19:36.824 ERROR (MainThread) [homeassistant.components.websocket_api.messages] Unable to serialize to JSON. Bad data found at $.event.a.device_tracker.top_floor_deco.a.ip=172.16.10.182(<class 'ipaddress.IPv4Address'>
2022-09-14 15:19:36.827 ERROR (MainThread) [homeassistant.components.websocket_api.messages] Unable to serialize to JSON. Bad data found at $.event.a.device_tracker.kitchen_deco.a.ip=172.16.10.86(<class 'ipaddress.IPv4Address'>
2022-09-14 15:19:36.829 ERROR (MainThread) [homeassistant.components.websocket_api.messages] Unable to serialize to JSON. Bad data found at $.event.a.device_tracker.shellyem_d3b509.a.ip=172.16.10.83(<class 'ipaddress.IPv4Address'>
2022-09-14 15:19:36.833 ERROR (MainThread) [homeassistant.components.websocket_api.messages] Unable to serialize to JSON. Bad data found at $.event.a.device_tracker.shelly1pm_8caab505ffdf.a.ip=172.16.10.79(<class 'ipaddress.IPv4Address'>
2022-09-14 15:19:36.835 ERROR (MainThread) [homeassistant.components.websocket_api.messages] Unable to serialize to JSON. Bad data found at $.event.a.device_tracker.nest_hello_acfc.a.ip=172.16.10.88(<class 'ipaddress.IPv4Address'>

This continues and then causes many json errors - the information listed is private and appears to be the result of a buffer overflow - I am not prepare to put these log on to a public site due to data contained in the logs


Add your debug logs here.

Unable to setup since upgrading to v 2.0.1

Version of the custom_component

v 2.0.1

Configuration

n/a?

Describe the bug

image

Debug log

Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 187, in _async_refresh
    self.data = await self._async_update_data()
  File "/config/custom_components/tplink_deco/coordinator.py", line 169, in _async_update_data
    deco.update(new_deco)
  File "/config/custom_components/tplink_deco/coordinator.py", line 71, in update
    self.hw_version = data["hardware_ver"]
KeyError: 'hardware_ver'


Error when trying to configure.

I go to add integration, add the TP-Link Deco, change the IP to 192.168.68.1 (Which is my IP) add my password and click submit.

The submit changes to a lopping gif, that lasts about 2 minutes, it then come back with the error below.
Settings_–Home_Assistant-_2022-08-22_13 22 21
The only Errors in the log are
This error originated from a custom integration.

Logger: custom_components.tplink_deco
Source: custom_components/tplink_deco/config_flow.py:81
Integration: TP-Link Deco (documentation, issues)
First occurred: 13:53:26 (1 occurrences)
Last logged: 13:53:26

Error testing credentials:

Mercusys Halo H80X (AX3000)

This device appears to work with the integration - I believe this may be a rebadged version of the TP-Link Deco X50

Reboot all deco devices

Is your feature request related to a problem? Please describe.
this integration uses the owner account and there is no option to reboot all deco devices when using manager account.

Describe the solution you'd like
as amosyuen suggested here that the web admin portal has the ability to reboot specific devices or all devices.

Additional context
it will be nice to have the option to be able to reboot a specific deco device or all devices within home assistant.

unavailable state for all DECO devices most of the time

I'm experiencing that all DECO devices report an 'unavailable' status most of the time. Sometimes it works for a few minutes, but not for long. I have 4x TP-Link Deco M4 and around 70 connected devices. I tried to increase the interval, but that doesn't appear to change anything. Is anyone seeing the same thing?

Logger: custom_components.tplink_deco
Source: custom_components/tplink_deco/api.py:134
Integration: TP-Link Deco (documentation, issues)
First occurred: 1:38:08 PM (3 occurrences)
Last logged: 1:41:19 PM

Unexpected error fetching tplink_deco data: List devices error None
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 187, in _async_refresh
    self.data = await self._async_update_data()
  File "/config/custom_components/tplink_deco/coordinator.py", line 90, in _async_update_data
    new_clients = await self._api.async_list_clients()
  File "/config/custom_components/tplink_deco/api.py", line 134, in async_list_clients
    raise Exception(f"List devices error {error_code}")
Exception: List devices error None
Logger: custom_components.tplink_deco
Source: custom_components/tplink_deco/api.py:152
Integration: TP-Link Deco (documentation, issues)
First occurred: 1:29:03 PM (6 occurrences)
Last logged: 1:40:19 PM

Unexpected error fetching tplink_deco data: List clients error None
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 187, in _async_refresh
    self.data = await self._async_update_data()
  File "/config/custom_components/tplink_deco/coordinator.py", line 90, in _async_update_data
    new_clients = await self._api.async_list_clients()
  File "/config/custom_components/tplink_deco/api.py", line 152, in async_list_clients
    raise Exception(f"List clients error {error_code}")
Exception: List clients error None

Error in HA setup

I get this error when I start up HA.

Logger: homeassistant.setup
Source: components/device_tracker/legacy.py:302
First occurred: 20:02:41 (1 occurrences)
Last logged: 20:02:41

Error during setup of component device_tracker
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/setup.py", line 229, in _async_setup_component
result = await task
File "/usr/src/homeassistant/homeassistant/components/device_tracker/init.py", line 48, in async_setup
await async_setup_legacy_integration(hass, config)
File "/usr/src/homeassistant/homeassistant/components/device_tracker/legacy.py", line 158, in async_setup_integration
legacy_platforms = await async_extract_config(hass, config)
File "/usr/src/homeassistant/homeassistant/components/device_tracker/legacy.py", line 302, in async_extract_config
raise ValueError(
ValueError: Unable to determine type for tplink_deco: None

Any idea what goes wrong or what I do wrong?

My configuration.yaml is simple as follows:
device_tracker:

  • platform: tplink_deco
    host: 192.168.xx.1
    username: at@xxx
    password: xxxxx
    interval_seconds: 5
    consider_home: 180
    new_device_defaults:
    track_new_devices: true

No mention of "Host"

In the installation guide there is no mention as to what to fill in at the "Host" field. I figured it out, but please clarify.

Found devices not added as entities

Version of the custom_component

V2.1.1 same in Master and V2.1.0

Deco Model

Deco X60 mesh system with 3 wired backbones.

Describe the bug

After configuring the component through HACS and adding the integration, no entities are added to Home Assistant. There isn't any error in the log and all devices are found correctly. From the logs, the deco-clients are successfully fetched and the deco-data successfully fetched are both shown twice, whereas you would expect there to be three since there are three Deco's. Finally, as you can see in the logs the integration seems to have searched everything twice, whereas it was started once. Maybe the cause could be because there are too many clients, or the third router isn't processed correctly, which causes it to never make the entities for the found clients?

Steps to reproduce

Have three Deco's X60 wired together. Install ha-tplink-deco through HACS. Add the TP-Link Deco integration. Enter credentials and correct IP of Deco, click on submit. Change the system options and enable 'enable newly added entities' and 'enable polling for updates'. Watch the system for any added entities, should be none. Integration overview also shows how many entities are added, should be none too.

What was expected to happen

The integration should add the found clients to Home Assistant as new entities.

What did happen

The integration found the clients, but didn't add any entities.

Debug log

[custom_components.tplink_deco] List devices device_count=3
[custom_components.tplink_deco] Finished fetching tplink_deco-decos data in 2.627 seconds (success: True)
[custom_components.tplink_deco] List Clients DECO1MAC client_count=23
[All device information shown correctly]
[custom_components.tplink_deco] List Clients DECO2MAC client_count=6
[All device information shown correctly]
[custom_components.tplink_deco] List Clients DECO3MAC client_count=20
[All device information shown correctly]
[custom_components.tplink_deco] Finished fetching tplink_deco-clients data in 6.116 seconds (success: True)

[custom_components.tplink_deco] List devices device_count=3
[custom_components.tplink_deco] Finished fetching tplink_deco-decos data in 1.592 seconds (success: True)
[custom_components.tplink_deco] List Clients DECO1MAC client_count=23
[All device information shown correctly]
[custom_components.tplink_deco] List Clients DECO2MAC client_count=6
[All device information shown correctly]
[custom_components.tplink_deco] List Clients DECO3MAC client_count=20
[All device information shown correctly]
[custom_components.tplink_deco] Finished fetching tplink_deco-clients data in 6.029 seconds (success: True)

Get which deco device client is connected to

Is your feature request related to a problem? Please describe.
No it‘s enhancement

Describe the solution you'd like
With which deco is the device connected, normally you have more mesh devices. So if Phone A is connected with deco living room and device B connected with deco in the kitchen.

Describe alternatives you've considered
It must not be the label or something else IP or Mac is ok i think

CONECTION HA LOST

Version of the custom_component

Deco modelo

DECO X20 Master

Describe the bug

HOME ASSISTANT VERSION 2022.7.0b2

TPLINK integration lost connection with HA.
I deleted and reinstalled, but I can't send the configuration because there is an "unexpected error"

Debug log


Add your debug logs here.

Attribute with the IP address is gone

Version of the custom_component

TP-Link Deco v1.0.1

Configuration

  • Deco M9+
  • Home Assistant 2022.2.6
  • HACS 1.22.0
Nothing in the logs

Describe the bug

The attribute with the IP address is gone. The only attributes left are:

source_type: router
mac: 3C-8D-20-XX-XX-XX
connection_type: band5
interface: main
down_kilobytes_per_s: 0.25
up_kilobytes_per_s: 0.25
icon: mdi:lan-connect
friendly_name: Chromecast Living Room

Debug log

2022-02-14 14:27:35 INFO (MainThread) [custom_components.tplink_deco]
-------------------------------------------------------------------
TP-Link Deco
Version: 0.0.0
This is a custom integration!
If you have any issues with this you need to open an issue here:
https://github.com/amosyuen/ha-tplink-deco/issues
-------------------------------------------------------------------

2022-02-14 14:27:35 DEBUG (MainThread) [custom_components.tplink_deco] aes_key=***
2022-02-14 14:27:35 DEBUG (MainThread) [custom_components.tplink_deco] aes_iv=***

Error adding entities

Version of the custom_component

v2.2.1

Deco Model

P9(2.0)
Firmware version: 1.1.3 Build 20201228 Rel. 55057

Describe the bug

Configuration seems to work. However, no entities are added to HA and an error message shows on the logs.

Debug log


Logger: homeassistant.components.device_tracker
Source: custom_components/tplink_deco/device_tracker.py:128
Integration: Device tracker ([documentation](https://www.home-assistant.io/integrations/device_tracker), [issues](https://github.com/home-assistant/home-assistant/issues?q=is%3Aissue+is%3Aopen+label%3A%22integration%3A+device_tracker%22))
First occurred: 19:57:24 (6 occurrences)
Last logged: 20:05:44

Error adding entities for domain device_tracker with platform tplink_deco
Error while setting up tplink_deco platform for device_tracker
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 428, in async_add_entities
    await asyncio.gather(*tasks)
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 529, in _async_add_entity
    device_info = entity.device_info
  File "/config/custom_components/tplink_deco/device_tracker.py", line 235, in device_info
    return create_device_info(self._deco, self.coordinator.data.master_deco)
  File "/config/custom_components/tplink_deco/device_tracker.py", line 128, in create_device_info
    device_info[ATTR_VIA_DEVICE] = (DOMAIN, master_deco.mac)
AttributeError: 'NoneType' object has no attribute 'mac'

Home Assistant version

Home Assistant 2022.9.4
Supervisor 2022.08.6
Operating System 8.5
Frontend 20220907.2 - latest

Option to keep last state instead of becoming unavailable

Is your feature request related to a problem? Please describe.
I have a similar problem to the ones reported in issue #39 and #61.
image

Sometimes my Deco will timeout and then everything will go unavailable and then recover their status on the next try. This results in dozens of devices becoming home or away in a short period of time, which is bad for some automation or guests detection.
Here's an example:

image

Describe the solution you'd like
Instead of devices going unavailable I'd like an option for the devices to keep their last know state when there's an error during status retrieval.

Describe alternatives you've considered
I've created a simple template for some device trackers, but it's not a good idea to create dozens of these.

Additional context
I believe this would make the integration work in a more stable manner, even if the fault is on the Deco devices.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.