Re: Possible bug with UploadedFile and form validation?

2016-06-13 Thread Simon Charette
Hi Nick, `io.TextIOWrapper` objects close their wrapped file when they are garbage collected (e.g. `__del__()`). This is similar to how `File` objects close their underlying file descriptor when collected. In the case of your `clean()` method the `file` object can be garbaged collected as soon

Possible bug with UploadedFile and form validation?

2016-06-13 Thread Nick Sarbicki
I've got an odd bug in my system, and while I'm not 100% convinced it is a Django bug, I don't think it is due to me either so thought I'd ask here for some clarification. Essentially if you upload a file to a form. If that forms clean() method reads that file (in my case it gathers data and