Flake8 35 (#11972)
* Upgrade flake8 to 3.5 * Fix flake8 bare except errors * Make flake8 and pylint cooperate
This commit is contained in:
1 parent
5426e5c875
commit
78a3c01f27
12 files changed
+15
-21
No files matched your search
@@ -153,8 +153,7 @@ class StoredData(object):
|
||||
with self._lock, open(self._data_file, 'rb') as myfile:
|
||||
self._data = pickle.load(myfile) or {}
|
||||
self._cache_outdated = False
|
||||
# pylint: disable=bare-except
|
||||
except:
|
||||
except: # noqa: E722 # pylint: disable=bare-except
|
||||
_LOGGER.error("Error loading data from pickled file %s",
|
||||
self._data_file)
|
||||
|
||||
@@ -172,8 +171,7 @@ class StoredData(object):
|
||||
url, self._data_file)
|
||||
try:
|
||||
pickle.dump(self._data, myfile)
|
||||
# pylint: disable=bare-except
|
||||
except:
|
||||
except: # noqa: E722 # pylint: disable=bare-except
|
||||
_LOGGER.error(
|
||||
"Error saving pickled data to %s", self._data_file)
|
||||
self._cache_outdated = True
|
||||
Reference in new issue
Block a user