google-code-export / django-photologue

Automatically exported from code.google.com/p/django-photologue
BSD 3-Clause "New" or "Revised" License
0 stars 0 forks source link

height=0 with "crop to fit" enabled crashes #90

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. create photo size
2. set height to 0
3. enable "crop to fit"

What is the expected output? What do you see instead?
i get an exception: tile cannot extend outside image
because the 0-height gets passed on to PIL. photologue should handle this
situation gracefully, even if "crop to fit" with height=0 doesn't make much
sense..

What version of the product are you using? On what operating system?
revision 354, debian linux, PIL 1.1.6

Please provide any additional information below.

Original issue reported on code.google.com by gundula....@gmail.com on 13 Dec 2008 at 4:25

Attachments:

GoogleCodeExporter commented 9 years ago
PhotoSize will now throw a ValueError on save if crop=True and width and height 
are 
zero.

Original comment by justin.d...@gmail.com on 23 Dec 2008 at 2:04