Skip to content

ImportError: libffi.so.7: cannot open shared object file: No such file or directory #18703

@UnexpectedGrit-3853

Description

@UnexpectedGrit-3853

az feedback auto-generates most of the information requested below, as of CLI version 2.0.62

Describe the bug

On Linux Ubuntu 21.04, I need the command, "az extension add --name azure-iot" to work in "pwsh", but it seems I am blocked by the check that says, "... Could not find a version that satisfies the requirement paho-mqtt==1.5.0 (from azure-iot)" Followed by the statement, "... No matching distribution found for paho-mqtt==1.5.0"

It appears the latest version of "paho-mqtt" is 1.5.1, NOT 1.5.0, and perhaps this is the cause of the error.

The version of Linux I'm using is:
lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 21.04
Release: 21.04
Codename: hirsute

It is my understanding that Azure CLI is NOT tested on Ubuntu version 21.04, and yet needs to be tested on 21.04

A more detailed description of the bug I encountered can be found recorded on the Microsoft Q&A Forum link here: https://docs.microsoft.com/en-us/answers/questions/452610/what-to-do-if-linux-34pwsh34-az-extension-add-name.html#answer-454757

To Reproduce

/*** Although I did not setup this machine, I believe the Lab guys followed the given steps below.
NOTE: This is a Linux Ubuntu 21.04 Lab machine. We use BOTH Azure CLI AND Azure via "pwsh" (Power Shell) to perform
various types of Azure testing on SubZero products.
***/

  1. Download Ubuntu 21.04 ( https://ubuntu.com/download/desktop )

  2. Install Python 3.9 on Linux
    sudo apt update
    sudo apt install software-properties-common
    sudo add-apt-repository ppa:deadsnakes/ppa
    sudo apt install python3.9
    sudo apt-get install python-pip

  3. Linux Azure CLI Install (with one command)
    curl -sL https://aka.ms/InstallAzureCLIDeb | sudo bash

  4. pip3 install azure-eventhub
    pip3 install azure-iot-hub
    pip3 freeze /* To show installed python packages */

  5. pwsh

    az extension add --name azure-devops
    az extension list
    az extension add --name azure-iot --debug

ERROR: Could not find a version that satisfies the requirement paho-mqtt==1.5.0 (from azure-iot)
ERROR: No matching distribution found for paho-mqtt==1.5.0
Exception information:
Traceback (most recent call last):
File "/opt/az/lib/python3.6/site-packages/pip/_internal/resolution/resolvelib/resolver.py", line 122, in resolve
requirements, max_rounds=try_to_avoid_resolution_too_deep,
File "/opt/az/lib/python3.6/site-packages/pip/_vendor/resolvelib/resolvers.py", line 453, in resolve
state = resolution.resolve(requirements, max_rounds=max_rounds)
File "/opt/az/lib/python3.6/site-packages/pip/_vendor/resolvelib/resolvers.py", line 357, in resolve
raise ResolutionImpossible(causes)
pip._vendor.resolvelib.resolvers.ResolutionImpossible: [RequirementInformation(requirement=SpecifierRequirement('paho-mqtt==1.5.0'), parent=LinkCandidate('file:///tmp/tmplxtmlhhr/azure_iot-0.10.13-py3-none-any.whl'))]

Expected behavior

  1. pwsh

    az extension add --name azure-iot --debug
    /*** Linux Ubuntu 21.04 Power Shell extension "azure-iot" added Successfully! ***/

Environment summary

The installation method was not automated (i.e. via Lab operator interacting with Linux 21.04 terminal)

Additional context

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions