Pergunta

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

Foi útil?

Solução

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.

Outras dicas

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.

Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top