1

I'm running CentOS and trying to install openstack. If I install libvirt-python, it will install the latest version e.g.

pip install --user libvirt-python
Collecting libvirt-python
Installing collected packages: libvirt-python
Successfully installed libvirt-python-4.10.0

However, the upper_constraints.txt (which is dynamically updated at runtime, not sure where it's getting set) lists libvirt-python===3.10.0

If I uninstall libvirt-python and try to install 3.10.0 I'm getting a wheel error (see below). Can anyone help me with this?

    pip install --user libvirt-python==3.10.0
    Collecting libvirt-python==3.10.0
    Using cached 
https://files.pythonhosted.org/packages/20/b3/d7e226a07efa1432a4dcf92b3baa0cf554241a7eecd8a654c23c2119b190/libvirt-python-3.10.0.tar.gz
Building wheels for collected packages: libvirt-python
  Running setup.py bdist_wheel for libvirt-python ... error
  Complete output from command /usr/bin/python -u -c "import setuptools, tokenize;__file__='/tmp/pip-install-Ry0ikH/libvirt-python/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" bdist_wheel -d /tmp/pip-wheel-GwcOJA --python-tag cp27:
  running bdist_wheel
  running build
  /usr/bin/pkg-config --print-errors --atleast-version=0.9.11 libvirt
  /usr/bin/python generator.py libvirt /usr/share/libvirt/api/libvirt-api.xml
  Found 446 functions in /usr/share/libvirt/api/libvirt-api.xml
  Found 0 functions in libvirt-override-api.xml
  Generated 355 wrapper functions
  Missing type converters:
  virNWFilterBindingPtr:8
  virTypedParameterPtr *:2
  virNWFilterBindingPtr **:1
  char **:1
  ERROR: failed virConnectBaselineHypervisorCPU
  ERROR: failed virConnectListAllNWFilterBindings
  ERROR: failed virDomainGetLaunchSecurityInfo
  ERROR: failed virNWFilterBindingCreateXML
  ERROR: failed virNWFilterBindingDelete
  ERROR: failed virNWFilterBindingFree
  ERROR: failed virNWFilterBindingGetFilterName
  ERROR: failed virNWFilterBindingGetPortDev
  ERROR: failed virNWFilterBindingGetXMLDesc
  ERROR: failed virNWFilterBindingLookupByPortDev
  ERROR: failed virNWFilterBindingRef
  ERROR: failed virNodeGetSEVInfo
  error: command '/usr/bin/python' failed with exit status 1

Failed building wheel for libvirt-python
  Running setup.py clean for libvirt-python
Failed to build libvirt-python
Installing collected packages: libvirt-python
  Running setup.py install for libvirt-python ... error
    Complete output from command /usr/bin/python -u -c "import setuptools, tokenize;__file__='/tmp/pip-install-Ry0ikH/libvirt-python/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-record-7u_zLd/install-record.txt --single-version-externally-managed --compile --user --prefix=:
running install
running build
/usr/bin/pkg-config --print-errors --atleast-version=0.9.11 libvirt
/usr/bin/python generator.py libvirt /usr/share/libvirt/api/libvirt-api.xml
Found 446 functions in /usr/share/libvirt/api/libvirt-api.xml
Found 0 functions in libvirt-override-api.xml
Generated 355 wrapper functions
Missing type converters:
virNWFilterBindingPtr:8
virTypedParameterPtr *:2
virNWFilterBindingPtr **:1
char **:1
ERROR: failed virConnectBaselineHypervisorCPU
ERROR: failed virConnectListAllNWFilterBindings
ERROR: failed virDomainGetLaunchSecurityInfo
ERROR: failed virNWFilterBindingCreateXML
ERROR: failed virNWFilterBindingDelete
ERROR: failed virNWFilterBindingFree
ERROR: failed virNWFilterBindingGetFilterName
ERROR: failed virNWFilterBindingGetPortDev
ERROR: failed virNWFilterBindingGetXMLDesc
ERROR: failed virNWFilterBindingLookupByPortDev
ERROR: failed virNWFilterBindingRef
ERROR: failed virNodeGetSEVInfo
error: command '/usr/bin/python' failed with exit status 1

----------------------------------------
Command "/usr/bin/python -u -c "import setuptools, tokenize;__file__='/tmp/pip-install-Ry0ikH/libvirt-python/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-record-7u_zLd/install-record.txt --single-version-externally-managed --compile --user --prefix=" failed with error code 1 in /tmp/pip-install-Ry0ikH/libvirt-python/
Lar
  • 23
  • 7

2 Answers2

0

Found two upper_constraints files. One is in the python site-packages. Updated both for libvirt-python and that has fixed it (or at least moved me on to the next install error!)

Lar
  • 23
  • 7
0

it needs dev tool installation

use: apt-get install libvirt-dev to install dev tool then t

Shunya
  • 2,344
  • 4
  • 16
  • 28
SR Giri
  • 1
  • 1
  • 2
    Your answer could be improved with additional supporting information. Please [edit] to add further details, such as citations or documentation, so that others can confirm that your answer is correct. You can find more information on how to write good answers [in the help center](/help/how-to-answer). – Community Jan 04 '22 at 15:16