Azure-Samples / iot-hub-python-raspberrypi-client-app

This repo contains the source code to help you get started with Azure IoT using the Microsoft IoT Pack for Raspberry Pi 3 Starter Kit. You will find the full tutorial on docs.microsoft.com.
MIT License
51 stars 44 forks source link

Python 3 #20

Open CurtisWJohnson opened 5 years ago

CurtisWJohnson commented 5 years ago

The python3 command python3 app.py '<your Azure IoT hub device connection string>' does not work but python2 app.py '<your Azure IoT hub device connection string>' does work.

sandeepnegi1996 commented 5 years ago

yes you are right in python 3 it is showing import error can anyone rectify it

markpatterson27 commented 5 years ago

Did you install the python 3 modules and not just the python 2 modules?

i.e. pip3 install azure-iothub-device-client, pip3 install azure-iothub-service-client. Or if you're building the C libraries, sudo ./setup.sh --python-version 3.5