Forums

No module named django.core.management on python manage.py

mkvirtualenv django1 --python=/usr/bin/python3.4 workon django17 python manage.py shell

File "manage.py", line 8, in <module> from django.core.management import execute_from_command_line ImportError: No module named django.core.management

This just started happening today.

Does anyone know a solution?

Thank you.

Using python3.5 manage.py shell instead seems to work....

Does anyone know why python3.4 would stop working?

I guess it's possible I neglected to use --python=/usr/bin/python3.4 in the mkvirtualenv command last time.

Not sure.

What does python --version return when you have your virtualenv activated?

Hi, Python 2.7.6

it certainly sounds like your virtualenv is not using the correct python version. try recreating it?