Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

node_modules/optipng-bin/vendor/optipng ENOENT #5

Closed
strever opened this issue Jun 2, 2016 · 8 comments
Closed

node_modules/optipng-bin/vendor/optipng ENOENT #5

strever opened this issue Jun 2, 2016 · 8 comments

Comments

@strever
Copy link

strever commented Jun 2, 2016

when run
$ gulp dev
Error: spawn /home/streverf/www/fancy/node_modules/optipng-bin/vendor/optipng ENOENT
at exports._errnoException (util.js:870:11)
at Process.ChildProcess._handle.onexit (internal/child_process.js:178:32)
at onErrorNT (internal/child_process.js:344:16)
at nextTickCallbackWith2Args (node.js:441:9)
at process._tickCallback (node.js:355:17)

env:
$ npm -version
3.5.2
$ nodejs --version
v4.2.6

@panteng
Copy link
Owner

panteng commented Jun 2, 2016

It seems like something is wrong with your gulp-imagemin plugin.
Try uninstall it and install it again.

npm uninstall gulp-imagemin

npm install gulp-imagemin

Make sure there are no errors during installation.

@strever
Copy link
Author

strever commented Jun 2, 2016

rm -rf node_modules
npm install
solve the problem.

probably because i run npm install before npm install -g node-gyp

@strever strever closed this as completed Jun 2, 2016
@panteng
Copy link
Owner

panteng commented Jun 2, 2016

Yeah, imagemin depends on node-gyp.

@chrisferagotti
Copy link

Similar issue. I believe what worked for me was:

npm install node-gyp
npm uninstall gulp-imagemin
npm install gulp-imagemin

So, I think what they said above, just all in one post.

@rafito
Copy link

rafito commented Oct 27, 2017

npm rebuild solve it here!

@mrjohnskelton
Copy link

Same issue here. uninstall/reinstall of gulp-imagemin fixed symptoms. npm install hadn't previously reported any issues with the install. node-gyp installed.

Not sure if there is some hidden instability in package dependencies as my gulp task had been running fine in the same environment/project then spuriously stopped working. I'm not sure what had changed to introduce error.

<project>\node_modules\optipng-bin\vendor\optipng.exe folder and executable were missing, yielding the error/stacktrace:

Error: The system cannot find the path specified.

  at notFoundError (<project>\node_modules\cross-spawn\lib\enoent.js:11:11)
  at verifyENOENT (<project>\node_modules\cross-spawn\lib\enoent.js:46:16)
  at ChildProcess.cp.emit (<project>\node_modules\cross-spawn\lib\enoent.js:33:19)
  at Process.ChildProcess._handle.onexit (internal/child_process.js:215:12)

@maheshDe
Copy link

maheshDe commented May 15, 2018

npm rebuild

works for me.

@DineshGon
Copy link

None of the solutions worked for me. Any other recommendations. Warning: Error: spawn /applic/node_modules/optipng-bin/vendor/optipng ENOENT

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants