Updating/building Enketo-Express Errors (Could not locate the bindings file)

214 views
Skip to first unread message

El Piqo

unread,
May 4, 2016, 9:00:05 AM5/4/16
to enketo-users
Hi there, 

I'm trying to update Enketo-Express (from 1.9.0) to the latest. 

After git pull, the npm update --production command, it was giving me:

npm ERR! peerinvalid The package grunt does not satisfy its siblings' peerDependencies requirements!
npm ERR! peerinvalid Peer load-gru...@3.5.0 wants grunt@>=0.4.0
npm ERR! peerinvalid Peer grunt-contr...@0.4.4 wants grunt@~0.4.0
npm ERR! peerinvalid Peer grunt-cont...@0.3.0 wants grunt@~0.4.1
npm ERR! peerinvalid Peer grunt...@0.11.0 wants gr...@0.4.x
npm ERR! peerinvalid Peer grunt-con...@0.6.1 wants grunt@~0.4.0
npm ERR! peerinvalid Peer grunt-cont...@0.11.2 wants grunt@>=0.4.0
npm ERR! peerinvalid Peer grunt-...@0.4.0 wants grunt@~0.4.1

I then, updated NPM (npm install -g npm) and did npm update --production again, and the error went away. I got the following (and some warnings):

enketo-...@1.28.0 /home/user/enketo-express
├── enket...@4.6.0
├── UNMET PEER DEPENDENCY gr...@1.0.1
└── l...@3.0.4


Running grunt on projects root doesn't give me any errors. But when I run grunt develop I get:

throw err
        ^
Error: Could not locate the bindings file. Tried:
 → /home/user/enketo-express/node_modules/libxslt/build/node-libxslt.node
 → /home/user/enketo-express/node_modules/libxslt/build/Debug/node-libxslt.node
 → /home/user/enketo-express/node_modules/libxslt/build/Release/node-libxslt.node
 → /home/user/enketo-express/node_modules/libxslt/out/Debug/node-libxslt.node
 → /home/user/enketo-express/node_modules/libxslt/Debug/node-libxslt.node
 → /home/user/enketo-express/node_modules/libxslt/out/Release/node-libxslt.node
 → /home/user/enketo-express/node_modules/libxslt/Release/node-libxslt.node
 → /home/user/enketo-express/node_modules/libxslt/build/default/node-libxslt.node
 → /home/user/enketo-express/node_modules/libxslt/compiled/0.10.33/linux/x64/node-libxslt.node
    at bindings (/home/user/enketo-express/node_modules/libxslt/node_modules/bindings/bindings.js:88:9)
    at Object.<anonymous> (/home/user/enketo-express/node_modules/libxslt/index.js:8:34)
    at Module._compile (module.js:456:26)
    at Object.Module._extensions..js (module.js:474:10)
    at Module.load (module.js:356:32)
    at Function.Module._load (module.js:312:12)
    at Module.require (module.js:364:17)
    at require (module.js:380:17)
    at Object.<anonymous> (/home/user/enketo-express/app/models/manifest-model.js:3:14)
    at Module._compile (module.js:456:26)


The application can be started using PM2 start app, but it cannot be accessed at all. That is why I tried grunt develop, to collect logs, but the above shows. 

Info about my environment:
Ubuntu 14.04.2 LTS
node v0.10.33
grunt-cli v0.1.13
grunt v1.0.1
npm 3.8.8


Best, 
piqo

El Piqo

unread,
May 4, 2016, 11:03:07 AM5/4/16
to enketo-users
I think it was resolved (though still a minor error) by doing the following:

1. removed node_modules directory
2. npm install --production
3. when building with grunt, was complaining because grunt-concurrent, "grunt-contrib-jshint", "grunt-contrib-watch", "grunt-jsbeautifier", "grunt-karma", "grunt-mocha-test", "grunt-nodemon", "grunt-shell" were not found. 
 I installed them manually and everything seems alright, just the following error (no side effects so far):

Running "sass:compile" (sass) task
>> Error: File to import not found or unreadable: ../../../node_modules/bootstrap-datepicker/dist/css/bootstrap-datepicker
>>        Parent style sheet: /home/vm/enketo-express/node_modules/enketo-core/src/widget/date/datepicker-extended.scss
>>         on line 1 of node_modules/enketo-core/src/widget/date/datepicker-extended.scss
>> >> @import "../../../node_modules/bootstrap-datepicker/dist/css/bootstrap-datepic
>>    ^
Warning:  Used --force, continuing.
Warning: File to import not found or unreadable: ../../../node_modules/bootstrap-datepicker/dist/css/bootstrap-datepicker
Parent style sheet: /home/vm/enketo-express/node_modules/enketo-core/src/widget/date/datepicker-extended.scss Used --force, continuing.

Martijn van de Rijdt

unread,
May 4, 2016, 12:30:41 PM5/4/16
to enketo...@googlegroups.com
Hi piqo,

removing node_modules and re-running npm install --production, usually resolves such issues.

There is no need to install those missing modules, as they just take up space and are not used in production. Those warnings (not errors) can be ignored.

Npm 3.x.x. is not supported yet: https://github.com/kobotoolbox/enketo-express/issues/322, so your css files will fail to build (sass:compile). You need to downgrade back to npm 2.x.x

Cheers,
Martijn

--
You received this message because you are subscribed to the Google Groups "enketo-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to enketo-users...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


-- 
Revolutionizing data collection since 2012.

Enketo    |    LinkedIn    |    GitHub    |    Twitter    |    Blog

El Piqo

unread,
May 5, 2016, 3:40:21 AM5/5/16
to enketo-users
Thanks

after  npm install -g npm@latest-2 everything seems fine . 

Best, 
piqo
Reply all
Reply to author
Forward
0 new messages