I am trying to convert unix time to human readable time in python and am either getting an error, or the date:1969-12-31 18:00:00.
When I run:
datetime.datetime.fromtimestamp((1540254404.9600408)).strftime('%Y-%m-%d %H:%M:%S')
I am getting error:
[Errno 22] Invalid argument
I have also tried a few other functons like:
time.strftime('%Y-%m-%d %H:%M:%S', time.localtime(int(1540254404.9600408)))
which returns: '1969-12-31 18:00:00', which is also not correct...
my unix value as noted above is: 1540254404.9600408