string to list when the contents is a list

Benjamin Kaplan benjamin.kaplan at case.edu
Thu Feb 18 15:33:14 EST 2010


On Thu, Feb 18, 2010 at 2:56 PM, Wes James <comptekki at gmail.com> wrote:
>
> I get an error (when I take the "try" out):
>
> AttributeError: 'function' object has no attribute 'reader'
>

 You have a function called "csv" that's defined after the import csv
statement is executed. That function has no attribute 'reader", so you
get the error. By the way, don't use a bare except- it's bad form
because it hides any other problems you have.



More information about the Python-list mailing list