[issue1286] fileinput, StringIO, and cStringIO do not support the with protocol
Yitz Gale
report at bugs.python.org
Thu Oct 25 14:09:00 CEST 2007
Yitz Gale added the comment:
I was actually bitten badly by this issue with
StringIO. I added fileinput only as an afterthought.
In an xml.sax app, I needed seek() support for a
codec-wrapped file handle, so I over-wrapped it with
StringIO. The result was that I had to refactor code all over
the place to handle StringIO as a special case. What a
mess!
Why is this getting over-excited? It's a very
lightweight change. You can't beat the cost/benefit ratio.
__________________________________
Tracker <report at bugs.python.org>
<http://bugs.python.org/issue1286>
__________________________________
More information about the Python-bugs-list
mailing list