RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 2179413 - Adding RepoID to the packages involved in dependency error RHEL 9-DNF.
Summary: Adding RepoID to the packages involved in dependency error RHEL 9-DNF.
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 9
Classification: Red Hat
Component: libdnf
Version: 9.1
Hardware: Unspecified
OS: Unspecified
unspecified
high
Target Milestone: rc
: ---
Assignee: Jaroslav Mracek
QA Contact: Tomáš Bajer
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2023-03-17 17:47 UTC by Sagar Navale
Modified: 2023-11-07 11:34 UTC (History)
6 users (show)

Fixed In Version: libdnf-0.69.0-5.el9
Doc Type: No Doc Update
Doc Text:
Clone Of:
Environment:
Last Closed: 2023-11-07 08:54:48 UTC
Type: Bug
Target Upstream Version:
Embargoed:
pm-rhel: mirror+


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Bugzilla 2179409 0 unspecified CLOSED Adding RepoID to the packages involved in dependency error RHEL 8-DNF. 2023-11-14 18:06:43 UTC
Red Hat Issue Tracker RHELPLAN-152231 0 None None None 2023-03-17 17:50:41 UTC
Red Hat Product Errata RHBA-2023:6647 0 None None None 2023-11-07 08:54:52 UTC

Internal Links: 2179409

Description Sagar Navale 2023-03-17 17:47:44 UTC
Description of problem:
Adding repository name (RepoID) to the packages involved in dependency error.

Version-Release number of selected component (if applicable):
dnf

How reproducible:

Any dnf transaction that triggers a dependency error 

Example:- 
~~~Error: 
 Problem 1: package selinux-policy-targeted-34.1.29-1.el9_0.noarch requires policycoreutils >= 3.3-5, but none of the providers can be installed
  - conflicting requests
 Problem 2: package selinux-policy-34.1.29-1.el9_0.noarch requires policycoreutils >= 3.3-5, but none of the providers can be installed
  - package policycoreutils-3.4-4.el9.x86_64 requires diffutils, but none of the providers can be installed
  - package policycoreutils-3.3-6.el9_0.x86_64 requires diffutils, but none of the providers can be installed
  - conflicting requests
 Problem 3: package selinux-policy-34.1.29-1.el9_0.noarch requires policycoreutils >= 3.3-5, but none of the providers can be installed
  - package rpm-plugin-selinux-4.16.1.3-12.el9_0.x86_64 requires selinux-policy-base, but none of the providers can be installed
  - package policycoreutils-3.4-4.el9.x86_64 requires libselinux-utils >= 3.4-1, but none of the providers can be installed
  - package policycoreutils-3.3-6.el9_0.x86_64 requires libselinux-utils >= 3.3-2, but none of the providers can be installed
  - conflicting requests
(try to add '--skip-broken' to skip uninstallable packages or '--nobest' to use not only best candidate packages)

~~~

Steps to Reproduce:
1. Trigger any `dnf` transaction that causes a dependency issue.

Actual results:

Error: 
 Problem 1: package selinux-policy-targeted-34.1.29-1.el9_0.noarch requires policycoreutils >= 3.3-5, but none of the providers can be installed
  - conflicting requests
 Problem 2: package selinux-policy-34.1.29-1.el9_0.noarch requires policycoreutils >= 3.3-5, but none of the providers can be installed
  - package policycoreutils-3.4-4.el9.x86_64 requires diffutils, but none of the providers can be installed
  - package policycoreutils-3.3-6.el9_0.x86_64 requires diffutils, but none of the providers can be installed
  - conflicting requests
 Problem 3: package selinux-policy-34.1.29-1.el9_0.noarch requires policycoreutils >= 3.3-5, but none of the providers can be installed
  - package rpm-plugin-selinux-4.16.1.3-12.el9_0.x86_64 requires selinux-policy-base, but none of the providers can be installed
  - package policycoreutils-3.4-4.el9.x86_64 requires libselinux-utils >= 3.4-1, but none of the providers can be installed
  - package policycoreutils-3.3-6.el9_0.x86_64 requires libselinux-utils >= 3.3-2, but none of the providers can be installed
  - conflicting requests
(try to add '--skip-broken' to skip uninstallable packages or '--nobest' to use not only best candidate packages)

Expected results:
The packages in the `problem` section shall include the `repository` name (RepoID) name beside them.

Comment 1 Jaroslav Mracek 2023-03-20 16:55:21 UTC
There is one negative part of the request - if the same package will be available from multiple repositories - dnf will report separate error report for each package. Currently DNF de-duplitate identical reports.

Comment 2 Jaroslav Mracek 2023-03-21 10:48:27 UTC
I would like to ask you for a feedback for the format of output. What do you think about:

                "package bloop-ext-2.0-1.noarch@updates requires bloop = 2.0-1, but none of the providers can be installed",
                "cannot install both bloop-2.0-1.noarch@updates and bloop-1.0-1.noarch@@System",
                "conflicting requests",
                "package bloop-ext-1.0-1.noarch@updates is filtered out by exclude filtering"

or

                "package bloop-ext-2.0-1.noarch from 'updates' requires bloop = 2.0-1, but none of the providers can be installed",
                "cannot install both bloop-2.0-1.noarch from `updates` and bloop-1.0-1.noarch from `@System`",
                "conflicting requests",
                "package bloop-ext-1.0-1.noarch from `updates` is filtered out by exclude filtering"

Or do you have any other idea?

Comment 3 Jan Blazek 2023-03-23 13:01:52 UTC
IMHO, the second suggested formatting is more clear and self descriptive (from 'updates'...). The '@' sign is already used for group ids which might be confusing.

Comment 4 Sagar Navale 2023-03-23 15:21:11 UTC
 from `updates` looks fine to me as it's more readable, also we can also consider having format bloop-2.0-1.noarch(updates) like we had something with yum previously.

Comment 5 Kyle Walker 2023-03-23 17:15:59 UTC
Just another opinion, but +1 for the "from '<repoid>'" format. It looks like the most straightforward.

Comment 6 Jaroslav Mracek 2023-03-24 12:03:02 UTC
Thank you very much for feedback.

I checked implementation in libdnf and it looks like that using "from '<repoid>'" will require additional changes in modules data structure, because formatting errors is shared with modules.

Comment 7 Jaroslav Mracek 2023-03-24 14:16:20 UTC
I have a patch that enhance error messages: https://github.com/rpm-software-management/libdnf/pull/1596

Comment 14 Tomáš Bajer 2023-06-02 09:08:46 UTC
VERIFIED with run-upstream-tests-on-rhel/see list below

NEW: libdnf-0.69.0-5.el9

19 features passed, 0 failed, 0 skipped
214 scenarios passed, 0 failed, 12 skipped
1507 steps passed, 0 failed, 87 skipped, 0 undefined
Took 1m4.987s

OLD: libdnf-0.69.0-3.el9_2.x86_64

Failing scenarios:
  dnf/broken-dependencies-report.feature:13  Broken dependencies are reported when strict and best options are off
  dnf/broken-dependencies-report.feature:37  Broken dependencies are reported when strict option is off and best option is on
  dnf/broken-dependencies-report.feature:61  Broken dependencies are reported when skip-broken and best options are on
  dnf/comps-group.feature:95  Install and remove group with excluded package dependency
  dnf/history-undo-dependant.feature:4  Undo module install with dependent userinstalled package
  dnf/install-dependencies.feature:8  Best candidates have conflicting dependencies
  dnf/install-exclude.feature:14  Install an RPM that requires excluded RPM
  dnf/microdnf/upgrade.feature:102  Upgrade all RPMs from multiple repositories with best=True
  dnf/module/enable-contexts.feature:48  An error is printed with no stream and context is possible to enable
  dnf/module/enable-dependencies.feature:241  Module cannot be disabled if there are other enabled streams requiring it
  dnf/module/enable-dependencies.feature:302  Cannot enable a stream depending on a disabled module
  dnf/module/enable-errors.feature:163  Enabling a stream depending on other than enabled stream should fail
  dnf/module/enable-errors.feature:198  Enabling a stream depending on a disabled stream should fail
  dnf/module/enable-errors.feature:236  Enabling two modules both requiring different streams of another module
  dnf/module/enable-errors.feature:248  Enabling module stream and another module requiring another stream
  dnf/module/install-module-static-context.feature:95  Install and upgrade from context with broken dependencies => static_context=true
  dnf/module/install.feature:68  Installing a module and its dependencies, non-modular dependency is not available
  dnf/obsoletes.feature:259  Both packages are installed when group contains both obsoleter and obsoleted packages and obsoletes are switched off
  dnf/plugins-core/builddep-modularity.feature:47  Builddep reports error where required package is available only in non-enabled non-default stream
  dnf/plugins-core/download-binary.feature:46  Error when failed to resolve dependencies
  dnf/repoquery/main.feature:585  repoquery --unsatisfied
  dnf/security-upgrade.feature:25  --security upgrade with advisories with pkgs of different arches (noarch variant)
  dnf/stick-to-vendor.feature:47  Downgrade is unable to resolve transaction
  dnf/transaction-sr/replay-errors.feature:250  Replay a transaction with a dependency conflict
  dnf/transaction-sr/replay-errors.feature:295  Replay a transaction with a broken dependency
  dnf/upgrade.feature:58  Upgrade all RPMs from multiple repositories with best=False
  dnf/upgrade.feature:88  Upgrade all RPMs from multiple repositories with best=True

0 features passed, 19 failed, 0 skipped
187 scenarios passed, 27 failed, 12 skipped
1455 steps passed, 27 failed, 112 skipped, 0 undefined
Took 1m1.382s

Comment 16 errata-xmlrpc 2023-11-07 08:54:48 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (libdnf bug fix and enhancement update), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2023:6647


Note You need to log in before you can comment on or make changes to this bug.