exc-info-outside-except-handler (LOG014)
Added in 0.12.0 · Related issues · View source
Derived from the flake8-logging linter.
Fix is sometimes available.
What it does
Checks for logging calls with exc_info= outside exception handlers.
Why is this bad?
Using exc_info=True outside of an exception handler
attaches None as the exception information, leading to confusing messages:
Example
Use instead:
Fix safety
The fix is always marked as unsafe, as it changes runtime behavior.