Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

improve output in with_items mode #627

Closed
mpdehaan opened this issue Jul 19, 2012 · 1 comment
Closed

improve output in with_items mode #627

mpdehaan opened this issue Jul 19, 2012 · 1 comment

Comments

@mpdehaan
Copy link
Contributor

Currently using with_items doesn't tell you what item you are using in non-verbose mode.

what should happen is inside of executor_internal_inner, on success, we should add the message (msg) there, saying what the value of "item" is.

This way, it can be used for all types of values fed into with_items. Given a module might have reason to return a message even if it doesn't fail, we could just set this as:

item: "$item"

Additionally, we would like to show this data even if not in verbose mode, so we probably want to modify callbacks.py such that if an item is set, it looks more like this:

ok: [localhost] => (item=$item) => {...}

Which we can do by seeing if the "item" key is in the return results.

This way no modules have to be customized to show what "item" they are running against, it just works, and with_items output is more logical.

@ghost ghost assigned goozbach Jul 19, 2012
@goozbach
Copy link
Contributor

Originally found in #626.

mpdehaan pushed a commit that referenced this issue Jul 20, 2012
mpdehaan added a commit that referenced this issue Jul 20, 2012
improved output in with_items fixes: #627
@ansible ansible locked and limited conversation to collaborators Apr 24, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants