Django2.1遇到 app_label and isn't in an application in INSTALLED_APPS 错误

在Django2.1中,遇到'app_label'不在INSTALLED_APPS错误,尝试注释不用的app无效。解决方案是在settings中添加相应app到INSTALLED_APPS列表,重启项目后恢复正常。
摘要由CSDN通过智能技术生成

Django在应用列表中添加新的应用时有时会出错

INSTALLED_APPS = [
    'django.contrib.admin',
    'django.contrib.auth',
    'django.contrib.contenttypes',
    'django.contrib.sessions',
    'django.contrib.messages',
    'django.contrib.staticfiles',
    'django.contrib.sites',
    'news_web',
    'DjangoUeditor',
    'mdeditor',
    'django_markdown',
    'markdownx',
    #'fluent_contents',
]

启动项目时报错为

Unhandled exception in thread started by <function check_errors.<locals>.wrapper at 0x7efe941f08c8>
Traceback (most recent call last):
  File "/usr/local/lib/python3.6/site-packages/Django-2.1-py3.6.egg/django/utils/autoreload.py", line 225, in wrapper
    fn(*args, **kwargs)
  File "/usr/local/lib/python3.6/site-packages/Django-2.1-py3.6.egg/django/core/management/commands/runserver.py"
评论 6
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值