[Csv] PEP305 csv package: from csv import csv? (fwd)
Cliff Wells
LogiplexSoftware at earthlink.net
Tue Apr 8 16:13:51 CEST 2003
On Tue, 2003-04-08 at 08:12, Skip Montanaro wrote:
> Passing this along... I have no argument against what Hamish asks. Any
> thoughts from this crowd?
None here. I just didn't know how to do it =)
BTW, I know you're new here, but please don't top-post <wink>
>
> ______________________________________________________________________
>
> From: Hamish Lawson <hbl at st-andrews.ac.uk>
> To: python-list at zope.org
> Subject: PEP305 csv package: from csv import csv?
> Date: 08 Apr 2003 15:44:02 +0100
>
> According to the documentation in progress at
>
> http://www.python.org/dev/doc/devel/whatsnew/node14.html
>
> use of the forthcoming csv module (as described in PEP305) requires it to
> be imported from the csv package:
>
> from csv import csv
>
> input = open('datafile', 'rb')
> reader = csv.reader(input)
> for line in reader:
> print line
>
> Is there some reason why the cvs package's __init__.py doesn't import the
> required names from cvs.py, so allowing the shorter form below?
>
> import csv
>
> input = open('datafile', 'rb')
> reader = csv.reader(input)
> for line in reader:
> print line
>
>
> Hamish Lawson
--
Cliff Wells, Software Engineer
Logiplex Corporation (www.logiplex.net)
(503) 978-6726 x308 (800) 735-0555 x308
More information about the Csv
mailing list