strang thing:

Chris Angelico rosuav at gmail.com
Tue Sep 6 10:22:37 CEST 2011


2011/9/6 守株待兔 <1248283536 at qq.com>:
>     file = open(filename,'r')

> when i  add    (date,open,high,low,close,vol,adjclose) = (row[0], row[1],

You're assigning to the name "open", which is shadowing the built-in
of the same name. The second time through the loop, you're not calling
the usual open() function, you're trying to call your string. That's
what your error is telling you.

Hope that helps!

ChrisA



More information about the Python-list mailing list