def epoch2datetime(epoch):
 if (epoch is not None):
  return datetime.datetime.fromtimestamp(epoch, tz=UTC)

def epoch2datetime ( epoch ) : if ( epoch is not None ) : return datetime . datetime . fromtimestamp ( epoch , tz = UTC )
convert a unix epoch time to a datetime object .