-
-
Notifications
You must be signed in to change notification settings - Fork 18.4k
API/BUG: inconsistent return in Timestamp/to_datetime for current year #3944
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
Comments
|
...having Timestamp(x) dependent on the current time seems a little strange to me. |
that's the bug it shouldn't but has to do with the parse order and fix a bit non trivial |
I tried some small-ish fixes for this to just make both of them use the same set of parsing functions, but it turns out there is another wrinkle with this:
Since multiple tests count on the fact that
This behavior works by accident (you are supposed to have to pass in So basically, if the two should have the same interface, then |
I think
it appears that this ignores the parsed timezone (the islocal). I think you could grab that, then do a |
Alright, I have looked into this more and I don't think this issue is worth fixing. The problem is that However, So, if you wanted to unify the two, you'd have to do one of the following:
I don't think either is worth it. However if somebody put a gun to my head and made me choose, I think adding |
I am attaching a very minor pull request (#5958) to deal with an inconsistency in how |
I am not sure if this is a related issue.
but this (adding an NaT) does not. At the very least, the error message is misleading:
|
Okay. I tracked down this issue to a bug in When iterating over the elements in The correct null check is to use |
I can submit a PR for this if there are no issues. |
See: #5961 |
Currently for certain formats of datetime strings, the tz offset will just be ignored.
BUG: Fix to_datetime to properly deal with tz offsets #3944
closed by #5958 |
Currently for certain formats of datetime strings, the tz offset will just be ignored.
after #3890, still unresolved / inconsistent
non-trivial to fix, so pushing to 0.12
The text was updated successfully, but these errors were encountered: