Odianosen25 / Monitor-App

Appdaemon App for Andrew's Monitor Presence Detection System
74 stars 9 forks source link

Wrong message type for MQTT Listener: MQTT instead of MQTT_MESSAGE #1

Closed shbatm closed 4 years ago

shbatm commented 5 years ago

Hello! I am trying to implement your new script in ADv4, but I'm struggling to get it running as posted.

Specifically, I wasn't getting any feedback from the MQTT service (publish was working fine, the subscription wasn't receiving any events). Changing the following line:

        self.mqtt.listen_event(self.presence_message, 'MQTT', wildcard = '{}/#'.format(self.presence_topic))

to this:

        self.mqtt.listen_event(self.presence_message, 'MQTT_MESSAGE', wildcard = '{}/#'.format(self.presence_topic))

seems to solve the issue.

Odianosen25 commented 5 years ago

Hello @shbatm,

First I am so sorry I am just responding. I don't get any notification in my mail, and just stumbled unto the fact you commented all these while. This is my first comment to a code I have released, to I very much appreciate the fact you using it, and wanting to make it better.

Now to your PR I didn't use "MQTT_MESSAGE" as I do change my event_name in the setup, but will respond in the PR