From b0cc8cfacfe3e64473012faa6a21cbf06efda477 Mon Sep 17 00:00:00 2001 From: Romain Bignon Date: Thu, 3 Jan 2013 19:40:56 +0100 Subject: [PATCH] add an error if unable to parse date --- modules/cmso/pages.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/modules/cmso/pages.py b/modules/cmso/pages.py index c4cfa66e..08f92713 100644 --- a/modules/cmso/pages.py +++ b/modules/cmso/pages.py @@ -104,6 +104,9 @@ class TransactionsPage(BasePage): yy = d.year date = datetime.date(yy, mm, dd) + else: + self.logger.error('Unable to parse date %r' % date) + continue t.parse(date, re.sub(r'[ ]+', ' ', raw)) t.amount = Decimal(div.xpath('.//span')[-1].text.strip().replace(' ', '').replace(',', ''))