time_string="1569834192" #in epoch format. I want to convert it in "US/Eastern" timezone. But The output I get is as follows: 2019-09-30 14:33:12-04:56 I want exact time instead of this -04:56
my code: time_string="1569834192" print datetime.fromtimestamp(time_string, tz= pytz.timezone('US/Eastern')).strftime("%Y-%m-%d %H:%M:%S")
output: 2019-09-30 14:33:12-04:56
time_string="1569834192" print datetime.fromtimestamp(time_string, tz= pytz.timezone('US/Eastern')).strftime("%Y-%m-%d %H:%M:%S")
2019-09-30 14:33:12-04:56