Failed to load c++ bson extension
Full error message
A total node noob here. I've been trying to set up a sample node app but the following error keeps popping up every time I try to run:
node app
Failed to load c++ bson extension, using pure JS version
events.js:72
throw er; // Unhandled 'error' event
^
Error: failed to connect to [#$%67890 :27017]
at null.<anonymous> (/home/thejazeto/code/nodejs/authen/node_modules/mongoose/node_modules/mongodb/lib/mongodb/connection/server.js:553:74)
at EventEmitter.emit (events.js:106:17)
at null.<anonymous> (/home/thejazeto/code/nodejs/authen/node_modules/mongoose/node_modules/mongodb/lib/mongodb/connection/connection_pool.js:140:15)
at EventEmitter.emit (events.js:98:17)
at Socket.<anonymous> (/home/thejazeto/code/nodejs/authen/node_modules/mongoose/node_modules/mongodb/lib/mongodb/connection/connection.js:512:10)
at Socket.EventEmitter.emit (events.js:95:17)
at net.js:830:16
at process._tickCallback (node.js:415:13)Solutionsource: stackoverflow \u2197
I guess you did not have the make tools available when you installed your mongodb library. I suggest you do xcode-select --install (on a mac) or sudo apt-get install gcc make build-essential (on ubuntu) and run rm -rf node_modules npm cache clean npm install OR just npm update based on @tobias comment (after installing build-essential) npm update
API access
Get this solution programmatically \u2014 free, no authentication.
curl https://depscope.dev/api/error/1f32f35af49b3ce7d06c510c8412b90eef44bca14c336e35bcd6aa693fc0caf6hash \u00b7 1f32f35af49b3ce7d06c510c8412b90eef44bca14c336e35bcd6aa693fc0caf6