mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-05-06 13:22:48 +00:00
Fix indexed_items.py to run on python3 (#17292)
On python3, zip is a iterator so we need to explictily create the list from that.
This commit is contained in:
committed by
Toshio Kuratomi
parent
9c311b6b13
commit
8f364b549b
@@ -31,5 +31,5 @@ class LookupModule(LookupBase):
|
||||
raise AnsibleError("with_indexed_items expects a list")
|
||||
|
||||
items = self._flatten(terms)
|
||||
return zip(range(len(items)), items)
|
||||
return list(zip(range(len(items)), items))
|
||||
|
||||
|
||||
Reference in New Issue
Block a user