Details
-
Bug
-
Status: Closed
-
Major - P3
-
Resolution: Fixed
-
3.0
-
None
Description
There one huge behaviour change in PyMongo 3, which is not documented if at all wished, but in my opinion is a bug (and therefore this ticket).
In collection.py, in the save() method, we had in PyMongo 2.X:
self.update({"_id": to_save["_id"]}, to_save, True, manipulate, safe, check_keys=check_keys, **kwargs)
|
return to_save.get("_id", None)
|
And now in PyMongo 3.0:
self._update(sock_info, {"_id": to_save["_id"]}, to_save, True, check_keys, False, manipulate, write_concern)
|
With no return !!! Whereas many apps base on the fact to check for the id to now if the upsert really worked.