| <type 'exceptions.IOError'> | Python 2.6.8: /usr/local/bin/python2.6 Wed Nov 23 05:58:32 2016 |
A problem occurred in a Python script. Here is the sequence of function calls leading up to the error, in the order they occurred.
| /var/www/static/epmghispanic.media.clients.ellingtoncms.com/media/mogrify.py in |
| 171 </html> |
| 172 """ |
| 173 |
| 174 if __name__ == '__main__': |
| 175 mogrify() |
| mogrify = <function mogrify> |
| /var/www/static/epmghispanic.media.clients.ellingtoncms.com/media/mogrify.py in mogrify() |
| 130 |
| 131 m = mogrifier.Mogrifier(original_file) |
| 132 m.apply_action_tuples(action_tuples) |
| 133 m.save(requested_path) |
| 134 |
| m = <mogrifier.Mogrifier instance>, m.apply_action_tuples = <bound method Mogrifier.apply_action_tuples of <mogrifier.Mogrifier instance>>, action_tuples = [('r', '100x90')] |
| /var/www/static/common/mogrifier.py in apply_action_tuples(self=<mogrifier.Mogrifier instance>, actions=[('r', '100x90')]) |
| 48 else: |
| 49 args = [arg] |
| 50 getattr(self, action)(*args) |
| 51 |
| 52 def parse_size(self, size, hold_proportion=False): |
| builtin getattr = <built-in function getattr>, self = <mogrifier.Mogrifier instance>, action = 'resize', args = ['100x90'] |
| /var/www/static/common/mogrifier.py in resize(self=<mogrifier.Mogrifier instance>, size='100x90') |
| 114 new_w, new_h = self.parse_size(size) |
| 115 if (old_h / (old_w / float(new_w))) < new_h: |
| 116 self.thumbnail("x%s" % new_h) |
| 117 self.crop(str(new_w)) |
| 118 else: |
| self = <mogrifier.Mogrifier instance>, self.thumbnail = <bound method Mogrifier.thumbnail of <mogrifier.Mogrifier instance>>, new_h = 90 |
| /var/www/static/common/mogrifier.py in thumbnail(self=<mogrifier.Mogrifier instance>, size='x90') |
| 90 """Thumbnail (maintaining dimensions)""" |
| 91 w, h = self.parse_size(size, True) |
| 92 self.im = ImageOps.fit(self.im, (w, h), Image.ANTIALIAS, centering=(0.0, 0.0)) |
| 93 if self.im.mode != "P": |
| 94 sharpener = ImageEnhance.Sharpness(self.im) |
| self = <mogrifier.Mogrifier instance>, self.im = <JpegImagePlugin.JpegImageFile image mode=RGB size=1590x1283>, global ImageOps = <module 'PIL.ImageOps' from '/usr/local/lib/python2.6/site-packages/PIL/ImageOps.pyc'>, ImageOps.fit = <function fit>, w = 111, h = 90, global Image = <module 'Image' from '/usr/local/lib/python2.6/site-packages/PIL/Image.pyc'>, Image.ANTIALIAS = 1, centering undefined |
| /usr/local/lib/python2.6/site-packages/PIL/ImageOps.py in fit(image=<JpegImagePlugin.JpegImageFile image mode=RGB size=1590x1283>, size=(111, 90), method=1, bleed=0.0, centering=[0.0, 0.0]) |
| 327 |
| 328 out = image.crop( |
| 329 (leftSide, topSide, leftSide + cropWidth, topSide + cropHeight) |
| 330 ) |
| 331 |
| leftSide = 0, topSide = 0, cropWidth = 1581, cropHeight = 1282 |
| /usr/local/lib/python2.6/site-packages/PIL/Image.py in crop(self=<JpegImagePlugin.JpegImageFile image mode=RGB size=1590x1283>, box=(0, 0, 1581, 1282)) |
| 761 "Crop region from image" |
| 762 |
| 763 self.load() |
| 764 if box is None: |
| 765 return self.copy() |
| self = <JpegImagePlugin.JpegImageFile image mode=RGB size=1590x1283>, self.load = <bound method JpegImageFile.load of <JpegImagePlugin.JpegImageFile image mode=RGB size=1590x1283>> |
| /usr/local/lib/python2.6/site-packages/PIL/ImageFile.py in load(self=<JpegImagePlugin.JpegImageFile image mode=RGB size=1590x1283>) |
| 199 if not s: |
| 200 self.tile = [] |
| 201 raise IOError("image file is truncated (%d bytes not processed)" % len(b)) |
| 202 b = b + s |
| 203 n, e = d.decode(b) |
| builtin IOError = <type 'exceptions.IOError'>, builtin len = <built-in function len>, b = '\xf0\xb7\x83|4\xde\x1a\xf1\x84\xfa\x9e\x81q\xe1\xcf\nK{\xf1\x13U\xd5\xae-\xf5_\x12iK\xa9\xf8\xff\x00]\xd3\xf4\xbdj\xcfE\xf0\xda[\xe9\xd2|T\xd6...U\xf1\x07\x8e\x93\xc3W\xf7v\xfa\x87\x86\xbe\x14\xe9o\xa2Y\xfc\x1d\x86\xda\xe6\xf6\xed\xf4\xd1o\x94\xd1\xa3}\x8d\x1f\xe1\x0c\x91\xea7Z_\x80<G\xe0MI\xb4\xb9' |
<type 'exceptions.IOError'>: image file is truncated (226 bytes not processed)
args =
('image file is truncated (226 bytes not processed)',)
errno =
None
filename =
None
message =
'image file is truncated (226 bytes not processed)'
strerror =
None