Please check the following simple code.
@dataclass
class FooData:
bar: int
baz: str
FooData(1, 's') # works fine
def through() -> Type[FooData]:
return FooData
DataClass = through()
DataClass(1, 's') # warning, unexpected arguments
Type hint for the function or method with return Type[Dataclass] is not working.
Is it a PyCharm bug or am I doing something wrong?
Pycharm version: PyCharm 2021.3.3 (Professional Edition)