emonhub icon indicating copy to clipboard operation
emonhub copied to clipboard

Syntax errors in EmonHubMqttInterfacer

Open delboy711 opened this issue 2 years ago • 0 comments

While commissioning my new emoncms server I came across a couple of syntax errors in EmonHubMqttInterfacer. In my application I am sending mqtt messages into emonhub for transmission over RF69 radio so am using parts of emonhub most users will not use.

On line 265 payload = msg.payload,decode() syntax error "NameError: name 'decode' is not defined"

corrected line is payload = msg.payload.decode()

On line 267 self._log.debug("Nodeid: "+str(nodeid)+" values: "+msg.payload) syntax error "TypeError: can only concatenate str (not "bytes") to str"

corrected line is self._log.debug("Nodeid: "+str(nodeid)+" values: "+str(msg.payload))

delboy711 avatar Dec 17 '22 11:12 delboy711