From b39a162ecbb2e9898c2f759e01ddd21f4af7f316 Mon Sep 17 00:00:00 2001 From: Perry Kundert Date: Mon, 7 Oct 2024 18:01:46 -0600 Subject: [PATCH] Add back in check for SEPARATING_LINE --- tabulate/__init__.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/tabulate/__init__.py b/tabulate/__init__.py index 6cf6ea3..296974d 100644 --- a/tabulate/__init__.py +++ b/tabulate/__init__.py @@ -2561,9 +2561,10 @@ def _format_table( if rows and fmt.linebetweenrows and "linebetweenrows" not in hidden: # initial rows with a line below for row, ralign in zip(rows[:-1], rowaligns): - append_row( - lines, pad_row(row, pad), padded_widths, colaligns, fmt.datarow, rowalign=ralign - ) + if row != SEPARATING_LINE: + append_row( + lines, pad_row(row, pad), padded_widths, colaligns, fmt.datarow, rowalign=ralign + ) _append_line(lines, padded_widths, colaligns, fmt.linebetweenrows) # the last row without a line below append_row(