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

Close ChangeStream cursor when the resume token is missing.

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major - P3
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 3.6
    • Component/s: API
    • Labels:
      None

      Description

      ChangeStreams raise an error when the resume token is not found in the current change document however, the underlying cursor is left open.

      We should close the cursor before raising an error here: https://github.com/mongodb/mongo-python-driver/blob/fdf4436201065e77a3d67c7c3d92be721bc7e20e/pymongo/change_stream.py#L116

      Thanks Emily Stolfo for pointing this out.

        Attachments

          Activity

            People

            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: