From 8cd9ddfdeb31cdbf907513e31ae71b9c3390a296 Mon Sep 17 00:00:00 2001 From: Florence Blanc-Renaud Date: Mon, 21 Nov 2022 09:47:59 +0100 Subject: [PATCH] pylint: remove arguments-renamed warnings Related: https://pagure.io/freeipa/issue/9278 Signed-off-by: Florence Blanc-Renaud Reviewed-By: Stanislav Levin --- ipaserver/plugins/group.py | 1 + ipaserver/plugins/schema.py | 4 +++- ipatests/test_xmlrpc/tracker/idp_plugin.py | 2 +- ipatests/test_xmlrpc/tracker/user_plugin.py | 2 +- 4 files changed, 6 insertions(+), 3 deletions(-) diff --git a/ipaserver/plugins/group.py b/ipaserver/plugins/group.py index afdad93c1..afc706ddc 100644 --- a/ipaserver/plugins/group.py +++ b/ipaserver/plugins/group.py @@ -545,6 +545,7 @@ class group_find(LDAPSearch): ), ) + # pylint: disable-next=arguments-renamed def pre_callback(self, ldap, filter, attrs_list, base_dn, scope, criteria=None, **options): assert isinstance(base_dn, DN) diff --git a/ipaserver/plugins/schema.py b/ipaserver/plugins/schema.py index 7888c9bb5..774bf1aa5 100644 --- a/ipaserver/plugins/schema.py +++ b/ipaserver/plugins/schema.py @@ -177,7 +177,7 @@ class metaobject(MetaObject): def _iter_params(self, metaobj): raise NotImplementedError() - def _get_obj(self, metaobj, all=False, **kwargs): + def _get_obj(self, metaobj, all=False, **kwargs): # pylint: disable=W0237 obj = dict() obj['name'] = unicode(metaobj.name) obj['version'] = unicode(metaobj.version) @@ -470,6 +470,7 @@ class BaseParam(BaseMetaObject): def parent(self): raise AttributeError('parent') + # pylint: disable-next=arguments-renamed def _split_search_args(self, parent_name, criteria=None): return [parent_name], criteria @@ -495,6 +496,7 @@ class BaseParamRetrieve(BaseParamMethod, BaseMetaRetrieve): class BaseParamSearch(BaseParamMethod, BaseMetaSearch): + # pylint: disable-next=arguments-renamed def execute(self, command, criteria=None, **options): result = list(self.obj.search(command, criteria, **options)) return dict(result=result, count=len(result), truncated=False) diff --git a/ipatests/test_xmlrpc/tracker/idp_plugin.py b/ipatests/test_xmlrpc/tracker/idp_plugin.py index 44e2fb591..b1ca4ec94 100644 --- a/ipatests/test_xmlrpc/tracker/idp_plugin.py +++ b/ipatests/test_xmlrpc/tracker/idp_plugin.py @@ -101,7 +101,7 @@ class IdpTracker(Tracker): """ Make function that finds idp using idp-find """ return self.make_command('idp_find', *args, **kwargs) - def check_find(self, result, all=False, pkey_only=False, raw=False): + def check_find(self, result, all=False, raw=False, pkey_only=False): """ Check idp-find command result """ if all: expected = self.filter_attrs(self.find_all_keys) diff --git a/ipatests/test_xmlrpc/tracker/user_plugin.py b/ipatests/test_xmlrpc/tracker/user_plugin.py index b04be4c19..499e42248 100644 --- a/ipatests/test_xmlrpc/tracker/user_plugin.py +++ b/ipatests/test_xmlrpc/tracker/user_plugin.py @@ -312,7 +312,7 @@ class UserTracker(CertmapdataMixin, KerberosAliasMixin, Tracker): result=expected, ), result) - def check_find(self, result, all=False, pkey_only=False, raw=False, + def check_find(self, result, all=False, raw=False, pkey_only=False, expected_override=None): """ Check 'user-find' command result """ if all: