I'm using the BWALink addon and maybe it makes more sense to open an issue on that git, but I'm not really familiar with how HA and all this works entirely. It looks like it used MQTT to talk to the hot tub and looks fine until I send a command. It becomes unavailable for a couple seconds and then reports the previous setting as shown. I can get a log as well.
#Entities going to unavailable when changing states manually or through automation MQTT BWALink
1 messages · Page 1 of 1 (latest)
This all communicates over a serial to wifi device to the hottub board. The connection seems strong enough according to my router.
If it just went to what the automation or i set it to after becoming unavailable, id be ok
You may want to be sure these are retained in the MQTT broker. that should make sure there is a value there until you change it to another value actively.
If you want to see if it's retained or not, there is this tool: MQTT-Explorer can help you be successful!
If you have Apps available, try adding this App repository to your Apps list. https://github.com/GollumDom/addon-repository.
With this you can see that the broker sees and likely find the bug.