You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Calling client.publish(topic, payload, qos=0) results in the message being handled as sent (client.on_publish function is executed)
But if the python script ends after the publish call, the message does not get sent.
Adding a time.sleep(1) after client.publish(...) consistently sends the message.
The text was updated successfully, but these errors were encountered:
If you want to publish a message and ensure it's left the client before exiting then use single. The library queues publish requests so 'Publish` is likely to return before the message is actually sent.
Closing this for now - if you still have an issue then feel free to reopen but please provide a full example.
Calling client.publish(topic, payload, qos=0) results in the message being handled as sent (client.on_publish function is executed)
But if the python script ends after the publish call, the message does not get sent.
Adding a time.sleep(1) after client.publish(...) consistently sends the message.
The text was updated successfully, but these errors were encountered: