Refuse a fit=outside size whose output exceeds the maximum (closes #257)
check / check (push) Waiting to run
check / check (push) Waiting to run
fit=outside scales the source to cover the requested size, and the side scaled past it was held to no maximum: 1x8192?fit=outside of a 3000x600 source was resized to 40960x8192 and encoded. resize now refuses such an output with ErrOutputTooLarge before resizing, so both image routes answer it 400 with the error a size with one side 0 already gets. The other fit modes make the requested size or one within it. README.md and TODO.md say so. Model: opus-5-5
This commit is contained in:
@@ -265,7 +265,9 @@ once, is refused with 400.
|
||||
|
||||
A size with one side `0` has that side scaled to keep the source's proportions,
|
||||
and is refused with 400 when that side would come out above 8192, the most
|
||||
either side may be.
|
||||
either side may be; so is a size with `fit=outside`, which scales the image to
|
||||
cover the size and so past it on one side, when that side would come out
|
||||
above 8192.
|
||||
|
||||
The source image may be JPEG, PNG, GIF, WebP, AVIF or JPEG XL. The upstream's
|
||||
`Content-Type` must name its format, and the image's first bytes must match it.
|
||||
|
||||
Reference in New Issue
Block a user