I’ve started working on a new automation scripting tool inspired by PyScript but in Go. The reason for making this is because I was a little frustrated with my ability to troubleshoot the very complicated automations I was making with PyScript. Without any good debugging tools available within PyScript I had a hard time knowing what was going on besides just writing to logs all the time and even then it was hard to really know what was coming from where.
This all started with various experiments with MQTT and adding devices, it just kind of grew from there until I realized I had all the parts for writing automations. Since the automations are in Go they need to be compiled into a program that talks to Home Assistant, in the example project there is an example of creating a docker container to run your project within. Because this grew out of MQTT experiments it does have the ability to add devices to Home Assistant which has opened up some cool possibilities like virtual climate devices that I will dive into another time.
Right now the tool works but is still very much in alpha. I have transitioned most of my automations to using it and it’s been stable for the past week or so.
Github - https://github.com/kjbreil/goscript
Example - https://github.com/kjbreil/goscript-example
Right now I wouldn’t recommend anyone to use this unless you are ready to hack and have your stuff break.