Running a command alongwith pip gives the following error. Even the command pip -V produces the following error. I read that the error is due to setuptoo
pip -V
Upgrade your setuptools: wget https://bootstrap.pypa.io/ez_setup.py -O - | sudo python3
wget https://bootstrap.pypa.io/ez_setup.py -O - | sudo python3
Generally sudo combined with pip is considered harmful, avoid this when your system is not already broken.