
July 4, 2022
12:25 a.m.
I'm not sure I understand what you propose to change here. If I run your class C through mypy today, it (correctly, in my mind) rejects it with "error: Return type "str" of "child_method" incompatible with return type "int" in supertype "A"" Are you suggesting that it should accept that? On Sun, Jul 3, 2022 at 2:05 PM Stanislav Zmiev <szmiev2000@gmail.com> wrote:
which could easily lead to typehints lying in large classes where we are not careful such as: ```python class C(A[int]): # Many lines of code here ... def child_method(self) -> str: return "83" ```