Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

python example does not work any more #103

Closed
wenwenchenbosch opened this issue Jun 18, 2021 · 3 comments
Closed

python example does not work any more #103

wenwenchenbosch opened this issue Jun 18, 2021 · 3 comments
Assignees
Labels
bug Something isn't working

Comments

@wenwenchenbosch
Copy link

I got the following warning, when I run the python basic example

python run.py
2021-06-18T14:55:54.019Z INFO [ 61872ecc-79fe-4471-a764-1a010ad8a150.MqttClient-8bc83b20 ]: *****INFO***** Using topic namespace iotea/
2021-06-18T14:55:54.019Z INFO [ Talent.python-basic-talent-4497ba31 ]: Talent python-basic-talent-4497ba31 started successfully
2021-06-18T14:55:54.019Z INFO [ 61872ecc-79fe-4471-a764-1a010ad8a150.MqttClient-8bc83b20 ]: Connecting to mqtt://localhost:1883 ...
2021-06-18T14:55:54.023Z WARNING [ hbmqtt.mqtt.protocol.handler ]: Unhandled exception: 'Lock' object is not iterable
Connection failed: TypeError("'Lock' object is not iterable")
2021-06-18T14:55:55.025Z WARNING [ hbmqtt.mqtt.protocol.handler ]: Unhandled exception: 'Lock' object is not iterable
Reconnection attempt failed: TypeError("'Lock' object is not iterable")
2021-06-18T14:55:57.028Z WARNING [ hbmqtt.mqtt.protocol.handler ]: Unhandled exception: 'Lock' object is not iterable
Reconnection attempt failed: TypeError("'Lock' object is not iterable")
2021-06-18T14:55:59.030Z WARNING [ hbmqtt.mqtt.protocol.handler ]: Unhandled exception: 'Lock' object is not iterable
Reconnection attempt failed: TypeError("'Lock' object is not iterable")
2021-06-18T14:56:01.033Z WARNING [ hbmqtt.mqtt.protocol.handler ]: Unhandled exception: 'Lock' object is not iterable

After I send events using mqtt tool node cli.js pub -c "mqtt://localhost:1883" -t "iotea/ingestion/events" -f "../../sdk/python/examples/basic/events.txt" --times 1 --delayMs 2000 --transform iotea.ts-now.jna
no event reached the basic example.

I am using python 3.9.5.

@llakie
Copy link
Collaborator

llakie commented Jun 22, 2021

@mariaivanova-git Can you check, if it has anything to do with the protocol gateway implementation

@llakie llakie added the bug Something isn't working label Jun 22, 2021
@mariaivanova-git
Copy link
Collaborator

The error seems to be due to the incompatibility of hbmqtt with python3.9 (njouanin/hbmqtt#223)
and has been recorded before (#47).

Unfortunately hbmqtt does not provide a fix, so for the moment using a python version 3.7 or 3.8 could be the solution.

@llakie
Copy link
Collaborator

llakie commented Jun 30, 2021

Fixed by PR #113

@llakie llakie closed this as completed Jun 30, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants