On Nov 22, 2:28 am, Joe Strout <[EMAIL PROTECTED]> wrote: > A follow-up question here... is it really necessary to close things > like files in Python?
Not if you use a context manager (2.6+, available in 2.5 from __future__): with open('data.csv', 'wb') as csvfile: writer = csv.writer(csvfile) ... The file is guaranteed to be closed at the end of the with-statement block. -- http://mail.python.org/mailman/listinfo/python-list