[New-bugs-announce] [issue12178] csv writer doesn't escape escapechar
Eric Breck
report at bugs.python.org
Wed May 25 20:27:10 CEST 2011
New submission from Eric Breck <ebreck at gmail.com>:
Consider the attached two files. A reader and writer with the same dialect parameters (escapechar \ quotechar " doublequote False) read, then write a CSV cell that looks like "C\\". It's written "C\". The problem is, when doublequote=False, the escapechar isn't used to escape itself, and the writer writes something that in the same dialect would be understood differently (\" isn't \ then end of string, it's an escaped quotechar within the string).
Execute python err.py first.csv to see.
----------
components: None
files: pybug.zip
messages: 136881
nosy: ebreck
priority: normal
severity: normal
status: open
title: csv writer doesn't escape escapechar
type: behavior
versions: Python 2.6, Python 2.7
Added file: http://bugs.python.org/file22112/pybug.zip
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue12178>
_______________________________________
More information about the New-bugs-announce
mailing list