MongoEngine/mongoengine

ImportError: cannot import name '_CaseInsensitiveDictionary' from 'pymongo.common'

useada opened this issue · 3 comments

mongoengine 0.28.1
pymongo 3.7.2

File "C:\Users\usead\anaconda3\envs\qlib\lib\site-packages\mongoengine_init_.py", line 2, in
from mongoengine import (
File "C:\Users\usead\anaconda3\envs\qlib\lib\site-packages\mongoengine\connection.py", line 4, in
from pymongo.common import (
ImportError: cannot import name '_CaseInsensitiveDictionary' from 'pymongo.common' (C:\Users\usead\anaconda3\envs\qlib\lib\site-packages\pymongo\common.py)

Thanks for reporting, this will be fixed shortly but note that although MongoEngine should work with Pymongo 3.7, it isn't being tested with that version since a while, it's currently only tested with Pymongo >= 3.9 so you really should upgrade. Pymongo 3.7 is quite old

Thanks for reporting, this will be fixed shortly but note that although MongoEngine should work with Pymongo 3.7, it isn't being tested with that version since a while, it's currently only tested with Pymongo >= 3.9 so you really should upgrade. Pymongo 3.7 is quite old

Thank you so much. I have to use python 3.8 version because of other old libraries.

It's not the Python version that I'm recomending your to update but the Pymongo version. Anyway 0.28.2 got released with a fix for your use case