Skip to content

Slicing an index with DateTime throws AttributeError: 'int' object has no attribute 'stop' #27127

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 9 commits into from
Jul 1, 2019

Conversation

soilstack
Copy link
Contributor

@soilstack soilstack commented Jun 29, 2019

Fixes GH26944 AttributeError on partial multiindex timestamp slice

Fixes GH26944 AttributeError on partial multiindex timestamp slice
@codecov
Copy link

codecov bot commented Jun 29, 2019

Codecov Report

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

Impacted file tree graph

@@            Coverage Diff             @@
##           master   #27127      +/-   ##
==========================================
- Coverage   91.87%   91.86%   -0.01%     
==========================================
  Files         180      180              
  Lines       50864    50866       +2     
==========================================
- Hits        46731    46729       -2     
- Misses       4133     4137       +4
Flag Coverage Δ
#multiple 90.51% <100%> (ø) ⬆️
#single 41.87% <0%> (-0.09%) ⬇️
Impacted Files Coverage Δ
pandas/core/indexes/multi.py 94.86% <100%> (ø) ⬆️
pandas/io/gbq.py 88.88% <0%> (-11.12%) ⬇️
pandas/core/frame.py 96.88% <0%> (-0.12%) ⬇️

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 b640530...ecc8d45. Read the comment docs.

@codecov
Copy link

codecov bot commented Jun 29, 2019

Codecov Report

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

Impacted file tree graph

@@            Coverage Diff             @@
##           master   #27127      +/-   ##
==========================================
- Coverage   91.87%   91.86%   -0.01%     
==========================================
  Files         180      180              
  Lines       50864    50819      -45     
==========================================
- Hits        46731    46687      -44     
+ Misses       4133     4132       -1
Flag Coverage Δ
#multiple 90.55% <100%> (+0.04%) ⬆️
#single 41.92% <0%> (-0.04%) ⬇️
Impacted Files Coverage Δ
pandas/core/indexes/multi.py 94.86% <100%> (ø) ⬆️
pandas/io/gbq.py 88.88% <0%> (-11.12%) ⬇️
pandas/core/panel.py 15.86% <0%> (-0.24%) ⬇️
pandas/core/frame.py 96.87% <0%> (-0.14%) ⬇️
pandas/core/internals/blocks.py 94.97% <0%> (-0.08%) ⬇️
pandas/core/indexes/datetimes.py 94.16% <0%> (-0.07%) ⬇️
pandas/core/arrays/categorical.py 95.91% <0%> (-0.03%) ⬇️
pandas/io/formats/csvs.py 98.18% <0%> (-0.02%) ⬇️
pandas/core/series.py 92.35% <0%> (-0.01%) ⬇️
pandas/io/html.py 94.24% <0%> (ø) ⬆️
... and 5 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 b640530...f8dfd84. Read the comment docs.

Copy link
Member

@mroeschke mroeschke left a comment

Choose a reason for hiding this comment

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

Needs a test.

Fixes GH26944 AttributeError on partial multiindex timestamp slice and includes test.
@pep8speaks
Copy link

pep8speaks commented Jun 30, 2019

Hello @soilstack! Thanks for updating this PR. We checked the lines you've touched for PEP 8 issues, and found:

There are currently no PEP 8 issues detected in this Pull Request. Cheers! 🍻

Comment last updated at 2019-07-01 15:42:06 UTC

Fixes GH26944 AttributeError on partial multiindex timestamp slice and includes test and PEP8 correction.
Fixes GH26944 AttributeError on partial multiindex timestamp slice and includes test and PEP8 corrections.
Fixes GH26944 AttributeError on partial multiindex timestamp slice and includes test and PEP8 corrections w293, w391.
Fixes GH26944 AttributeError on partial multiindex timestamp slice and includes test and PEP8 corrections w293, w391.  Simplified test code.
Fixes GH26944 AttributeError on partial multiindex timestamp slice and includes test and PEP8 corrections w293, w391.  Simplified test code. E501
@soilstack
Copy link
Contributor Author

Needs a test.

done

@soilstack soilstack closed this Jun 30, 2019
@soilstack
Copy link
Contributor Author

oops accidentally closed

@soilstack soilstack reopened this Jun 30, 2019
@jreback jreback changed the title BUG: GH26944 Slicing an index with DateTime throws AttributeError: 'int' object has no attribute 'stop' Jul 1, 2019
@jreback jreback added Bug Datetime Datetime data dtype labels Jul 1, 2019
@jreback jreback added this to the 0.25.0 milestone Jul 1, 2019
soilstack added 2 commits July 1, 2019 23:36
Fixes GH26944 AttributeError on partial multiindex timestamp slice and includes test and PEP8 corrections w293, w391.  Simplified test code. E501. changed assertion method.
Fixes GH26944 AttributeError on partial multiindex timestamp slice and includes test and PEP8 corrections w293, w391.  Simplified test code. E501. changed assertion method. more pep8 violations.
@TomAugspurger TomAugspurger merged commit b115a6b into pandas-dev:master Jul 1, 2019
@TomAugspurger
Copy link
Contributor

Thanks!

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

Successfully merging this pull request may close these issues.

Slicing an index with DateTime throws AttributeError: 'int' object has no attribute 'stop'
5 participants