Skip to content
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

DatetimeIndex from timezone-aware datetimes fails #1777

Closed
ijmcf opened this issue Aug 17, 2012 · 3 comments

Comments

@ijmcf
Copy link

commented Aug 17, 2012

If you try to create a DatetimeIndex from a list of timezone aware datetimes, you get the exception: "Tz-aware datetime.datetime cannot be converted to datetime64 unless utc=True"

For example:

import pandas, datetime, pytz
d = [datetime.datetime(2012, 8, 19, tzinfo=pytz.timezone('US/Eastern'))]
pandas.DatetimeIndex(d)

@ijmcf

This comment has been minimized.

Copy link
Author

commented Aug 17, 2012

This is similar to issue 1676 raised by kdebrab, but that raises a different exception, so I created a new issue for this one.

@wesm

This comment has been minimized.

Copy link
Member

commented Aug 17, 2012

Confirmed it's still a bug in master

@wesm wesm closed this in befedb5 Aug 18, 2012

@wesm

This comment has been minimized.

Copy link
Member

commented Aug 18, 2012

Got this one sorted out

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.