Skip to content

Commit

Permalink
update mypy to 0.790 (#4581)
Browse files Browse the repository at this point in the history
  • Loading branch information
mathause authored Nov 13, 2020
1 parent b76a13f commit dd9fe2a
Show file tree
Hide file tree
Showing 7 changed files with 8 additions and 7 deletions.
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ repos:
hooks:
- id: flake8
- repo: https://github.com/pre-commit/mirrors-mypy
rev: v0.782 # Must match ci/requirements/*.yml
rev: v0.790 # Must match ci/requirements/*.yml
hooks:
- id: mypy
# run this occasionally, ref discussion https://github.com/pydata/xarray/pull/3194
Expand Down
2 changes: 1 addition & 1 deletion ci/requirements/py36.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ dependencies:
- isort
- lxml # Optional dep of pydap
- matplotlib
- mypy=0.782 # Must match .pre-commit-config.yaml
- mypy=0.790 # Must match .pre-commit-config.yaml
- nc-time-axis
- netcdf4
- numba
Expand Down
2 changes: 1 addition & 1 deletion ci/requirements/py37-windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ dependencies:
- isort
- lxml # Optional dep of pydap
- matplotlib
- mypy=0.782 # Must match .pre-commit-config.yaml
- mypy=0.790 # Must match .pre-commit-config.yaml
- nc-time-axis
- netcdf4
- numba
Expand Down
2 changes: 1 addition & 1 deletion ci/requirements/py37.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ dependencies:
- isort
- lxml # Optional dep of pydap
- matplotlib
- mypy=0.782 # Must match .pre-commit-config.yaml
- mypy=0.790 # Must match .pre-commit-config.yaml
- nc-time-axis
- netcdf4
- numba
Expand Down
2 changes: 1 addition & 1 deletion ci/requirements/py38-all-but-dask.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ dependencies:
- isort
- lxml # Optional dep of pydap
- matplotlib
- mypy=0.782 # Must match .pre-commit-config.yaml
- mypy=0.790 # Must match .pre-commit-config.yaml
- nc-time-axis
- netcdf4
- numba
Expand Down
2 changes: 1 addition & 1 deletion ci/requirements/py38.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ dependencies:
- isort
- lxml # Optional dep of pydap
- matplotlib
- mypy=0.782 # Must match .pre-commit-config.yaml
- mypy=0.790 # Must match .pre-commit-config.yaml
- nc-time-axis
- netcdf4
- numba
Expand Down
3 changes: 2 additions & 1 deletion xarray/core/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -463,7 +463,8 @@ def __delitem__(self, key: K) -> None:
del self.mapping[key]

def __iter__(self) -> Iterator[K]:
return iter(sorted(self.mapping))
# see #4571 for the reason of the type ignore
return iter(sorted(self.mapping)) # type: ignore

def __len__(self) -> int:
return len(self.mapping)
Expand Down

0 comments on commit dd9fe2a

Please sign in to comment.