EDIT: The below seems not to have been a good idea. After a while, the tuya integration stopped loading at all. I think this might cause too many API calls on the tuya side So I guess, we will have to wait.
Since for me manually reloading the integration at least updates the states, I created an automation that just reloads the integration every 2 minutes. Obviously by no means is this a “solution” and it obviously is incredibly inelegant. But at least I get a somewhat consistent (albeit with a max. of 2 min. delay) status updates. So for me this works as a stop-gap solution until the situation is resolved properly. Notice that when you reload the tuya integration all your devices become briefly unavailable (1s or so). In practice this is not an issue, unless of course you have automations that do something when a device becomes unavailable.
Anyway, if you want to use this stop-gap solution, below is the code of the automation.
description: ''
trigger:
- platform: time_pattern
minutes: /2
condition: []
action:
- service: homeassistant.reload_config_entry
data:
entry_id: XXXXXXXXXXXXXXXXXXXXXXXXXX
mode: single>
In order to find out the entry ID, you have to check in the file /config/.storage/core.config_entries. Sicne this is a hidden .storage folder, I don’t think you can check that file with the file editor Visual Studio (correct me if I am wrong). Instead:
1. install the ssh add-on
2. open the ssh webUI
3. type the following command: less /root/config/.storage/core.config_entries
Look for the section with domain tuya:
{
"entry_id": "XXXXXXXXXXXXXXXXXXXXXXXXXX",
"version": 1,
"domain": "tuya",
"title": "XXXX",
"data": {
"endpoint": "https://openapi.tuyaeu.com",
"auth_type": 0,
"access_id": "XXXX",
"access_secret": "XXXX",
"username": "XXX",
"password": "XXXX",
"country_code": "32",
"tuya_app_type": "smartlife"
},
Let’s hope it get’s fixed quickly. There are already a bunch of github issues opened, so I think the devs should be aware.