-
-
Notifications
You must be signed in to change notification settings - Fork 18.8k
Closed
Labels
Error ReportingIncorrect or improved errors from pandasIncorrect or improved errors from pandasIO HTMLread_html, to_html, Styler.apply, Styler.applymapread_html, to_html, Styler.apply, Styler.applymapgood first issue
Description
The length of formatters
should match the number of columns
Both of these should error with a nice message.
In [2]: df = pd.DataFrame(columns=['a', 'b', 'c'])
In [3]: df.to_html(formatters=['{}'.format])
In [4]: df.to_html(formatters=['{}'.format] * 5)
Currntly In [4]
succeeds, silently ignoring the bad input. In[3]
values with a vague IndexError: list index out of range
.
Metadata
Metadata
Assignees
Labels
Error ReportingIncorrect or improved errors from pandasIncorrect or improved errors from pandasIO HTMLread_html, to_html, Styler.apply, Styler.applymapread_html, to_html, Styler.apply, Styler.applymapgood first issue