2👍
✅
Did you read the comments on http://djangosnippets.org/snippets/365/? Try:
For people on Windows you’ll need to specify "read binary" mode for anything other than a text file:
wrapper = FileWrapper(file(filename), "rb")
or
Got this working with a few tweaks:
wrapper = FileWrapper(open(filename, ‘rb’))
Source:stackexchange.com