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

Motor and PyMongo version compatibilities are confusing

    • Type: Icon: Bug Bug
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • 0.1.1
    • Affects Version/s: 0.1
    • Component/s: None
    • None
    • Environment:

      When trying to create a MotorReplicaSetClient, I get the following error:

      % python motor_sample.py
      Traceback (most recent call last):
      File "motor_sample.py", line 10, in <module>
      client = motor.MotorReplicaSetClient(",".join(servers), replicaSet="tsurumongoapi").open_sync()
      File "/Users/f/.venvs/motor/lib/python2.7/site-packages/motor/_init_.py", line 967, in open_sync
      super(MotorReplicaSetClient, self).open_sync()
      File "/Users/f/.venvs/motor/lib/python2.7/site-packages/motor/_init_.py", line 804, in open_sync
      for pool in self._get_pools():
      File "/Users/f/.venvs/motor/lib/python2.7/site-packages/motor/_init_.py", line 1004, in _get_pools
      self.delegate.MongoReplicaSetClient_members.values()]
      File "/Users/f/.venvs/motor/lib/python2.7/site-packages/pymongo/collection.py", line 1418, in _call_
      self.__name)
      TypeError: 'Collection' object is not callable. If you meant to call the 'values' method on a 'Database' object it is failing because no such method exists.

      I tried both formats: "mongodb://<server1>,<server2>,<server3>/" and "<server1>,<server2>,<server3>".

      It works nicely on pymongo.

            Assignee:
            jesse@mongodb.com A. Jesse Jiryu Davis
            Reporter:
            fss Francisco Souza
            Votes:
            2 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: