rospogrigio / localtuya

local handling for Tuya devices
GNU General Public License v3.0
2.71k stars 530 forks source link

Plugs unavailable - Reload Plugin = crash #949

Open sebaschn opened 1 year ago

sebaschn commented 1 year ago

The problem

after updateing to the current version v4.0.x (only some of) my plugs become unavailable randomly. with the version 3.x i simply triggered the "reload" event and everything went to normal again. with the current version the reload event has the result that ALL my tuya devices become unavailable = the plugin stops working

as long as the devices are available, everything works just fine :-)

my Tuya Local Reload script:

  alias: Tuya Local Reload
  sequence:
  - service: localtuya.reload
  mode: single

Environment

Steps to reproduce

  1. device becomes unavailable
  2. navigate to "devices -> tuya local plugin -> reload
  3. ALL my tuya devices become unavailable
besiktas97 commented 1 year ago

Since today I am always having troubles with my tuya devices that I am using with local tuya. They keep disconnecting and coming back againd and got a full load of error logs...

willsmarthome commented 1 year ago

After installing 4.x, sSame problem here, All device via Tuya Local once a day unavailable. After restart Home Assisant device are available again.

coldkevin commented 1 year ago

Unfortunately this just happened to me now. Had a switch showing as unavailable but was on my network. Tried reloading the integration and everything went offline. The Tuya Integration is now highlighted with a yellow border.

coldkevin commented 1 year ago

hmm, restarting home assistant brought everything back.

besiktas97 commented 1 year ago

There are strange things going on with Local Tuya since the update of 2022.7.x and local tuya V4.x. I had a bulb that was working with the tuya app but not with local tuya. Key was good, and this was for almost 2-3 days. Today they have placed solar panels and the electricity did cut of on and of on and now suddenly the bulb is working...

foxymichelle commented 1 year ago

I'm having trouble with this too. I just set this up maybe 2 weeks ago, and I just had to reboot HA for the third time because all of the local tuya devices became unavailable and only seem to come back online with a system reboot. Looking at each local tuya device, history shows they all became unavailable at the exact same time. Devices left on the official tuya integration are fine and all devices work fine through the tuya app, so this is definitely isolated to the local tuya integration. I just created an automation so that if a handful of the local tuya devices become unavailable, I'm sent a notification about the failure and HA reboots so that we're not stuck with all the bulbs in our house being unresponsive until I manually reboot.