Skip to content

Commit

Permalink
fix: csvlook only reads up to --max-rows rows instead of the entire file
Browse files Browse the repository at this point in the history
  • Loading branch information
jpmckinney committed Feb 7, 2024
1 parent 9fa97d8 commit 7bba1bd
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 1 deletion.
2 changes: 2 additions & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,9 @@ Unreleased
----------

* feat: :doc:`/scripts/in2csv` adds a :code:`--reset-dimensions` option to `recalculate <https://openpyxl.readthedocs.io/en/stable/optimized.html#worksheet-dimensions>`_ the dimensions of an XLSX file, instead of trusting the file's metadata. csvkit's dependency `agate-excel <https://agate-excel.readthedocs.io/en/latest/>`_ 0.4.0 automatically recalculates the dimensions if the file's metadata expresses dimensions of "A1:A1" (a single cell).
* fix: :doc:`/scripts/csvlook` only reads up to :code:`--max-rows` rows instead of the entire file.
* fix: :doc:`/scripts/in2csv`: :code:`--write-sheets` no longer errors when standard input is an XLS or XLSX file.
* Update minimum agate version to 1.6.3.

1.3.0 - October 18, 2023
------------------------
Expand Down
1 change: 1 addition & 0 deletions csvkit/utilities/csvlook.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ def main(self):
self.input_file,
skip_lines=self.args.skip_lines,
sniff_limit=sniff_limit,
row_limit=self.args.max_rows,
column_types=self.get_column_types(),
line_numbers=self.args.line_numbers,
**self.reader_kwargs,
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@
],
},
install_requires=[
'agate>=1.6.1',
'agate>=1.6.3',
'agate-excel>=0.2.2',
'agate-dbf>=0.2.2',
'agate-sql>=0.5.3',
Expand Down

0 comments on commit 7bba1bd

Please sign in to comment.