Bug 1229730 - dnf.subject.Subject() does not honour epoch
Summary: dnf.subject.Subject() does not honour epoch
Alias: None
Product: Fedora
Classification: Fedora
Component: dnf
Version: 24
Hardware: Unspecified
OS: Unspecified
Target Milestone: ---
Assignee: Jaroslav Mracek
QA Contact: Fedora Extras Quality Assurance
Keywords: Triaged
Depends On:
Blocks: 1286877
TreeView+ depends on / blocked
Reported: 2015-06-09 14:08 UTC by Michael Mráka
Modified: 2016-12-02 15:17 UTC (History)
9 users (show)

Clone Of:
Last Closed: 2016-12-02 15:17:04 UTC

Attachments (Terms of Use)

External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Bugzilla 1286877 None CLOSED Cannot specify package installation versions without including epoch using DNF 2019-03-07 10:24 UTC

Internal Trackers: 1286877

Description Michael Mráka 2015-06-09 14:08:43 UTC
Description of problem:
dnf.subject.Subject() returns packages with different epochs even if epoch is specified

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

How reproducible:

Steps to Reproduce:
1. have a repo with two packages of the same name and different epoch, e.g
   foo-0:1.0-1.fc22.noarch.rpm and foo-1:1.0-1.fc22.noarch.rpm
2. dnf list foo-0:1.0-1.fc22

Actual results:
# dnf list foo-0:1.0-1.fc22
Available Packages
foo.noarch               1.0-1.fc22      foo
foo.noarch               1:1.0-1.fc22    foo   

Expected results:
# dnf list foo-0:1.0-1.fc22
Available Packages
foo.noarch               1.0-1.fc22      foo

Additional info:
-> subj = dnf.subject.Subject('foo-0:1.0-1.fc22')
-> pkgs = subj.get_best_query(self.base.sack)
(Pdb) pkgs.run()
[<hawkey.Package object id 46019, foo-1.0-1.fc22.noarch, foo>, <hawkey.Package object id 46020, foo-1:1.0-1.fc22.noarch, foo>]

Comment 1 Jan Kurik 2015-07-15 14:02:34 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 23 development cycle.
Changing version to '23'.

(As we did not run this process for some time, it could affect also pre-Fedora 23 development
cycle bugs. We are very sorry. It will help us with cleanup during Fedora 23 End Of Life. Thank you.)

More information and reason for this action is here:

Comment 2 Honza Silhan 2015-07-24 12:13:55 UTC
IIRC we have the bug report not recognizing the package with epoch in install cmd (can't find the bug now). This is the cause.

Comment 3 Fedora Admin XMLRPC Client 2016-07-08 09:34:54 UTC
This package has changed ownership in the Fedora Package Database.  Reassigning to the new owner of this component.

Comment 4 Fedora End Of Life 2016-11-24 11:52:34 UTC
This message is a reminder that Fedora 23 is nearing its end of life.
Approximately 4 (four) weeks from now Fedora will stop maintaining
and issuing updates for Fedora 23. It is Fedora's policy to close all
bug reports from releases that are no longer maintained. At that time
this bug will be closed as EOL if it remains open with a Fedora  'version'
of '23'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora 23 is end of life. If you would still like 
to see this bug fixed and are able to reproduce it against a later version 
of Fedora, you are encouraged  change the 'version' to a later Fedora 
version prior this bug is closed as described in the policy above.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

Comment 5 Michael Mráka 2016-11-24 13:03:18 UTC
Jarda, has this bug been fixed with the latest Subject/Selector changes?

Comment 6 Jaroslav Mracek 2016-11-25 14:33:51 UTC
Michael sorry, but latest selectors changes did not solve the issue, but this PR YEEEES: https://github.com/rpm-software-management/dnf/pull/662

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