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

clean "changed" only after it has been processed #59958

Merged
merged 2 commits into from Oct 10, 2019

Conversation

jamescassell
Copy link
Contributor

@jamescassell jamescassell commented Aug 1, 2019

SUMMARY

without this change, a loop of debug tasks with changed_when
causes the "changed" status to get lost before output

updates position of _clean_results() in v2_runner_item_on_ok to match the position in v2_runner_on_ok

fixes #57958
fixes #38974

ISSUE TYPE
  • Bugfix Pull Request
COMPONENT NAME

debug
loop
default callback

ADDITIONAL INFORMATION

@ansibot ansibot added affects_2.9 This issue/PR affects Ansible v2.9 bug This issue/PR relates to a bug. core_review In order to be merged, this PR must follow the core review workflow. needs_triage Needs a first human triage before being processed. support:community This issue/PR relates to code supported by the Ansible community. support:core This issue/PR relates to code supported by the Ansible Engineering Team. labels Aug 1, 2019
@samdoran samdoran added P3 Priority 3 - Approved, No Time Limitation and removed needs_triage Needs a first human triage before being processed. labels Aug 6, 2019
@jamescassell jamescassell changed the title clean "changed" after it has been processed clean "changed" only after it has been processed Aug 10, 2019
without this change, a loop of `debug` tasks with `changed_when`
causes the "changed" status to get lost before output
Copy link
Contributor

@felixfontein felixfontein left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@ansibot ansibot added the stale_ci This PR has been tested by CI more than one week ago. Close and re-open this PR to get it retested. label Aug 20, 2019
@s-hertel s-hertel self-requested a review October 10, 2019 15:26
Copy link
Contributor

@s-hertel s-hertel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks right to me. It continues filtering out excess noise with debug while properly reporting changed in a loop (sans loop that is already the current behavior).

@s-hertel
Copy link
Contributor

rebuild_merge

@ansibot ansibot added shipit This PR is ready to be merged by Core and removed core_review In order to be merged, this PR must follow the core review workflow. stale_ci This PR has been tested by CI more than one week ago. Close and re-open this PR to get it retested. labels Oct 10, 2019
@ansibot ansibot merged commit bfd32c9 into ansible:devel Oct 10, 2019
jamescassell added a commit to jamescassell/ansible that referenced this pull request Oct 11, 2019
* clean "changed" after it has been processed

without this change, a loop of `debug` tasks with `changed_when`
causes the "changed" status to get lost before output

* runme.sh tests for debug loop status

(cherry picked from commit bfd32c9)
jamescassell added a commit to jamescassell/ansible that referenced this pull request Oct 11, 2019
* clean "changed" after it has been processed

without this change, a loop of `debug` tasks with `changed_when`
causes the "changed" status to get lost before output

* runme.sh tests for debug loop status

(cherry picked from commit bfd32c9)
abadger pushed a commit that referenced this pull request Oct 12, 2019
* clean "changed" after it has been processed

without this change, a loop of `debug` tasks with `changed_when`
causes the "changed" status to get lost before output

* runme.sh tests for debug loop status

(cherry picked from commit bfd32c9)
abadger pushed a commit that referenced this pull request Oct 12, 2019
* clean "changed" after it has been processed

without this change, a loop of `debug` tasks with `changed_when`
causes the "changed" status to get lost before output

* runme.sh tests for debug loop status

(cherry picked from commit bfd32c9)
abadger pushed a commit that referenced this pull request Nov 1, 2019
* clean "changed" after it has been processed

without this change, a loop of `debug` tasks with `changed_when`
causes the "changed" status to get lost before output

* runme.sh tests for debug loop status

(cherry picked from commit bfd32c9)
@ansible ansible locked and limited conversation to collaborators Nov 13, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
affects_2.9 This issue/PR affects Ansible v2.9 bug This issue/PR relates to a bug. has_issue P3 Priority 3 - Approved, No Time Limitation shipit This PR is ready to be merged by Core support:community This issue/PR relates to code supported by the Ansible community. support:core This issue/PR relates to code supported by the Ansible Engineering Team.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

changed_when in a loop gets lost Using with_items causes changed items to report ok in output
6 participants