Open TiboVZ-r opened 9 months ago
I had to update the setup.py in the azure-iot-hub to get it installed. The setup.py for azure-iot-hub is explicitly excluding the azure folder. Don't understand why. I am using yocto for building for my target and could not find any recipe for the azure-iot-hub so I had to create my own and to get it to work I had to patch the setup.py. To be honest not sure if the azure-iot-hub module should actually be running on the device or if it is more for management and is more for a backend or application. Anyway once I got the setup.py patched I got it installed but then I got other dependencies issues that was missing so currently I have still not been able to get a fully working azure-iot-hub stack working on my target. I have no problem getting azure-iot-device working so that is why I am second guessing if the idea is to really have azure-iot-hub running on the device. You can find the setup.py at
https://github.com/Azure/azure-iot-hub-python/blob/main/setup.py#L87
On a Beaglebone Black, I want to run some python code making use of this package. The device is on Debian 11. Using python 3.9 Virtual environment is selected with source activate.
After running pip install azure-iot-hub or pip3 ..., the install process looks as normal. Yet python code fails to run when trying to import the modules from azure.iot.hub.
When taking a look at venv/lib/pyhton3.9/site-packages/azure, "iot" folder does not exist. After searching online, it popped up several times. People suggested to build the wheel locally. This is not a good idea since the beaglebone has really limited hardware.
We can download the "wheel" on pypi. When I do pip install ...whl, it gives the same behaviour.
Yet when I just unzip and copy the 'iot' folder to venv/lib/pyhton3.9/site-packages/azure/, everything works as expected. This is not a good way since it requires manual action and is hard to automate in pipelines. (in comparison to requirements file)
Is this expected behavior for armv7? Should this work or is just doing "pip3 install azure-iot-hub" wrong?