def METHOD_NAME(s, data):
    try:
        async_to_sync(self.send)(json.dumps({"output": data}))
    except Exception:
        # ignore send errors, allow script to continue execution
        # better to drop output then to abort a script in the middle
        pass