﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
10485	Incomplete file interface for django.core.files.temp.TemporaryFile (Windows only)	tzonghao	tzonghao	"On Windows, when an uploaded is stored as a temporary file, it is wrapped as {{{django.core.files.temp.TemporaryFile}}}.  That class lacks proper seek and tell interfaces which will result in errors when a client of the class is trying to use the file's {{{seek}}} and {{{tell}}} methods.  Specifically, the seek implementation only takes one argument, while a file's {{{seek}}} method can take an optional 'whence' argument.  And the {{{tell}}} method is missing.

For example, to reproduce the error caused by this, 

 1. Upload any file large enough for it to be stored as a temp file to a server running on Windows.
 2. Construct a {{{zipfile.ZipFile}}} object with the {{{TemporaryFile}}} instance.
 3. The {{{ZipFile.__init__}}} will fail when it tries to call {{{TemporaryFile}}}'s {{{seek}}} with two arguments, or when it calls the file's {{{tell}}} method.

"		closed	File uploads/storage	1.0		duplicate	file, seek, tell		Unreviewed	0	0	0	0	0	0
