I get an error when I execute python2 -m pip freeze
this command.
The error message is as below:
/usr/bin/python: cannot import name HashMissing; 'pip' is a package and cannot be directly executed
I had used apt-get remove --purge python python-pip
fo removing the python2.
Then, I do these path checking for knowing pip and python command path.
john@mymachine:~$ whereis python python: /usr/bin/python /usr/bin/python3.4m /usr/bin/python3.4 /usr/bin/python2.7 /usr/bin/python2.7-config /usr/lib/python3.4 /usr/lib/python2.7 /etc/python3.4 /etc/python2.7 /usr/local/lib/python3.4 /usr/local/lib/python2.7 /usr/include/python2.7 /usr/share/python /usr/share/man/man1/python.1.gz john@mymachine:~$ which -a pip /usr/local/bin/pip jonh@mymachine:~$ whereis pip pip: /usr/local/bin/pip /usr/local/bin/pip3.5 /usr/local/bin/pip2.7 /usr/local/bin/pip3.4 john@mymachine:~$ which -a python /usr/bin/python
Wish some help.
pip freeze
– Samuel Muiruri