pngquant: Command Failed
See original GitHub issueHi, i’m trying to compress a PNG with the example settings you provided in the README file:
'image-webpack?{progressive:true, optimizationLevel: 7, interlaced: false, pngquant:{quality: "65-90", speed: 4}}'
However, when i run my build, i get this error:
ERROR in ./src/assets/images/highResHell.png
Module build failed: Error: Command failed: /home/elias/Projects/Javascript/idexdanmark/node_modules/pngquant-bin/vendor/pngquant --output /tmp/012c00ce-0e87-4c68-bfa8-185586e92037 /tmp/7add16f3-8bf9-4ad2-b370-ad97ce2b9856 --quality 65-90 --speed 4
at ChildProcess.exithandler (child_process.js:202:12)
at emitTwo (events.js:106:13)
at ChildProcess.emit (events.js:191:7)
at maybeClose (internal/child_process.js:852:16)
at Process.ChildProcess._handle.onexit (internal/child_process.js:215:5)
@ ./src/components/ExampleComponent/index.js 7:19-59
I tried removing my node_modules folder and reinstalling my dependencies, but it had no effect.
Issue Analytics
- State:
- Created 7 years ago
- Comments:15 (2 by maintainers)
Top Results From Across the Web
Pngquant failed to build, make sure that libpng-dev is installed ...
If you have a package.json file , then try npm install , it will install all the dependencies · Got it fixed. ·...
Read more >npm install is broken by pngquant-bin dependency #46 - GitHub
Failed to resolve the domain name raw.githubusercontent.com which is commonly caused by DNS pollution. Lack of corresponding Visual C++ runtime ...
Read more >Fix "Error: pngquant failed to build, make sure that libpng-dev ...
I kept getting an error message “Error: pngquant failed to build, make sure that libpng-dev is installed” while trying to build a Nodejs ......
Read more >pngquant failed to build, make sure that libpng-dev is installed ...
Command I tried $ npm i –unsafe-perm. Got following Error; ✓ pngquant pre-build test passed successfully ✖ Error: pngquant failed to build ......
Read more >pngquant — lossy PNG compressor
pngquant is a command-line utility and a library for lossy compression of PNG ... When remapping, error diffusion is applied only to areas...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
npm install imagemin/imagemin-pngquant --save
did it for me.Optimizing large PNGs (1Mo) is very complicated:
pngquant
was crashing, andoptipng
is very slow with almost no difference in resulting image (quality or weight). Using roots/sage, optimizing a few PNGs took more than 200 seconds! Is it normal? What’s the point of using two different librairies for optimizing PNGs?