On Tue, 22 Nov 2011, Ethan Furman wrote:
They are closed automatically.
Ah, so.
It's not good practice to do this way, though better would be to assign
the open files to their own name, then you could 'name.close()' when you
were done.
Ethan,
That's what I thought you did in the lines
reader = csv.reader(open(filename,"r"),
delimiter="|",
quotechar="'")
output = csv.writer(open("out.txt","w"),
delimiter="|",
quotechar="'")
but reader.close() and output.close() generated python errors.
Rich
_______________________________________________
Portland mailing list
[email protected]
http://mail.python.org/mailman/listinfo/portland