You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When calling this script via an Ansible task with conditionals setup to check for any output as a Changed or Failed indicator, the conditional is tripped whenever no further updates are available.
The rc value of 0 seems to indicate success, but the conditionals applied that demand no ouput from the script as a success indicator are tripped whenever a (Windows?) EOL is emitted.
The text was updated successfully, but these errors were encountered:
After a light review, I did not spot where the newline is "leaking" out. The workaround here might very well be to key solely off of return code instead of triggering on script output.
When calling this script via an Ansible task with conditionals setup to check for any output as a Changed or Failed indicator, the conditional is tripped whenever no further updates are available.
Example task parameters:
Example "failure":
fatal: [host.example.com]: FAILED! => {"changed": true, "failed_when_result": true, "rc": 0, "stderr": "Shared connection to host.example.com closed.\r\n", "stderr_lines": ["Shared connection to host.example.com closed."], "stdout": "\r\n", "stdout_lines": [""]}
This stands out:
"stdout": "\r\n"
"changed": true
"failed_when_result": true
"rc": 0
The
rc
value of 0 seems to indicate success, but the conditionals applied that demand no ouput from the script as a success indicator are tripped whenever a (Windows?) EOL is emitted.The text was updated successfully, but these errors were encountered: