Skip to content
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

convert string to timestamp shouldn't apply local timezone offset if there's no explicit timezone info in the string #2813

Closed
Tracked by #3148
waitingkuo opened this issue Sep 30, 2022 · 0 comments · Fixed by #2814
Labels
arrow Changes to the arrow crate bug

Comments

@waitingkuo
Copy link
Contributor

Describe the bug

To Reproduce

use arrow::compute::kernels::cast_utils::string_to_timestamp_nanos;

fn main() {
    let t = string_to_timestamp_nanos("1970-01-01T00:00:00");
    println!("{:?}", t);
}

outputs

Ok(-28800000000000)

note that i'm in UTC+8

Expected behavior

should outputs

Ok(0)

Additional context

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
arrow Changes to the arrow crate bug
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants