mtga-log-client icon indicating copy to clipboard operation
mtga-log-client copied to clipboard

Script does not work in Windows

Open kelesi opened this issue 4 years ago • 0 comments

This code fails in Windows:

self.cur_log_time = datetime.datetime.fromtimestamp(0)
self.last_utc_time = datetime.datetime.fromtimestamp(0)

with

Traceback (most recent call last):
  File "mtga_follower.py", line 833, in <module>
    follower = Follower(token, host=args.host)
  File "mtga_follower.py", line 154, in __init__
    self.cur_log_time = datetime.datetime.fromtimestamp(0)
OSError: [Errno 22] Invalid argument

It seems like the lowest value that fromtimestamp() function can take on Windows is 86400.

kelesi avatar Aug 20 '20 17:08 kelesi