10000 CLN: Move some PI/DTI methods to EA subclasses, implement tests by jbrockmendel · Pull Request #22961 · pandas-dev/pandas · GitHub
[go: up one dir, main page]

Skip to content

CLN: Move some PI/DTI methods to EA subclasses, implement tests #22961

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 11 commits into from
Oct 8, 2018
Prev Previous commit
Next Next commit
Fix failing test by ammending constructor
  • Loading branch information
jbrockmendel committed Oct 3, 2018
commit 12eb1b92478e9605c2c934d75eeff36ad31932f2
3 changes: 2 additions & 1 deletion pandas/core/indexes/datetimes.py
Original file line number Diff line number Diff line change
Expand Up @@ -302,7 +302,8 @@ def __new__(cls, data=None,
tz=tz, normalize=normalize,
closed=closed, ambiguous=ambiguous)

if not isinstance(data, (np.ndarray, Index, ABCSeries)):
if not isinstance(data, (np.ndarray, Index, ABCSeries,
DatetimeArrayMixin)):
if is_scalar(data):
raise ValueError('DatetimeIndex() must be called with a '
'collection of some kind, %s was passed'
Expand Down
0