From: Roman Donchenko Date: Thu, 4 Jul 2013 14:03:03 +0000 (+0400) Subject: xls-report.py: don't eat all errors when reading sheet.conf X-Git-Tag: accepted/tizen/ivi/20140515.103456~1^2~667^2~4 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=83fd385bbdc581d6aac631005fe2a5c652cff7b3;p=profile%2Fivi%2Fopencv.git xls-report.py: don't eat all errors when reading sheet.conf --- diff --git a/modules/ts/misc/xls-report.py b/modules/ts/misc/xls-report.py index e911314..4e2d8c6 100755 --- a/modules/ts/misc/xls-report.py +++ b/modules/ts/misc/xls-report.py @@ -67,6 +67,7 @@ from __future__ import division import ast +import errno import fnmatch import logging import numbers @@ -176,7 +177,8 @@ def main(): try: with open(os.path.join(sheet_path, 'sheet.conf')) as sheet_conf_file: sheet_conf = ast.literal_eval(sheet_conf_file.read()) - except Exception: + except IOError as ioe: + if ioe.errno != errno.ENOENT: raise sheet_conf = {} logging.debug('no sheet.conf for %s', sheet_path)