Join GitHub today
GitHub is home to over 20 million developers working together to host and review code, manage projects, and build software together.
concat of tz series and no tz results in attribute error. #11755
Comments
varun-kr
changed the title from
concat of tz series and no tz results in attribute error. Is it a bug ? to concat of tz series and no tz results in attribute error.
Dec 3, 2015
|
this is realted to #11705 this should work, but both series get converted to so this is a bug in there somewhere |
jreback
added Bug Reshaping Timezones Difficulty Intermediate Effort Low
labels
Dec 3, 2015
jreback
added this to the
0.18.0
milestone
Dec 3, 2015
|
@jreback If we convert to |
|
tz that compat iow they match should be preserved this already exists - this is just missing a conversion somewhere I think - if u add tests as I suggest it should be easy to figure out |
|
@jreback
Creating a series will always return datetime series not object. Output
Any suggestions? |
|
just step thru the code |
|
@jreback In this group by test case we expect a datetime64[ns] series . "combining multiple / different timezones yields UTC". And in the above example we expect an object . Is it not an inconsistency ? Should it be datetime64[ns] ? |
|
see if you can find when that groupby behavior was put in place. IIRC this was though to be more natural. cc @sinhrks but as I look now, we have a policy of only combing the exact same timezones, and converting to object dtype otherwise. There is an exception though because whenever you convert to an actual numpy array, and you have all uniform dtypes then you will get converted to UTC then to naive. So the answer to your question, is that we may need to change this groupby test case to conform. (and possibly note as an API change to clean this up). |
jreback
referenced
this issue
Feb 10, 2016
Closed
DEPR: GH10623 remove items from msgpack.encode for blocks #12129
jreback
modified the milestone: 0.18.1, 0.18.0
Feb 10, 2016
|
was closed by #12195 |
varun-kr commentedDec 3, 2015
AttributeError: 'numpy.ndarray' object has no attribute 'tz_localize'
Is it a bug or not supported ?