anaisbetts / grunt-build-atom-shell

Grunt task to build Electron and rebuild node modules
MIT License
122 stars 11 forks source link

rebuild-native-modules Warning: Arguments to path.resolve must be strings #23

Closed Wortex17 closed 9 years ago

Wortex17 commented 9 years ago

As stated in #22, running grunt rebuild-native-modules (after a successfull grunt build-atom-shell) results in

>> Found existing node.js installation, skipping install to save time!
Warning: Arguments to path.resolve must be strings Use --force to continue.

for me

Running grunt -v --stack rebuild-native-modules gives:

>> Found existing node.js installation, skipping install to save time!
Warning: Arguments to path.resolve must be strings Use --force to continue.
TypeError: Arguments to path.resolve must be strings
    at Object.exports.resolve (path.js:116:15)
    at F:\PROJ\node_modules\grunt-build-atom-shell\tasks\build-atom-shell-task.coffee:164:23
    at tryCatcher (F:\PROJ\node_modules\grunt-build-atom-shell\node_modules\rx\dist\rx.js:568:29)
    at setDisposable (F:\PROJ\node_modules\grunt-build-atom-shell\node_modules\rx\dist\rx.js:4830:36)
    at AnonymousObservable.s [as _subscribe] (F:\PROJ\node_modules\grunt-build-atom-shell\node_modules\rx\dist\rx.js:4847:11)
    at AnonymousObservable.Rx.Observable.observableProto.subscribe.observableProto.forEach (F:\PROJ\node_modules\grunt-build-atom-shell\node_modules\rx\dist\rx.js:2138:19)
    at F:\PROJ\node_modules\grunt-build-atom-shell\node_modules\rx\dist\rx.js:1633:38
    at F:\PROJ\node_modules\grunt-build-atom-shell\node_modules\rx\dist\rx.js:1086:9
    at recursiveAction (F:\PROJ\node_modules\grunt-build-atom-shell\node_modules\rx\dist\rx.js:1030:9)
    at F:\PROJ\node_modules\grunt-build-atom-shell\node_modules\rx\dist\rx.js:1038:13

_(I substituted the full project path with _PROJ* for readibility)*

maxkorp commented 9 years ago

The call to generateNodeLib inside of rebuildNativeModules isn't passing the node-version, so it breaks. I'll make a PR in a second here.