My Tuya Switches/Bulbs take insane amounts of time to update their state after HA0.111.1

Upgraded to HA 0.111.1 yesterday and the moment everything was back up and running again my Tuya Lights and switches now take 1-3minutes to update their state. Using the Smartliffe app, they respond immediately; same with Alexa; just HA seems to not get the current state for a long time.

In the UI it’ll show a light on (when its been off for a while) and if I toggle it off, it just slides back to ON again. This is obviously causing hell with all my light or switch based automations.

But here’s the other thing… if i keep hitting the toggle, it’ll turn the light or switch on or off, but only if i keep hitting it maybe 5-6 times. But even still, the state will show the wrong state for minutes afterwards.

So this is a state reporting issue back to HA. I know this update added the Tuya Intergration, but I’m wondering if it did anything else? I tried removing the Tuya Intergration and reinstalling… no help. Tried ditching the Intergration and using the previous config yaml way, no luck, same issues.

This is happening to 18 of my 25 or so lights and switches since update; and once again, only an issue with HA not the other apps

Anyone else experiencing this issue?

UPDATE: As of now, 7 of my Tuya SmartLife switches and bulbs don’t update their state… ever.
Tuya.force_update and tuya.pull_devices does absolutely nothing. Ive rolled back to where everything was fine, and the problems followed me. So this must be an isssue with tuya. I cant believe more people aren’t experiencing this. I have no clue what’s causing it.


I only have 2 tuya lights I can’t flash. But I’m not seeing that behavior on 0.111.x

I am also experiencing the same time lag.

Mine started doing this to me yesterday. Very frustrating! Some of my buttons won’t toggle lights now since the state won’t update properly. Only way I can turn things on and off in ha is to quickly toggle on and off it vice versa.

Hello, I also had problems with my Tuya devices. Now I have updated from V 0.110.4 to V 0.111.2 and currently I do not see any time delay when switching, everything runs very quickly … My devices are set up via the Tuya app !!!

I just installed Home Assistant and TUYA was the first device set that I added. I have been trying to figure out what I did wrong that was causing this lag, just short of rebuilding the entire system.

I’m glad I saw your post and am not going crazy. Is there a workaround for this?

Same here… I have tried about everything I have found… Downgraded HA, tried Custom Configuration, deleted and restored devices and the intergration. I even loaded a copy of my HA I have in a virtual machine that I was testing a few weeks ago that I KNOW was functioning properly… Same lag. What seemed to work at first was to move my selected ‘platform’ from Smart Life to Tuya. The first switch I changed started responding instantly in Home Assistant so I swapped all 16 devices, then the problem returned. The Tuyan and Smart Life contol is almost instant so it doesnt seem to be on their end. These devices have worked flawlessly for months, my issues started Friday evening, 6-12-2020.

I also am seeing the same behavior on my tuya devices, they’re taking forever to update.

Honestly, i still have NO CLUE why they’re doing this. I literally have tried everything i can think of and searched high and low to resolve this crazy state lag time issue.

I even bought a cheap $30 2.4ghz router which i assigned another WAN IP to and disabled all firewalls, and everything else on. I read somewhere when you have many Chinese wifi tuya switches and bulbs, that sometimes the constant traffic and reporting back to the tuya China servers can cause this lag issue with states. Although considering the Tuya/SmartLife app and Alexa don’t seem to have this lag, i doubt that was the issue… I gave all the tuya devices reserved IPs as well… it changed nothing, same problem.

I tried deleting the tuya Intergration and unscrewing 90% of my lights and switches — to test if its a “too many devices” issue, since i have over 35ish — same issue with only 5 bulbs in HA.

Tried switching from SmartLife to the Tuya app and setting up 5 or so bulbs… same issue.

I upgraded to 0.111.2 and that didn’t fix it either for me.

At this point, it seems to be a limited issue for all of us HA users using Tuya; Otherwise we’d be seeing 100s of posts about this. Maybe an addon interfering, or some other config issue; who knows.

At this point I’ve given up. I wont be adding anymore of these cheap tuya devices to my home automation system anymore. I’ll probably start buying GE bulbs (or other bulbs/switches compatible) to use with my HUE HUB or another much more reliable and efficient system with HA

A temporary fix — for me — was to disable ALL current state triggers and checks (I primarily use node red) and slowly find workarounds for automations that rely on a light/switch states — So I’m hammering HA twice as hard as before with all these redundant requests, but what else can i do?

Ive also added timed delays for all my light triggers — automatically shut off after X time on… just in case they never shut off. Basically I have input_booleans coming out of my ass at this point. Turn “input_boolean.bedroom_side_table_light” ON triggers “switch.bedroom_side_table_light” ON, And then the opposite for OFF. This way the boolean is keeping track of my states now. My frontend is also using these input_booleans instead of light/switch entity toggles now too because of this.

Since the state does usually report back… eventually, i also have state checks against my input_booleans to keep them in sync throughout the day/night. But this is not very reliable.

This is all so stupid and annoying. But since it doesn’t seem to be a wide spread issue, i doubt we’ll see a solution/fix anytime soon.

But to rule out individual issues… try running the service “tuya.force_update” and “tuya.pull_devices” and see if that helps you. It didnt do anything for me, but maybe you’ll have better luck.

I’m glad it’s not just me seeing it. I have tried several things myself with no luck. Hopefully it gets fixed. It’s not causing me too many issues, as none of my automations rely on their state. But, it is annoying to not see the updated state for several minutes.

Edit: It must be an issue on Tuya’s end, as my Google Assistant cannot see them at all. For all of my Tuya devices, Google is showing them as offline.

Any thoughts on flashing these devices to Tasmota? Everything I have at this point are bulbs so the only option is an OTA flash (seems like 100 things can go wrong).

I have been unable to flash any devices I have received. I just started messing with smart devices and I guess I showed up late to the party enough that everything I have purchased so far will not flash.

Is there anyway to go back on the update ? It´s happening here too with all and only tuya devices, since yesterday i think…

I haven’t attempted flashing anything to Tasmota as of yet. I see the appeal of doing it; with getting rid of the need for 3rd party Intergrations and relying on APIs etc. But diving into hardware and soldering etc isn’t really my specialty. But if this issue continues for much longer, i might jump on that and give it a try. I have nothing to lose with these bulbs… they either start working with HA, or they get replaced.

But on that note. A reply on another thread mentions this is a known issue with the latest HA update. I couldn’t find posts about Tuya specifically, but apparently they exist. So maybe we’ll see a fix soon.

They will fix for sure, just give time.
Lesson learned, I will never update without a working sd card backup.

1 Like

I was able to downgrade to 110.0 and the problem is present too.

Are you still without any lag?

Yup. Problem is exactly the same.

But I’ve almost entirely re-written any code or nodes that relied on a lights’ current state.

Its a mess of a system now with all my boolean toggles to manually keep track of states, but it “works” for the most part with my automations.

This isn’t the first issue I’ve had with Tuya and HA over the years — I’ve had quite a few. So i think I’m going to move to a much more stable and reliable bulb/switch platform; maybe Hue, or SmartThings etc.

Ive had curtains and window shades with Tuya that have never once worked properly with HA since day one. They routinely go into an “unknown” state, don’t update their current state for hours and hours, and many times just open and close completely on their own without any input from HA or the app. I actually had to setup zwave door/window sensors at the bottom (or closed area) to run my automations from.

But ill update this post if any solution is found.

Hello. Have a short video recorded, look here. On the left you see the browser with the Home Assistant and on the right is the “Tuya app” on the smartphone. However, since a few days ago I get this message displayed in HA …

!! Failed to call service switch/turn_off ‘NoneType’ object is not iterable !!

This message appears exclusively when switching on Tuya devices …

The devices that are turned on and off are connected to this socket lists

You don’t seem to be experiencing the same issue as us; Your states are in-sync.

I’m not sure what that error is; I’ve never seen it before. But I’m sure a quick google would get you on the right track to fixing it. Or make a new post in this topic forum about it. But you’ll need to show people your log files etc. not much can’t be figured out just from a video.