DEV Community

Discussion on: Stop using sudo pip install

Collapse
 
phydroxide profile image
phydroxide

What about for pip install --upgrade pip

"ERROR: Could not install packages due to an EnvironmentError: [Errno 13] Permission denied: '/usr/bin/pip3'
"

How do you get pip into /usr/bin without running it privileged?

Collapse
 
elabftw profile image
eLabFTW

You don't, that's the whole point. Unless you give your user permissions to write in /usr/bin, which is not a good idea.

Collapse
 
vikrantsingh47 profile image
vikrant singh

should we install pip itself with sudo?
eg: sudo apt install python3-pip
and then ,
pip install --upgrade pip

is that corrent process?