Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
ansible
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
OpenEdx
ansible
Commits
3f968ff4
Commit
3f968ff4
authored
Oct 09, 2013
by
Michael DeHaan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Check one more skipped scenario in with_subelements.
parent
9124ebb4
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
0 deletions
+4
-0
lib/ansible/runner/lookup_plugins/subelements.py
+4
-0
No files found.
lib/ansible/runner/lookup_plugins/subelements.py
View file @
3f968ff4
...
...
@@ -39,6 +39,7 @@ class LookupModule(object):
if
isinstance
(
terms
[
0
],
dict
):
# convert to list:
if
terms
[
0
]
.
get
(
'skipped'
,
False
)
!=
False
:
# the registered result was completely skipped
return
[]
elementlist
=
[]
for
key
in
terms
[
0
]
.
iterkeys
():
...
...
@@ -51,6 +52,9 @@ class LookupModule(object):
for
item0
in
elementlist
:
if
not
isinstance
(
item0
,
dict
):
raise
errors
.
AnsibleError
(
"subelements lookup expects a dictionary, got '
%
s'"
%
item0
)
if
item0
.
get
(
'skipped'
,
False
)
!=
False
:
# this particular item is to be skipped
continue
if
not
subelement
in
item0
:
raise
errors
.
AnsibleError
(
"could not find '
%
s' key in iterated item '
%
s'"
%
(
subelement
,
item0
))
if
not
isinstance
(
item0
[
subelement
],
list
):
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment