From 663454c0370588d728cf0e03fd4e1b4f76d63101 Mon Sep 17 00:00:00 2001 From: Bradlee Speice Date: Sat, 13 Aug 2016 10:30:20 -0400 Subject: [PATCH] Do I actually need to correct EST? Or was it just install dateutil? --- metrik/tasks/ice.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/metrik/tasks/ice.py b/metrik/tasks/ice.py index 7d25d2c..5e17dde 100644 --- a/metrik/tasks/ice.py +++ b/metrik/tasks/ice.py @@ -63,14 +63,14 @@ class LiborRateTask(MongoCreateTask): # download with `requests`, I see both date (often incorrect) and time. dt = parse(row['publication']) - if dt.tzinfo is None: + # if dt.tzinfo is None: # Seems like the messed up timezone is always America/New_York # I'd be interested to know if it's an IP based thing, but the # Travis settings resolve the `local` timezone to UTC so just # manually set New York here to work around that. - logging.warning('Correcting parsed ICE time to America/New_York') - tz = pytz.timezone('America/New_York') - dt = tz.localize(dt, is_dst=('EST' in row['publication'])) + # logging.warning('Correcting parsed ICE time to America/New_York') + # tz = pytz.timezone('America/New_York') + # dt = tz.localize(dt, is_dst=('EST' in row['publication'])) dt = dt.replace(year=date.year, month=date.month, day=date.day) globals()['publication'] = dt