-
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
zypper: add simple_errors option - fixes #8416 #9270
Conversation
This comment was marked as outdated.
This comment was marked as outdated.
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.
Thanks for your contribution! Can you please add a changelog fragment? Thanks.
This comment was marked as outdated.
This comment was marked as outdated.
Changelog fragment added as requested. |
Setting this to draft as it requires some additional work and testing. |
I added an option to turn off the With Here are some examples of the output when updating packages and disk is full using the various flags implemented here. Please note I'm using the Default options with
The final options and screenshot listed above was my targeted output, this will help me troubleshoot patching issues much more quickly and will make finding the specific error much more efficient than visually parsing through large amounts of xml especially when patching many servers at one time. |
Please note that there's now a conflict since we reformatted the module's documentation. |
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.
Besides this and the conflicts, looks good to me!
@erichoog this PR contains the following merge commits: Please rebase your branch to remove these commits. |
I made a mess of this rebase, probably should have been using a feature branch but for some reason I didn't this time. Any suggestions on best approach to clean this up? I suppose if the commits are all being squashed anyways it doesn't really matter. Please ignore unless it's an issue :) |
Can you tick the box that maintainers can push to your branch? (Right now it doesn't seem to be active, at least the tell-tale text is missing.) Then I'll clean it up and force-push it for you. |
If you want to try this yourself, I'd probably try running |
So I already tried this method but when I do I end up getting a bunch of conflicts which I thought I already resolved. You are more than welcome to fix it up if you are able to. |
GitHub changed their UI; previously you could detect that the checkbox was set by looking at the bottom of the discussion, GH would mention there that I (as a maintainer) can add additional commits by pushing to repo/branch. That text is no longer there; I just noticed that now there's an entry in the sidebar on the right: "Maintainers are allowed to edit this pull request." That's definitely easier to find, but not if you expect it to be somewhere else ;-) I'll try to fix this in the next few minutes. |
Co-authored-by: Felix Fontein <felix@fontein.de>
Co-authored-by: Felix Fontein <felix@fontein.de>
Co-authored-by: Felix Fontein <felix@fontein.de>
I think it should be OK now. Can you check? Thanks :) |
Thanks very much! I'll check if over now! |
Everything is looking good, and my tests looked good as well. Thanks for all your assistance so far! |
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.
Looks good from my side (I don't use Zypper, I only looked at the implementation).
Backport to stable-10: 💚 backport PR created✅ Backport PR branch: Backported as #9370 🤖 @patchback |
* zypper: add simple_errors option -fixes #8416 * Fix style issues * Apply suggestions from code review Co-authored-by: Felix Fontein <felix@fontein.de> * Fix indentation * Add changelog fragment * Apply suggestions from code review Co-authored-by: Felix Fontein <felix@fontein.de> * Updated as per code review recommendations * Fix whitespace * Add quiet option, fix logic, update changelog * Fix trailing whitespace * Update plugins/modules/zypper.py Co-authored-by: Felix Fontein <felix@fontein.de> * Add suggested improvements --------- Co-authored-by: Eric Hoogeveen <eric.hoogeveen@ssc-spc.gc.ca> Co-authored-by: Felix Fontein <felix@fontein.de> (cherry picked from commit 825e0ee)
@erichoog thanks for your contribution! |
…ion - fixes #8416 (#9370) zypper: add simple_errors option - fixes #8416 (#9270) * zypper: add simple_errors option -fixes #8416 * Fix style issues * Apply suggestions from code review Co-authored-by: Felix Fontein <felix@fontein.de> * Fix indentation * Add changelog fragment * Apply suggestions from code review Co-authored-by: Felix Fontein <felix@fontein.de> * Updated as per code review recommendations * Fix whitespace * Add quiet option, fix logic, update changelog * Fix trailing whitespace * Update plugins/modules/zypper.py Co-authored-by: Felix Fontein <felix@fontein.de> * Add suggested improvements --------- Co-authored-by: Eric Hoogeveen <eric.hoogeveen@ssc-spc.gc.ca> Co-authored-by: Felix Fontein <felix@fontein.de> (cherry picked from commit 825e0ee) Co-authored-by: Eric <8869330+erichoog@users.noreply.github.com>
…sible-collections#9270) * zypper: add simple_errors option -fixes ansible-collections#8416 * Fix style issues * Apply suggestions from code review Co-authored-by: Felix Fontein <felix@fontein.de> * Fix indentation * Add changelog fragment * Apply suggestions from code review Co-authored-by: Felix Fontein <felix@fontein.de> * Updated as per code review recommendations * Fix whitespace * Add quiet option, fix logic, update changelog * Fix trailing whitespace * Update plugins/modules/zypper.py Co-authored-by: Felix Fontein <felix@fontein.de> * Add suggested improvements --------- Co-authored-by: Eric Hoogeveen <eric.hoogeveen@ssc-spc.gc.ca> Co-authored-by: Felix Fontein <felix@fontein.de>
SUMMARY
This fixes #8416
It adds a
simple_errors
option for the zypper module which can be used to simplify or reduce the error output of the zypper module during package installs/updates so that only the content of<message>
tags are displayed. (Default isfalse
so the default behavior is unaffected)It also adds a
quiet
option for the zypper module to allow for the option to disable the--quiet
parameter from being passed to the zypper command. (Default istrue
so the default behavior is unaffected.ISSUE TYPE
COMPONENT NAME
zypper module