def prettify_date(data): for item in data: date = parse(item['created_time']) tzlocal = tz.gettz('Asia/Kolkata') local_date = date.astimezone(tzlocal) item['real_date'] = local_date.strftime('%d-%m-%Y') item['real_time'] = local_date.strftime('%I:%M%p') return data