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

The bson package should not depend on the pymongo package

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major - P3
    • Resolution: Fixed
    • None
    • 4.0
    • None
    • Minor Change

    Description

      While researching PYTHON-1964 I discovered that json_util imports from pymongo.errors (and has for a few years). It really shouldn't. The pymongo package should depend on bson, not the other way around:

      ~/work/mongo-python-driver/bson $ git grep pymongo
      _cbsonmodule.c:     * pymongo.database.Database returns a new Collection instance for
      json_util.py:from pymongo.errors import ConfigurationError
      objectid.py:        # pickled with pymongo-1.9 or older.
      lines 1-3/3 (END)
      

      The bson package has its own errors module. We can define a ConfigurationError there instead.

      Attachments

        Activity

          People

            julius.park@mongodb.com Julius Park (Inactive)
            bernie@mongodb.com Bernie Hackett
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: