Bug 219850

Summary: ascii source reader is not robust enough
Product: [Applications] kst Reporter: GrĂ©goire Verlut <gregoire.verlut>
Component: generalAssignee: kst
Status: RESOLVED NOT A BUG    
Severity: normal CC: arwalker, wino
Priority: NOR    
Version: 1.7.0   
Target Milestone: ---   
Platform: unspecified   
OS: Linux   
Latest Commit: Version Fixed In:

Description Grégoire Verlut 2009-12-23 17:38:17 UTC
Version:           2.0.0_devel (using unspecified)
OS:                Windows 32-Bit

When using the option "custom delimiter" with comma as delimiter, the following problems appear:
, 1234, will be read as nan because of the leading space
,12/24/09,123 will cause 123 to be read as nan because of the /. If it is instead a : or letters, 123 is read as 123.
Comment 1 Ron Jensen 2010-04-11 06:31:31 UTC
I see this with 1.7.1 from debian lenny and 1.9.1 from SVN, too.  I have to pipe my csv files through sed 's/, /,/' to get them to read.
Comment 2 Andrew Walker 2010-04-12 20:09:41 UTC
At least part of the problem is that by default the '/' character is defined as a comment indicator, meaning that everything following it on a line will be treated as a comment (and so not read).

Removing the '/' character from the list of comment indicators in the configure dialog fixes this part of the problem.
Comment 3 Andrew Walker 2010-04-12 20:14:01 UTC
There are no remaining problems once '/' is removed as a comment indicator.
Comment 4 Andrew Walker 2010-04-12 23:06:18 UTC
In order to correctly read the entries that appear as:

, 1234,

the custom delimiters should be change from "," to " ," i.e. add a space