Skip to content

Commit d758f7c

Browse files
committed
mqtt: Fix using correct logger instance
1 parent 2cb097e commit d758f7c

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

msgflo/msgflo.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -293,13 +293,13 @@ def _message_pump_greenthread(self):
293293
return
294294

295295
def _on_connect(self, client, userdata, flags, rc):
296-
logging.debug("Connected with result code" + str(rc))
296+
logger.debug("Connected with result code" + str(rc))
297297

298298
# Subscribe to queues for inports
299299
subscriptions = [] # ("topic", QoS)
300300
for port in self.participant.definition['inports']:
301301
topic = port['queue']
302-
logging.debug('subscribing to %s' % topic)
302+
logger.debug('subscribing to %s' % topic)
303303
subscriptions.append((topic, 0))
304304
self._client.subscribe(subscriptions)
305305

@@ -315,10 +315,10 @@ def send_discovery():
315315
gevent.Greenlet.spawn(send_discovery)
316316

317317
def _on_subscribe(self, client, userdata, mid, granted_qos):
318-
logging.debug('subscribed %s' % str(mid))
318+
logger.debug('subscribed %s' % str(mid))
319319

320320
def _on_message(self, client, userdata, mqtt_msg):
321-
logging.debug('got message on %s' % mqtt_msg.topic)
321+
logger.debug('got message on %s' % mqtt_msg.topic)
322322
port = ""
323323
for inport in self.participant.definition['inports']:
324324
if inport['queue'] == mqtt_msg.topic:

0 commit comments

Comments
 (0)