diff options
author | INADA Naoki <songofacandy@gmail.com> | 2016-10-21 10:47:57 (GMT) |
---|---|---|
committer | INADA Naoki <songofacandy@gmail.com> | 2016-10-21 10:47:57 (GMT) |
commit | 0a421a28f87f2a01566e443fc59203d0b7bcb3b8 (patch) | |
tree | fb304d99a0decc4b3beae18b0bbed1704628edf7 /Doc/library/csv.rst | |
parent | 4510e6de9d38987c5b00ce416da19fe9ffc2dde9 (diff) | |
download | cpython-0a421a28f87f2a01566e443fc59203d0b7bcb3b8.zip cpython-0a421a28f87f2a01566e443fc59203d0b7bcb3b8.tar.gz cpython-0a421a28f87f2a01566e443fc59203d0b7bcb3b8.tar.bz2 |
Issue #18219: Optimize csv.DictWriter for large number of columns.
Patch by Mariatta Wijaya.
Diffstat (limited to 'Doc/library/csv.rst')
-rw-r--r-- | Doc/library/csv.rst | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/Doc/library/csv.rst b/Doc/library/csv.rst index 6341bc3..f916572 100644 --- a/Doc/library/csv.rst +++ b/Doc/library/csv.rst @@ -195,10 +195,12 @@ The :mod:`csv` module defines the following classes: written if the dictionary is missing a key in *fieldnames*. If the dictionary passed to the :meth:`writerow` method contains a key not found in *fieldnames*, the optional *extrasaction* parameter indicates what action to - take. If it is set to ``'raise'`` a :exc:`ValueError` is raised. If it is - set to ``'ignore'``, extra values in the dictionary are ignored. Any other - optional or keyword arguments are passed to the underlying :class:`writer` - instance. + take. + If it is set to ``'raise'``, the default value, a :exc:`ValueError` + is raised. + If it is set to ``'ignore'``, extra values in the dictionary are ignored. + Any other optional or keyword arguments are passed to the underlying + :class:`writer` instance. Note that unlike the :class:`DictReader` class, the *fieldnames* parameter of the :class:`DictWriter` is not optional. Since Python's :class:`dict` |