Uploaded image for project: 'Motor'
  1. Motor
  2. MOTOR-356

Cannot use MOTOR with PyMongo 3.6.x

    • Type: Icon: Bug Bug
    • Resolution: Won't Fix
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: 2.0
    • Component/s: None
    • None

      Implementation of the handshake protocol in https://github.com/mongodb/motor/commit/2024c7c97c9ef8860c22df7ba1ae55b77b23b298 has rendered MOTOR unusable with PyMongo 3.6 because the DriverInfo API was only added to PyMongo 3.7 onwards (see https://github.com/mongodb/mongo-python-driver/commit/c63c068611bd4ea3387fc1a08082a96869ac82a1).

      This is problematic because the current setup.py asserts that install_requires = ['pymongo>=3.6,<4'] so users can easily end up with an environment that is non-operational.

      Example of the failure (packages were pip-installed in a clean virtualenv with pymongo-3.6.0 being installed first):

      $ pip list
      Package    Version
      ---------- -------
      motor      2.0.0
      pip        19.1.1
      pymongo    3.6.0
      setuptools 41.0.1
      wheel      0.33.4
      $ python -c "import motor.core"
      Traceback (most recent call last):
        File "<string>", line 1, in <module>
        File "/Users/pmital/Developer/motor/motor/core.py", line 37, in <module>
          from pymongo.driver_info import DriverInfo
      ModuleNotFoundError: No module named 'pymongo.driver_info'
      

            Assignee:
            prashant.mital Prashant Mital (Inactive)
            Reporter:
            prashant.mital Prashant Mital (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: