I try the following code to write csv.
df = pd.DataFrame({'A': [1, 2, 3, 4, 5]})
with open('D:/Test/1.csv', 'w') as f:
df.to_csv(f, index=False)
df.to_csv('D:/Test/2.csv', index=False)
The 1.csv would have empty row between each row, and 2.csv looks fine. Anyone knows why? I am using pandas '0.24.2'