This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author serhiy.storchaka
Recipients bkabrda, ethan.furman, georg.brandl, ncoghlan, paul.moore, python-dev, sYnfo, serhiy.storchaka, vstinner, wolma
Date 2015-03-20.14:13:16
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
> csv.reader(fileobj) returns the generator created by fileobj.__iter__, but no reference to it is kept so the object gets destroyed right afterwards. This closes the generator and because it uses yield from also the contained subgenerator, which is the file itself.

Yes, there are no references to to the generator, created by fileobj.__iter__, but there are references to fileobj itself and to the file fileobj.file. I still don't understand why the file is closed. This looks as a bug.

Committed existing fix only to make buildbots green.
Date User Action Args
2015-03-20 14:13:16serhiy.storchakasetrecipients: + serhiy.storchaka, georg.brandl, paul.moore, ncoghlan, vstinner, ethan.furman, python-dev, bkabrda, sYnfo, wolma
2015-03-20 14:13:16serhiy.storchakasetmessageid: <>
2015-03-20 14:13:16serhiy.storchakalinkissue23700 messages
2015-03-20 14:13:16serhiy.storchakacreate