I am receiving twitter messages that are sent at a certain date in the following format from twitter:
Tue Mar 29 08:11:25 +0000 2011
I want
Using a similar strategy as SoFolichon proposed, in Python 3.x you can also use pytz like:
from datetime import datetime, timezone
import pytz
datetime.strptime(tweets["created_at"], '%a %b %d %H:%M:%S %z %Y').replace(
tzinfo=timezone.utc).astimezone(pytz.timezone('US/Eastern')).strftime(
'%Y-%m-%d %H:%M:%S')