community.mongodb
community.mongodb copied to clipboard
Drop support for pymongo < 4.0?
SUMMARY
Pymongo 4.0 was a pretty big change from previous versions. Currently the code attempts to account for these differences where needed/known about. This causes complexity. We could remove support for older (<4.0) PyMongo versions and remove a lot of this code, thus keeping things simple. There are however consequences for this...
https://pymongo.readthedocs.io/en/stable/changelog.html
PyMongo 4.0 drops support for MongoDB 2.6, 3.0, 3.2, and 3.4. PyMongo 4.0 drops support for Python 2.7, 3.4, and 3.5. PyMongo 4.1 drops support for Python 3.6.0 and 3.6.1, Python 3.6.2+ is now required.
These Python versions are still widely used. Do we drop support for these by requiring PyMongo 4.0+ or do we maintain compatibility, thus creating more complexity?
Thoughts welcome.
ISSUE TYPE
- Feature Idea
COMPONENT NAME
community.mongodb
The things I care about most are python 3.6.5+ (3.6.5 is the default version on Ubuntu 18; 3.6.8 is the default on CentOS 7) and Mongo 4.0+. So, at least for me, requiring pymongo 4.1+ would be just fine.
Imho the problem is not what is supported by pymongo 4.0 but whether pymongo itself is easily available. Debian Sid and Ubuntu 22.04 only have pymongo 3.11, Fedora 36 has pymongo 3.10...
3.10 is a couple of years old now - https://pypi.org/project/pymongo/#history
The problem is I can't really test multiple versions of pymongo without the number of tests exploding. I currently test 3.12.3 and latest (4.1.X), along with MongoDB 4.4 & 5.0 on multiple OS/Python versions. There's already over two hundred integration tests. Each new Pymongo version would add another hundred or so. What's more important MongoDB / OS compatability or PyMongo compatability?
I understand your point of view but after all the purpose of ansible is to deploy systems and software. What is more important the software that deploys or the software that is deployed?