Bug 1243501 - `dnf downgrade' treats installed packages as not installed
`dnf downgrade' treats installed packages as not installed
Status: CLOSED ERRATA
Product: Fedora
Classification: Fedora
Component: dnf (Show other bugs)
rawhide
x86_64 Linux
unspecified Severity unspecified
: ---
: ---
Assigned To: Adam Salih
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2015-07-15 11:22 EDT by Matus Honek
Modified: 2015-09-08 12:37 EDT (History)
8 users (show)

See Also:
Fixed In Version: dnf-plugins-core-0.1.10-1.fc23
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2015-08-14 22:13:39 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Matus Honek 2015-07-15 11:22:22 EDT
Description of problem:
When downgrading packages using `dnf downgrade <package-name>\*', dnf incorrectly considers already installed packages (aka those eligible for downgrading) as if they were not installed, resulting in `No match for available package' also for already installed packages, which is IMO incorrect.

Version-Release number of selected component (if applicable):
Latest Fedora Rawhide.

How reproducible:
Always.

Steps to Reproduce:
1. Upgrade packages to higher version than the one available in repos.
2. Try to downgrade using `dnf downgrade <package-name>\*'.

Actual results:
For `openldap' package behaves as follows:

[root@vm-086 10353731]# dnf downgrade openldap\*
Last metadata expiration check performed 1:58:03 ago on Wed Jul 15 14:57:43 2015.
No match for available package: openldap-2.4.40-14.fc23.i686
No match for available package: openldap-2.4.40-14.fc23.x86_64
No match for available package: openldap-clients-2.4.40-14.fc23.x86_64
No match for available package: openldap-devel-2.4.40-14.fc23.i686
No match for available package: openldap-devel-2.4.40-14.fc23.x86_64
No match for available package: openldap-servers-2.4.40-14.fc23.x86_64
Error: Nothing to do.

[root@vm-086 10353731]# dnf list openldap\*
Last metadata expiration check performed 1:59:16 ago on Wed Jul 15 14:57:43 2015.
Installed Packages
openldap.x86_64                                 2.4.41-1.fc23                           @System
openldap-clients.x86_64                         2.4.41-1.fc23                           @System
openldap-devel.x86_64                           2.4.41-1.fc23                           @System
openldap-servers.x86_64                         2.4.41-1.fc23                           @System
Available Packages
openldap.i686                                   2.4.40-14.fc23                          rawhide
openldap-devel.i686                             2.4.40-14.fc23                          rawhide


Expected results:
Apart from resolving #1234763, dnf should also correctly match already installed packages and display correct statements instead of `No match for available package' for these.

Additional info:
  - Yum handles this as expected.
  - Beforehand I upgraded packages to version 2.4.41-1 (available as a scratch-build in koji) using `yum update openldap*.rpm'.
Comment 1 Honza Silhan 2015-07-15 11:28:57 EDT
Thanks for the report. Adam, take a lok, please - you have done this for update command.
Comment 2 Honza Silhan 2015-07-29 10:38:24 EDT
PR: https://github.com/rpm-software-management/dnf/pull/306
Comment 3 Fedora Update System 2015-08-10 06:05:53 EDT
dnf-plugins-core-0.1.10-1.fc23,dnf-1.1.0-1.fc23,hawkey-0.6.0-1.fc23 has been submitted as an update for Fedora 23.
https://admin.fedoraproject.org/updates/dnf-plugins-core-0.1.10-1.fc23,dnf-1.1.0-1.fc23,hawkey-0.6.0-1.fc23
Comment 4 Fedora Update System 2015-08-10 06:49:55 EDT
dnf-plugins-core-0.1.10-1.fc22,dnf-1.1.0-1.fc22,hawkey-0.6.0-1.fc22 has been submitted as an update for Fedora 22.
https://admin.fedoraproject.org/updates/dnf-plugins-core-0.1.10-1.fc22,dnf-1.1.0-1.fc22,hawkey-0.6.0-1.fc22
Comment 5 Fedora Update System 2015-08-10 22:11:07 EDT
Package dnf-plugins-core-0.1.10-1.fc22, dnf-1.1.0-1.fc22, hawkey-0.6.0-1.fc22:
* should fix your issue,
* was pushed to the Fedora 22 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing dnf-plugins-core-0.1.10-1.fc22 dnf-1.1.0-1.fc22 hawkey-0.6.0-1.fc22'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2015-13162/dnf-plugins-core-0.1.10-1.fc22,dnf-1.1.0-1.fc22,hawkey-0.6.0-1.fc22
then log in and leave karma (feedback).
Comment 6 Fedora Update System 2015-08-14 22:13:39 EDT
dnf-plugins-core-0.1.10-1.fc22, hawkey-0.6.0-1.fc22, dnf-1.1.0-2.fc22 has been pushed to the Fedora 22 stable repository.  If problems still persist, please make note of it in this bug report.
Comment 7 Fedora Update System 2015-08-19 03:51:40 EDT
dnf-plugins-core-0.1.10-1.fc23, hawkey-0.6.0-1.fc23, dnf-1.1.0-2.fc23 has been pushed to the Fedora 23 stable repository.  If problems still persist, please make note of it in this bug report.

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