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

Pandas resample fails when data exists only up to time change #22532

Closed
mmrahn opened this issue Aug 29, 2018 · 1 comment
Closed

Pandas resample fails when data exists only up to time change #22532

mmrahn opened this issue Aug 29, 2018 · 1 comment

Comments

@mmrahn
Copy link

mmrahn commented Aug 29, 2018

Code Sample

df = pandas.DataFrame(
        0,
        index=pd.DatetimeIndex(['2018-03-24 23:00', '2018-03-25 00:00', '2018-03-25 01:00'],
                               tz='Europe/Berlin'),
        columns=[0])
df.resample('1h').mean()

Problem description

The code above fails with the error pytz.exceptions.NonExistentTimeError: 2018-03-25 02:00:00

Output of pd.show_versions()

INSTALLED VERSIONS

commit: None
python: 3.6.6.final.0
python-bits: 64
OS: Windows
OS-release: 10
machine: AMD64
processor: Intel64 Family 6 Model 61 Stepping 4, GenuineIntel
byteorder: little
LC_ALL: None
LANG: None
LOCALE: None.None
pandas: 0.23.4
pytest: 3.3.2
pip: 10.0.1
setuptools: 38.4.0
Cython: None
numpy: 1.14.5
scipy: None
pyarrow: None
xarray: None
IPython: 6.2.1
sphinx: None
patsy: None
dateutil: 2.6.1
pytz: 2017.3
blosc: None
bottleneck: None
tables: 3.4.2
numexpr: 2.6.4
feather: None
matplotlib: None
openpyxl: 2.4.10
xlrd: None
xlwt: None
xlsxwriter: None
lxml: None
bs4: None
html5lib: 1.0.1
sqlalchemy: None
pymysql: None
psycopg2: None
jinja2: 2.10
s3fs: None
fastparquet: None
pandas_gbq: None
pandas_datareader: None

[paste the output of pd.show_versions() here below this line]

@mroeschke
Copy link
Member

Thanks for the report. This is a duplicate of #10117

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants