Skip to content

BUG: DatetimeTz shift raises AmbiguousTimeError near DST #13926

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

Closed
wants to merge 1 commit into from

Conversation

sinhrks
Copy link
Member

@sinhrks sinhrks commented Aug 6, 2016

  • tests added / passed
  • passes git diff upstream/master | flake8 --diff
  • whatsnew entry

As the same as #13650, caused by .tz_localize(None) which can be removed.

import pandas as pd
s = pd.Series(pd.date_range('2016-11-06', freq='H', periods=10, tz='US/Eastern'))
s.shift(1)
# pytz.exceptions.AmbiguousTimeError: Cannot infer dst time from Timestamp('2016-11-06 01:00:00'), try using the 'ambiguous' argument

@sinhrks sinhrks added Bug Timezones Timezone data dtype labels Aug 6, 2016
@sinhrks sinhrks added this to the 0.19.0 milestone Aug 6, 2016
@codecov-io
Copy link

codecov-io commented Aug 6, 2016

Current coverage is 85.30% (diff: 100%)

Merging #13926 into master will increase coverage by <.01%

@@             master     #13926   diff @@
==========================================
  Files           139        139          
  Lines         50138      50141     +3   
  Methods           0          0          
  Messages          0          0          
  Branches          0          0          
==========================================
+ Hits          42769      42773     +4   
+ Misses         7369       7368     -1   
  Partials          0          0          

Powered by Codecov. Last update 3186fef...c079ee3

@jreback
Copy link
Contributor

jreback commented Aug 6, 2016

ty sir!

@jreback jreback closed this in cffe6f2 Aug 6, 2016
@sinhrks sinhrks deleted the dttz_shift_dst branch August 7, 2016 03:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Timezones Timezone data dtype
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants