Automattic/mongoose

Documented errors, page 3 of 3. Back to Automattic/mongoose

Code / MessageTypeSeverityTags
Cannot call hasNext() on errored ChangeStream
exception error change-stream, hasnext, error-recovery, mongoose
Model.ensureIndexes() no longer accepts a callback
exception error mongoose, callback-removed, promise, indexes, migration
Query.prototype.findOneAndDelete() no longer accepts a…
exception error mongoose, callback, promise, migration, breaking-change, delete
Mongoose does not support calling populate() on nested…
exception error mongoose, populate, array-subdocument
Query.prototype.deleteOne() no longer accepts a callback
exception error mongoose, callback, promise, migration, breaking-change, delete
AggregationCursor.prototype.close() no longer accepts a…
exception error aggregation-cursor, callback, promise, mongoose-7, migration
Cannot set both `validateAllPaths` and…
exception error mongoose, validate, options, typeerror
Query.prototype.distinct() no longer accepts a callback
exception error mongoose, callback, promise, migration, breaking-change, distinct
MongoDB prohibits index creation on connections that read…
exception error
Collection name must be a string
exception error mongoose, model, collection-name, typeerror
conditional requires an array
exception error query, logical-operators, type-mismatch, arrays
Mongoose maps do not support reserved key name
exception error mongoose, map, keys, prototype-pollution, security
Can't validate() the same doc multiple times in parallel…
exception error mongoose, validate, concurrency, parallel
Model.distinct() no longer accepts a callback
exception error mongoose, callback-removed, promise, distinct, migration
Cannot set both `validateAllPaths` and `pathsToValidate`
exception error mongoose, validate, options, typeerror
Model.findById() no longer accepts a callback
exception error mongoose, callback-removed, promise, query, migration
Cannot validate subdocument that does not have a parent
exception error mongoose, subdocuments, validate, parent-child
Model.find() no longer accepts a callback
exception error mongoose, callback-removed, promise, query, migration
A setter must be a function.
exception error mongoose, schema, setter, typeerror, validation
Invalid sort() argument, must be array of arrays
exception error mongoose, query, sort, typeerror, invalid-argument
Cannot set populate virtual as a property of an array
exception error virtuals, populate, arrays, schema-definition
A getter must be a function.
exception error mongoose, schema, getter, typeerror, validation
Can't use with Array.
exception error query, operators, arrays, cast-error
Cast to BigInt failed for value
exception error cast-error, bigint, json, input-validation
Cannot set both `validateAllPaths` and `pathsToSkip`
exception error mongoose, validate, options, typeerror
Model.cleanIndexes() no longer accepts a callback
exception error mongoose, callback-removed, promise, indexes, migration
Model.insertMany() no longer accepts a callback
exception error mongoose, callback, promise, migration, insertmany, bulk
Cannot overwrite Schema.indexTypes
exception error read-only, static-api, monkey-patching
Path " " may not have `index` set to false and `text` set…
exception error mongoose, schema, index, text-search, options
Cannot set default value of path
exception error mongoose, schema, default, subdocument, options
Virtual path " " conflicts with a real path in the schema
exception error virtuals, path-conflict, schema-definition
Model.bulkWrite() no longer accepts a callback
exception error mongoose, callback, promise, migration, bulkwrite, bulk
Model.listIndexes() no longer accepts a callback
exception error mongoose, callback-removed, promise, indexes, migration
QueryCursor.prototype.close() no longer accepts a callback
exception error query-cursor, callback, promise, mongoose-7, migration
Document.prototype.validate() no longer accepts a callback
exception error mongoose, callbacks, promises, migration, validate
Model.deleteMany() no longer accepts a callback
exception error mongoose, callback-removed, promise, delete, migration
Invalid subtype. Expected a number
exception error mongoose, buffer, subtype, typeerror, bson
Model.countDocuments() no longer accepts a callback
exception error mongoose, callback-removed, promise, count, migration
Cannot call addListener() on errored ChangeStream
exception error change-stream, addlistener, error-recovery, mongoose
Parameter "doc" to init() must be an object, got
exception error document, init, hydration, objectparametererror, mongoose
Cannot call once() on errored ChangeStream
exception error change-stream, once, error-recovery, mongoose
QueryCursor.prototype.next() no longer accepts a callback
exception error query-cursor, callback, promise, mongoose-7, migration
Model.findOne() no longer accepts a callback
exception error mongoose, callback-removed, promise, query, migration
Cast to Boolean failed for value
exception error cast-error, boolean, form-data, input-validation
AggregationCursor.prototype.next() no longer accepts a…
exception error aggregation-cursor, callback, promise, mongoose-7, migration
Cannot call on() on errored ChangeStream
exception error change-stream, event-listener, error-recovery, mongoose
Invalid schema configuration: Could not determine the…
exception error
Model.createIndexes() no longer accepts a callback
exception error mongoose, callback-removed, promise, indexes, migration
batchSize must be an integer
exception error mongoose, cursor, eachasync, batch-size, integer
Invalid schema configuration
exception error
Mongoose maps do not support keys that start with "$", got
exception error mongoose, map, keys, sanitization
Cannot call `next()` on a closed cursor
exception error query-cursor, cursor-lifecycle, close, mongoose
Mongoose maps only support string keys, got
exception error mongoose, map, keys, typeerror
Mongoose maps do not support keys that contain ".", got
exception error mongoose, map, keys, dotted-path