-
Notifications
You must be signed in to change notification settings - Fork 419
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
distro-sync: Print better info message when no match #1996
Conversation
Note: the changes in the PR are subject to discussion, therefore marking as |
Eh, we really need to provide good descriptive commit messages. Filtering out @System repo packages was introduced in PR #1148 which unfortunately only says "[goal] Exclude @System repo packages from distro_sync.", with no details. I really would like to know why the packages were excluded, but alas... |
"Unfortunately" the CI tests are passing, I was hoping for exploring the use case that was fixed by the original change. Anyway, I discussed the matter with @j-mracek and I will try to find less invasive solution as this issue is only about user reporting (and potentially I'll try to cover also other edges)... |
I found the clue. Available: Command: Before this patch it correctly downgrades |
Thanks @j-mracek, I will try to cover this use case in CI tests. |
So just FYI, adding the |
Another thing which feels incorrect IMO is when we pass a package which is not installed, but is available in any repository. In this case we get zero exit code with "Nothing to do. Complete!" messages, though the command should be examining the state of installed packages and I would expect the |
Print better error message when the package specified in the argument is installed but is not available in the currently enabled repositories. Resolves: https://issues.redhat.com/browse/RHEL-7018
1dffe7c
to
0471799
Compare
I think that the message is much better. I think we can merge this, but do you consider the change as a final? @jan-kolarik |
Yes, I tried to provide the reasons in the PR description. To ensure that the logic throughout the solver's path remains unchanged and to maintain backward compatibility of the command behavior, this is the only painless solution that came to my mind. |
If the package specified in the argument is installed but is not available in the currently enabled repositories, distro-sync will print an error when excluding the system repository.
System repo excluding was originally added here: #1148.
The originally posted fix was to simply revert the commit mentioned above (drop filtering the packages from system repo) as it was assumed as only an "optimization" change.
With regard to the comments mentioned below, the simplest and most straightforward solution, without breaking any existing workflow, is to improve the error message. The content of the message itself is also the main problem reported by the user in the linked ticket below.
CI tests: rpm-software-management/ci-dnf-stack#1390.
Resolves: https://issues.redhat.com/browse/RHEL-7018.