Closed lsim-aegeri closed 2 days ago
cc @smackesey if you've run across this before or have any ideas? @gibsondan you've also been looking at pendulum stuff recently right?
From what I can find through searching around, pendulum claims to have fixed this in https://github.com/sdispater/pendulum/issues/53, but it was part of the 0.6.2 release in 2016, so you should definitely have that code.
Other libraries that ran into the same issue, seem to write custom code to special case negative time on windows:
This PR from py-arrow uses timedelta if the date is negative and the OS is windows
Another example from faker https://github.com/joke2k/faker/pull/1436
IIUC @gibsondan has a PR that removes pendulum entirely so hopefully that will make this issue moot
We are going to remove pendulum, but we will still be using UNIX timestamps after that, so I'm not positive that will resolve this.
It's possible that the workaround suggested here could resolve this, but I have not tried it: https://stackoverflow.com/questions/37494983/python-fromtimestamp-oserror/41400321#41400321
yeah, after some internal discussion, this is something we aren't going to try to fix. We assume we can use unix timestamps all over our code base, so trying to work around this issue is infeasible at the time. Closing this issue
Dagster version
1.7.4
What's the issue?
Attempting to use a date before 1969-12-31 12:00:00 (i.e. negative epochs < -43200) results in the following error:
I'm pretty sure this comes up becuase
datetime.datetime.utcfromtimestamp()
will not accept large negative epochs on Windows machines. For example:returns
When I run an identical snippet on Linux, I get the expected result.
What did you expect to happen?
I expect to be able to create partitions that start or end before 1969-12-31 12:00:00.
How to reproduce?
I'm not sure it's helpful, but here's the contents of my anaconda environment.
The particular partitions that are failing are:
Deployment type
Local
Deployment details
No response
Additional information
No response
Message from the maintainers
Impacted by this issue? Give it a 👍! We factor engagement into prioritization.