-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Add tests for time conversions in tools package #2341
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
Changes from all commits
Commits
Show all changes
48 commits
Select commit
Hold shift + click to select a range
9347f12
Add tests for tools.localize_to_utc
markcampanelli 0638773
Add tests for datetime_to_djd and djd_to_datetime
markcampanelli c1df9a7
Update what's new
markcampanelli 77c0f81
Appease the linter
markcampanelli 6704d06
Fix pandas equality tests for Python 3.9
markcampanelli dbb1805
Fix pandas equality tests for Python 3.9 more
markcampanelli 6750709
Fix pandas equality tests for Python 3.9 more more
markcampanelli 1144106
Bump miniimum pandas to fix bad test failure
markcampanelli 14715ed
Try alternative pandas test fix
markcampanelli 545c196
Revert change in minimum pandas version
markcampanelli 271fd97
Fix test
markcampanelli 01263c2
Type Location's tz and pytz attributes as advertised
markcampanelli 60a5d94
Add timezone type checks to Location init test
markcampanelli 9ab2ecf
Don't parameterize repetitive tests
markcampanelli ddef8d1
Update whatsnew for Location bugfix
markcampanelli 4f17f49
Update docstring
markcampanelli a3c3e03
Improve whatsnew formatting
markcampanelli 5f59417
Support non-fractional int and float and pytz and zoneinfo time zones
markcampanelli c84801f
Appease the linter
markcampanelli 195efbc
Use zoneinfo as single source of truth and tz as interface point
markcampanelli 1a5efed
Add zoneinfo asserts in tests
markcampanelli e5af9ae
Try to fix asv ci
markcampanelli 67e9844
See if newer asv works with newer conda
markcampanelli e35eb42
Remove comments no longer needed
markcampanelli a1a0261
Remove addition of zoneinfo attribute
markcampanelli 8373ac4
Revise whatsnew bugfix
markcampanelli eee6f51
Revise whatsnew bugfix more
markcampanelli 9662c1f
Spell my name correctly
markcampanelli 32284ba
The linter strikes back again
markcampanelli 01e4cfc
Merge branch 'main' into add_tools_tests
markcampanelli c09a328
Fix whatsnew after main merge
markcampanelli 4ef4b69
Address Cliff's comment
markcampanelli 7490792
Adjust Location documentation
markcampanelli a5f7646
Fix indent
markcampanelli 1382e30
More docstring tweaks
markcampanelli 059e35f
Try to fix bad parens
markcampanelli f9f07d7
Rearrange docstring
markcampanelli 75db2aa
Appease the linter
markcampanelli 1164c96
Document pytz attribute as read only
markcampanelli 5f6ad14
Consistent read only
markcampanelli f691bb6
Update pvlib/location.py per review comment
markcampanelli 7cfb170
Add breaking change to whatsnew and fix linting
markcampanelli ef5c60f
Clarify breaking change in whatsnew
markcampanelli c96c018
Merge branch 'main' into add_tools_tests
markcampanelli 5d4be75
Update whatsnew ordering
markcampanelli 5d5e553
Implement review comments on documentation
markcampanelli 6d83e16
Missed saving changes and appease the linter
markcampanelli d26204f
Apply suggestions from code review
cwhanse File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I really don't think this is the place to describe how the interface is changed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Seems to me like the "bug fix" here is not to do with what types are allowed, but rather that
Location
now ensures consistency between itstz
andpytz
attributes.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's both. My memory is already fading, but I'm pretty sure a non-string value could be assigned to
pvlib.location.Location.tz
, and in addition to that this value andpvlib.location.Location.pttz
could diverge.