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

AttributeError raised when use_greenlets=True is specified without gevent

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor - P4
    • Resolution: Fixed
    • None
    • 2.6.3
    • None
    • None

    Description

      Seems like self.sockets needs to be set before doing this check.

      >>> import pymongo
      >>> c = pymongo.MongoClient(use_greenlets=True)
      Traceback (most recent call last):
        File "<stdin>", line 1, in ?
        File "pymongo/mongo_client.py", line 331, in __init__
          wait_queue_multiple=self.__wait_queue_multiple)
        File "pymongo/pool.py", line 145, in __init__
          raise ConfigurationError(
      pymongo.errors.ConfigurationError: The Gevent module is not available. Install the gevent package from PyPI.
      >>> 
      Exception exceptions.AttributeError: "Pool instance has no attribute 'sockets'" in <bound method Pool.__del__ of <pymongo.pool.Pool instance at 0x722878>> ignored

      Attachments

        Activity

          People

            jesse@mongodb.com A. Jesse Jiryu Davis
            bernie@mongodb.com Bernie Hackett
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: