enb / enb-sass

MIT License
12 stars 7 forks source link

Build (enb make) failed on enb-sass #13

Closed ditransler closed 8 years ago

ditransler commented 8 years ago

Today I faced an unexpected problem trying to run enb make (with "enb-sass" installed and configured in "./enb/make.js").

Here is an excerpt from my npm log:

$ enb make
22:00:24.439 - build started
22:00:24.507 - [rebuild] [desktop.bundles\index\index.bemjson.js] file-provider
22:00:24.739 - [rebuild] [desktop.bundles\index\index.levels] levels
22:00:24.751 - [rebuild] [desktop.bundles\index\index.bemdecl.js] bemjson-to-bemdecl
22:00:24.793 - [rebuild] [desktop.bundles\index\index.deps.js] deps
22:00:24.801 - [rebuild] [desktop.bundles\index\index.files] files
22:00:24.802 - [rebuild] [desktop.bundles\index\index.dirs] files
22:00:24.820 - [failed] [desktop.bundles\index\index.post.css] enb-sass
22:00:24.825 - [failed] [desktop.bundles\index\index.css] enb-postcss
22:00:24.826 - [failed] [desktop.bundles\index\index.min.css] borschik
22:00:24.827 - build failed
TypeError: vow.promise is not a function
    at Object.Queue.enqueue (I:\projects\test\bem-test-project\node_modules\enb-sass\node_modules\vow-queue\lib\queue.js:56:31)
    at Object.wrapper [as read] (I:\projects\test\bem-test-project\node_modules\enb-sass\node_modules\vow-fs\lib\fs.js:39:39)
    at I:\projects\test\bem-test-project\node_modules\enb-sass\techs\css-sass.js:41:26
    at Array.map (native)
    at null.<anonymous> (I:\projects\test\bem-test-project\node_modules\enb-sass\techs\css-sass.js:33:36)
    at resultTechMethods._getBuildResult (I:\projects\test\bem-test-project\node_modules\enb-sass\node_modules\enb\lib\build-flow.js:599:34)
    at I:\projects\test\bem-test-project\node_modules\enb-sass\node_modules\enb\lib\build-flow.js:657:67
    at Array.<anonymous> (I:\projects\test\bem-test-project\node_modules\enb-sass\node_modules\enb\node_modules\vow\lib\vow.js:202:56)
    at Immediate.callFns [as _onImmediate] (I:\projects\test\bem-test-project\node_modules\enb-sass\node_modules\enb\node_modules\vow\lib\vow.js:462:35)
    at processImmediate [as _immediateCallback] (timers.js:383:17)

Note: After the "enb-sass" was installed there was a warning:

npm WARN EPEERINVALID vow-queue@0.0.2 requires a peer of vow@~0.3.9 but none was installed.

I'm using:

My configuration of "make.js" (just in case):

// scss
[techs.scss, {
    target: '?.post.css',
    sourceSuffixes: ['scss'],
    sass: {
          outFile: '?.post.css',
          outputStyle: 'compressed',
          sourceMap: true,
          sourceMapContents: true,
          sourceMapEmbed: true
    }
}],

I tried to completely reinstall all npm packages, then only "enb-sass", then only "vow", "vow-fs", "vow-node" and "vow-queue" but unsuccessfully.

Note: Before that I tried it on another machine and everything was OK:

Please, help me to solve this issue.

ditransler commented 8 years ago

It seems that I managed to solve the issue by downgrading the Node.

I installed nvm for windows to manage different versions of Node and chose the version that was installed on another machine (Node v.4.2.1).

Now ENB builds the project without any errors. I guess the whole problem was with the Node version.

So it'll be great if enb-sass will have no conflicts with the latest Node version.