fbchat
fbchat copied to clipboard
MQTT connection failed
Description of the problem
When trying to run the echo bot example I'm getting: fbchat._exception.FBchatException: MQTT connection failed
Code to reproduce
https://fbchat.readthedocs.io/en/stable/examples.html#echobot
Traceback
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/Users/peter/PycharmProjects/shrek_messenger/echo.py", line 22, in <module>
client.listen()
File "/Users/peter/PycharmProjects/shrek_messenger/venv/lib/python3.7/site-packages/fbchat/_client.py", line 2883, in listen
self.startListening()
File "/Users/peter/PycharmProjects/shrek_messenger/venv/lib/python3.7/site-packages/fbchat/_client.py", line 2835, in startListening
foreground=True,
File "/Users/peter/PycharmProjects/shrek_messenger/venv/lib/python3.7/site-packages/fbchat/_mqtt.py", line 65, in connect
raise _exception.FBchatException("MQTT connection failed")
fbchat._exception.FBchatException: MQTT connection failed
Have you tried the latest version? 1.9.7
Hello, I also had that problem to solve it, what I did was use fbchat with python 2.7 because it didn't work for me with python 3.6 or 3.7 Hope I can help you 🙌🏽