hh54188
hh54188

Reputation: 15646

virtualenv on windows installs in system site packages

I initialize my project with virtualenv through these steps(in Windows 7 OS):

$ cd myproject
$ virtualenv venv
$ venv\scripts\activate

and then I try to install flask

$ pip install Flask

but I found the flask isn't install in my /venv/lib/site-packages folder

it is still install in my C:/Python27/lib/site-packages folder

Is this correct? I think it should be install in the venv folder

If this is incorrect, what should I do?

Upvotes: 1

Views: 487

Answers (2)

Nafiul Islam
Nafiul Islam

Reputation: 82550

Start over with CMD. Recreate your virtualenv using only CMD. Then do a pip freeze. Things should work now. The reason why git-bash does not work is because it has only the PATH for git, and nothing else.

Upvotes: 1

Steve Barnes
Steve Barnes

Reputation: 28405

Try using the Scripts\pip.exe in your venv folder.

Upvotes: 3

Related Questions