Deploy to Galaxy is failing

Hello!

My trials to deploy to galaxy is failing, and the support from galaxy is not helping. These are the error logs below. I think it’s a very simple thing related to dependencies, and I tried a lot to reinstall everything from scratch, but was unsuccessful… :confused:

Any ideas?

2jpjn
2017-12-23 14:26:28+01:00{ Error: Cannot find module '…/build/Release/bson’
2jpjn
2017-12-23 14:26:28+01:00 at Function.Module._resolveFilename (module.js:536:15)
2jpjn
2017-12-23 14:26:28+01:00 at Function.Module._load (module.js:466:25)
2jpjn
2017-12-23 14:26:28+01:00 at Module.require (module.js:579:17)
2jpjn
2017-12-23 14:26:28+01:00 at require (internal/module.js:11:18)
2jpjn
2017-12-23 14:26:28+01:00 at Object. (/app/bundle/programs/server/npm/node_modules/meteor/cfs_gridfs/node_modules/mongodb/node_modules/bson/ext/index.js:15:10)
2jpjn
2017-12-23 14:26:28+01:00 at Module._compile (module.js:635:30)
2jpjn
2017-12-23 14:26:28+01:00 at Object.Module._extensions…js (module.js:646:10)
2jpjn
2017-12-23 14:26:28+01:00 at Module.load (module.js:554:32)
2jpjn
2017-12-23 14:26:28+01:00 at tryModuleLoad (module.js:497:12)
2jpjn
2017-12-23 14:26:28+01:00 at Function.Module._load (module.js:489:3) code: ‘MODULE_NOT_FOUND’ }
2jpjn
2017-12-23 14:26:28+01:00js-bson: Failed to load c++ bson extension, using pure JS version

Could you please provide some more information? The command you’re running and your project setup (do you use symlinks or something? Or just a plain simple meteor folder project?) would help a lot.

Thanks for your message.

I was a bit hard on trying to debug. Indeed the whole problem appeared because of this most popular(!) answer on SO:

I have already wrote down the errors in the previous post, but I’ll do it again here:

bqmkr
2017-12-27 02:08:52+01:00{ Error: Cannot find module '../build/Release/bson'
bqmkr
2017-12-27 02:08:52+01:00 at Function.Module._resolveFilename (module.js:536:15)
bqmkr
2017-12-27 02:08:52+01:00 at Function.Module._load (module.js:466:25)
bqmkr
2017-12-27 02:08:52+01:00 at Module.require (module.js:579:17)
bqmkr
2017-12-27 02:08:52+01:00 at require (internal/module.js:11:18)
bqmkr
2017-12-27 02:08:52+01:00 at Object.<anonymous> (/app/bundle/programs/server/npm/node_modules/meteor/cfs_gridfs/node_modules/mongodb/node_modules/bson/ext/index.js:15:10)
bqmkr
2017-12-27 02:08:52+01:00 at Module._compile (module.js:635:30)
bqmkr
2017-12-27 02:08:52+01:00 at Object.Module._extensions..js (module.js:646:10)
bqmkr
2017-12-27 02:08:52+01:00 at Module.load (module.js:554:32)
bqmkr
2017-12-27 02:08:52+01:00 at tryModuleLoad (module.js:497:12)
bqmkr
2017-12-27 02:08:52+01:00 at Function.Module._load (module.js:489:3) code: 'MODULE_NOT_FOUND' }
bqmkr
2017-12-27 02:08:52+01:00js-bson: Failed to load c++ bson extension, using pure JS version

So that’s why Galaxy deploy fails.

I tried to clean install all the node_modules, especially made sure to update mongodb, mongodb-core and bson. Nothing helps :confused:

Finally I fixed it. The solution is here:

:tada:

1 Like