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

raw_bson doctest failures

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Minor - P4 Minor - P4
    • 3.12, 4.0
    • Affects Version/s: None
    • Component/s: None
    • Labels:
      None

       [2021/06/30 01:49:49.222] **********************************************************************
       [2021/06/30 01:49:49.222] File "api/bson/raw_bson.rst", line ?, in default
       [2021/06/30 01:49:49.222] Failed example:
       [2021/06/30 01:49:49.222]     for doc in db.test.find():
       [2021/06/30 01:49:49.222]        print(f"raw document: {doc.raw}")
       [2021/06/30 01:49:49.222]        print(f"decoded document: {bson.decode(doc.raw)}")
       [2021/06/30 01:49:49.222]        result = replica_db.test.insert_one(doc)
       [2021/06/30 01:49:49.222] Exception raised:
       [2021/06/30 01:49:49.222]     Traceback (most recent call last):
       [2021/06/30 01:49:49.222]       File "/opt/python/2.7/lib/python2.7/doctest.py", line 1315, in __run
       [2021/06/30 01:49:49.222]         compileflags, 1) in test.globs
       [2021/06/30 01:49:49.222]       File "/opt/python/2.7/lib/python2.7/site-packages/sphinx/ext/doctest.py", line 503, in compile
       [2021/06/30 01:49:49.222]         return compile(code, name, self.type, flags, dont_inherit)
       [2021/06/30 01:49:49.222]       File "<doctest default[7]>", line 2
       [2021/06/30 01:49:49.222]         print(f"raw document: {doc.raw}")
       [2021/06/30 01:49:49.222]                                        ^
       [2021/06/30 01:49:49.222]     SyntaxError: invalid syntax
       [2021/06/30 01:49:49.228] **********************************************************************
      

            Assignee:
            bernie@mongodb.com Bernie Hackett
            Reporter:
            bernie@mongodb.com Bernie Hackett
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: