Pip3 ImportError: Cannot import the name "IncompleteRead"

Failed to install the modules using pip3 , tried several offers from the voted thread since December 2014, but still got the following:

 sudo pip3 install send2trash Traceback (most recent call last): File "/usr/bin/pip3", line 9, in <module> load_entry_point('pip==1.5.6', 'console_scripts', 'pip3')() File "/usr/lib/python3/dist-packages/pkg_resources/__init__.py", line 558, in load_entry_point return get_distribution(dist).load_entry_point(group, name) File "/usr/lib/python3/dist-packages/pkg_resources/__init__.py", line 2682, in load_entry_point return ep.load() File "/usr/lib/python3/dist-packages/pkg_resources/__init__.py", line 2355, in load return self.resolve() File "/usr/lib/python3/dist-packages/pkg_resources/__init__.py", line 2361, in resolve module = __import__(self.module_name, fromlist=['__name__'], level=0) File "/usr/lib/python3/dist-packages/pip/__init__.py", line 74, in <module> from pip.vcs import git, mercurial, subversion, bazaar # noqa File "/usr/lib/python3/dist-packages/pip/vcs/mercurial.py", line 9, in <module> from pip.download import path_to_url File "/usr/lib/python3/dist-packages/pip/download.py", line 25, in <module> from requests.compat import IncompleteRead ImportError: cannot import name 'IncompleteRead' 

On Ubuntu 15.10; tried to completely remove python 3 and reinstall while still having problems. Help?

Edit: UPDATE: Tried to use my bootable USB to restore Ubuntu and return to the original configuration and reinstall via sudo apt-get install python3-pip, but now it generates a crash report saying:

 Sorry, the application pip3 has unexpectedly crashed. 
+7
python pip
source share
4 answers

This seems to be a problem with pip interacting with the requests package . requests removed the IncompleteRead module, but older versions of the pip that you have still rely on it, newer versions do not.

You should try updating pip through easy_install-3.5 (if you have Python 3.5 ) or easy_install-3 for other versions:

 sudo easy_install-3.5 -U pip 

or:

 sudo easy_install-3 -U pip 

and you should be good to go.

+15
source share

Had a similar error on Raspberry Pi. The solution was a combination of all the above suggestions:

  sudo pip install --upgrade pip sudo pip install --upgrade requests sudo easy_install3 -U pip 
+3
source share

This happened when I tried installing the pip module on my Python3 installation. I mistakenly run pip instead of pip3 , and it installed the Python2 modules in the Python3 installation. After that, I realized that the command was wrong, I started pip3 this time. But it wasn’t good, the installation was blown up, errors in Python2 like brackets were missing from the print statement (obviously, this is an error for Python3). In the end, he also blew up my terminal, I needed to install another terminal.

Like you, I tried to install and reinstall everything, but it did not work. You need to fix it manually. After trying for several days and failing, I backed up my files and reinstalled Ubuntu.

I know that this is not what you want, but perhaps you can save your time by accepting the fact that reinstalling the OS is the easiest solution.

0
source share

Make sure you install the latest pip and query versions:

 pip install --upgrade pip pip install --upgrade requests 
-one
source share

All Articles