> pip3.8 list
Package Version
----------------- -------
attrs 19.3.0
mypy 0.761
mypy-extensions 0.4.3
pip 19.3.1
setuptools 42.0.2
typed-ast 1.4.1
typing-extensions 3.7.4.1
wheel 0.33.6
> mypy --version
mypy 0.761
# types.py
import typing
import attr
@attr.s(auto_attribs=True, slots=True, frozen=True)
class Test:
b: bool = False
> mypy types.py
types.py:4: error: Cannot determine type of 's'
Found 1 error in 1 file (checked 1 source file)
我需要安装其他东西以获得attrs
支持吗?