From bbee6fac338b54a3f541bec06ef9bf554aa7f83a Mon Sep 17 00:00:00 2001 From: Edward Welbourne Date: Mon, 13 Aug 2018 14:52:16 +0200 Subject: Stipulate which error is expected in try/except MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit PEP 8 wisely advises against the use of naked except: (unless re-raising the error). Change-Id: Ia0dfdb48b330d33ad370bdb9f6b205046aa919da Reviewed-by: Jędrzej Nowacki --- util/local_database/cldr2qlocalexml.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'util') diff --git a/util/local_database/cldr2qlocalexml.py b/util/local_database/cldr2qlocalexml.py index ce45f631a6..8c730cdcde 100755 --- a/util/local_database/cldr2qlocalexml.py +++ b/util/local_database/cldr2qlocalexml.py @@ -243,7 +243,7 @@ def _generateLocaleInfo(path, language_code, script_code, country_code, variant_ numbering_system = None try: numbering_system = findEntry(path, "numbers/defaultNumberingSystem") - except: + except xpathlite.Error: pass def findEntryDef(path, xpath, value=''): try: -- cgit v1.2.3