赞
踩
文章目录
- 1. SQLite 3.8.3 or later is required (found 3.7.17)
- 2. ModuleNotFoundError: No module named '_sqlite3'
- 3. 导入的django项目不能至直接运行
- 4. 执行python3 manage.py makemigrations
- 5. Forbidden (CSRF cookie not set.)
- 6. pip安装模块出现连接问题
- 7. django.core.exceptions.ImproperlyConfigured: mysqlclient 1.3.13 or newer is required; you have 0.9.3.
- 8. You called this URL via POST, but the URL doesn't end in a slash and you have APPEND_SLASH set. Django can't redirect to the slash URL while maintaining POST data.
- 9. ModuleNotFoundError: No module named 'MySQLdb'
- 10. RuntimeError: You called this URL via POST, but the URL doesn't end in a slash and you have APPEND_SLASH set. Django can't redirect to the slash URL while maintaining POST data
- 11. django.core.exceptions.ImproperlyConfigured: Application labels aren't unique, duplicates: xxx
- 12. django.core.exceptions.ImproperlyConfigured: Specifying a namespace in include() without providing an app_name is not supported. Set the app_name attribute in the included module, or pass a 2-tuple containing the list of patterns and app_name instead.
- 13. django.db.migrations.exceptions.InconsistentMigrationHistory: Migration admin.00
- 14. Requested setting USE_I18N, but settings are not configured.
- 15. ImportError: No module named 'MySQLdb'
- 16. OSError: mysql_config not found
- 17. ERROR: No matching distribution found for mysqlclient
- 18. ModuleNotFoundError: No module named 'import_export'
- 19. ModuleNotFoundError: No module named 'captcha.fields'
- 20. Django: ImportError: No module named 'corsheaders'
- 21. 使用PyCharm启动Django项目不能加载静态资源
- 22. ImportError: cannot import name 'six' from 'django.utils'
raise ImproperlyConfigured('SQLite 3.8.3 or later is required (found %s).' % Database.sqlite_version)django.core.exceptions.ImproperlyConfigured: SQLite 3.8.3 or later is required (found 3.7.17).
① django版本降级
② 安装SQLite 3.8.3或以上的版本
【SQLite官网】:https://www.sqlite.org/download.html
下载SQLite3源码安装包:[root@instance-mtfsf05r ~]# wget https://www.sqlite.org/2019/sqlite-autoconf-3290000.tar.gz
解压缩:[root@instance-mtfsf05r ~]# tar -zxvf sqlite-autoconf-3290000.tar.gz
切换到sqlite目录下:[root@instance-mtfsf05r ~]# cd sqlite-autoconf-3290000/
释放编译文件:[root@instance-mtfsf05r sqlite-autoconf-3290000]# ./configure --prefix=/usr/local/sqlit329
编译和安装[root@instance-mtfsf05r sqlite-autoconf-3290000]# make && make install
查看当前全局sqlite3的版本检查sqlite3版本还是没有被改变,所以更改旧的sqlite3:
[root@instance-mtfsf05r ~]# sqlite3 -version
3.7.17 2013-05-20 00:56:22 118a3b35693b134d56ebd780123b7fd6f1497668
[root@instance-mtfsf05r ~]# mv /usr/bin/sqlite3 /usr/bin/sqlite3_old
为新版本创建软链接:[root@instance-mtfsf05r ~]# ln -s /usr/local/bin/sqlite3 /usr/bin/sqlite3
检查当前SQLite3版本:[root@instance-mtfsf05r ~]# sqlite3 --version
检查Python的SQLite3版本:[root@instance-mtfsf05r ~]# python3
>>> import sqlite3
>>> sqlite3.sqlite_version
'3.29.0'
再次运行django项目:
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。