Strange behavior of python-pip

I use a pretty Python 3 application found on Pypi, named youtube-downloader which needs the Python module PySide2, and PySide2 requires the Shiboken2 module.
The two packages pyside2 (5.15.1-1) and python-shiboken2 (5.15.1-2) from the officials repositories are installed on my box, and youtube-downloader works perfectly, but pip list doesn’t see these two modules. pip check returns:

youtube-downloader 0.6.0 requires pyside2, which is not installed.

My python-pip (20.2-1) package is also from the officials repositories

Maybe if you go the Pip route you need to have all from Pip?

I have youtube-dl installed from official repositories personally.

youtube-downloader is not the same as youtube-dl, it is a graphical wrapper of youtube-dl.
A excerpt of pipdeptree:

  - beautifulsoup4 [required: Any, installed: 4.9.3]
    - soupsieve [required: >1.2, installed: 2.0.1]
  - lz4 [required: Any, installed: 3.1.1]
  - PySide2 [required: Any, installed: ?]
  - sqlalchemy [required: Any, installed: 1.3.20]
  - youtube-dl [required: Any, installed: 2020.11.17]

My youtube-dl (2020.11.17-1) is from the officials repositories.

You might want to consider using a virtual environment and let pip pull in the dependencies there.

1 Like

Using pip list --path /usr/lib/python3.8/site-packages > piplistglobal.txt and pamac list | grep -E -i 'python-|PySide2' > pamaclist.txt, and then comparing the two files, I have scored the python3 packages from the official’s repositories not listed by pip list. Only a small part of them is not recognized by pip:

pyside2                              5.15.1-1                    extra      53,2 Mo *
python-dbus                          1.2.16-1                    extra      556,2 ko *
python-dbus-common                   1.2.16-1                    extra      8,9 Mo *
python-shiboken2                     5.15.1-2                    extra      437,9 ko *

But all is working fine…
import PySide2 or import shiboken2 work perfectly even (even they are very case-sensitive)