Closed PhilRW closed 6 years ago
On second thought... this needs more testing
Okay, reopening request. It is working much better for me now. I still have an issue if I restart HA while a switch is 'on' it will reset to its default state of 'off' and get out-of-sync.
I think this is resolved via #136
SmartThings occasionally loses sync with HA. If the MQTT bridge retains the history without verifying that the device changed its state, it will refuse to process new command messages from HA because it already believes that the SmartThings device is in that state. This change ignores the MQTT bridge internal state machine when
retain
isfalse
.There may be a better way to do it, but it's currently working for me.