#5290 Ensuring integer for mqtt port, needed by paho-mqtt
Merged by ngompa. Opened by arrfab.
arrfab/pagure mqtt_paho_fix  into  master

Download 5290.patch

Current pagure code using paho-mqtt is triggering issue :

remote: 2022-04-29 14:58:46,500 [ERROR] pagure.lib.notify: Error sending mqtt message
remote: Traceback (most recent call last):
remote:   File "/usr/lib/python3.6/site-packages/pagure/lib/notify.py", line 201, in mqtt_publish
remote:     client.connect(mqtt_host, mqtt_port)
remote:   File "/usr/lib/python3.6/site-packages/paho/mqtt/client.py", line 936, in connect
remote:     bind_address, bind_port, clean_start, properties)
remote:   File "/usr/lib/python3.6/site-packages/paho/mqtt/client.py", line 1002, in connect_async
remote:     if port <= 0:
remote: TypeError: '<=' not supported between instances of 'str' and 'int'

The proposed fix is just to force integer (tested to be working on https://git.dev.centos.org, running pagure 5.13)

Signed-off-by: Fabian Arrotin arrfab@centos.org

:thumbsup:

Pull-Request has been merged by ngompa

Metadata