Lights "unavailable" after turning manual switch off/on

Hi guys,

I have a problem with the LocalTuya integration. I have several lights included in Home Assistant and e.g. a light group of 3 lights in the living room. All lights work well and are disconnected from WiFi in the router (Fritzbox) so are just in the local network.

Now i encounter a problem, that if i use the manual switch to turn on/off the lights, they are shown in HA as “unavailable” afterwards.

The only solution for now is to reconnect them to WiFi → restart HA → disconnect them from WiFi
—> until someone uses the manual switch again…

What could cause this issue? And why are the lights/ the light group not reconnected to HA automatically and shown as “unavailable”?

Thank you for kind responses!

Can you provide more details of your setup. I assume the manual switch cuts all power to the lights, which I’m guessing are tuya-based wifi smart lights. They still require wifi to work with tuya-local, so it’s not clear what you mean by disconnected from wifi. Do you mean you’ve blocked their internet access, but their still on your wifi network (eg vlan)? I believe tuya lights still need internet access, and tuya-local still gets config from the cloud, but control is local. I don’t believe there is 100% local with tuya; could be wrong though. There’s also multiple “tuya local” options. There is a related issue here.

Hi Michael,

yes, the manual switch cuts the power off and they are indeed tuya-based wifi smart lights (as all the others which work smoothly as well).
I´m sorry and yes, i meant that i blocked them from internet access, not the Wifi, due to the limitation of the Tuya API.

So local tuya actually works completely local without internet access of the devices but in the case of this specific light group, the lights are “unavailable” after switching the manual switch. For the other bulbs this doesn´t matter and they reconnect properly.

UPDATE: Also, what i just whitnessed:
If any light is blocked from internet and cut from power for some time, it is not automatically reconnected to Home Assistant (so again needs internet, restart of HA and then i can block access again).
→ There seems to be a time limitation? I really don´t know… but local tuya seems not perfectly working so far.