Bump mypy to 0.790 for Python 3.9 compat

HashError.order is now annotated as an int to allow
HashErrors.errors.sort(key=lambda e: e.order).  Alternatively we can
define a function which assert e is not None but I prefer the more
concise version, since we never raise HashError directly anyway.
这个提交包含在:
Nguyễn Gia Phong 2020-10-12 17:36:51 +07:00
父节点 da7569a440
当前提交 cf6ecab627
共有 2 个文件被更改,包括 2 次插入2 次删除

查看文件

@ -69,7 +69,7 @@ repos:
files: \.py$
- repo: https://github.com/pre-commit/mirrors-mypy
rev: v0.770
rev: v0.790
hooks:
- id: mypy
exclude: docs|tests

查看文件

@ -200,7 +200,7 @@ class HashError(InstallationError):
"""
req = None # type: Optional[InstallRequirement]
head = ''
order = None # type: Optional[int]
order = -1 # type: int
def body(self):
# type: () -> str