Tuya devices state not updating properly

https://community.home-assistant.io/t/tuya-integration-hangsup/519130/12