Derived from the flake8-bugbear linter.
Fix is always available.
What it does#
Checks for uses of
Why is this bad?#
assert statements when running in optimized mode
python -O), making
assert False an unreliable means of
Instead, raise an
This rule's fix is marked as unsafe, as changing an
assert to a
raise will change the behavior of your program when running in
optimized mode (