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

Error: Lossy operations are not currently supported #180

Closed
binarykitchen opened this Issue Mar 27, 2014 · 31 comments

Comments

Projects
None yet
8 participants
@binarykitchen

binarykitchen commented Mar 27, 2014

Yesterday that error wasn't here. But today. What does this mean?

Running "imagemin:png" (imagemin) task
Warning: ** Error: Lossy operations are not currently supported
 Use --force to continue.
@kevva

This comment has been minimized.

Show comment
Hide comment
@kevva

kevva Mar 28, 2014

Member

I've no idea. It's an error outputted from optipng.

Member

kevva commented Mar 28, 2014

I've no idea. It's an error outputted from optipng.

@jamesplease

This comment has been minimized.

Show comment
Hide comment
@jamesplease

jamesplease Mar 28, 2014

Member

@binarykitchen their issue tracker is here.

Member

jamesplease commented Mar 28, 2014

@binarykitchen their issue tracker is here.

@binarykitchen

This comment has been minimized.

Show comment
Hide comment
@binarykitchen

binarykitchen Mar 29, 2014

Ok I will ask there. But I think since this module relies heavily on optipng, it concerns everyone of us here.

binarykitchen commented Mar 29, 2014

Ok I will ask there. But I think since this module relies heavily on optipng, it concerns everyone of us here.

@binarykitchen

This comment has been minimized.

Show comment
Hide comment
@vladikoff

This comment has been minimized.

Show comment
Hide comment
@binarykitchen

This comment has been minimized.

Show comment
Hide comment
@binarykitchen

binarykitchen Mar 29, 2014

@vladikoff I've seen it too but it doesn't tell me much. No hint on how to solve it, what the cause it etc.

Look, I did not touch my PNG files nor program code this week and then suddenly this happened. All I did is an npm update over many packages. Weird.

binarykitchen commented Mar 29, 2014

@vladikoff I've seen it too but it doesn't tell me much. No hint on how to solve it, what the cause it etc.

Look, I did not touch my PNG files nor program code this week and then suddenly this happened. All I did is an npm update over many packages. Weird.

@vladikoff

This comment has been minimized.

Show comment
Hide comment
@vladikoff

vladikoff Mar 29, 2014

Member

@binarykitchen clear the old PNGs, try optimizing with the new version of the plugin, 0.6.0 ?

Member

vladikoff commented Mar 29, 2014

@binarykitchen clear the old PNGs, try optimizing with the new version of the plugin, 0.6.0 ?

@ctruta

This comment has been minimized.

Show comment
Hide comment
@ctruta

ctruta Mar 29, 2014

The resolution to this error is using an OptiPNG version that supports the option "-strip=all". The earliest version that supports this option is 0.7 (although using that old version is not recommended, because of other defects). The recommended stable versions are either 0.7.4 or 0.7.5.

Thank you very much for using OptiPNG :-)

ctruta commented Mar 29, 2014

The resolution to this error is using an OptiPNG version that supports the option "-strip=all". The earliest version that supports this option is 0.7 (although using that old version is not recommended, because of other defects). The recommended stable versions are either 0.7.4 or 0.7.5.

Thank you very much for using OptiPNG :-)

@vladikoff

This comment has been minimized.

Show comment
Hide comment
@ctruta

This comment has been minimized.

Show comment
Hide comment
@ctruta

ctruta Mar 29, 2014

@vladikoff The "lossy operations not supported" error message exists in the 0.6.x line only. It was removed from version 0.7, when the option -strip got implemented. I guess you might pick up an older OptiPNG version accidentally from somewhere else in your $PATH?

ctruta commented Mar 29, 2014

@vladikoff The "lossy operations not supported" error message exists in the 0.6.x line only. It was removed from version 0.7, when the option -strip got implemented. I guess you might pick up an older OptiPNG version accidentally from somewhere else in your $PATH?

@kevva

This comment has been minimized.

Show comment
Hide comment
@kevva

kevva Mar 30, 2014

Member

Do you have OptiPNG installed globally?

Member

kevva commented Mar 30, 2014

Do you have OptiPNG installed globally?

@binarykitchen

This comment has been minimized.

Show comment
Hide comment
@binarykitchen

binarykitchen Mar 30, 2014

Thanks guys for your comments. Hmmm, with the new version 0.6.0 I get a new error:

Fatal error: Cannot find module 'pngquant-bin'

binarykitchen commented Mar 30, 2014

Thanks guys for your comments. Hmmm, with the new version 0.6.0 I get a new error:

Fatal error: Cannot find module 'pngquant-bin'
@binarykitchen

This comment has been minimized.

Show comment
Hide comment
@binarykitchen

binarykitchen Mar 30, 2014

Also, I found in another grunt task for JPG files only that any JPG file becomes corrupted :(

binarykitchen commented Mar 30, 2014

Also, I found in another grunt task for JPG files only that any JPG file becomes corrupted :(

@binarykitchen

This comment has been minimized.

Show comment
Hide comment
@binarykitchen

binarykitchen Mar 30, 2014

@kevva No, I do not have OptiPNG installed globally

binarykitchen commented Mar 30, 2014

@kevva No, I do not have OptiPNG installed globally

@kevva

This comment has been minimized.

Show comment
Hide comment
@kevva

kevva Mar 31, 2014

Member

@binarykitchen, that's weird because the version we provide is 0.7.4

asd

Member

kevva commented Mar 31, 2014

@binarykitchen, that's weird because the version we provide is 0.7.4

asd

@binarykitchen

This comment has been minimized.

Show comment
Hide comment
@binarykitchen

binarykitchen Mar 31, 2014

Windoze? I am on Linux. Has anyone tested the latest package on Linux yet?

binarykitchen commented Mar 31, 2014

Windoze? I am on Linux. Has anyone tested the latest package on Linux yet?

@kevva

This comment has been minimized.

Show comment
Hide comment
@kevva

kevva Mar 31, 2014

Member

Oh, was under the impression you was on Windows. Just ran it on Linux (Ubuntu) and everything worked smoothly. Also Travis is Linux too and tests are passing fine there.

Try npm cache clean and install again.

Member

kevva commented Mar 31, 2014

Oh, was under the impression you was on Windows. Just ran it on Linux (Ubuntu) and everything worked smoothly. Also Travis is Linux too and tests are passing fine there.

Try npm cache clean and install again.

@binarykitchen

This comment has been minimized.

Show comment
Hide comment
@binarykitchen

binarykitchen Mar 31, 2014

Hah, I made that impression? Lol ...

Ok, I'll try to clean the npm cache tomorrow at work. Ta!

binarykitchen commented Mar 31, 2014

Hah, I made that impression? Lol ...

Ok, I'll try to clean the npm cache tomorrow at work. Ta!

@kevva

This comment has been minimized.

Show comment
Hide comment
@kevva

kevva Mar 31, 2014

Member

Nah, not you. But most problems seems to come from Windows users so I just assumed you were one of them ;pp.

Member

kevva commented Mar 31, 2014

Nah, not you. But most problems seems to come from Windows users so I just assumed you were one of them ;pp.

@ctruta

This comment has been minimized.

Show comment
Hide comment
@ctruta

ctruta Mar 31, 2014

@binarykitchen just a guess: are you, by any chance, using Debian, or a Debian-based distro? The stock OptiPNG that comes with Debian was still at version 0.6.4, last time I checked. Maybe you had that version installed, indirectly?

ctruta commented Mar 31, 2014

@binarykitchen just a guess: are you, by any chance, using Debian, or a Debian-based distro? The stock OptiPNG that comes with Debian was still at version 0.6.4, last time I checked. Maybe you had that version installed, indirectly?

@binarykitchen

This comment has been minimized.

Show comment
Hide comment
@binarykitchen

binarykitchen Mar 31, 2014

nope, using ubuntu 13 here

binarykitchen commented Mar 31, 2014

nope, using ubuntu 13 here

@kevva

This comment has been minimized.

Show comment
Hide comment
@kevva

kevva Mar 31, 2014

Member

Does which optipng give you anything?

Member

kevva commented Mar 31, 2014

Does which optipng give you anything?

@ctruta

This comment has been minimized.

Show comment
Hide comment
@ctruta

ctruta Mar 31, 2014

@binarykitchen ah, Ubuntu, that's definitely Debian-based, and Ubuntu 13.x ships OptiPNG version 0.6.4.

ctruta commented Mar 31, 2014

@binarykitchen ah, Ubuntu, that's definitely Debian-based, and Ubuntu 13.x ships OptiPNG version 0.6.4.

@binarykitchen

This comment has been minimized.

Show comment
Hide comment
@binarykitchen

binarykitchen Mar 31, 2014

At work now on Ubuntu 13:

$ which optipng
/usr/bin/optipng

and

$ optipng
OptiPNG 0.6.4: Advanced PNG optimizer.
Copyright (C) 2001-2010 Cosmin Truta.
...

So, what now?

binarykitchen commented Mar 31, 2014

At work now on Ubuntu 13:

$ which optipng
/usr/bin/optipng

and

$ optipng
OptiPNG 0.6.4: Advanced PNG optimizer.
Copyright (C) 2001-2010 Cosmin Truta.
...

So, what now?

@kevva

This comment has been minimized.

Show comment
Hide comment
@kevva

kevva Apr 1, 2014

Member

So you have a global install after all. Just update it to a new version.

Member

kevva commented Apr 1, 2014

So you have a global install after all. Just update it to a new version.

@binarykitchen

This comment has been minimized.

Show comment
Hide comment
@binarykitchen

binarykitchen Apr 3, 2014

Okay, works now after recompiling optipng according to
http://kb.imakewebsites.ca/2012/10/16/installing-optipng-0-7-3-on-ubuntu-12-04/

But what happens when I deploy the code on the server? :(

Too bad apt-get does not install/update optipng anymore ...

binarykitchen commented Apr 3, 2014

Okay, works now after recompiling optipng according to
http://kb.imakewebsites.ca/2012/10/16/installing-optipng-0-7-3-on-ubuntu-12-04/

But what happens when I deploy the code on the server? :(

Too bad apt-get does not install/update optipng anymore ...

@binarykitchen

This comment has been minimized.

Show comment
Hide comment
@binarykitchen

binarykitchen Apr 3, 2014

Hmmm, there is a new problem: JPEG images are corrupted! When I try to open these in the image viewer I see this error message "Error interpreting JPEG image file (Improper call to JPEG library in state 200)"

binarykitchen commented Apr 3, 2014

Hmmm, there is a new problem: JPEG images are corrupted! When I try to open these in the image viewer I see this error message "Error interpreting JPEG image file (Improper call to JPEG library in state 200)"

@binarykitchen

This comment has been minimized.

Show comment
Hide comment
@binarykitchen

binarykitchen May 5, 2014

@kevva Ummm, I am having these issues again after installing a new machine.

I wonder why you guys aren't adding https://github.com/yeoman/node-optipng-bin to package.json?

binarykitchen commented May 5, 2014

@kevva Ummm, I am having these issues again after installing a new machine.

I wonder why you guys aren't adding https://github.com/yeoman/node-optipng-bin to package.json?

@morgoth

This comment has been minimized.

Show comment
Hide comment
@morgoth

morgoth May 23, 2014

I had the same problem.
I'm on Ubuntu 14.04.
I removed optipng from my system and it works now.

morgoth commented May 23, 2014

I had the same problem.
I'm on Ubuntu 14.04.
I removed optipng from my system and it works now.

@jwyles-rmn

This comment has been minimized.

Show comment
Hide comment
@jwyles-rmn

jwyles-rmn May 23, 2014

@morgoth that worked for me as well (Debian Squeeze)

jwyles-rmn commented May 23, 2014

@morgoth that worked for me as well (Debian Squeeze)

paulcwatts added a commit to JoltLabs/speedrate-mobile that referenced this issue Jul 17, 2014

Disable imagemin
This seems to have too many issues with different versions and on
Ubuntu.

gruntjs/grunt-contrib-imagemin#180

Since we can’t totally control our build server, we have to remove this.

@paulcwatts paulcwatts referenced this issue Jul 17, 2014

Merged

Imagemin fix #7

@Misterhex

This comment has been minimized.

Show comment
Hide comment
@Misterhex

Misterhex Aug 15, 2015

@binarykitchen +1 for adding https://github.com/yeoman/node-optipng-bin to package.json, worked for me on ubuntu 14.04

Misterhex commented Aug 15, 2015

@binarykitchen +1 for adding https://github.com/yeoman/node-optipng-bin to package.json, worked for me on ubuntu 14.04

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment