# HG changeset patch # User RĂ©mi Cardona # Date 1442222170 -7200 # Node ID c7a090052e5feec8572adfb11cdb761a26b5b770 # Parent 6a55853f14c9a7a031731d4bcd9e784969e6d505 Use isinstance() instead of type comparison diff -r 6a55853f14c9 -r c7a090052e5f devtools/__init__.py --- a/devtools/__init__.py Tue Sep 15 15:10:59 2015 +0200 +++ b/devtools/__init__.py Mon Sep 14 11:16:10 2015 +0200 @@ -842,7 +842,7 @@ except Exception: # DateTime used as Time? row[cellindex] = strptime(value, '%Y-%m-%d %H:%M:%S') - if vtype == 'Interval' and type(value) is int: + if vtype == 'Interval' and isinstance(value, int): found_date = True row[cellindex] = timedelta(0, value, 0) # XXX value is in number of seconds? if not found_date: