3

I managed to install virtualenv, install django-1.4-alpha-1 via pip install and am trying to start a django with it's manage.py runserver

Eventhough I switched with virtualenv via activate (note the prefix in cmd screen bellow) to the right enviroment (where I successfully installed django), manage.py runserver still somehow grabs data from my stable not-virtualenv python install.

Stable python (wrong one): D:\Python26\Scripts

Right one: E:\Prace\django-1.4-alpha-1\Scripts

My PATH doesn't include anything with Python.

Cmd screen:

enter image description here

diegueus9
  • 29,351
  • 16
  • 62
  • 74
mreq
  • 6,414
  • 4
  • 37
  • 57

2 Answers2

3

Files with the .py extension are linked to your default Windows Python installation. One way of using your virtualenv python executable instead is by typing python manage.py <command> instead.

Please also see the accepted answer of a question I posted on this matter before.

Community
  • 1
  • 1
Mathieu Dhondt
  • 8,405
  • 5
  • 37
  • 58
1

You don't specify which version of virtualenv you're using. Recently, they've made --no-site-packages default, but if you're using a version before this change was instituted, you need to specify that switch to prevent the main site-packages from loading in.

Chris Pratt
  • 232,153
  • 36
  • 385
  • 444