
OPERATIONAL DEFECT DATABASE
...

...
> db.foo.insert({_id: 2}) > db.runCommand({update: "foo", updates: [{q: {_id: 2}, u: [{$replaceWith: {$literal: {_id:2, $v: 2}}}]}]}) … does this in the (global) change stream: { _id: { _data: '8268D33CF7000000012B042C0100296E5A10043BA8D84899464C078E0C29EE953D547C463C6F7065726174696F6E54797065003C696E736572740046646F63756D656E744B657900461E5F6964002B04000004' }, operationType: 'insert', clusterTime: Timestamp({ t: 1758674167, i: 1 }), wallTime: ISODate('2025-09-24T00:36:07.146Z'), fullDocument: { _id: 2 }, ns: { db: 'test', coll: 'foo' }, documentKey: { _id: 2 } } MongoServerError[Location40532]: Executor error during getMore :: caused by :: Entry field "o.diff" should be object, found: missing The server should simply show the `replace` event.
1. Open a change stream. (global, db, or collection) 2. Insert a document. 3. Replace that document with a version of itself with $v: 2 as a top-level field. 4. Iterate the change stream. You’ll eventually see the getMore error.
Click on a version to see all relevant bugs
MongoDB Integration
Learn more about where this data comes from
Bug Scrub Advisor
Streamline upgrades with automated vendor bug scrubs
BugZero Enterprise
Wish you caught this bug sooner? Get proactive today.