[PR #6927/4b382ed1 backport][stable-7] remove pylint exceptions (#6929)

remove pylint exceptions (#6927)

* remove pylint exceptions

* add changelog frag

(cherry picked from commit 4b382ed1df)

Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
This commit is contained in:
patchback[bot] 2023-07-14 07:41:55 +02:00 committed by GitHub
parent 6584348d05
commit f6b5b793c8
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 9 additions and 13 deletions

View file

@ -210,13 +210,6 @@ from ansible_collections.community.general.plugins.module_utils.gitlab import (
)
try:
cmp # pylint: disable=used-before-assignment
except NameError:
def cmp(a, b):
return (a > b) - (a < b)
class GitLabRunner(object):
def __init__(self, module, gitlab_instance, group=None, project=None):
self._module = module
@ -302,7 +295,7 @@ class GitLabRunner(object):
list1.sort()
list2 = arguments[arg_key]
list2.sort()
if cmp(list1, list2):
if list1 != list2:
setattr(runner, arg_key, arguments[arg_key])
changed = True
else: