From 0e3dafff1da82f795e9c0afe31f25d44cddab2df Mon Sep 17 00:00:00 2001 From: builderjer Date: Sun, 22 Jan 2023 09:09:09 -0700 Subject: [PATCH] fixed bug with 'emit' --- ovos_plugin_manager/templates/phal.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/ovos_plugin_manager/templates/phal.py b/ovos_plugin_manager/templates/phal.py index feaea7f4..d58bdc6b 100644 --- a/ovos_plugin_manager/templates/phal.py +++ b/ovos_plugin_manager/templates/phal.py @@ -2,6 +2,7 @@ from ovos_utils import camel_case_split from ovos_utils.log import LOG from ovos_utils.messagebus import get_mycroft_bus +from mycroft_bus_client.message import Message from ovos_config import Configuration from ovos_plugin_manager.utils.config import get_plugin_config from threading import Thread @@ -92,7 +93,8 @@ def __init__(self, bus=None, name="", config=None): def emit(self, msg_type, msg_data=None): skill_id = f"ovos.PHAL.{self.name}" - self.bus.emit(f"{skill_id}.{msg_type}", msg_data, {"skill_id": skill_id}) + LOG.info(f"{skill_id}.{msg_type}") + self.bus.emit(Message(f"{skill_id}.{msg_type}", msg_data, {"skill_id": skill_id})) def shutdown(self): self.bus.remove("enclosure.reset", self.on_reset)