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 martin.panter
Recipients benjamin.peterson, martin.panter, pitrou, serhiy.storchaka, socketpair, stutzbach
Date 2015-12-15.06:59:55
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1450162799.31.0.573636420049.issue25190@psf.upfronthosting.co.za>
In-reply-to
Content
There were a few tricky bits doing this with _pyio.StringIO, but I think I was successful. Here is a patch with both implementations and some tests. If people think this should go ahead, I can add documentation.

In the process I may have discovered a bug with the TextIOWrapper implementations. Is calling truncate() meant to truncate the internal read buffer? At the moment you can read back truncated data, although the underlying byte stream is actually truncated.
History
Date User Action Args
2015-12-15 06:59:59martin.pantersetrecipients: + martin.panter, pitrou, benjamin.peterson, stutzbach, socketpair, serhiy.storchaka
2015-12-15 06:59:59martin.pantersetmessageid: <1450162799.31.0.573636420049.issue25190@psf.upfronthosting.co.za>
2015-12-15 06:59:59martin.panterlinkissue25190 messages
2015-12-15 06:59:59martin.pantercreate