From 2369d557b347e51174fdd9b1e975dff45e73ef7e Mon Sep 17 00:00:00 2001 From: Vaibhav Vishal Date: Mon, 13 May 2019 14:57:31 +0530 Subject: [PATCH 1/2] remove the module from mypy.ini --- mypy.ini | 3 --- 1 file changed, 3 deletions(-) diff --git a/mypy.ini b/mypy.ini index 54b2c59e1ba33..9b1188cbedfa5 100644 --- a/mypy.ini +++ b/mypy.ini @@ -8,9 +8,6 @@ ignore_errors=True [mypy-pandas.core.indexes.base] ignore_errors=True -[mypy-pandas.core.indexes.datetimelike] -ignore_errors=True - [mypy-pandas.core.indexes.datetimes] ignore_errors=True From a817365e3314ae64f0cb33447075128d85315e38 Mon Sep 17 00:00:00 2001 From: Vaibhav Vishal Date: Mon, 13 May 2019 15:02:28 +0530 Subject: [PATCH 2/2] fix a few typing errors --- pandas/core/indexes/datetimelike.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/pandas/core/indexes/datetimelike.py b/pandas/core/indexes/datetimelike.py index 7454b015cb556..fca85653a692d 100644 --- a/pandas/core/indexes/datetimelike.py +++ b/pandas/core/indexes/datetimelike.py @@ -2,6 +2,7 @@ Base and utility classes for tseries type pandas objects. """ import operator +from typing import Set import warnings import numpy as np @@ -134,7 +135,7 @@ def values(self) -> np.ndarray: # Note: PeriodArray overrides this to return an ndarray of objects. return self._data._data - @property + @property # type: ignore @Appender(DatetimeLikeArrayMixin.asi8.__doc__) def asi8(self): return self._data.asi8 @@ -758,9 +759,9 @@ class DatetimelikeDelegateMixin(PandasDelegate): boxed in an index, after being returned from the array """ # raw_methods : dispatch methods that shouldn't be boxed in an Index - _raw_methods = set() + _raw_methods = set() # type: Set[str] # raw_properties : dispatch properties that shouldn't be boxed in an Index - _raw_properties = set() + _raw_properties = set() # type: Set[str] name = None _data = None