django-admin runserver给出错误django.core.exceptions.ImproperlyConfigured

时间:2018-12-19 16:43:10

标签: python django exception django-admin environment-variables

我是Python Django的初学者。我的Django项目运行正常。但是我不知道何时运行命令

django-admin runserver

我遇到错误,请帮我一下突然发生了什么。它发生在所有Django项目中。该如何解决?

django.core.exceptions.ImproperlyConfigured: Requested setting DEBUG, but settings are not configured. You must either define the environment variable DJANGO_SETTINGS_MODULE or call settings.configure() before accessing settings.

0 个答案:

没有答案