【问题标题】:AWS Elastic Beanstalk requires SQLite 3.8.3 or higher for Django ApplicationAWS Elastic Beanstalk 需要 SQLite 3.8.3 或更高版本才能用于 Django 应用程序
【发布时间】:2021-06-26 08:58:29
【问题描述】:

我正在尝试在 AWS Elastic Beanstalk 上上传 Django 应用程序。 我使用了以下教程:

但我在 /admin 上尝试登录后收到以下错误消息

NotSupportedError at /admin/login/
deterministic=True requires SQLite 3.8.3 or higher
Request Method: POST
Request URL:    http://django-env50.eba-3ipauf3e.us-west-2.elasticbeanstalk.com/admin/login/?next=/admin/
Django Version: 3.1.7
Exception Type: NotSupportedError
Exception Value:    
deterministic=True requires SQLite 3.8.3 or higher
Exception Location: /var/app/venv/staging-LQM1lest/lib/python3.8/site-packages/django/db/backends/sqlite3/base.py, line 215, in get_new_connection
Python Executable:  /var/app/venv/staging-LQM1lest/bin/python
Python Version: 3.8.5
Python Path:    
['/var/app/current',
 '/var/app/venv/staging-LQM1lest/bin',
 '/var/app/venv/staging-LQM1lest/bin',
 '/usr/lib64/python38.zip',
 '/usr/lib64/python3.8',
 '/usr/lib64/python3.8/lib-dynload',
 '/var/app/venv/staging-LQM1lest/lib64/python3.8/site-packages',
 '/var/app/venv/staging-LQM1lest/lib/python3.8/site-packages']
Server time:    Mon, 29 Mar 2021 16:23:05 +0000

这是 Pipfile:

[[source]]
url = "https://pypi.org/simple"
verify_ssl = true
name = "pypi"

[packages]
asgiref = "==3.3.1"
pytz = "==2021.1"
sqlparse = "==0.4.1"
Django = "==3.1.7"

[dev-packages]

[requires]
python_version = "3.8"

感谢您的帮助。

【问题讨论】:

  • 遇到同样的问题,请问您是怎么​​解决的?
  • 抱歉回复晚了。解决方案发布在下面。希望对你有帮助。

标签: python django amazon-web-services amazon-ec2 amazon-elastic-beanstalk


【解决方案1】:

切换到 Python 3.7 似乎可以解决问题。

[[source]]
url = "https://pypi.org/simple"
verify_ssl = true
name = "pypi"

[packages]
asgiref = "==3.3.1"
pytz = "==2021.1"
sqlparse = "==0.4.1"
Django = "==3.1.7"

[dev-packages]

[requires]
python_version = "3.7"

【讨论】:

    猜你喜欢
    • 2020-12-11
    • 2022-07-03
    • 2022-11-04
    • 2022-08-13
    • 2020-08-24
    • 2019-09-04
    • 2020-06-14
    • 2020-07-04
    • 1970-01-01
    相关资源
    最近更新 更多