django - 如何在 Django 我们应用程序中为 mongoDB 连接配置 settings.py
问题描述
我收到以下错误:
django.core.exceptions.ImproperlyConfigured:
'django_mongodb_engine' isn't an available database backend.
尝试使用
'django.db.backends.XXX'
,其中XXX
之一是:u'mysql'
,u'oracle'
,u'postgresql_psycopg2'
,u'sqlite3'
如您所见,mongodb
文档中的列表中没有。
有什么建议么?
解决方案
根据错误消息,可能django_mongodb_engine
是没有正确安装:
pip install git+https://github.com/django-nonrel/django@nonrel-1.5
pip install git+https://github.com/django-nonrel/djangotoolbox
pip install git+https://github.com/django-nonrel/mongodb-engine
在以下位置查看更多信息:https ://django-mongodb-engine.readthedocs.io/en/latest/topics/setup.html
推荐阅读
- xml - How do I find this xpath node? One of the elements has periods, and one of the elements doesn't have a key
- c++ - 使用 iwlib 扫描可见的 wifi 网络
- ios - 如何在没有测试目标的情况下让 SwiftUI Preview 只构建主要目标?
- c# - 从 C# 中的列表中获取 cookie 的索引
- postgresql - postgres中是否有低优先级查询之类的东西?
- electron - 使用 Electron-Wix-Msi 更改 ALLUSERS 属性
- ruby-on-rails - 在 Ruby on Rails 项目中运行“rakefile create:db”时发生错误
- rust - 如何制作 rust websocket 客户端?
- java - 在命令行 java 应用程序中使用 Thymeleaf
- authentication - 在 JAVA 中通过身份验证后如何获取 okta 用户详细信息/当前会话