pylint-errors

W0711 (binary-op-exception)

:x: Problematic code:

try:
    1 / 0
except ZeroDivisionError or ValueError:
    pass

:heavy_check_mark: Correct code:

try:
    1 / 0
except (ZeroDivisionError, ValueError):
    pass

Rationale:

Used when the exception to catch is of the form except A or B. If intending to catch multiple, rewrite as except (A, B).