Skip to content
Open
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
2 changes: 1 addition & 1 deletion tabulate/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -1485,7 +1485,7 @@ def _normalize_tabular_data(tabular_data, headers, showindex="default"):

# add or remove an index column
showindex_is_a_str = type(showindex) in [str, bytes]
if showindex == "default" and index is not None:
if showindex_is_a_str and showindex == "default" and index is not None:
rows = _prepend_row_index(rows, index)
elif isinstance(showindex, Sized) and not showindex_is_a_str:
rows = _prepend_row_index(rows, list(showindex))
Expand Down