Django2.0运行错误解决笔记
RuntimeError: Model class models.User doesn't declare an explicit app_label and isn't in an application in INSTALLED_APPS.
- 运行环境:Pycharm2019.2.4+python3.6.9+Django2.0
- 初次分析是导包路径问题
- 解决办法:相对路径引用Models模块,即在模块前面加
.
-
解决办法参考了该博客https://blog.csdn.net/weixin_40841752/article/details/79414681from .models import *