Closed asottile closed 4 years ago
fun times, this is a syntax error in python3.7+
FFS.
They really need to add :sob: to the reaction list.
but actually 😢 😭 😢
here's how I noticed :salt: https://github.com/asottile/pyupgrade/pull/45/commits/6a1816aabf2d0dc57f7a5af55258f803bbb3bf06
instead of fixing lib2to3, they changed how the parser works so this is now kinda "invalid"
$ python3.6 -c 'print(1 for _ in range(4),)'
<generator object <genexpr> at 0x7fc713b9baf0>
$ python3.7 -c 'print(1 for _ in range(4),)'
File "<string>", line 1
SyntaxError: Generator expression must be parenthesized