STINNER Victor <vstin...@python.org> added the comment:
The following change broke test_fstring when using the old parser. I reopen the issue. commit 846d8b28ab9bb6197ee81372820311c0abe509c0 (refs/bisect/bad) Author: Lysandros Nikolaou <lisandros...@gmail.com> Date: Mon May 4 14:32:18 2020 +0300 bpo-40246: Revert reporting of invalid string prefixes (GH-19888) Due to backwards compatibility concerns regarding keywords immediately followed by a string without whitespace between them (like in `bg="#d00" if clear else"#fca"`) will fail to parse, commit 41d5b94af44e34ac05d4cd57460ed104ccf96628 has to be reverted. $ ./python -X oldparser -m test -v test_fstring (...) ====================================================================== FAIL: test_invalid_string_prefixes (test.test_fstring.TestCase) (str='BF""') ---------------------------------------------------------------------- File "<string>", line 1 BF"" ^ SyntaxError: invalid syntax During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/home/vstinner/python/master/Lib/test/test_fstring.py", line 29, in assertAllRaise eval(str) AssertionError: "unexpected EOF while parsing" does not match "invalid syntax (<string>, line 1)" (...) ---------- resolution: wont fix -> status: closed -> open _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue40246> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com