python3.7-MongoDB-'Collection' object is not callable.

2022-09-21 08:42:30 浏览数 (1)

问题

python3.7 MongoDB报错

TypeError: ‘Collection’ object is not callable. If you meant to call the ‘authenticate’ method on a ‘Database’ object it is failing because no such method exists.

解决办法

降级Mongodb库的版本

代码语言:javascript复制
pip3 uninstall pymongo   
pip3 install pymongo==3.9 

0 人点赞