[New-bugs-announce] [issue1033] Support for newline and encoding in tempfile module
report at bugs.python.org
Mon Aug 27 02:10:44 CEST 2007
New submission from Adam Hupp:
It would be useful for tempfile.TemporaryFile and friends to pass
newline and encoding arguments to the underlying io.open call. For
example, several tests in test_csv use TemporaryFile and need to handle
unicode file output or preserve exact newlines. This is simpler with
direct support in TemporaryFile.
The attached patch makes the following changes:
1) tempfile.TemporaryFile, NamedTemporaryFile, and SpooledTemporaryFile
now pass newline and encoding to the underlying io.open call.
2) test_tempfile is updated
3) test_csv is updated to use the new arguments.
components: Library (Lib)
title: Support for newline and encoding in tempfile module
versions: Python 3.0
Tracker <report at bugs.python.org>
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 12447 bytes
Desc: not available
Url : http://mail.python.org/pipermail/new-bugs-announce/attachments/20070827/ea64ffc3/attachment-0001.obj
More information about the New-bugs-announce