user_image
By  Seven-wen-zi    On   2018年11月16日 10:22

之前都没有问题,在最后一步使用数据库的时候,使用完了,在网页端提示这个。 IntegrityError at /index/ NOT NULL constraint failed: login_userinfo.user Request Method: POST Request URL: http://127.0.0.1:8000/index/ Django Version: 2.1.3 Exception Type: IntegrityError Exception Value: NOT NULL constraint failed: login_userinfo.user Exception Location: /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/Django-2.1.3-py3.7.egg/django/db/backends/sqlite3/base.py in execute, line 296 Python Executable: /usr/local/bin/python3 Python Version: 3.7.0 Python Path: ['/Users/seven/Desktop/Django', '/Users/seven/Desktop/Django', '/Library/Frameworks/Python.framework/Versions/3.7/lib/python37.zip', '/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7', '/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/lib-dynload', '/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages', '/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/Django-2.1.3-py3.7.egg', '/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/pytz-2018.7-py3.7.egg', '/Applications/PyCharm.app/Contents/helpers/pycharm_matplotlib_backend'] Server time: Fri, 16 Nov 2018 02:21:44 +0000