-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
fix modules' output by using publish_cmd #3655
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess we cannot backport this since this feature of MH was only added for 4.0.0.
Co-authored-by: Felix Fontein <[email protected]>
Co-authored-by: Felix Fontein <[email protected]>
Co-authored-by: Felix Fontein <[email protected]>
Yup,, that occurred to me after sending the PR. The impact is small enough for me to care not. So, if you agree with me, then just hit it. Otherwise we need to discuss options. |
I could change it to a minor_change as well |
@russoz no, the current form is fine I think :) Just wanted to point it out so we don't accidentally try to backport it later ;) |
@russoz thanks for this improvement! |
* fix modules' output by using publish_cmd * added changelog frag * Update changelogs/fragments/3655-use-publish_cmd.yaml Co-authored-by: Felix Fontein <[email protected]> * Update changelogs/fragments/3655-use-publish_cmd.yaml Co-authored-by: Felix Fontein <[email protected]> * Update changelogs/fragments/3655-use-publish_cmd.yaml Co-authored-by: Felix Fontein <[email protected]> Co-authored-by: Felix Fontein <[email protected]>
SUMMARY
These three modules have the same mechanics: they run a "state gathering" function before and after executing the actual command. Because we lacked the
publish_cmd
option inMH.run_command()
, the output valuecmd_args
would always contain the arguments of the after-state-gathering call. Instead, what made sense was to show the command actually executed.ISSUE TYPE
COMPONENT NAME
plugins/modules/packaging/language/ansible_galaxy_install.py
plugins/modules/packaging/language/pipx.py
plugins/modules/packaging/os/snap_alias.py