Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 0 additions & 5 deletions doc/source/io.rst
Original file line number Diff line number Diff line change
Expand Up @@ -199,11 +199,6 @@ low_memory : boolean, default ``True``
Note that the entire file is read into a single DataFrame regardless,
use the ``chunksize`` or ``iterator`` parameter to return the data in chunks.
(Only valid with C parser)
buffer_lines : int, default None
.. deprecated:: 0.19.0

Argument removed because its value is not respected by the parser

compact_ints : boolean, default False
.. deprecated:: 0.19.0

Expand Down
1 change: 1 addition & 0 deletions doc/source/whatsnew/v0.22.0.txt
Original file line number Diff line number Diff line change
Expand Up @@ -227,6 +227,7 @@ Removal of prior version deprecations/changes
- ``DatetimeIndex.to_datetime``, ``Timestamp.to_datetime``, ``PeriodIndex.to_datetime``, and ``Index.to_datetime`` have been removed (:issue:`8254`, :issue:`14096`, :issue:`14113`)
- :func:`read_csv` has dropped the ``skip_footer`` parameter (:issue:`13386`)
- :func:`read_csv` has dropped the ``as_recarray`` parameter (:issue:`13373`)
- :func:`read_csv` has dropped the ``buffer_lines`` parameter (:issue:`13360`)

.. _whatsnew_0220.performance:

Expand Down
3 changes: 1 addition & 2 deletions pandas/_libs/parsers.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -360,7 +360,6 @@ cdef class TextReader:
allow_leading_cols=True,
use_unsigned=False,
low_memory=False,
buffer_lines=None,
skiprows=None,
skipfooter=0,
verbose=False,
Expand Down Expand Up @@ -557,7 +556,7 @@ cdef class TextReader:
if not self.table_width:
raise EmptyDataError("No columns to parse from file")

# compute buffer_lines as function of table width
# Compute buffer_lines as function of table width.
heuristic = 2**20 // self.table_width
self.buffer_lines = 1
while self.buffer_lines * 2 < heuristic:
Expand Down
9 changes: 0 additions & 9 deletions pandas/io/parsers.py
Original file line number Diff line number Diff line change
Expand Up @@ -273,9 +273,6 @@
Note that the entire file is read into a single DataFrame regardless,
use the `chunksize` or `iterator` parameter to return the data in chunks.
(Only valid with C parser)
buffer_lines : int, default None
.. deprecated:: 0.19.0
This argument is not respected by the parser
compact_ints : boolean, default False
.. deprecated:: 0.19.0
Argument moved to ``pd.to_numeric``
Expand Down Expand Up @@ -503,7 +500,6 @@ def _read(filepath_or_buffer, kwds):
'use_unsigned': False,
'low_memory': True,
'memory_map': False,
'buffer_lines': None,
'error_bad_lines': True,
'warn_bad_lines': True,
'tupleize_cols': False,
Expand All @@ -518,18 +514,15 @@ def _read(filepath_or_buffer, kwds):
_c_unsupported = {'skipfooter'}
_python_unsupported = {
'low_memory',
'buffer_lines',
'float_precision',
}

_deprecated_defaults = {
'buffer_lines': None,
'compact_ints': None,
'use_unsigned': None,
'tupleize_cols': None
}
_deprecated_args = {
'buffer_lines',
'compact_ints',
'use_unsigned',
'tupleize_cols',
Expand Down Expand Up @@ -606,7 +599,6 @@ def parser_f(filepath_or_buffer,
compact_ints=None,
use_unsigned=None,
low_memory=_c_parser_defaults['low_memory'],
buffer_lines=None,
memory_map=False,
float_precision=None):

Expand Down Expand Up @@ -676,7 +668,6 @@ def parser_f(filepath_or_buffer,
warn_bad_lines=warn_bad_lines,
error_bad_lines=error_bad_lines,
low_memory=low_memory,
buffer_lines=buffer_lines,
mangle_dupe_cols=mangle_dupe_cols,
tupleize_cols=tupleize_cols,
infer_datetime_format=infer_datetime_format,
Expand Down
4 changes: 1 addition & 3 deletions pandas/tests/io/parser/test_unsupported.py
Original file line number Diff line number Diff line change
Expand Up @@ -128,9 +128,7 @@ def read(self):
class TestDeprecatedFeatures(object):

@pytest.mark.parametrize("engine", ["c", "python"])
@pytest.mark.parametrize("kwargs", [{"buffer_lines": True},
{"buffer_lines": False},
{"compact_ints": True},
@pytest.mark.parametrize("kwargs", [{"compact_ints": True},
{"compact_ints": False},
{"use_unsigned": True},
{"use_unsigned": False},
Expand Down