ForestAdmin / lumber

Install Forest Admin in minutes.
https://www.forestadmin.com
MIT License
2.08k stars 106 forks source link

MongoError - "invalid for/in left-hand side" #360

Open jordymalonda opened 4 years ago

jordymalonda commented 4 years ago

Expected behavior

Generate new project

Actual behavior

Cannot creating with mongo error `> Cannot generate your project.

An unexpected error occured. Please create a Github issue with following error: { MongoError: SyntaxError: invalid for/in left-hand side : functionExpressionParser@src/mongo/scripting/mozjs/mongohelpers.js:48:25

at Connection.<anonymous> (/usr/lib/node_modules/lumber-cli/node_modules/mongodb/lib/core/connection/pool.js:466:61)
at Connection.emit (events.js:198:13)
at processMessage (/usr/lib/node_modules/lumber-cli/node_modules/mongodb/lib/core/connection/connection.js:364:10)
at Socket.<anonymous> (/usr/lib/node_modules/lumber-cli/node_modules/mongodb/lib/core/connection/connection.js:533:15)
at Socket.emit (events.js:198:13)
at addChunk (_stream_readable.js:287:12)
at readableAddChunk (_stream_readable.js:268:11)
at Socket.Readable.push (_stream_readable.js:223:10)
at TCP.onStreamRead [as onread] (internal/stream_base_commons.js:94:17)

ok: 0, errmsg: 'SyntaxError: invalid for/in left-hand side :\nfunctionExpressionParser@src/mongo/scripting/mozjs/mongohelpers.js:48:25\n', code: 139, codeName: 'JSInterpreterFailure', name: 'MongoError', [Symbol(mongoErrorContextSymbol)]: {} } `

TODO: Please provide any relevant information about your setup.

slimee commented 4 years ago

Hi Jordy,

Where is located your mongo, is it a mongo atlas for example or do you host it?

Regards

jordymalonda commented 4 years ago

mongodb is on my local machine

VincentMolinie commented 4 years ago

Are you on MongoAtlas ? Which version of NodeJs are you using ?