Skip to content

Fixed PeriodIndex._shallow_copy for i8 #24604

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

Merged
merged 4 commits into from
Jan 4, 2019

Conversation

TomAugspurger
Copy link
Contributor

Closes #24391

cc @jschendel

@TomAugspurger TomAugspurger added the Period Period data type label Jan 3, 2019
@TomAugspurger TomAugspurger added this to the 0.24.0 milestone Jan 3, 2019
@jreback
Copy link
Contributor

jreback commented Jan 3, 2019

lgtm.

@codecov
Copy link

codecov bot commented Jan 4, 2019

Codecov Report

Merging #24604 into master will decrease coverage by <.01%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master   #24604      +/-   ##
==========================================
- Coverage   43.05%   43.05%   -0.01%     
==========================================
  Files         166      166              
  Lines       52471    52482      +11     
==========================================
+ Hits        22593    22595       +2     
- Misses      29878    29887       +9
Flag Coverage Δ
#single 43.05% <100%> (-0.01%) ⬇️
Impacted Files Coverage Δ
pandas/core/indexes/period.py 36.77% <100%> (+0.02%) ⬆️
pandas/core/internals/blocks.py 51.93% <0%> (-1%) ⬇️
pandas/util/testing.py 50.73% <0%> (-0.93%) ⬇️
pandas/core/dtypes/dtypes.py 73.57% <0%> (-0.5%) ⬇️
pandas/core/indexes/datetimelike.py 57.55% <0%> (-0.22%) ⬇️
pandas/core/indexes/category.py 50.8% <0%> (-0.03%) ⬇️
pandas/core/strings.py 33% <0%> (ø) ⬆️
pandas/core/internals/__init__.py 100% <0%> (ø) ⬆️
pandas/core/arrays/timedeltas.py 41.53% <0%> (ø) ⬆️
pandas/core/arrays/datetimes.py 65.78% <0%> (ø) ⬆️
... and 7 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 25c1c38...776aa90. Read the comment docs.

@codecov
Copy link

codecov bot commented Jan 4, 2019

Codecov Report

Merging #24604 into master will decrease coverage by <.01%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master   #24604      +/-   ##
==========================================
- Coverage   92.37%   92.37%   -0.01%     
==========================================
  Files         166      166              
  Lines       52471    52470       -1     
==========================================
- Hits        48471    48469       -2     
- Misses       4000     4001       +1
Flag Coverage Δ
#multiple 90.8% <100%> (-0.01%) ⬇️
#single 43.06% <25%> (ø) ⬆️
Impacted Files Coverage Δ
pandas/core/resample.py 97.23% <100%> (ø) ⬆️
pandas/core/indexes/period.py 92.06% <100%> (-0.06%) ⬇️
pandas/util/testing.py 88% <0%> (-0.1%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 25c1c38...776aa90. Read the comment docs.

@TomAugspurger
Copy link
Contributor Author

Had to update a few places using this.

One in resample. We were using this for PI/TDI/DTI to change the freq. It only worked since the object was empty.

The others were tests using the _shallow_copy API. Those have been updated to use asfreq for PI.

@TomAugspurger
Copy link
Contributor Author

All green now.

@jreback jreback merged commit 9642fea into pandas-dev:master Jan 4, 2019
@jreback
Copy link
Contributor

jreback commented Jan 4, 2019

thanks @TomAugspurger

1 similar comment
@jschendel
Copy link
Member

thanks @TomAugspurger

@TomAugspurger TomAugspurger deleted the pi-roundtrip-i8 branch January 4, 2019 19:53
Pingviinituutti pushed a commit to Pingviinituutti/pandas that referenced this pull request Feb 28, 2019
Pingviinituutti pushed a commit to Pingviinituutti/pandas that referenced this pull request Feb 28, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Period Period data type
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants