basedmypy icon indicating copy to clipboard operation
basedmypy copied to clipboard

Based Python static type checker with baseline, sane default settings and based typing features

Results 446 basedmypy issues
Sort by recently updated
recently updated
newest added

### Gist to reproduce ```python class Foo: @overload def a(self, a: int, /) -> None: ... @overload def a(self, b: str, /) -> None: ... def a(self, c: int |...

bug

```py # type: ignore ``` ``` 👉 mypy test.py --disable-error-code unused-ignore test.py:1:1 error: unused "type: ignore" comment [unused-ignore] ``` You have to supply `--no-warn-unused-ignore`

bug
good first issue

Is this valid? Sounds valid to me ```py def f(i: list[T]) -> list[T]: ... a: list[str] | list[int] # current reveal_type(f(a)) # Cannot infer type argument 1 of "f" #...

feature
p-3

```py from typing import _T as T, TypeVar L = TypeVar("L", bound=list[T]) # error: Type variable "typing._T" is unbound def foo(l: L) -> L | T: # error: A function...

p-1
feature

```py # from __future__ import annotations from typing import ForwardRef def foo(a: "asdf") -> True: # literal string `"asdf"` ... MyType: TypeAlias = int | ForwardRef("asdf") # a forward reference...

future-annotations

1.5 will be based on mypy 0.971 and will include: - #340 And anything else that gets finished before that: - #358 - #137 Timeline: - beta1: 26/07/2022 - rc1:...

project

People use `abc.abstractmethod` for usages that have nothing to do with `abc.ABC`. Also it can't be used on attributes. ```py @abstract class A: a: Abstract[int] class B(A): # error: make...

feature

```py from basedtyping import T def foo(t: T): a: int = t # T reveal_type(t) # T@foo ```

bug

```py a: 1 | 2 # error if TYPE_CHECKING: a: 1 | 2 # no error ```

feature