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

"cursor_id is not None" assert should be a well defined exception

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Trivial - P5
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 3.3
    • Component/s: None
    • Labels:
      None
    • Environment:
      pymongo current master Dec 15 792b7626dc8e3300924e125bd9f153f94de87469
      MongoDB 2.4.6

      Description

      I'm (still) trying to get to the bottom of our rare auth issues in production. In one test I wrote, I've been able to trigger a driver assertion in a mutli-threaded app when a socket disappears.

        File "/users/is/jblackburn/git/arctic/arctic/decorators.py", line 53, in f_retry
          return f(*args, **kwargs)
        File "/users/is/jblackburn/git/ahl.mongo/ahl/mongo/mongoose/store/version_store.py", line 108, in write
          return super(VersionStore, self).write(symbol, data, metadata, prune_previous_version, **kwargs)
        File "/users/is/jblackburn/git/arctic/arctic/decorators.py", line 53, in f_retry
          return f(*args, **kwargs)
        File "/users/is/jblackburn/git/arctic/arctic/store/version_store.py", line 548, in write
          self._ensure_index()
        File "/users/is/jblackburn/git/arctic/arctic/decorators.py", line 53, in f_retry
          return f(*args, **kwargs)
        File "/users/is/jblackburn/git/arctic/arctic/store/version_store.py", line 77, in _ensure_index
          th._ensure_index(collection)
        File "/users/is/jblackburn/git/arctic/arctic/store/_ndarray_store.py", line 115, in _ensure_index
          ('sha', pymongo.ASCENDING)], unique=True, background=True)
        File "/users/is/jblackburn/git/mongo-python-driver/pymongo/collection.py", line 1380, in create_index
          self.__create_index(keys, kwargs)
        File "/users/is/jblackburn/git/mongo-python-driver/pymongo/collection.py", line 1297, in __create_index
          sock_info, index, True, False, False, wcn)
        File "/users/is/jblackburn/git/mongo-python-driver/pymongo/collection.py", line 530, in _insert
          check_keys, manipulate, write_concern, op_id, bypass_doc_val)
        File "/users/is/jblackburn/git/mongo-python-driver/pymongo/collection.py", line 519, in _insert_one
          check_keys, acknowledged, concern, False, self.codec_options)
        File "/users/is/jblackburn/git/mongo-python-driver/pymongo/collection.py", line 458, in _legacy_write
          rqst_id, msg, max_size, acknowledged)
        File "/users/is/jblackburn/git/mongo-python-driver/pymongo/pool.py", line 264, in legacy_write
          return helpers._check_gle_response(response)
        File "/users/is/jblackburn/git/mongo-python-driver/pymongo/helpers.py", line 201, in _check_gle_response
          response = _unpack_response(response)
        File "/users/is/jblackburn/git/mongo-python-driver/pymongo/helpers.py", line 109, in _unpack_response
          assert cursor_id is not None
      AssertionError
      

        Attachments

          Activity

            People

            Assignee:
            behackett Bernie Hackett
            Reporter:
            jblackburn James Blackburn
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: