Python

Python

By DeepSource

Comparison with callable detectedPYL-W0143

Bug risk

Comparison with a callable has been detected, which suggests you may have forgotten the parentheses to actually call the function or method. If you intended to check if both of these callables are the same, it's recommended to use the is operator for comparison.

So instead of:

some_callable == some_other_callable

Do this:

some_callable is some_other_callable  # using the `is` operator