-
Type: Bug
-
Resolution: Duplicate
-
Priority: Major - P3
-
None
-
Affects Version/s: 2.4.3
-
Component/s: Write Ops
-
None
-
Environment:Debian running 2.4.3
-
ALL
Bar.py
import pymongo conn = pymongo.Connection() coll = conn.test.create_collection('bar', autoIndexId=False) coll.update({'a': 1}, {'$set': {'b': 2}}, upsert=True) list(coll.find()) [{u'a': 1, u'b': 2}] # NO _id!!
Once _id is missing we saw fatal assertions coming from replica set code (we tried creating the index but it complain on dup key error) and failed migration because migrated documents must contain a _id. I assume all documents in mongo must have a _id.
- duplicates
-
SERVER-12334 Update does not ensure an _id field
- Closed