summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorScott Moser <smoser@brickies.net>2017-05-22 10:17:38 -0400
committerScott Moser <smoser@brickies.net>2017-05-22 12:12:46 -0400
commit9c33cb24b8a834aa8034db4c989725901a0814c6 (patch)
tree0765d347c9ba1d0431005d46b16fd29b1b1f9da0
parent2c0655feb9a194b5fbdfe90a5f847c16f1e15409 (diff)
downloadcloud-init-git-9c33cb24b8a834aa8034db4c989725901a0814c6.tar.gz
tox: move pylint target to 1.7.1
The motivation for this is to make tip-pylint target green. It does 2 things: a.) silence a warning that is generated in pylint 1.7.1, but not other versions of pylint. This bug in pylint is filed at https://github.com/PyCQA/pylint/issues/1444 b.) move tox -e pylint to use pylint 1.7.1
-rw-r--r--cloudinit/util.py5
-rw-r--r--tox.ini2
2 files changed, 4 insertions, 3 deletions
diff --git a/cloudinit/util.py b/cloudinit/util.py
index 67ff7ba3..135e4608 100644
--- a/cloudinit/util.py
+++ b/cloudinit/util.py
@@ -478,10 +478,11 @@ def decomp_gzip(data, quiet=True, decode=True):
try:
buf = six.BytesIO(encode_text(data))
with contextlib.closing(gzip.GzipFile(None, "rb", 1, buf)) as gh:
+ # E1101 is https://github.com/PyCQA/pylint/issues/1444
if decode:
- return decode_binary(gh.read())
+ return decode_binary(gh.read()) # pylint: disable=E1101
else:
- return gh.read()
+ return gh.read() # pylint: disable=E1101
except Exception as e:
if quiet:
return data
diff --git a/tox.ini b/tox.ini
index 826f554e..fce07740 100644
--- a/tox.ini
+++ b/tox.ini
@@ -18,7 +18,7 @@ setenv =
LC_ALL = en_US.utf-8
[testenv:pylint]
-deps = pylint==1.6.5
+deps = pylint==1.7.1
commands = {envpython} -m pylint {posargs:cloudinit}
[testenv:py3]