I was trying to find the answer to this question but after hours of search still no luck, so thought I'd ask here...
In short, do we yet have support for scripting in Python to change the actions of a trigger? Specifically, to change the script code of an "Execute script" action?
Asking because I've been using the Homebridge-Indigo plugin to integrate Indigo with Apple HomeKit. I created triggers (action written in Python) for each device so that when its state changes, the trigger sends an http request to Homebridge which notifies HomeKit of the status change. Since I have lots of devices, I adapted a script found on the forum (couldn't remember where exactly it was) to batch create such triggers - obviously this includes changing the script code of these triggers, and since Python didn't support this function, it was done with help of AppleScript like this:
app.trigger_actions["Trigger Name"].action_steps[1].script_code.set("Python Script Here")
But recently I found this method stopped working - in event log it just says "Application can not handle this command". After finding that AppleScript support will be deprecated soon, I wonder if we already can do the same thing in Python?
Any help would be greatly appreciated.