Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Reinstalling requirement file using pip

Tags:

pip

django

I try to reinstall requirements for my project using pip but I get this error. There is a previous failed installation. how can I delete it and proceed ?

E:\projects\project course\tkz>pip install -r requirements.txt
Downloading/unpacking Django==1.5.4 (from -r requirements.txt (line 1))
pip can't proceed with requirement 'Django==1.5.4 (from -r requirements.txt (lin
e 1))' due to a pre-existing build directory.
location: c:\users\sina\appdata\local\temp\pip_build_sina\Django
This is likely due to a previous installation that failed.
pip is being responsible and not assuming it can delete this.
Please delete it and try again.

Cleaning up...
like image 615
gabi Avatar asked Jan 23 '14 22:01

gabi


2 Answers

Use:

pip uninstall Django==1.5.4

or

pip uninstall -r requirements.txt

If that still doesn't work, then go into you Python/Lib/site-packages directory where these packages live, and delete them. Then re-run

pip install -r requirements.txt

and that should work.

like image 130
Aaron Lelevier Avatar answered Sep 23 '22 01:09

Aaron Lelevier


You can just go ahead and delete that directory, that's what the message is telling you.

like image 41
rafaponieman Avatar answered Sep 23 '22 01:09

rafaponieman