title: Uploading CSV files to S3 directly through Django
body: <p>I am creating a django application which is connected to Amazon S3 to save user upload files. This is done using django-storages.</p>
  <p>During the course of the app a CSV file is generated. I am able to save the file locally. But how can I upload the file directly to S3 without saving it locally and save the file S3 URL in the database at the same time?</p>
  <p>I have tried using StringIO but that generates a TypeError: Unicode objects must be encoded before hashing</p>
  <p>Any suggestions/solutions will be much appreciated!</p>