From 84c35553c9f8891a810ef2e613c7415eb12e2d2a Mon Sep 17 00:00:00 2001 From: Jeff Reback Date: Tue, 6 Jun 2017 06:06:45 -0400 Subject: [PATCH 1/2] BUG: pickle compat with UTC tz's closes #16608 --- pandas/compat/pickle_compat.py | 2 +- .../0.19.2/0.19.2_x86_64_darwin_3.6.1.pickle | Bin 125349 -> 126076 bytes .../tests/io/generate_legacy_storage_files.py | 8 +++++++- 3 files changed, 8 insertions(+), 2 deletions(-) mode change 100644 => 100755 pandas/tests/io/generate_legacy_storage_files.py diff --git a/pandas/compat/pickle_compat.py b/pandas/compat/pickle_compat.py index b875bbb0d63c0..f6223c48994ae 100644 --- a/pandas/compat/pickle_compat.py +++ b/pandas/compat/pickle_compat.py @@ -15,7 +15,7 @@ def load_reduce(self): args = stack.pop() func = stack[-1] - if type(args[0]) is type: + if len(args) and type(args[0]) is type: n = args[0].__name__ # noqa try: diff --git a/pandas/tests/io/data/legacy_pickle/0.19.2/0.19.2_x86_64_darwin_3.6.1.pickle b/pandas/tests/io/data/legacy_pickle/0.19.2/0.19.2_x86_64_darwin_3.6.1.pickle index 6bb02672a4151c8d6536127fc94e68634e56c86d..75ea95ff402c4e9f0c93ef80e6c04baf7f0a70d7 100644 GIT binary patch delta 785 zcmah{Ur19?7(d_H*{*vCuc`ZU4d>jp=7gkK*7 zbDG^U-F;$y>Z#7`OHC!lFJ2x?bta}}FQG0)G3l&>LHyKm2&K{<2m(&4u44d}5@v*~-n>`aa6m6)H86ooF zVb!;w`sAa^6^4sZJ6&ezZnRTmc*NGKJ@d?hu)~3h&Tvw4im%F~UCw)k!CEKIx7g_m zhHs^A{)k?!>R=kg?-f8|#x+T*FBr{JN*5($dQ{1oxGv}2cOSQwJd6v2UYq9ii9mOF zlKQYw`aRAXhq)qci@B7x&5WCV2?|=?KSE(r>uCQ-K}TyKR-G*qc9Z7tT%cFnhd1Ir5Br*S!Bu>mgir7f1XJYfo`F!-#$;UsyRIra-ib&&MK&_? z50Ey|LqR-dsn|ji(@_VVv6Q|{#)AEBJ3P3Sk8b6oaC?MG!q$Z~2*zPK delta 603 zcmex!gMH~`cGd=#sXDVZvTjk{JVC9Bk-eCOfg!7eWpbgEq(BakonaX}rFM!&hD}yA z%VYy#$;rVQ;!GJVlP^k{Y+j(TpHW~6ilXH#lk>HtL??g*-Lj0C7#K>EvJNl<%>?RM zsA$IqHotiDBP~rvrec=KilU|<%3oPha6i-_4TyDTSSEiE6=%FOd7`p3Q%(3CbHOv;eYN}1eiS%$2bv1GHW6%(W26R3}%!OzYH3VtS8 zw#kZe;!MVDll>LN89kd9S#Mut%{ViW=^)#7+qsMeevC@f^IkLVg-6Zw;5Uq#0GDgF A(*OVf diff --git a/pandas/tests/io/generate_legacy_storage_files.py b/pandas/tests/io/generate_legacy_storage_files.py old mode 100644 new mode 100755 index 22c62b738e6a2..996965999724e --- a/pandas/tests/io/generate_legacy_storage_files.py +++ b/pandas/tests/io/generate_legacy_storage_files.py @@ -1,3 +1,5 @@ +#!/usr/env/bin python + """ self-contained to write legacy storage (pickle/msgpack) files """ from __future__ import print_function from warnings import catch_warnings @@ -125,7 +127,11 @@ def create_data(): mixed_dup=mixed_dup_df, dt_mixed_tzs=DataFrame({ u'A': Timestamp('20130102', tz='US/Eastern'), - u'B': Timestamp('20130603', tz='CET')}, index=range(5)) + u'B': Timestamp('20130603', tz='CET')}, index=range(5)), + dt_mixed2_tzs=DataFrame({ + u'A': Timestamp('20130102', tz='US/Eastern'), + u'B': Timestamp('20130603', tz='CET'), + u'C': Timestamp('20130603', tz='UTC')}, index=range(5)) ) with catch_warnings(record=True): From c7966ff050f82b6775ef6617d77e4087affdbe8d Mon Sep 17 00:00:00 2001 From: Jeff Reback Date: Tue, 6 Jun 2017 08:43:02 -0400 Subject: [PATCH 2/2] add v0.20.3 whatsnew --- doc/source/whatsnew.rst | 2 + doc/source/whatsnew/v0.20.3.txt | 89 +++++++++++++++++++++++++++++++++ 2 files changed, 91 insertions(+) create mode 100644 doc/source/whatsnew/v0.20.3.txt diff --git a/doc/source/whatsnew.rst b/doc/source/whatsnew.rst index b1f9990a3e6af..3385bafc26467 100644 --- a/doc/source/whatsnew.rst +++ b/doc/source/whatsnew.rst @@ -20,6 +20,8 @@ These are new features and improvements of note in each release. .. include:: whatsnew/v0.21.0.txt +.. include:: whatsnew/v0.20.3.txt + .. include:: whatsnew/v0.20.2.txt .. include:: whatsnew/v0.20.0.txt diff --git a/doc/source/whatsnew/v0.20.3.txt b/doc/source/whatsnew/v0.20.3.txt new file mode 100644 index 0000000000000..2032209c4aa23 --- /dev/null +++ b/doc/source/whatsnew/v0.20.3.txt @@ -0,0 +1,89 @@ +.. _whatsnew_0203: + +v0.20.3 (June ??, 2017) +----------------------- + +This is a minor bug-fix release in the 0.20.x series and includes some small regression fixes, +bug fixes and performance improvements. +We recommend that all users upgrade to this version. + +.. contents:: What's new in v0.20.3 + :local: + :backlinks: none + + +.. _whatsnew_0203.enhancements: + +Enhancements +~~~~~~~~~~~~ + + + + + + +.. _whatsnew_0203.performance: + +Performance Improvements +~~~~~~~~~~~~~~~~~~~~~~~~ + + + + + + +.. _whatsnew_0203.bug_fixes: + +Bug Fixes +~~~~~~~~~ + + + + +Conversion +^^^^^^^^^^ + +- Bug in pickle compat prior to the v0.20.x series, when ``UTC`` is a timezone in a Series/DataFrame/Index (:issue:`16608`) + +Indexing +^^^^^^^^ + + + +I/O +^^^ + + + +Plotting +^^^^^^^^ + + + + +Groupby/Resample/Rolling +^^^^^^^^^^^^^^^^^^^^^^^^ + + + +Sparse +^^^^^^ + + + + +Reshaping +^^^^^^^^^ + + + +Numeric +^^^^^^^ + + +Categorical +^^^^^^^^^^^ + + +Other +^^^^^