summaryrefslogtreecommitdiff
path: root/tools/hacking.py
diff options
context:
space:
mode:
authorScott Moser <smoser@ubuntu.com>2012-08-09 13:42:55 -0400
committerScott Moser <smoser@ubuntu.com>2012-08-09 13:42:55 -0400
commit0243c5d9c7948e247a85870a24835e2f5ce92cb0 (patch)
treeb67c2911c07b013f893f1ac0c8428a99c9095628 /tools/hacking.py
parent1bb67be5bd8c826717c9757f727406c73c7ef4e8 (diff)
parent0849ad447de8a1628e6b0158a5ce9b45d93f9bb8 (diff)
downloadvyos-cloud-init-0243c5d9c7948e247a85870a24835e2f5ce92cb0.tar.gz
vyos-cloud-init-0243c5d9c7948e247a85870a24835e2f5ce92cb0.zip
fix pylint in all files used by ./tools/run-pylint
'make pylint' was not checking tests and tools. This fixies a bunch of pylint/pep8 issues in that code. It also enables 'make pylint' to check them.
Diffstat (limited to 'tools/hacking.py')
-rwxr-xr-xtools/hacking.py7
1 files changed, 2 insertions, 5 deletions
diff --git a/tools/hacking.py b/tools/hacking.py
index d0c27d25..a2e6e829 100755
--- a/tools/hacking.py
+++ b/tools/hacking.py
@@ -23,11 +23,8 @@ built on top of pep8.py
import inspect
import logging
-import os
import re
import sys
-import tokenize
-import warnings
import pep8
@@ -158,7 +155,7 @@ def add_cloud():
if not inspect.isfunction(function):
continue
if name.startswith("cloud_"):
- exec("pep8.%s = %s" % (name, name))
+ exec("pep8.%s = %s" % (name, name)) # pylint: disable=W0122
if __name__ == "__main__":
# NOVA based 'hacking.py' error codes start with an N
@@ -167,7 +164,7 @@ if __name__ == "__main__":
pep8.current_file = current_file
pep8.readlines = readlines
try:
- pep8._main()
+ pep8._main() # pylint: disable=W0212
finally:
if len(_missingImport) > 0:
print >> sys.stderr, ("%i imports missing in this test environment"