Commit 4cad7d6
authored
Ensure empty last line isnt printed when writing TSV (#559)
when printing df.to_csv(sep=sep, index=False), a line break is added
automatically;
print(x) is also adding a line break, so when the dataframe string is
printed, two line breaks are printed, leading to an empty line.
I also refactored the `lines` part a bit moving it inside the
conditional, as they are only needed there.1 parent f15975a commit 4cad7d6
1 file changed
+3
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
62 | 62 | | |
63 | 63 | | |
64 | 64 | | |
65 | | - | |
66 | | - | |
67 | | - | |
68 | 65 | | |
69 | 66 | | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
70 | 70 | | |
71 | 71 | | |
72 | 72 | | |
| |||
0 commit comments