Skip to content

Conversation

@Endlessdelate
Copy link

Fix, bug: CSV import program incorrectly recognizes CSV files with "r\n"(CRLF) as line breaks, causing files to not be imported correctly
image

…r\n"(CRLF) as line breaks, causing files to not be imported correctly
@azonenberg
Copy link
Collaborator

What exactly is the bug? Is it that \r\n is interpreted as two line breaks, not one, on unix systems?

@azonenberg
Copy link
Collaborator

Also, all comments should be in English since the majority of the development team speaks English as a first or second language, but most of us (myself included) can't read Chinese well if at all. Please translate them.

@Endlessdelate
Copy link
Author

Endlessdelate commented Oct 26, 2025

The file.wfm.csv exported from my R&S oscilloscope uses CRLF ("\r\n") as line breaks, which cannot be correctly imported into your software on Windows system. The log information shows errors such as "ERROR: Malformed file." Therefore, I analyzed and modified the source code. After testing, it is now compatible with three types of line breaks: "\n" (Unix), "\r\n" (Windows), and "\r" (Mac). Of course, I will also translate the Chinese content in the program before submitting it again.

@Endlessdelate
Copy link
Author

Meanwhile, you can also use the following test files to test the original program.

sin_waveform_CR.csv
sin_waveform_LF.csv
sin_waveform_CRLF.csv

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants