Serhiy Storchaka added the comment: Even more minimized artificial example:
from email._header_value_parser import * import email.policy tl = TokenList([ TokenList([ ValueTerminal('x', 'atext'), WhiteSpaceTerminal(' ', 'fws'), ValueTerminal('x'*76, 'atext'), ]), ValueTerminal(',', 'list-separator') ]) tl.fold(policy=email.policy.default) list(tl.parts)[0] == tl and tl.has_fws is True, so TokenList._fold() is called recursively with the same argument. ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue22684> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com