Django - ImproperlyConfigured: Module “django.contrib.auth.middleware”

后端 未结 13 610
我寻月下人不归
我寻月下人不归 2020-12-30 19:25

I\'m running a virtualenv to try to learn Django, but for whatever reason after installing Django and when I try to access the default Django start page, I get the following

相关标签:
13条回答
  • 2020-12-30 20:10

    I encountered an issue similar to this today (Using OS X Mavericks).

    First of all, do you have django installed to your base OS? Before using Virtualenv I was running Django directly on the OS. The main thing I noticed is I usually type django-admin, not django-admin.py. This was calling Django outside of the virtualenv, which was version 1.7.1.

    Outside of my virtualenv I ran pip uninstall django, then went back into my Virtualenv. Running django-admin --version without a .py at the end returned "zsh: command not found: django-admin" (it used to return 1.7.1), however, running django-admin.py --version returned 1.6.5.

    Check to make sure you aren't accidentally bringing in an outside version of django directly from your OS, you may need to type django-admin.py

    0 讨论(0)
提交回复
热议问题