-
Notifications
You must be signed in to change notification settings - Fork 41
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 empty error window #230
base: master
Are you sure you want to change the base?
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.
Looks good to me. BTW are you testing this functionality in master using dnf5daemon?
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 have dnf 4.14.0 on my distro. I think if anyway there's no error with dnf 5, this text won't be shown.
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.
@anaselli I suggest to change the text:
err = _('The list of packages cannot be installed:') + '\n' + '\n'.join(self.options['install'] + '\nMaybe some of them are already installed.')
We couldn't find this error in other cases rather than this. An empty error window appeared only when there were packages had been installed beforehand. Maybe it can help users.
@@ -1993,6 +1993,8 @@ def _OnBuildTransaction(self, info): | |||
self._status = DNFDragoraStatus.RUN_TRANSACTION | |||
else: | |||
err = "".join(resolve) if isinstance(resolve, list) else resolve if isinstance(resolve, list) else repr(resolve); | |||
if not err: | |||
err = _('The list of packages cannot be installed:') + '\n' + '\n'.join(self.options['install']) |
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.
Maybe "The list of packages that cannot be installed"?
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.
В этой фразе "the" переводится как "этот" или "данный". Всё правильно.
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.
У тебя пропущено слово "которые" ("that" или, может, лучше "which", надо подумать)
When installing the package that is already installed, error window has no text. This patch fixes the problem.