Re: Help needed for pandas bug: Could anybody verify the suspicion that tzdata might have some influence?

2017-03-28 Thread Gert Wollny
Hello, I did some digging: > Maybe it's a bug in python-tz? Most likely: Pandas uses this code to get the time offset for the local time in tslib.pyx: cpdef _get_utcoffset(tzinfo, obj): try: return tzinfo._utcoffset except AttributeError: return

Re: Help needed for pandas bug: Could anybody verify the suspicion that tzdata might have some influence?

2017-03-28 Thread Gert Wollny
At second thought it might not be a bug in python-tz, but some undefined behavior that results from the pandas use of tz._utcoffset: >   tz = pytz.timezone('Asia/Tokyo') >   dt = datetime.datetime(2011,1,1) >   >   In[76]:  tz.utcoffset(dt) >   Out[76]: datetime.timedelta(0, 32400) > >   In