def utc2str(u): #return str(datetime.datetime.fromtimestamp(u)) #return _format_date(datetime.datetime.utcfromtimestamp(u)) return _format_date(datetime.datetime.fromtimestamp(u, tz.tzlocal()))
def utc2str(u, tz=None): # Format to RFC822 time string in current timezone if tz is None: tz = SNSAPI_TIMEZONE return _format_date(datetime.fromtimestamp(u, tz))