Closed torarne closed 5 years ago
Hi @torarne
The syntax is correct for Python 3 - if you run using Python 2 then you will get the following error:
File "/usr/src/enviroplus-mqtt/src/main.py", line 47
sys.exit(f"Connecting to the MQTT server failed: {logger.connection_error}")
^
SyntaxError: invalid syntax
There is a bug in the following line:
A extra "f" needs to be removed from the arguments to sys.exit.
Thanks for the code which runs with Mosquitto in my setup!