一位面试官问我检查模型没有错误的命令是什么。
Django 有这样的命令吗?
请您参考如下方法:
您可以使用 check 显式运行检查命令:
check
python manage.py check
要专门检查模型,您可以:
python manage.py check --tag models