New submission from Florian Bruhin: I just found this thanks to Hypothesis[1]:
>>> import re >>> re.compile('(' * 500) Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/usr/lib/python3.5/re.py", line 224, in compile return _compile(pattern, flags) File "/usr/lib/python3.5/re.py", line 293, in _compile p = sre_compile.compile(pattern, flags) File "/usr/lib/python3.5/sre_compile.py", line 536, in compile p = sre_parse.parse(p, flags) File "/usr/lib/python3.5/sre_parse.py", line 829, in parse p = _parse_sub(source, pattern, 0) File "/usr/lib/python3.5/sre_parse.py", line 437, in _parse_sub itemsappend(_parse(source, state)) File "/usr/lib/python3.5/sre_parse.py", line 778, in _parse p = _parse_sub(source, state) File "/usr/lib/python3.5/sre_parse.py", line 437, in _parse_sub itemsappend(_parse(source, state)) File "/usr/lib/python3.5/sre_parse.py", line 778, in _parse p = _parse_sub(source, state) File "/usr/lib/python3.5/sre_parse.py", line 437, in _parse_sub itemsappend(_parse(source, state)) [...] File "/usr/lib/python3.5/sre_parse.py", line 493, in _parse subpattern = SubPattern(state) RecursionError: maximum recursion depth exceeded It seems a maximum recursion error has been treated as a bug before (like in issue401612), so I'm guessing this isn't intended here either. [1] https://hypothesis.readthedocs.org/ ---------- components: Library (Lib) messages: 254040 nosy: The Compiler, effbot, ezio.melotti, pitrou, serhiy.storchaka priority: normal severity: normal status: open title: RecursionError in re with '(' * 500 type: behavior versions: Python 3.4, Python 3.5 _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue25550> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com