Skip to content

Commit

Permalink
remove empty rows
Browse files Browse the repository at this point in the history
  • Loading branch information
contrick64 committed Dec 20, 2024
1 parent e986e9e commit f73b4fc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion main.py
Original file line number Diff line number Diff line change
Expand Up @@ -219,9 +219,9 @@ def check_cols(filepath,sheet_name=None):
if not sheet_name:
sheet_name = get_sheet_name(filepath)
data = pd.read_excel(f,sheet_name)
data = data.fillna('')
# Remove empty rows
data.dropna(how='all', inplace=True)
data.fillna('',inplace=True)
# Check for empty column headers in pandas dataframe
headers = data.columns
# logging.debug(f"Headers: {headers}")
Expand Down

0 comments on commit f73b4fc

Please sign in to comment.