-
Notifications
You must be signed in to change notification settings - Fork 2.7k
Closed
Labels
T: bugSomething isn't workingSomething isn't working
Description
$ black --fast -c '''
try: pass
except (a := 1) as (b := why_does_this_exist): pass
'''
try:
pass
except (a := 1) as (b := why_does_this_exist):
pass
$ black --preview --fast -c '''
try: pass
except (a := 1) as (b := why_does_this_exist): pass
'''
try: pass
except (a := 1) as (b := why_does_this_exist): pass
error: cannot format <string>: Cannot parse: 3:9: except a := 1 as (b := why_does_this_exist):
$ black --version
black, 22.12.0 (compiled: yes)
Python (CPython) 3.9.14
Similar to #3419, found this in CI for #3418. This needs --fast because CPython actually rejects walrus here (good call), but the grammar allows it.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
T: bugSomething isn't workingSomething isn't working