Closed
Description
Code Sample, a copy-pastable example if possible
import pandas as pd # version 0.23.0, the same as 1.0.0
df=pd.read_csv("1.csv",sep=r",") # 1.csv treat first row as header, which start with BOM due to some unknow reason.
print(df.columns)
Problem description
_check_for_bom will not just remove BOM, but also remove all the fields except for the first one.
due to code:
first_row = first_row[0] // line 2571 at parsers.py @0.23.0
first_row_bom = first_row[0] // line 2758 at parsers.py @latest code at github
Solution:
Change line 2775 at parsers.py @latest code at github to
return [first_row_bom[1:]]+first_row[1:]