Derived from the flake8-return linter.
What it does#
else statements with a
continue statement in the preceding
Why is this bad?#
else statement is not needed, as the
continue statement will always
continue onto the next iteration of a loop. Removing the
else will reduce
nesting and make the code more readable.