Pip command not found when installing on OSX using get-pip [duplicate] - python

This question already has answers here:
bash: pip: command not found
(39 answers)
Closed 1 year ago.
It appears as though pip is installing fine (it says it "Successfully installed pip-19.1.1"), but I cannot located pip on my computer afterwards. I'm running OSX 10.14.4.
I haven't used Python recently on my Mac, and I recently upgraded to Python3 for a project, which requires me to use pip as well. I had pip already installed and working, but it kept trying to use Python 2.7, so I decided to uninstall and reinstall pip with the new version of Python. I've gone through a few tutorials to try and install pip. Most recently, I've tried the method recommended here: https://ahmadawais.com/install-pip-macos-os-x-python/, which has me run:
curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py
python get-pip.py
This appears to work just fine:
Collecting pip
Downloading https://files.pythonhosted.org/packages/5c/e0/be401c003291b56efc55aeba6a80ab790d3d4cece2778288d65323009420/pip-19.1.1-py2.py3-none-any.whl (1.4MB)
|████████████████████████████████| 1.4MB 706kB/s
Installing collected packages: pip
Found existing installation: pip 19.1.1
Uninstalling pip-19.1.1:
Successfully uninstalled pip-19.1.1
Successfully installed pip-19.1.1
However, attempting to use pip after this results in "command not found". I realize that the likely issue is that it's just not in my PATH, but I don't know how to locate it to add it to my path.
Please let me know if there's anything else that would be useful to diagnosing this. I'm pretty new to working with these tools, so I might just be missing something obvious.

You can either try:
pip3 install package-name
or you can add the locate the pip, and add if not already added into your path:
locate pip3
/usr/bin/pip3
/usr/bin/pip3.6
/usr/local/bin/pip3
/usr/local/bin/pip3.7
/usr/share/bash-completion/completions/pip3
/usr/share/bash-completion/completions/pip3.6
/usr/share/man/man1/pip3.1.gz
/usr/share/ruby/vendor_ruby/puppet/provider/package/pip3.rb
Then select the right one for your use. Generally for the fresh install (python 3), you should do (see this post):
pip3 install package-name
You can check the version using:
pip3 --version
Check this question if you have further issues.

Related

How do i permanently add the pip directory to PATH on Windows as system administrator? [duplicate]

This question already has answers here:
How do I install pip on Windows?
(40 answers)
'pip' is not recognized as an internal or external command
(39 answers)
Closed 1 year ago.
Disclaimer: in my first semester learning python and every answer I've found for this either hasn't worked or is way over my head. My Teachers Aid runs MacOS and I'm on Windows so he claims hasn't been able to help.
I'm trying to install the packages 'requests' and 'beautifulsoup' for a homework assignment. I installed pip, then requests, (through cmd prompt) and the cmd prompt says successfully installed but VSCode gives me "ModuleNotFoundError: No module named 'requests'".
I uninstalled requests then tried to reinstall and I get "Requirement already satisfied".
Then I tried to follow this YouTube video (It's short) "https://www.youtube.com/watch?v=paRXeLurjE4" And after step 3, to update pip and install packages I get the following:
"
C:\Users\honeycuttsierra\AppData\Local\Programs\Python\Python39>python -m pip install --upgrade pip
Requirement already satisfied: pip in c:\users\honeycuttsierra\appdata\local\programs\python\python39\lib\site-packages (21.1.3)
Collecting pip
Using cached pip-21.2.4-py3-none-any.whl (1.6 MB)
Installing collected packages: pip
Attempting uninstall: pip
Found existing installation: pip 21.1.3
Uninstalling pip-21.1.3:
Successfully uninstalled pip-21.1.3
WARNING: The scripts pip.exe, pip3.9.exe and pip3.exe are installed in 'C:\Users\honeycuttsierra\AppData\Local\Programs\Python\Python39\Scripts' which is not on PATH.
Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location.
Successfully installed pip-21.2.4"
So how do I add pip.exe, pip3.9.exe and pip3.exe to PATH permanently? Will this fix my issue?

Problem trying to install pillow 5.3.0 for python 3.7 [duplicate]

This question already has answers here:
How do I install pip on Windows?
(40 answers)
Closed 4 years ago.
My system is:
Win 10 64 bit
I'm trying to install Pillow for python but I can never do it, I'm new to this stuff.
I downloaded the wheel for 5.3.0 because I have 3.7, then I try to install but get this:
pip install Pillow==5.3.0
'install' is not recognized as an internal or external command,
operable program or batch file.
does anyone know a solution or better yet an easier way to download pillow?
I tried the command and it is working for me:
C:\Users>workon python37
(python37) C:\Users>pip install Pillow==5.3.0
Collecting Pillow==5.3.0
Downloading https://files.pythonhosted.org/packages/55/ea/305f61258278790706e69f01c53e107b0830ea5a4a69aa1f2c11fe605ed3/Pillow-5.3.0-cp37-cp37m-win_amd64.whl (1.6MB)
100% |████████████████████████████████| 1.6MB 3.9MB/s
Installing collected packages: Pillow
Successfully installed Pillow-5.3.0
You are using pip version 18.0, however, version 18.1 is available.
You should consider upgrading via the 'python -m pip install --upgrade pip' command.
You should check if pip is installed in your python3.7. It might be not even installed.
In your tags, you have mention Pycharm and in it, you are not installing packages with pip it has its own packages ocntrol ui.
Pycharm package install guide

How to download matplotlib for python 3.7 in windows 8?

How do you download matplotlib to windows so I can use it with python?
Every other question related to this that I've found on StackOverflow has led to the same problem which is that it keeps giving me the error:
python setup.py egg_info failed with error code 1 in C:\Users\Myname\AppData\Local\Temp\pip-install-9gc765gs\matplotlib\
Things I have tried (from the command prompt):
pip install matplotlib
pip install matplotlib-1.5.0-cp35-none-win_amd64.whl (which is the file I downloaded from SourceForge and is now stored in my computer)
pip install "matplotlib-1.5.0-cp35-none-win_amd64.whl"
python -mpip install -U matplotlib
I even tried tried:
pip install --upgrade setuptools
python -mpip install -U pip
prior to using the other commands to make sure everything was up to date.
Any help would be very appreciated.
Matplotlib has not been officially released for Python 3.7 yet.
As of this writing, a 3.7 version for Mac and Linux has been uploaded to PyPI earlier today, which means the Windows versions are probably coming very soon. pip will probably work after that.
Similarly, no 3.7 compatible versions have been put onto conda-forge or integrated into the main conda repo yet. I'm sure those will be coming in the next couple of weeks.
Until then, maybe installing from source will work?

pip stuck while "Using cached wheezy.template-0.1.167.tar.gz"

I recently had issues with my local Anaconda version and decided to reinstall it.
I chose the newest version (Anaconda 5.0.1 (Python 3.6)) and started to reinstall all my packages.
There's a problem installing pyimzml package.
To install it, I've tried:
pip install pyimzml
and
pip install git+git://github.com/alexandrovteam/pyimzML.git
Pip always gets stuck during Using cached wheezy.template-0.1.167.tar.gz.
Tried to install wheezy.template as source tarball from PyPI with pip, then it stucks at Processing c:\users\kawu\downloads\wheezy.template-0.1.167.tar.gz.
What can I do?
I solved the problem with the following steps (Windows 10 x64 machine):
Download wheezy.template tarball
Extract it and remove the nthreads=2 within the setup.py code.
Install wheezy.template with the python .\setup.py install command.
Install pyimzml
I tried many ways to install wheezy.template in my machine, like pip by network, pip/easy_install from local file, but the way above was the only way working out. I can not explain why but it works.

unable to install python pdfinterp with pip cammand

when i am installing some module like pdfinterp with pip command gives below error please share any solution.
Could not find a version that satisfies the requirement pip (from versions: )
No matching distribution found for pip
From what I understand of your question, you are trying to install the pdfinterp module, which is a part of the pdfminer package.
So, to properly install pdfinterp, you would need to run:
sudo -H pip install pdfminer
However, pdfminer is only for Python2.7! You don't specify in your question, but if you are using Python3.6, you would need to run:
sudo -H pip3 install pdfminer3k
Which downloads pdfminer3k, a "Python 3 port of pdfminer" which should mean your pdfinterp module should be downloaded with.
Hope it helps!
EDIT
Before we begin, try upgrading your pip package by running:
pip install --upgrade pip
(Or python -m pip install --upgrade pip on Windows)
This will ensure your pip packages are up-to-date.
Then, according to errors reported on the pip GitHub repo concerning pdfminer, you should be able to run the install explained in the original answer above. The reason this error is occurring for you is because at one time PEP 440 was having issues with the declaration of "prerelease detection logic":
I'm guessing pip was confused by the old N[.N]+ spelling in the PEP,
that got clarified in recent editions to N(.N)*. SOURCE
This should fix the issue, if you still have problems comment below with the error it returns and we can go from there!
Here is some additional information about the issue that was raised in error #1555 of PyPa pip's GitHub Repo.
As a side note, my machine is running the most recent version of pip and is fully functioning with pdfminer and pdfminer3k!

Categories