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

Remove NotMasterError

    • Type: Icon: Task Task
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 4.0
    • Affects Version/s: None
    • Component/s: None
    • Labels:
      None
    • Major Change

      We should consider deprecating NotMasterError and renaming it to NotPrimaryError.

      Apps that need to be pymongo 3+4 compatible will need to be updated like this:

      try:
          # PyMongo >=3.12
          from pymongo.errors import NotPrimaryError
      except ImportError:
          # PyMongo <=3.11
          from pymongo.errors import NotMasterError as NotPrimaryError
      

            Assignee:
            prashant.mital Prashant Mital (Inactive)
            Reporter:
            shane.harvey@mongodb.com Shane Harvey
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: