Comment 1 for bug 731803

Revision history for this message
Pascal Bach (pascal-bach) wrote :

Hi

I can confirm this problem. The problem is that tempfile.mkstemp() returns a file handler to an open file which prevents os.rename from working on this file.
As a solution I close the file directly after creating the temporary file using os.close

I attached a patch for this.