Skip Montanaro <[EMAIL PROTECTED]> added the comment:
>> It works entirely based on chracter frequencies.
Amaury> Does it make sense to restrict delimiters to a reasonable set of
Amaury> characters? Usual punctuations, spaces, tabs... what else?
There is an optional delimiters argument to the sniff() method which
defaults to None. I would be happier if it was "the usual suspects"
(NeoOffice refuses to gues, but offers TAB, space, semicolon and comma as
the default separators when importing a CSV file - Excel seems to just
figure it out). That would change the behavior though. With no delimiter
set it's generally going to find something, just pick incorrectly. With a
non-existent delimiter set it's going to raise an exception. I'm not sure
this would be a good tradeoff and would just break existing code.
Skip
__________________________________
Tracker <[EMAIL PROTECTED]>
<http://bugs.python.org/issue2078>
__________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe:
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com