Skip to content

Regression: thrown no-changed-when error for async operation with command #4649

@Red-GV

Description

@Red-GV
Summary

Original issue here: #4638

There appears to be a regression from #1588 .

no-changed-when is being thrown for an asynchronous operation when it should not. The docs state that changed_when should not be applied for an asynchronous task.

Issue Type
  • Bug Report
OS / ENVIRONMENT
ansible-lint 25.4.0 using ansible-core:2.18.3 ansible-compat:25.5.0 ruamel-yaml:0.18.12 ruamel-yaml-clib:0.2.12
  • ansible installation method: pip
  • ansible-lint installation method: pip
STEPS TO REPRODUCE
- name: Do something with async
  ansible.builtin.command:
    cmd: echo 'hello world'
  async: 600
  poll: 0
  register: async_update_results
Desired Behavior

The changed_when error should not be firing.

Possible security bugs should be reported via email to [email protected]

Actual Behavior

The no-changed-when error is appearing

no-changed-when: Commands should not change things if nothing needs doing.
roles/awx/tasks/<name>.yaml: Task/Handler:

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    Status

    No status

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions