Developers can use type hints to specify which type a function is expected to return. These annotations are not enforced at runtime and returning a different type might not fail. It is however likely to be unintended and will lead to maintainability issues, if not bugs.
This rule raises an issue when a function or method returns a value that contradicts its type hint.