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 2151910 - yum check-update incorrectly reports source packages as updates
Summary: yum check-update incorrectly reports source packages as updates
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 8
Classification: Red Hat
Component: dnf
Version: 8.7
Hardware: All
OS: Unspecified
medium
medium
Target Milestone: rc
: ---
Assignee: Packaging Maintenance Team
QA Contact: Tomáš Bajer
URL:
Whiteboard:
Depends On:
Blocks: 2203069
TreeView+ depends on / blocked
 
Reported: 2022-12-08 14:36 UTC by jcastran
Modified: 2023-11-14 18:06 UTC (History)
6 users (show)

Fixed In Version: dnf-4.7.0-17.el8
Doc Type: No Doc Update
Doc Text:
Clone Of:
: 2203069 (view as bug list)
Environment:
Last Closed: 2023-11-14 15:49:42 UTC
Type: Bug
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github rpm-software-management dnf pull 1871 0 None open Omit src RPMs from check-update (RhBug: 2151910) 2022-12-20 14:39:34 UTC
Red Hat Issue Tracker RHELPLAN-141681 0 None None None 2022-12-08 14:45:16 UTC
Red Hat Product Errata RHBA-2023:7122 0 None None None 2023-11-14 15:49:54 UTC

Description jcastran 2022-12-08 14:36:34 UTC
Description of problem:
When a source repository is enabled, yum check-update 

Version-Release number of selected component (if applicable):
dnf-4.7.0-11.el8.noarch
libdnf-0.63.0-11.1.el8.x86_64
libsolv-0.7.20-3.el8.x86_64

Steps to Reproduce:
1. enable source repo
2. install perl-parent
3. yum check-update

Actual results:
$ yum check-update perl-parent --enablerepo=rhel-8-for-x86_64-appstream-source-rpms
Updating Subscription Management repositories.
Last metadata expiration check: 0:02:21 ago on Thu 08 Dec 2022 09:29:41 AM EST.

perl-parent.src   1:0.237-1.module+el8+2464+d274aed1   rhel-8-for-x86_64-appstream-source-rpms


$ yum update perl-parent --enablerepo=rhel-8-for-x86_64-appstream-source-r
Updating Subscription Management repositories.
Last metadata expiration check: 0:05:20 ago on Thu 08 Dec 2022 09:29:41 AM EST.
Dependencies resolved.
Nothing to do.
Complete!


Expected results:
yum check-update should not report source packages as updates to anything.

Additional info:
The reported package is from another module:stream. It seems that check-update is just going off version, and not respecting modular filtering. It should just ignore source packages all together since they are not updates to anything.

Comment 1 Kyle Walker 2022-12-19 21:01:02 UTC
So, this looks to be due to:

  dnf/cli/cli.py
    check_updates()
    -> returnPkgLists()

  dnf/base.py
       -> _do_package_lists()
          -> _list_pattern()

Where, _list_pattern() will return src RPMs. The solution looks to be something like passing in something like a new "include_src=True" default argument into _do_package_lists that can be overridden in the returnPkgLists() callpath.

Comment 2 Kyle Walker 2022-12-20 14:39:34 UTC
Filed PR upstream to illustrate what I mean by the above, feel free to make alterations/changes.

Comment 3 Marek Blaha 2023-01-03 10:27:30 UTC
I've created a test for the issue: https://github.com/rpm-software-management/ci-dnf-stack/pull/1198

Comment 14 errata-xmlrpc 2023-11-14 15:49:42 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 (dnf 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:7122


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