Incomplete file save of models.FileField.save

7 views
Skip to first unread message

masterclock

unread,
Jul 2, 2009, 8:31:33 AM7/2/09
to Django users
I'm using python2.6 and django 1.0.2

class MyModel(Model):
file = models.FileField(...)
...

mymodel = MyModel(...)

mymodel.file.save(...)

but the saved file is truncated.

when I use admin, the uploaded file is also incomplete.

could anyone give me a reason.

Xiong Chiamiov

unread,
Jul 2, 2009, 12:54:21 PM7/2/09
to Django users
Are all files truncated? Are they truncated to a certain size? Does
this happen whether or not you're using the development server or
something else (Apache, etc.)? Just to make sure, have you tried
different browsers?

masterclock

unread,
Jul 2, 2009, 8:08:59 PM7/2/09
to Django users
All files are truncated regargless of its size or file type.
and, each file is truncated to a certain size.
this happens even I don't use a server.
I tried saving a file in "manage.py shell" from local disk to local
disk, but it is still incomplete.
Reply all
Reply to author
Forward
0 new messages