mizzao / meteor-sharejs

Meteor smart package for transparently adding ShareJS editors to an app
MIT License
225 stars 53 forks source link

Does not build on Python >3.0, with error: js-bson: Failed to load c++ bson extension, using pure JS version #13

Closed ghost closed 10 years ago

ghost commented 10 years ago

No idea why, but I get this error when adding sharejs on meteor 0.8.1.3

    js-bson: Failed to load c++ bson extension, using pure JS version

I tried reinstall npm bson and mongodb, but no success. Any ideas?

mizzao commented 10 years ago

We're depending on the same version of Mongo as Meteor: https://github.com/meteor/meteor/blob/devel/packages/mongo-livedata/package.js#L16.

Is it possible that you have an old smart.lock file lying around? (delete it.) What OS are you using?

ghost commented 10 years ago

hey mizzao, thanks for replying. I removed the smart.lock but still the same error. I am on latest Arch Linux.

mizzao commented 10 years ago

Do you have this issue when you do a regular npm install mongodb outside of a Meteor app? Are you on 32-bit or 64-bit? It definitely seems to be something that is part of mongodb: https://github.com/mongodb/js-bson

ghost commented 10 years ago

Outside of Meteor the problem does not occur, and I am on 64 bit. I set up a clean new meteor project with mrt sharejs and still the same error. I think it is some mongo configuration problem, but have not figured out yet what to do.

ghost commented 10 years ago

I solved it. there was a build error message produced by the sharejs bson module which came with mongodb in '~/.meteorite/packages/sharejs/mizzao/meteor-sharejs/1d8137b59906ce210b2f5c015b7b142735bc2f4e/.npm/package/node_modules/mongodb/node_modules/bson/'

it basically said it does not support python > 3.0, so manually rebuilding with python2.7 solved it.

mizzao commented 10 years ago

I updated the title in case anyone else runs into this.

How is it possible that the build process outside of Meteor used the right version of Python, but inside Meteor it used a different version?