Bug 1253517

Summary: Yum via python returning incorrect package lists
Product: Red Hat Enterprise Linux 6 Reporter: Andrew Colin Kissa <andrew>
Component: yumAssignee: Valentina Mukhamedzhanova <vmukhame>
Status: CLOSED INSUFFICIENT_DATA QA Contact: BaseOS QE Security Team <qe-baseos-security>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 6.7CC: andrew, james.antill, ksrot
Target Milestone: rc   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2015-12-03 14:28:44 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Andrew Colin Kissa 2015-08-13 22:56:35 UTC
Description of problem:

When called via a python script the new version of yum in 6.7
is returning incorrect pkgs.available some packages that are
in the repo are not returned as part of the list.


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

How reproducible:

from yum import YumBase
yumbase = YumBase()
yumbase.setCacheDir()
yumbase.doLock()
yumbase._getTs()
yumbase._getRpmDB()
yumbase._getRepos(doSetup=True)
yumbase._getSacks()
pkgs = yumbase.doPackageLists(patterns=[])
for pkg in sorted(pkgs.available):
    if pkg.name.startswith('openssh'):
        pkg.name


Steps to Reproduce:

Run the above python snippet in a python terminal.


Actual results:

'openssh-askpass'
'openssh-ldap'


Expected results:

'openssh'
'openssh-clients'
'openssh-server'
'openssh-askpass'
'openssh-ldap'


Additional info:

This will break any scripts that use the yum python modules
directly as the results being returned are incorrect.

Comment 2 Karel Srot 2015-10-12 13:26:26 UTC
Hello Andrew,
according to my testing the result is the same as for yum-3.2.29-60.el6.noarch from RHEL-6.6 and yum-3.2.29-40.el6.noarch from RHEL-6.5. Btw, it matches the output of the
  yum list available openssh\* 
command (there is a missing 'print' at the last line of the reproducer in #c0)

Could you please provide more evidence, e.g. yum version that was working the way you expected? Thank you.

Comment 3 Valentina Mukhamedzhanova 2015-12-03 14:28:44 UTC
We can't move forward on this report unless the requested information is provided, so I'm closing this.