Carl Tidén Carl Tidén - 2 months ago 15
Linux Question

How to get pip3 to work on Linux

I successfully installed Python 3.5.2 on my CentOS 6.5 system. I'm trying to get pip to work with this version of Python to be able to install some modules.

When I run

$ pip3 install ...
it says command not found.

I also tried to run:

$ sudo yum install python3-pip


but that just returns:
No package python3-pip available.


I also did:

$ python3 get-pip.py


But it says:

zipimport.ZipImportError: can't decompress data; zlib not available


How am I supposed to get this working?

Answer

zipimport.ZipImportError: can't decompress data; zlib not available

Then get ZLIB

yum install zlib-devel 

pip 8.1.1 requires SSL/TLS

Then get SSL...

yum install openssl-devel
python3 -m ensurepip

In any case, since the pip version is being printed, you already have pip installed, you just need to determine why it won't run