From c4f78a0b54481b535f365057fddd1761b6bf1887 Mon Sep 17 00:00:00 2001 From: Sanj Date: Thu, 15 Nov 2012 15:17:00 +0530 Subject: [PATCH] year parsing --- ifa/films/imports.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ifa/films/imports.py b/ifa/films/imports.py index 4008ecc..3d8092a 100644 --- a/ifa/films/imports.py +++ b/ifa/films/imports.py @@ -34,7 +34,7 @@ def import_csv(path=csv_path): for line in lines: try: - year = int(line[1].replace('"', '')[0:4]) + year = int(line[1].replace('"', '').strip()[0:4]) year_error = False except: year = None