Closed doryphores closed 12 years ago
Traceback (most recent call last):
File "/site-packages/django/core/handlers/base.py", line 111, in get_response response = callback(request, _callback_args, *_callback_kwargs)
File "/apod/views.py", line 53, in picture_json picture.get_image()
File "/apod/models.py", line 364, in get_image self.image.save(filename, image_file, save=False)
File "/site-packages/django/db/models/fields/files.py", line 87, in save setattr(self.instance, self.field.name, self.name)
File "/site-packages/django/db/models/fields/files.py", line 308, in set self.field.update_dimension_fields(instance, force=True)
File "/site-packages/django/db/models/fields/files.py", line 378, in update_dimension_fields width = file.width
File "/site-packages/django/core/files/images.py", line 15, in _get_width return self._get_image_dimensions()[0]
TypeError: 'NoneType' object has no attribute 'getitem'
Not much can be done about this one. PIL simply cannot get the size information from the file. Fixed by manually uploading a fixed version.
Traceback (most recent call last):
File "/site-packages/django/core/handlers/base.py", line 111, in get_response response = callback(request, _callback_args, *_callback_kwargs)
File "/apod/views.py", line 53, in picture_json picture.get_image()
File "/apod/models.py", line 364, in get_image self.image.save(filename, image_file, save=False)
File "/site-packages/django/db/models/fields/files.py", line 87, in save setattr(self.instance, self.field.name, self.name)
File "/site-packages/django/db/models/fields/files.py", line 308, in set self.field.update_dimension_fields(instance, force=True)
File "/site-packages/django/db/models/fields/files.py", line 378, in update_dimension_fields width = file.width
File "/site-packages/django/core/files/images.py", line 15, in _get_width return self._get_image_dimensions()[0]
TypeError: 'NoneType' object has no attribute 'getitem'