def tempfile(self, mode='<STR_LIT:wb>', **args):
tf = tempfile.NamedTemporaryFile(mode=mode)<EOL>self.write(tf.name, mode=mode, **args)<EOL>return tfn<EOL>
write the contents of the file to a tempfile and return the tempfile filename