-
-
Notifications
You must be signed in to change notification settings - Fork 469
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
Fail gracefully when format=auto
#309
Comments
* feat: add fly.io * feat(readme): fly image width * feat(readme): add html image + badge * fix(docs): try space non-URL encoding * Update README.md * Update README.md * Update README.md * feat(docs): add fly.io info and links * feat(#305, #309, #308, #305. #284) * fix(ci): golinter * fix(Dockerfile): use root folder for go test / ci linter * fix(ci): allow to fail go 1.14 build, still not sure why * fix(ci): bad yaml format * fix(ci): use travis-compatible regex * fix(ci): lets skip go1.14 for now * fix(mod): update dependencies
#270 is fixed in I will keep this issue open since it is still room for future improvement in the API behavior about the underlying idea of smarter format detection mechanism by inferring accepted image using Client Hints HTTP headers. |
Related feature proposal: #253 |
Hello, We seems facing same kind of problem. When trying to convert JPEG (160px x 21600px) into WebP - getting HTTP400 with this inside: Would be great to fallback into JPEG in such cases instead of error. In our case we send requests with explicit |
Hello @n1bs! A fallback mechanism might be optimal in this case, but I'd rather prefer this behavior to be explicitly requested in the HTTP request contract. Something like overloading the current Would that work? |
I managed to replicate this with a random jpeg: The imaginary params were: Type with multiple available formats would work great for me. |
thanks for the test image, Kurt! @h2non thanks for the quick look into this! Just to confirm - we're running v1.2.2 and |
Cool, I will try to ship this feature by the end of the week or early next week. Will keep things posted here! |
A fix was pushed in There is no change required in terms of URL API consumption. You can test it with: |
* feat: add fly.io * feat(readme): fly image width * feat(readme): add html image + badge * fix(docs): try space non-URL encoding * Update README.md * Update README.md * Update README.md * feat(docs): add fly.io info and links * feat(h2non#305, h2non#309, h2non#308, h2non#305. h2non#284) * fix(ci): golinter * fix(Dockerfile): use root folder for go test / ci linter * fix(ci): allow to fail go 1.14 build, still not sure why * fix(ci): bad yaml format * fix(ci): use travis-compatible regex * fix(ci): lets skip go1.14 for now * fix(mod): update dependencies
We're seeing images that fail on webp encoding, but work fine with just jpg. The actual issue is #270.
Is it possible to make imaginary fail gracefully and just return the jpeg data it has when this kind of error happens?
The text was updated successfully, but these errors were encountered: