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

Handle UNIX timestamps in handle_datetime #374

Merged
merged 9 commits into from
Feb 16, 2024
Merged

Handle UNIX timestamps in handle_datetime #374

merged 9 commits into from
Feb 16, 2024

Conversation

jvavrek
Copy link
Contributor

@jvavrek jvavrek commented Jun 30, 2023

Passing a UNIX timestamp like 1686726000.0 to handle_datetime currently gives an error, but we can parse it with datetime.fromtimestamp.

@jvavrek
Copy link
Contributor Author

jvavrek commented Jun 30, 2023

One test failure occurs on the CI but not my machine:

FAILED tests/utils_test.py::test_handle_datetime[1686726000.0] - AssertionError: assert datetime.datetime(2023, 6, 14, 7, 0) == datetime.datetime(2023, 6, 14, 0, 0)

This is almost certainly a timezone issue.

The other test failure is in isotope_qty_test.py, which I will investigate.

@markbandstra
Copy link
Member

Sorry @jvavrek , I accidentally canceled the tests while trying to rerun them, I didn't see you had just pushed.

@jvavrek
Copy link
Contributor Author

jvavrek commented Jul 12, 2023

Sorry @jvavrek , I accidentally canceled the tests while trying to rerun them, I didn't see you had just pushed.

No problem. I only updated from main, so they were bound to fail again anyway.

@jvavrek jvavrek merged commit 0b7b5b8 into main Feb 16, 2024
22 checks passed
@jvavrek jvavrek deleted the handle-unix-ts branch February 16, 2024 19:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants