From 03727188310e7fa9b5fc0b3e04e8e418d2acac6a Mon Sep 17 00:00:00 2001 From: Pedro Algarvio Date: Tue, 2 Apr 2019 00:25:29 +0100 Subject: [PATCH] Fix lint issues on salt --- .testing.pylintrc | 3 ++- salt/cloud/clouds/vmware.py | 2 +- salt/modules/gpg.py | 2 +- salt/netapi/rest_cherrypy/app.py | 2 +- 4 files changed, 5 insertions(+), 4 deletions(-) diff --git a/.testing.pylintrc b/.testing.pylintrc index 30f93d53bb..86237fd582 100644 --- a/.testing.pylintrc +++ b/.testing.pylintrc @@ -154,7 +154,8 @@ disable=R, E8266, E8402, E8731, - 3rd-party-local-module-not-gated + 3rd-party-local-module-not-gated, + pep8-reserved-keywords # Disabled: # R* [refactoring suggestions & reports] diff --git a/salt/cloud/clouds/vmware.py b/salt/cloud/clouds/vmware.py index 79e2fe4cd6..1d51674df1 100644 --- a/salt/cloud/clouds/vmware.py +++ b/salt/cloud/clouds/vmware.py @@ -139,7 +139,7 @@ import salt.config as config from salt.ext import six try: # Attempt to import pyVmomi libs - from pyVmomi import vim + from pyVmomi import vim # pylint: disable=no-name-in-module HAS_PYVMOMI = True except ImportError: HAS_PYVMOMI = False diff --git a/salt/modules/gpg.py b/salt/modules/gpg.py index 864f45b042..4e2bbb35d5 100644 --- a/salt/modules/gpg.py +++ b/salt/modules/gpg.py @@ -181,7 +181,7 @@ def _create_gpg(user=None, gnupghome=None): gnupghome = _get_user_gnupghome(user) if GPG_1_3_1: - gpg = gnupg.GPG(homedir=gnupghome) + gpg = gnupg.GPG(homedir=gnupghome) # pylint: disable=unexpected-keyword-arg else: gpg = gnupg.GPG(gnupghome=gnupghome) diff --git a/salt/netapi/rest_cherrypy/app.py b/salt/netapi/rest_cherrypy/app.py index 15af1e73dc..82615afb29 100644 --- a/salt/netapi/rest_cherrypy/app.py +++ b/salt/netapi/rest_cherrypy/app.py @@ -1082,7 +1082,7 @@ def lowdata_fmt(): # headers for form encoded data (including charset or something similar) if data and isinstance(data, collections.Mapping): # Make the 'arg' param a list if not already - if 'arg' in data and not isinstance(data['arg'], list): + if 'arg' in data and not isinstance(data['arg'], list): # pylint: disable=unsupported-membership-test data['arg'] = [data['arg']] # Finally, make a Low State and put it in request