Description
Prerequisites
- I have written a descriptive issue title
- I have searched existing issues to ensure the bug has not already been reported
Mongoose version
8.10.0
Node.js version
20
MongoDB server version
6.0.20
Typescript version (if applicable)
No response
Description
Jest detects open handles after upgrading from 8.9.6
to 8.10.0
.
Here are some logs:
Jest has detected the following 14 open handles potentially keeping Jest from exiting:
...
at node_modules/mongoose/lib/connection.js:838:19
at NativeConnection._waitForConnect (node_modules/mongoose/lib/connection.js:837:7)
at _createCollection (node_modules/mongoose/lib/model.js:1106:16)
at Function.init (node_modules/mongoose/lib/model.js:1119:16)
at Mongoose._model (node_modules/mongoose/lib/mongoose.js:667:9)
at Mongoose.model (node_modules/mongoose/lib/mongoose.js:622:27)
...
My code hasn't changed it was just a mongoose dependency upgrade. When I rollback the upgrade everything works fine again.
Steps to Reproduce
upgrade from 8.9.6
to 8.10.0
. Run tests that use jest and mongoose connections.
Expected Behavior
No response
Metadata
Metadata
Assignees
Labels
No labels