seppevs / migrate-mongo

A database migration tool for MongoDB in Node
MIT License
926 stars 163 forks source link

migrate-mongo init yields Warning: Accessing non-existent property 'MongoError' of module exports inside circular dependency #313

Open Wavez opened 3 years ago

Wavez commented 3 years ago

migrate-mongo init results in: migrate-mongo init (node:41653) Warning: Accessing non-existent property 'MongoError' of module exports inside circular dependency Also happens on migrate up.

macOS Big Sur node v14.15.1 npm 6.14.8 MongoDB shell version v4.4.1

"mongodb": "3.6.4", "migrate-mongo": "8.1.4",

vinnyhoward commented 3 years ago

Hopefully this helps someone.

After running either migrate-mongo up or migrate-mongo down and don't immediately exit out of the process; a more descriptive error will appear. In my case my mongo uri was incorrect. After fixing it everything worked fine.