[RFC] store inventory in tab-separated file

Dmitry Vasiliev dima at hlabs.spb.ru
Mon Jan 29 09:07:07 GMT 2007


Alexander Belchenko пишет:
> Dmitry Vasiliev пишет:
>> Alexander Belchenko пишет:
>>> Jari Aalto пишет:
>>>>
>>>> Perhaps just plain space, colon, semicolon or any other
>>>> standard-visible character?
>>> This file is not intended to be editable by user.
>>> So I say 'no'. TAB is deliberated choice.
>> But for CSV files parsing you can use csv builtin module which can be
>> easy to use and faster.
> 
> I cannot agree with you about csv module.
> I don't think it will be faster: it's the pure python module,
> it uses regular expressions to parse input,
> it more complicated because it's general purpose.
> So I'm pretty sure that it cannot be faster of my
> strictly specialized implementation.

Actually, csv.reader is implemented in C, but only profiling can tells 
which implementation is faster.

-- 
Dmitry Vasiliev (dima at hlabs.spb.ru)
     http://hlabs.spb.ru



More information about the bazaar mailing list