New submission from Serhiy Storchaka <storchaka+cpyt...@gmail.com>:
In Lib/idlelib/searchengine.py there is a code which decomposes re.error and reports error message, pattern, and position of error. The problem is that that code does not match the structure of re.error. It takes args[0] as error message, and args[1] (if specified) as position in the pattern. But actually re.error always sets args[0] to formatted error message, and args has only one item. So some code in IDLE is dead. Currently reported: Error: bad escape \z at position 1 Pattern: a\z Expected: Error: bad escape \z Pattern: a\z Offset: 1 ---------- assignee: terry.reedy components: IDLE messages: 381566 nosy: serhiy.storchaka, terry.reedy priority: normal severity: normal status: open title: IDLE: Fix reporting RE error in searchengine versions: Python 3.10, Python 3.8, Python 3.9 _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue42426> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com