Tuya local trying to connect to a unplugged device

I have a Tuya device with local Tuya integration. Somtimes I need to unplug the device but then the log file is filled with a lot of error lines triying to connect to the device.

How can I say HA that can show the device as unavailable but do not fill log file with a lot of connection error messages?

This must be an automatic operation because I don’t want to disable/enable manually the device in HA each time I unplug/plug the device.

Thanks

The Logger Integration might be useful with your case.

What do you mean automatic? The device is disconnected and there could be many reasons for that and integration is understandably trying to recover its state. Any suggestions?

I have the same situation with my power sockets; some of which I only need from time to time.

After a bit of thought I realised it’s more a matter of philosophy.

  • For some devices ( such as the power socket I use for xmas lights), being off-line (unplugged) is an expected state and not an error condition.
  • For other devices (such as the power socket with the freezer in the garage), being unplugged is a major error condition.

I’m not sure that there is an answer at the driver/integration level. Maybe to flag individual devices as to whether being off-line is considered an error or not ?