-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
How can I do with error that - Input file has corrupt header: pngload: reached chunk/cache limits #2984
Comments
I suspect this image trips the https://github.com/randy408/libspng/blob/master/docs/decode.md#memory-usage To allow an optional increase in this value, we'd need to expose control over this in libvips first. Are you able to provide a sample image that fails in this manner? |
The sample image is large. Can you leave an email address? I will post to you. |
Hopefully it's not that, I'll raise the default value if that's the case. Either way I'll be adding a new error code to differentiate from the other two limits. |
@lovell I posted the sample image download url to npm@lovell.info email. Thank you. |
Thanks for the image, it has 143 chunks, two of which are text chunks that consume ~260MB when decompressed. $ pngchunks preview221.png | grep "Chunk:" | wc -l
143
$ pngchunks preview221.png | grep zTXt
Chunk: Data Length 131093001 (max 2147483647), Type 1951945850 [zTXt]
Chunk: Data Length 131085202 (max 2147483647), Type 1951945850 [zTXt] As Randy has pointed out, there's a new |
@lovell Thanks. |
v0.30.0 now available with this feature. |
What are you trying to achieve?
I was going to get a thumbnail from a png which is 254 M large, which occured that error.
Have you searched for similar questions?
yes, but I can not find out how to fixed it.
Are you able to provide a minimal, standalone code sample that demonstrates this question?

that is my process code
Are you able to provide a sample image that helps explain the question?

that is error tip
The text was updated successfully, but these errors were encountered: