-
Notifications
You must be signed in to change notification settings - Fork 150
fix: parse timezone-aware datetime strings as UTC consistently across backends #2166
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
fix: parse timezone-aware datetime strings as UTC consistently across backends #2166
Conversation
bbe16ad
to
7f1d06f
Compare
if "pandas" in str(constructor) and PANDAS_VERSION < (1,): | ||
# "Cannot pass a tz argument when parsing strings with timezone information." | ||
pytest.skip() | ||
if "pyarrow_table" in str(constructor) and is_windows(): |
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.
Hate to be the windows guy but ...
Lines 170 to 172 in caaa840
def is_pyarrow_windows_no_tzdata(constructor: Constructor, /) -> bool: | |
"""Skip test on Windows when the tz database is not configured.""" | |
return "pyarrow" in str(constructor) and is_windows() and not windows_has_tzdata() |
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 think that util needs updating to use "pyarrow_table"
actually
My bad π€¦
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.
yup, thanks!
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.
Oh it turns out I accidentally had the right thing lol https://github.com/narwhals-dev/narwhals/actions/runs/13730338881/job/38405984916?pr=2166
Double my bad π€¦π€¦
needs reverting (fdb2f48)
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.
@MarcoGorelli fyi I un-resolved this
tests/utils.py
Outdated
@@ -169,4 +169,6 @@ def windows_has_tzdata() -> bool: # pragma: no cover | |||
|
|||
def is_pyarrow_windows_no_tzdata(constructor: Constructor, /) -> bool: |
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.
Truly unfortunate name I settled on here π
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.
Thanks @MarcoGorelli
thanks for your review! |
What type of PR is this? (check all applicable)
Related issues
Checklist
If you have comments or can explain your changes, please do so below