Skip to content

algebra cleanup in FY5253 and Easter offsets #18350

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 1 commit into from
Nov 22, 2017

Conversation

jbrockmendel
Copy link
Member

Same types of cleanups you've gotten used to seeing elsewhere, now applied to FY5253 and Easter. This should be orthogonal to others.

@codecov
Copy link

codecov bot commented Nov 17, 2017

Codecov Report

Merging #18350 into master will decrease coverage by 0.01%.
The diff coverage is 90.69%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master   #18350      +/-   ##
==========================================
- Coverage   91.38%   91.37%   -0.02%     
==========================================
  Files         164      164              
  Lines       49790    49758      -32     
==========================================
- Hits        45501    45465      -36     
- Misses       4289     4293       +4
Flag Coverage Δ
#multiple 89.17% <90.69%> (ø) ⬆️
#single 39.51% <0%> (-0.05%) ⬇️
Impacted Files Coverage Δ
pandas/tseries/offsets.py 97.2% <90.69%> (+0.28%) ⬆️
pandas/io/gbq.py 25% <0%> (-58.34%) ⬇️
pandas/core/frame.py 97.8% <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 cfad581...47fa1b9. Read the comment docs.

@gfyoung gfyoung added Clean Timedelta Timedelta data type labels Nov 18, 2017
pass
elif other == next_year:
n += 1
# TODO: Not hit in tests
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can we hit these in tests

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It wasn't obvious to me how to hit it, so I left the note to try again next time around. (which will be soon. We're far from done with offsets PRs)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jbrockmendel : If you don't mind explaining, how do you know that this particular branch isn't hit? What about the other branches?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

BTW, the changes themselves look OK but would like to get some more color on the questions I just posed to you before merging.

Copy link
Member Author

@jbrockmendel jbrockmendel Nov 22, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Put in a bunch of assert false statements as a quick coverage check. All the others were hit.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, I see. From which test files did those assert false failures then originate?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Almost certainly tests.tseries.offsets.test_offsets

Copy link
Member

@gfyoung gfyoung Nov 22, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Okay, sounds good. Have a look at those tests once I merge to see how we can increase coverage in this section of logic.

@jbrockmendel
Copy link
Member Author

I think there's one more algebra/cleanup after this, then we're jumping into bugfixes.

@jreback jreback added this to the 0.22.0 milestone Nov 22, 2017
@jreback
Copy link
Contributor

jreback commented Nov 22, 2017

I doubt we have very many tests for this. @gfyoung can you have a look and see if the changes look ok.

@gfyoung
Copy link
Member

gfyoung commented Nov 22, 2017

@jreback : I'll take a look later this evening. If all looks good, can I just merge this?

@jreback
Copy link
Contributor

jreback commented Nov 22, 2017

yep

@jbrockmendel
Copy link
Member Author

#14774 has a use case that hits one of the existing assert False statements (i.e. not one of the ones discussed above for coverage checks). I'll take a look at that after this gets closed.

@gfyoung gfyoung merged commit dac9b43 into pandas-dev:master Nov 22, 2017
@gfyoung
Copy link
Member

gfyoung commented Nov 22, 2017

@jbrockmendel : Merged and closed. Thanks!

@jbrockmendel jbrockmendel deleted the tslibs-offsets-fyeast branch December 8, 2017 19:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Clean Timedelta Timedelta data type
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants