New submission from Serhiy Storchaka: When open the About IDLE dialog and press the README button on bottom line, I get the UnicodeDecodeError:
Exception in Tkinter callback Traceback (most recent call last): File "/home/serhiy/py/cpython/Lib/tkinter/__init__.py", line 1548, in __call__ return self.func(*args) File "/home/serhiy/py/cpython/Lib/idlelib/aboutDialog.py", line 127, in ShowIDLEAbout self.display_file_text('About - Readme', 'README.txt') File "/home/serhiy/py/cpython/Lib/idlelib/aboutDialog.py", line 139, in display_file_text textView.view_file(self, title, fn, encoding) File "/home/serhiy/py/cpython/Lib/idlelib/textView.py", line 74, in view_file contents = file.read() File "/home/serhiy/py/cpython/Lib/codecs.py", line 321, in decode (result, consumed) = self._buffer_decode(data, self.errors, final) UnicodeDecodeError: 'utf-8' codec can't decode byte 0x92 in position 72: invalid start byte That is because IDLE opens the Lib/idlelib/README.txt file with default (locale) encoding, while it contains the RIGHT SINGLE QUOTATION MARK character encoded with the CP1252 encoding and non-decodable with UTF-8. I think IDLE should open all distributed files with UTF-8 encoding. Lib/idlelib/CREDITS.txt and Lib/idlelib/README.txt should be recoded to UTF-8. ---------- components: IDLE messages: 256679 nosy: Rosuav, kbk, roger.serwy, serhiy.storchaka, terry.reedy priority: normal severity: normal status: open title: IDLE fails to display the README file type: behavior versions: Python 2.7, Python 3.5, Python 3.6 _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue25905> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com