Message 164377 - Python tracker

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.

Content
> The proposal [1] is that TextIOWrapper support a set_encoding() method 
> that is only supported between creation of the stream and the first
> read or write operation.

That will be fragile. A bit of prematurate input or output (for whatever reason) and your program breaks.