
May 8, 2021
3:07 p.m.
That's this bit: ``` except (A, B): ^^^^^^ ``` bpo-43149 currently calls it an "exception group", but that conflicts with PEP 654 -- Exception Groups and except* ```
try: ... pass ... except A, B: ... pass Traceback (most recent call last): SyntaxError: exception group must be parenthesized
some alternatives:
exception classinfo must be parenthesized (classinfo so named from the parameter to issubclass)
exception sequence must be parenthesized
see also:
- https://github.com/python/cpython/pull/24467#discussion_r628756347
- https://www.python.org/dev/peps/pep-0654/