A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://github.com/python/mypy/issues/8992 below:

Version 0.780 does not recognize python internal types as `typing.Type` anymore · Issue #8992 · python/mypy · GitHub

Since upgrading from version 0.770 to 0.780 we saw issues, where types used during runtime were recognized as object and not as typing.Type anymore.

# test.py
from typing import Type, Union

def method(type: Type) -> None:
    pass

method(int)
method(Union[int, str])
> mypy test.py # mypy==0.780
test.py:8: error: Argument 1 to "method" has incompatible type "object"; expected "Type[Any]"
Found 1 error in 1 file (checked 1 source file)
> mypy test.py # mypy==0.770
Success: no issues found in 1 source file

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4