mirror of
https://github.com/ansible-collections/community.general.git
synced 2024-09-14 20:13:21 +02:00
[ecs_service_facts] replace map with dict for Python3 compatibility (#35355)
This commit is contained in:
parent
927ef22ad6
commit
e10e1d6ddf
1 changed files with 3 additions and 1 deletions
|
@ -167,7 +167,9 @@ class EcsServiceManager:
|
|||
fn_args['cluster'] = cluster
|
||||
fn_args['services'] = services.split(",")
|
||||
response = self.ecs.describe_services(**fn_args)
|
||||
relevant_response = dict(services=map(self.extract_service_from, response['services']))
|
||||
relevant_response = {'services': []}
|
||||
for service in response.get('services', []):
|
||||
relevant_response['services'].append(self.extract_service_from(service))
|
||||
if 'failures' in response and len(response['failures']) > 0:
|
||||
relevant_response['services_not_running'] = response['failures']
|
||||
return relevant_response
|
||||
|
|
Loading…
Reference in a new issue