Rich Leland committed 201cea9

Fixes #89: broken StringIO import in CloudFiles.

This bug was introduced by commit 0b6ff832b77b.

Comments (0)

Files changed (1)


 Custom storage for django with Mosso Cloud Files backend.
 Created by Rich Leland <>.
-from _io import StringIO
 import os
 from django.conf import settings
 from django.core.exceptions import ImproperlyConfigured
 from django.core.files import File
 from django.utils.text import get_valid_filename
+    from cStringIO import StringIO
+    from StringIO import StringIO
     import cloudfiles
     from cloudfiles.errors import NoSuchObject
 except ImportError:
         cloud_obj = self.container.create_object(name)
         cloud_obj.size = content.size
         # If the content type is available, pass it in directly rather than
         # getting the cloud object to try to guess.
         if hasattr(content.file, 'content_type'):