In the old docs at:
https://pymongo.readthedocs.io/en/3.6.1/api/bson/codec_options.html
it says:
unicode_decode_error_handler: The error handler to use when decoding an invalid BSON string. Valid options include ‘strict’, ‘replace’, and ‘ignore’. Defaults to ‘strict’.
But in the new docs (4.3.3) at:
https://pymongo.readthedocs.io/en/stable/api/bson/codec_options.html
The only value listed for unicode_decode_error_handler is 'strict'
My tests with pymongo 4.3.3 show that the 'ignore' option does work.
Note, I'm using the unicode_decode_error_handler option by passing it to the MongoClient() connection function (based on an example from stackoverflow.com). But this parameter is not documented in the MongoClient documentation at:
https://pymongo.readthedocs.io/en/stable/api/pymongo/mongo_client.html
- is related to
-
PYTHON-3558 Missing docs for JSONOptions
- Closed