7

I have 14.04. I read on the pip readthedocs that pip is included by default with Python 3. When I installed Python 3 on Windows it was there, but I'm getting pip command not found on Ubuntu. I checked dpkg and it is not there. I also looked at the Ubuntu Python 3 port page and did not see anything. If pip is here, where do I find it and get it working? If it is not here, why and what else is missing from the default Python 3 that I should know about so I don't waste time looking for it?

karel
  • 110,292
  • 102
  • 269
  • 299
Malik A. Rumi
  • 533
  • 3
  • 9
  • 16
  • 2
    `pip3` is provided by [`python3-pip`](http://packages.ubuntu.com/search?searchon=contents&keywords=bin%2Fpip3&mode=exactfilename&suite=trusty&arch=any). – muru Apr 01 '15 at 09:23

1 Answers1

5

Open the terminal and type:

sudo apt-get install python3-pip  

python3-pip is the Python 3 version of the alternative Python package installer. This program is run from a terminal using: pip3.

Another program that is bundled with the default implementation of Python in Windows and is a separate package in Ubuntu is the IDLE Integrated Development Environment for Python 3 (idle3). I don't use IDLE myself. I much prefer Spyder (spyder3).

karel
  • 110,292
  • 102
  • 269
  • 299
  • 1
    Just to be clear: Is the command for pip3 pip, pip3, or pip-3.2, as in this answer http://superuser.com/questions/769920/python3-pip-installed-but-pip3-command-not-found – Malik A. Rumi Apr 02 '15 at 23:06
  • I was anticipating the some additional questions that weren't in your original question such as what about Enhanced interactive Python shell (*ipython3*) and Python 3 virtual environment creator (*python3-venv*)? python3-venv is in the default Ubuntu repositories starting with Ubuntu 14.10. The command to install a package using the pip3 (from the Ubuntu repos) is: `sudo pip3 install some-package-name`. The command to uninstall a package using pip3 is: `sudo pip3 uninstall some-package-name`. These commands are for a global install. The same commands without sudo are used for a local install – karel Apr 03 '15 at 03:53
  • 1
    Even though I did `sudo apt install python3.8` and the current Ubuntu python is 3.7, this answer worked for me. – Boris Verkhovskiy Aug 11 '19 at 04:29
  • Well this does _not_ work for me on `python3.8` `$ pip3 -V pip 9.0.1 from /usr/lib/python3/dist-packages (python 3.6)` – WestCoastProjects Apr 01 '20 at 21:25
  • @javadba try `python3.8 -m pip install ` – Boris Verkhovskiy Apr 01 '20 at 21:28
  • @Boris That's looking good. thanks. Note that `pip3.8` _does_ work on `macos`. Strange. – WestCoastProjects Apr 01 '20 at 21:36
  • Not really. It would give me `pip` for python3.6 although I have 3.8 installed. – Qumber Aug 01 '20 at 14:50
  • But still note that as of 2020, for Bionic 18.04, python3-pip is *very* out-of-date, at version 9.0.1-2.3~ubuntu1.18.04.4. So much has changed in the last 2 years! – nealmcb Oct 28 '20 at 03:50
  • 1
    @nealmcb The default version of python3-pip has been upgraded in Ubuntu 20.04 to 20.0.2-5ubuntu1.1. That's a big version upgrade. – karel Oct 28 '20 at 03:52
  • The approach I'd suggest on older systems is to ignore the old hard-to-upgrade system pip, and just install python3.x-venv, then use that to create virtual environments via `python3.x -m venv ...`, which automatically install a pip local to the venv, which can then be actived and used to upgrad the pip via `pip install -U pip`. – nealmcb Oct 28 '20 at 04:26