Jeffrey Kintscher <websur...@surf2c.net> added the comment:
I looked at the implementation in Lib/_pyio.py. The only way to change the error handler is by calling TextIOWrapper.reconfigure() and supply the new error handler as the "errors" parameter. For example: >>> import io >>> s = io.TextIOWrapper(io.BytesIO()) >>> print(s.errors) strict >>> s.reconfigure(errors='replace') >>> print(s.errors) replace >>> ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue41465> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com