Django搭建fastdfs错误

a server error occurred. please contact the administrator

尝试:

pip install mutagen
pip install requests

  

IntegrityError (1452, 'Cannot add or update a child row: a foreign key constraint fails (`dailyfresh`.`django_admin_log`, CONSTRAINT
 
这时候需要在setting文件的databases中添加以下代码取消外键检查
'OPTIONS': {
"init_command": "SET foreign_key_checks = 0;",
}

  

原文地址:https://www.cnblogs.com/huxiaoyi/p/10140204.html