Home > Blockchain >  pip list returns -bash: pip: command not found
pip list returns -bash: pip: command not found

Time:05-04

I am checking the documentation and there are basically two ways to install pip.

python -m ensurepip --upgrade

Looking in links: /var/folders/d0/gnksqzwn2fn46fjgrkp6045c0000gn/T/tmpe2ll6upv
Requirement already satisfied: setuptools in /Applications/Anaconda/anaconda3/lib/python3.9/site-packages (58.0.4)
Requirement already satisfied: pip in /Applications/Anaconda/anaconda3/lib/python3.9/site-packages

All the packages are in /Applications/Anaconda/anaconda3/lib/python3.9/site-packages directory including pip.

However, when I run pip list from base environment, I get:

-bash: pip: command not found

I am getting module not found error when running my application.

My application was running fine until I tried to upgrade a python package. What did I mess up? What do I need to check?

CodePudding user response:

Try this python -m pip list instead of python pip list

CodePudding user response:

It could be that pip might not be installed or it could be the version of the pip might not be compatible with the current version.

pip used for python2, use pip3 for python3 and upgrade your pip and retry once.

python -m pip install --upgrade pip
  • Related