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
Reorganize the error handler #3056
Reorganize the error handler #3056
Conversation
Congratulations! One of the builds has completed. 🍾 You can install the built RPMs by following these steps:
Please note that the RPMs should be used only in a testing environment. |
Code looks far better, but won't our users miss all the wonderful detail in error popups? |
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.
Great cleanup, thanks a lot for this!
I have a few question below which I would like to have answered before merge.
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 to me - nice cleanup & removal of effectively dead code in hiding! :)
d9970b6
to
d88f148
Compare
/kickstart-test --testtype coverage |
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 to me, except that I wasn't able to spot the removed IPMI calls replacement.
We shouldn't handle errors in the code that is run by the installation tasks.
If the password cannot be encrypted with the specified algorithm, it is a bug.
We should fail to set up the source and report that to the user instead. The mountImage function is called only from the _find_and_mount_iso method with a normalized path of an ISO file. Therefore, we can remove the mountImage function and use the mount function from the payload utils instead.
d88f148
to
a1de0e3
Compare
We should fail to set up the source and report that to the user instead.
We are able to handle unknown groups. This is always a bug.
Move the mapping into an attribute and rename some of the handlers.
If there is no callback, then there is nothing to handle. We will always raise the exception.
Let the installation task handle the exception raised in the code. Any PayloadError exception is fatal anyway.
Rename the method to _handle_marking_error.
There is no InstallMoreStreamsException class in dnf.exceptions and the NoStreamSpecifiedException class is not used by DNF.
Show a dialog window that informs a user why the non-package payload couldn't be set up. There is no UI support that could handle the error state, so we need to handle or raise the error directly. Make sure that payloads raise the right exception from the setup method.
Log the IPMI events, so we can debug them when IPMI is not supported.
Make sure that we always report an IPMI event before calling sys.exit. Fix some of the exit codes since the installation cannot be successful in this case.
Make sure that exit dialog windows report an IPMI event before calling sys.exit. TUI already works this way, so we just need to fix GUI to work the same way.
a1de0e3
to
b6d9133
Compare
/kickstart-test --testtype coverage |
All issues should be resolved and the code is tested. |
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.
Great work! Thanks a lot for this!
We are not able to use the error handler in the DBus modules, so move
it from the low-level code to the top level if possible, so we don't have to
deal with it during the Anaconda modularization.
Remove error handlers for deprecated or invalid use cases and clean up
the code.