SmileyChris/easy-thumbnails — Issue #98: Issues with the Lower level usage with S3
Author: epicserve
Created: 2011-11-18 00:13:39+00:00
State: open

I'm trying to cache thumbnails on S3 so they don't have to be created dynamically the first time the template is loaded. I'm using the 1.0-alpha-15 version of easy-thumbnails that I installed via pip. Also of note is that easy-thumbnails creates the thumbnails on S3 just fine dynamically. I'm not getting any errors.

I have the `THUMBNAIL_DEFAULT_STORAGE` set to `storages.backends.s3.S3Storage`.

The following is a snippet from the code I'm using:

``` python
def create_square_thumbnail(source):
log.info("Creating a thumbnail for %s" % source)
thumbnail_options = dict(size=(80, 80), crop=True, quality=75)
thumbnailer = get_thumbnailer(source)
thumbnailer.get_thumbnail(thumbnail_options, save=True)

page, created = Page.objects.get_or_create(pdf=pdf_rel_url, thumbnail=thumbnail_rel_url, page_number=page_num, section=section, edition=edition)
create_square_thumbnail(page.thumbnail)
```