New submission from Serhiy Storchaka: MemoryError raised in readline.set_completer_delims() turns the readline library to incorrect state.
$ (ulimit -v 200000; ./python;) Python 3.6.0a0 (default:e33b4c18af59+, Sep 17 2015, 17:05:17) [GCC 4.8.4] on linux Type "help", "copyright", "credits" or "license" for more information. >>> import readline >>> readline.get_completer_delims() ' \t\n`~!@#$%^&*()-=+[{]}\\|;:\'",<>/?' >>> readline.set_completer_delims(' '*10**8) Traceback (most recent call last): File "<stdin>", line 1, in <module> MemoryError >>> readline.get_completer_delims() Traceback (most recent call last): File "<stdin>", line 1, in <module> UnicodeDecodeError: 'utf-8' codec can't decode byte 0xe4 in position 1: invalid continuation byte Proposed patch fixes the issue. ---------- components: Extension Modules files: readline_set_completer_delims.patch keywords: patch messages: 251239 nosy: serhiy.storchaka, twouters priority: normal severity: normal stage: patch review status: open title: Incorrect handling MemoryError in readline.set_completer_delims type: behavior versions: Python 2.7, Python 3.4, Python 3.5, Python 3.6 Added file: http://bugs.python.org/file40535/readline_set_completer_delims.patch _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue25203> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com