mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-10-04 23:44:00 -07:00
Replace .iteritems() with six.iteritems()
Replace .iteritems() with six.iteritems() everywhere except in module_utils (because there's no 'six' on the remote host). And except in lib/ansible/galaxy/data/metadata_template.j2, because I'm not sure six is available there.
This commit is contained in:
parent
9e1bc434c7
commit
823677b490
28 changed files with 81 additions and 41 deletions
|
@ -21,6 +21,8 @@ __metaclass__ = type
|
|||
|
||||
import os
|
||||
|
||||
from six import iteritems
|
||||
|
||||
from ansible.errors import AnsibleParserError
|
||||
from ansible.parsing.splitter import split_args, parse_kv
|
||||
from ansible.parsing.yaml.objects import AnsibleBaseYAMLObject, AnsibleMapping
|
||||
|
@ -95,7 +97,7 @@ class PlaybookInclude(Base, Conditional, Taggable):
|
|||
if isinstance(ds, AnsibleBaseYAMLObject):
|
||||
new_ds.ansible_pos = ds.ansible_pos
|
||||
|
||||
for (k,v) in ds.iteritems():
|
||||
for (k,v) in iteritems(ds):
|
||||
if k == 'include':
|
||||
self._preprocess_include(ds, new_ds, k, v)
|
||||
else:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue