Module Expr Str ImportFrom alias ImportFrom alias ImportFrom alias ImportFrom alias alias alias alias alias alias FunctionDef arguments args NameParam defaults body For TupleStore NameStore NameStore Call NameLoad NameLoad body If CompareEq AttributeLoad NameLoad attr AttributeLoad NameLoad attr body If CompareEq AttributeLoad SubscriptLoad AttributeLoad NameLoad attr Index Num attr Str body Expr Yield TupleLoad NameLoad SubscriptLoad NameLoad Index BinOpAdd NameLoad Num decorator_list ClassDef bases AttributeLoad NameLoad attr body Assign NameStore NameLoad Assign NameStore Str FunctionDef arguments args NameParam NameParam NameParam defaults body Assign NameStore AttributeLoad NameLoad attr Assign NameStore ListComp Call AttributeLoad NameLoad attr comprehension NameStore SubscriptLoad NameLoad Index Str Assign NameStore ListComp Call AttributeLoad NameLoad attr comprehension NameStore SubscriptLoad NameLoad Index Str For TupleStore NameStore NameStore Call NameLoad NameLoad body If CompareEq Call NameLoad AttributeLoad NameLoad attr Num body Assign TupleStore NameStore NameStore NameStore SubscriptLoad AttributeLoad NameLoad attr Slice Num Num Expr Call AttributeLoad NameLoad attr Call NameLoad Str keyword Str If CompareNotEq AttributeLoad NameLoad attr AttributeLoad NameLoad attr body Assign NameStore Call NameLoad Call AttributeLoad NameLoad attr keyword Str Assign NameStore Call AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr Str Expr Call AttributeLoad NameLoad attr NameLoad Assign NameStore Call AttributeLoad NameLoad attr Assign NameStore AttributeLoad NameLoad attr For TupleStore NameStore NameStore Call NameLoad NameLoad body If Call NameLoad NameLoad AttributeLoad NameLoad attr body Break If BoolOpOr Call NameLoad NameLoad Call NameLoad NameLoad body Assign NameStore Call NameLoad NameLoad Call NameLoad NameLoad Call NameLoad Str orelse Assign NameStore Call NameLoad NameLoad NameLoad For NameStore Call NameLoad SubscriptLoad NameLoad Slice NameLoad body Expr Call AttributeLoad NameLoad attr Num NameLoad Expr Call AttributeLoad NameLoad attr NameLoad NameLoad orelse If CompareEq AttributeLoad NameLoad attr Str body Assign AttributeStore NameLoad attr Str Assign NameStore BinOpAdd BinOpAdd ListComp Call AttributeLoad NameLoad attr comprehension NameStore SubscriptLoad AttributeLoad NameLoad attr Slice Num NameLoad NameLoad Return Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr NameLoad decorator_list decorator_list
N/A N/A Fixer for except statements with named exceptions.

The following cases will be converted:

- "except E, T:" where T is a name:

    except E as T:

- "except E, T:" where T is not a name, tuple or list:

        except E as t:
            T = t

    This is done because the target of an "except" clause must be a
    name.

- "except E, T:" where T is a tuple or list literal:

        except E as t:
            T = t.args
 N/A pytree pgen2 token N/A fixer_base fixer_util Assign Attr Name is_tuple is_list syms find_excepts N/A N/A nodes N/A N/A N/A N/A i n N/A enumerate nodes N/A N/A N/A N/A n type N/A syms except_clause N/A N/A N/A N/A N/A N/A n children N/A 0 value except N/A N/A N/A N/A n N/A nodes N/A N/A i 2 N/A FixExcept N/A N/A fixer_base BaseFix N/A N/A BM_compatible True N/A PATTERN 
    try_stmt< 'try' ':' (simple_stmt | suite)
                  cleanup=(except_clause ':' (simple_stmt | suite))+
                  tail=(['except' ':' (simple_stmt | suite)]
                        ['else' ':' (simple_stmt | suite)]
                        ['finally' ':' (simple_stmt | suite)]) >
     transform N/A N/A self node results N/A N/A N/A syms N/A self syms N/A tail N/A N/A N/A n clone N/A n N/A results N/A tail N/A try_cleanup N/A N/A N/A ch clone N/A ch N/A results N/A cleanup N/A N/A except_clause e_suite N/A find_excepts try_cleanup N/A N/A N/A N/A len N/A except_clause children 4 N/A N/A N/A E comma N N/A N/A except_clause children N/A 1 4 N/A N/A N/A comma replace N/A Name as prefix N/A N/A N/A N type N/A token NAME N/A N/A new_N N/A Name N/A N/A self new_name prefix N/A target N/A N/A N clone N/A N/A target prefix N/A N/A N/A N replace new_N N/A new_N N/A N/A new_N clone N/A suite_stmts N/A e_suite children N/A N/A i stmt N/A enumerate suite_stmts N/A N/A N/A isinstance stmt N/A pytree Node N/A N/A N/A N/A N/A is_tuple N N/A is_list N N/A N/A assign N/A Assign target N/A Attr new_N N/A Name args N/A N/A assign N/A Assign target new_N N/A child N/A reversed N/A suite_stmts N/A i N/A N/A N/A N/A e_suite insert_child 0 child N/A N/A N/A e_suite insert_child i assign N/A N/A N/A N/A N prefix N/A N/A N/A N prefix N/A children N/A N/A N/A N/A N/A c clone N/A c N/A N/A node children N/A 3 try_cleanup tail N/A N/A N/A pytree Node N/A node type children N/A N/A