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
While looking for an alternative to the native Python client due to a "limitation" (eclipse-paho/paho.mqtt.python#348), I stumbled upon the hidden Python (2.7) module in https://github.com/eclipse/paho.mqtt.c/tree/master/test/python.
As far as I could test, it seems to (still) work.
Actually, kind of, there appears to be an issue with memory management.
But it behaves differently between running in Debian and in Alpine?!?
I've made a quick demo in https://github.com/dalbani/paho-mqtt-c-python-binding to show what I'm talking about.
My findings are so far the following when publishing messages:
with the Alpine image, the heap keeps growing
with the Debian image, it doesn't go so far and fails quickly (free(): invalid pointer)
Independently from these issues, what's the status of this module?
In any case, wouldn't there be a use for such a Python binding of the C library?
The text was updated successfully, but these errors were encountered:
I haven't looked at it for a long time, partly because of the existence of the Python client and I was told that it wouldn't be useful due to the overhead of maintenance for multiple versions of Python. There undoubtedly will be issues as it was a prototype to show the basic principles. I had contemplated using SWIG (http://www.swig.org/) rather than a hand cranked Python interface, but it has got no further than being an idea so far.
Thanks for your response!
I suppose that using SWIG would indeed bring the full API to Python. But I personally have no time / knowledge on how to do it.
In the meantime, I've managed to produce a Docker image where no memory-related errors are generated.
For those curious/interested, see https://github.com/dalbani/paho-mqtt-c-python-binding.
Works fine in Debian and Alpine, with no memory leak and such as far as I am aware.
While looking for an alternative to the native Python client due to a "limitation" (eclipse-paho/paho.mqtt.python#348), I stumbled upon the hidden Python (2.7) module in https://github.com/eclipse/paho.mqtt.c/tree/master/test/python.
As far as I could test, it seems to (still) work.
Actually, kind of, there appears to be an issue with memory management.
But it behaves differently between running in Debian and in Alpine?!?
I've made a quick demo in https://github.com/dalbani/paho-mqtt-c-python-binding to show what I'm talking about.
My findings are so far the following when publishing messages:
free(): invalid pointer
)Independently from these issues, what's the status of this module?
In any case, wouldn't there be a use for such a Python binding of the C library?
The text was updated successfully, but these errors were encountered: