119

I have tried entering:

sudo apt install python3-pip

The error I get is:

$ sudo apt install python3-pip  
Reading package lists... Done 
Building dependency tree        
Reading state information... Done 
The following additional packages will be installed:
    libexpat1-dev libpython3-dev libpython3.5-dev python-pip-whl python3-dev python3-wheel python3.5-dev 
The following NEW packages will be installed:
    libexpat1-dev libpython3-dev libpython3.5-dev python-pip-whl python3-dev python3-pip python3-wheel python3.5-dev 0 to upgrade, 8 to newly install, 0 to remove and 0 not to upgrade. 
Need to get 1,219 kB/39.1 MB of archives. 
After this operation, 56.8 MB of additional disk space will be used. 
Do you want to continue? [Y/n] y 
Ign:1 au.archive.ubuntu.com/ubuntu xenial-updates/universe i386 python-pip-whl all 8.1.1-2ubuntu0.1 
Ign:2 au.archive.ubuntu.com/ubuntu xenial-updates/universe i386 python3-pip all 8.1.1-2ubuntu0.1 
Err:1 au.archive.ubuntu.com/ubuntu xenial-updates/universe i386 python-pip-whl all 8.1.1-2ubuntu0.1
    404  Not Found 
Err:2 au.archive.ubuntu.com/ubuntu xenial-updates/universe i386 python3-pip all 8.1.1-2ubuntu0.1
    404  Not Found
E: Failed to fetch http://au.archive.ubuntu.com/ubuntu/pool/universe/p/python-pip/python-pip-whl_8.1.1-2ubuntu0.1_all.deb 
    404  Not Found
E: Failed to fetch http://au.archive.ubuntu.com/ubuntu/pool/universe/p/python-pip/python3-pip_8.1.1-2ubuntu0.1_all.deb
    404  Not Found
E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing?

I believe we have bypassed the proxy, so I'm not sure why I'm getting '404 file not found'.

3
  • 3
    Try again running sudo apt-get update
    – muru
    May 27 '16 at 3:51
  • Works from home fine, but I have Linux machines at the school I teach at, which have a proxy which I thought we had bypassed for ubuntu.com, but looks like I haven't somehow...
    – Abisdad
    May 28 '16 at 13:15
  • 1
    So this has nothing to do with Ubuntu but your network configuration then. Jul 12 '16 at 14:33
199

The first procedure you followed is correct

sudo apt-get -y install python3-pip

But before installing try to update using command

sudo apt-get update

If first did not work then you can also do this using curl

curl "https://bootstrap.pypa.io/get-pip.py" -o "get-pip.py"
python3 get-pip.py --user

Then to verify installation try

pip3 --help 

For checking version :

pip3 --version 
8
  • 2
    Thank you! But it needed: "pip3 --help"
    – Abisdad
    May 28 '16 at 13:11
  • 2
    curl -sS https://bootstrap.pypa.io/get-pip.py | sudo python
    – PvdL
    Jul 12 '16 at 21:29
  • 1
    Interesting! Why do you need the 'sudo apt-get update' to install pip3? seems rather unexpected to me. Dec 16 '16 at 3:38
  • This does not work for pip3, it installs pip2 script which python3 can't run.
    – rjurney
    Jan 13 '17 at 19:14
  • 10
    curl -sS https://bootstrap.pypa.io/get-pip.py | sudo python3 for Python 3 ;)
    – mbdevpl
    Jan 24 '17 at 1:09
2

I fixed such problem by changing Server in "Software & Updates" -> Download from: there I chose different address and 404 disappeared.

1
  • 2
    what address did you choose? please add more details
    – TiloBunt
    Aug 24 '16 at 20:14
2

what worked for me

curl -sS https://bootstrap.pypa.io/get-pip.py >>setup.py
python3 setup.py

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.