1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00

Ignore pylint warnings for construct that does not work with Python 2.

This commit is contained in:
Felix Fontein 2024-03-23 10:43:49 +01:00
parent da048aa12e
commit 51d559cc94
2 changed files with 3 additions and 3 deletions

View file

@ -161,7 +161,7 @@ def ldap_search(filter, base=None, attr=None):
break
else:
if result_type is ldap_module().RES_SEARCH_ENTRY:
for res in result_data:
for res in result_data: # pylint: disable=use-yield-from
yield res
uldap().lo.lo.abandon(msgid)

View file

@ -51,7 +51,7 @@ if sys.version_info >= (3,) and sys.version_info < (3, 4, 4):
# newline that our naive format() added
data_as_list[-1] = data_as_list[-1][:-1]
for line in data_as_list:
for line in data_as_list: # pylint: disable=use-yield-from
yield line
def mock_open(mock=None, read_data=''):
@ -80,7 +80,7 @@ if sys.version_info >= (3,) and sys.version_info < (3, 4, 4):
if handle.readline.return_value is not None:
while True:
yield handle.readline.return_value
for line in _data:
for line in _data: # pylint: disable=use-yield-from
yield line
global file_spec