eclipse-paho / eclipse-paho/paho.mqtt.python

on_pre_connect not optional?

Open
#703 12 comments 1 reaction 0 assignees View on GitHub
Status: Available Status: More info needed
Dominant language
Python
Stars
2.4k
Forks
742
Avg merge
12d 48m
Merged PRs (30d)
1

Description

Hi,

I just migrated a ( rather large) script to 1.6.1, and for some reason I had to add something like this

```
self.client.on_pre_connect = self.on_pre_connect

def on_pre_connect(self, *args):
"""This seems to be needed due to a bug in paho-1-6-1"""
self.logger.debug('running on_pre_connect, apparently paho needs this now')
```

for it to connect. Otherwise it would complain about the missing overwrite above. After quickly glancing at the code this seems to be meant as optional, which for me it apparently is not.

KR,
Moritz

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.