Uploaded image for project: 'Python Driver'
  1. Python Driver
  2. PYTHON-541

AttributeError in MongoReplicaSetClient.alive()

    • Type: Icon: Bug Bug
    • Resolution: Done
    • Priority: Icon: Minor - P4 Minor - P4
    • 2.6
    • Affects Version/s: 2.5.1, 2.5.2
    • Component/s: None
    • None
    • Fully Compatible

      Occasional error in MongoReplicaSetClient.alive() exposed by test_alive in test_ha.py:

        File "/Users/emptysquare/.virtualenvs/official/mongo-python-driver/pymongo/mongo_replica_set_client.py", line 1265, in alive
          member.pool.maybe_return_socket(sock_info)
      AttributeError: 'NoneType' object has no attribute 'pool'
      

      If the replica set has no primary, alive() still tries to return its sock_info to the primary member's pool, even though both sock_info and member are None.

            Assignee:
            jesse@mongodb.com A. Jesse Jiryu Davis
            Reporter:
            jesse@mongodb.com A. Jesse Jiryu Davis
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: