netcreateorg / netcreate-itest

Developing the 2.0 version of NetCreate
https://github.com/netcreateorg/netcreate-2018
Other
0 stars 0 forks source link

Import from PC csv chokes on carriage return at end of file #136

Closed jdanish closed 7 months ago

jdanish commented 7 months ago

We ran into an issue where we export a nodes table, change it in excel, save it as csv and re-upload. On the Mac it worked fine, but on PC it throws the error attached.

image

I opened the file on a Mac in source code and see an extra empty line. If I delete that line then the file opens just fine. Can we somehow ignore the final carriage return or account for it in those cases that someone edits / saves on a PC?

Not a high priority since we can handle it socially for now.

benloh commented 7 months ago

Yeah this looks like an annoying Windows Excel issue. It should not be adding blank lines. There's a ton of references to this problem.

A more general solution is to just ignore any blank lines anywhere. I'll add this.

The bigger question is how/when to fold in the changes. We're currently in the dev branch, which has some changes post v1.5.1. Do you want to add this to master 1.5.1? Or after the meta-fixes #129? Or after we finish the comment feature?

jdanish commented 7 months ago

Whatever is most convenient - after / with the comments is aok.