basedmypy
basedmypy copied to clipboard
Based Python static type checker with baseline, sane default settings and based typing features
This is redundant and confusing and would benefit from some errors.
```py class Foo: def __new__(cls, value: int): ... def __init__(self, value): # inferred as int ... ```
```py from typing import overload @overload def foo(a: int=...): ... @overload def foo(a: str): ... def foo(a: object): print(a) ``` ``` test.py:7:1: error: Overloaded function implementation does not accept all...
This would be a really useful feature as currently they just check if they crash or not. - #307
```py def foo(a: int, b: int): ... def foo(a: str): ... def foo(a, b=None): reveal_type(b) # int | None ``` Would it be good if the default value from the...
Run mypy twice and ensure identical output is appeared
```py def foo(l: Any): ... foo(1) # no error foo([1, 2, 3]) # error: Any expression, has type "List[Any]" ``` It it really an `Any` expression? What do you think...
They are currently an unreadable mess that looks nothing like their written form, they should look more like ``` test.py:10: note: Revealed type is: def foo(a: int = ...) ->...
```py class B: def __init__(self, foo: Untyped): ... @staticmethod def bar(): ... B.bar() # error: Expression type contains "Any" (has type "type[B]") [no-any-expr] ``` Despite the fact that `B`s constructor...