synesthesiam / rhasspy

Rhasspy voice assistant for offline home automation
https://rhasspy.readthedocs.io
MIT License
941 stars 101 forks source link

[mqtt.py:126] AttributeError: 'NoneType' object has no attribute 'connect' #225

Open Da-LiFe opened 4 years ago

Da-LiFe commented 4 years ago

After enabling MQTT in settings, I get the following error in the log every 5 seconds:

[DEBUG:4142033] HermesMqtt: Reconnecting in 5 second(s)
[ERROR:4142032] HermesMqtt: connecting
Traceback (most recent call last):
  File "/usr/share/rhasspy/rhasspy/mqtt.py", line 126, in do_connect
    ret = self.client.connect(self.host, self.port)
AttributeError: 'NoneType' object has no attribute 'connect'

I don't find

https://github.com/synesthesiam/rhasspy/blob/77d2196f0057855d44e6c5cc4d42ad7d3a31177f/rhasspy/mqtt.py#L120

in the logs, so I assume to_connecting is not executed (correctly), but I don't see any additonal messages in the log.

My settings are:

    "mqtt": {
        "enabled": true,
        "host": <internal ip address>
    },

Rhasspy version 2.4.20 running in docker setup on raspberry 3b+, debian buster