set mqtt msgs to retain

This commit is contained in:
Andreas Wrede
2026-08-02 17:09:51 -04:00
parent 8efb8dba5f
commit 1d3a053f5d
+1 -1
View File
@@ -152,7 +152,7 @@ while session.read() == 0:
if debug:
print('* ', gc, jmsg)
print('* ', mytopic, pubproperties)
rc = client.publish(mytopic, jmsg, 0, properties=pubproperties)
rc = client.publish(mytopic, jmsg, qos=1, retain=True, properties=pubproperties)
if debug:
print("* client.publish rc=", rc)
lastmsg = msg