django.core.exceptions.ImproperlyConfigured: Requested setting LOGGING_CONFIG, but settings are not configured

前端 未结 8 1330
你的背包
你的背包 2021-02-18 18:07

I\'m trying to run a populate script which I put together from the tango_with_django tutorial (https://github.com/leifos/tango_with_django/blob/master/tango_with_django_project/

8条回答
  •  悲&欢浪女
    2021-02-18 18:45

    Call to django.setup() should go after setting DJANGO_SETTINGS_MODULE environment variable. Just move it into your __main__ right after os.environ.setdefault().

提交回复
热议问题