Public bug reported:

This is specifically a problem with the debundling of the pip package,
see https://github.com/pypa/pip/issues/6149 for further discussion.

Environment
pip version: python-pip (9.0.1-2.3)
Python version: Python 2.7.15+
OS: Ubuntu 18.10

Description
The python-pip package (at least on Ubuntu 18.10) depends on the 
python-configparser package, which dumps a blank __init__.py into the 
/usr/lib/python2.7/dist-packages/backports directory. However, backports should 
instead be defined as a namespace package (see PEP 420 and 
https://pypi.org/project/backports/). While this is not good in general, this 
is particularly problematic for pip because the some of packages it installs do 
not work as a result!

Expected behavior
pip should be able to install backports packages, which can then be imported 
without error.

How to Reproduce
After installing python-pip, run command pip install backports.shutil_which 
(the specific backports package does not particularly matter)
Then run from backports.shutil_which import which inside a python shell
An error occurs.

Output
>>> from backports.shutil_which import which
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ImportError: No module named shutil_which```

** Affects: python-pip (Ubuntu)
     Importance: Undecided
         Status: New

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1812589

Title:
  pip's configparser dependency breaks backports namespace conventions

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/python-pip/+bug/1812589/+subscriptions

-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to