1. David Larlet
  2. django-storages
  3. Issues


Issue #138 invalid

[s3boto] Problem uploading media files

created an issue

I am trying to upload media files to S3, I am using a variation of S3BotoStorage but I am receiving the following error:

'cStringIO.StringO' object has no attribute 'size'

I not have idea about the cause of this error. I test the app with django-storages 1.1.4, django 1.3. After the error appear, I update the versions of these libraries without luck.

I appreciate your help

Comments (6)

  1. darkness51 reporter

    The problem was caused because I was trying to use GZIP_CONTENT_TYPES for images and DEFAULT_FILE_STORAGE but this not works.

    I created a custom S3BotoStorage class without images content types in GZIP_CONTENT_TYPES and works.

    I only have the question about why this feature works in static files but not work media files.

  2. darkness51 reporter

    You can close the bug.

    The problem was used because I am trying to use gzip compression in media files (Files uploaded to /media/)

    Best Regards

  3. Log in to comment