You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Python 3.9.21
'\r\n'
Python 3.10.16
'\r\n'
Python 3.11.11
Traceback (most recent call last):
File "/tmp/csvtest.py", line 4, in <module>
csv.writer(b, quoting=csv.QUOTE_NONE, lineterminator='\n').writerow(["\r"])
_csv.Error: need to escape, but no escapechar set
Python 3.12.8
Traceback (most recent call last):
File "/tmp/csvtest.py", line 4, in <module>
csv.writer(b, quoting=csv.QUOTE_NONE, lineterminator='\n').writerow(["\r"])
_csv.Error: need to escape, but no escapechar set
Python 3.13.1
Traceback (most recent call last):
File "/tmp/csvtest.py", line 4, in <module>
csv.writer(b, quoting=csv.QUOTE_NONE, lineterminator='\n').writerow(["\r"])
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^
_csv.Error: need to escape, but no escapechar set
As in Python 3.10 and earlier, escaping the carriage return character (\r) should not be necessary (due to the custom lineterminator), but Python 3.11+ still expects it.
CPython versions tested on:
3.9, 3.10, 3.11, 3.12, 3.13
Operating systems tested on:
Linux
The text was updated successfully, but these errors were encountered:
Bug report
Bug description:
The following
csvtest.py
script works for Python 3.10 and earlier but fails for 3.11 and later:For example, running the shell script …
… yields:
As in Python 3.10 and earlier, escaping the carriage return character (
\r
) should not be necessary (due to the customlineterminator
), but Python 3.11+ still expects it.CPython versions tested on:
3.9, 3.10, 3.11, 3.12, 3.13
Operating systems tested on:
Linux
The text was updated successfully, but these errors were encountered: