Bug 661753 - repoquery --archlist=src does not work
repoquery --archlist=src does not work
Status: CLOSED WONTFIX
Product: Fedora
Classification: Fedora
Component: yum-utils (Show other bugs)
14
Unspecified Unspecified
low Severity medium
: ---
: ---
Assigned To: Seth Vidal
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2010-12-09 10:37 EST by Michal Hlavinka
Modified: 2014-01-21 18:17 EST (History)
4 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2012-08-16 16:38:08 EDT
Type: ---
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 Michal Hlavinka 2010-12-09 10:37:50 EST
Description of problem:
I was trying to find out what packages require uuid-devel, in man repoquery was example how to get that answer. I've used that command, but repoquery complained that it can't download metadata. I've checked fedora.repo configuration and used yum --enablerepo=fedora-source to verify that it works for yum.

Version-Release number of selected component (if applicable):
yum-utils-1.1.28-1.fc14.noarch

How reproducible:
always

Steps to Reproduce:
1.repoquery --archlist=src --whatrequires  uuid-devel
2.
3.
  
Actual results:
# repoquery --archlist=src --whatrequires  uuid-devel 
Could not parse metalink https://mirrors.fedoraproject.org/metalink?repo=fedora-14&arch=src error was 
No repomd file
Traceback (most recent call last):
  File "/usr/bin/repoquery", line 1187, in <module>
    main(sys.argv)
  File "/usr/bin/repoquery", line 1181, in main
    repoq.runQuery(regexs)
  File "/usr/bin/repoquery", line 763, in runQuery
    pkgs = self.matchPkgs(items, plain_pkgs=plain_pkgs)
  File "/usr/bin/repoquery", line 739, in matchPkgs
    pkgs = self.returnPkgList(patterns=items)
  File "/usr/bin/repoquery", line 692, in returnPkgList
    pkgs = self.pkgSack.returnNewestByNameArch(**kwargs)
  File "/usr/lib/python2.7/site-packages/yum/__init__.py", line 827, in <lambda>
    pkgSack = property(fget=lambda self: self._getSacks(),
  File "/usr/lib/python2.7/site-packages/yum/__init__.py", line 617, in _getSacks
    self.repos.populateSack(which=repos)
  File "/usr/lib/python2.7/site-packages/yum/repos.py", line 283, in populateSack
    sack.populate(repo, mdtype, callback, cacheonly)
  File "/usr/lib/python2.7/site-packages/yum/yumRepo.py", line 163, in populate
    if self._check_db_version(repo, mydbtype):
  File "/usr/lib/python2.7/site-packages/yum/yumRepo.py", line 221, in _check_db_version
    return repo._check_db_version(mdtype)
  File "/usr/lib/python2.7/site-packages/yum/yumRepo.py", line 1224, in _check_db_version
    repoXML = self.repoXML
  File "/usr/lib/python2.7/site-packages/yum/yumRepo.py", line 1413, in <lambda>
    repoXML = property(fget=lambda self: self._getRepoXML(),
  File "/usr/lib/python2.7/site-packages/yum/yumRepo.py", line 1409, in _getRepoXML
    raise Errors.RepoError, msg
yum.Errors.RepoError: Cannot retrieve repository metadata (repomd.xml) for repository: fedora. Please verify its path and try again

Expected results:
list of packages buildrequiring uuid-devel

Additional info:
Comment 1 James Antill 2010-12-10 10:01:50 EST
There are two bugs in that repquery:

1. It assumes you have the source repos. enabled (almost nobody does).

2. We now change the basearch to the first member of the archlist, so that "--archlist ppc" works on x86_64 (fixed upstream).
Comment 2 Michal Hlavinka 2010-12-16 09:33:14 EST
(In reply to comment #1)
> There are two bugs in that repquery:

do you mean that just the query itself is wrong? I think it should not produce any traceback even if the query is wrong, right? Also if the query is wrong, man page should be updated.

> 1. It assumes you have the source repos. enabled (almost nobody does).

I've tried:
repoquery --enablerepo='*source' --archlist=src --whatrequires  uuid-devel

but the result is still the same.

> 
> 2. We now change the basearch to the first member of the archlist, so that
> "--archlist ppc" works on x86_64 (fixed upstream).

I don't understand what you mean
Comment 3 James Antill 2010-12-16 10:28:00 EST
> > 2. We now change the basearch to the first member of the archlist, so that
> > "--archlist ppc" works on x86_64 (fixed upstream).
>
> I don't understand what you mean

 So if you want to do a query for ppc on x86_64, it was impossible because even though you said --archlist=ppc ... the $basearch for yum was still x86_64, so when you got the mirrorlist/etc. it wasn't the ppc one.
 We fixed that so that we took the first arch of --archlist and made it basearch, thus. the above worked. But we forgot about --archlist=src, and there is no $basearch=src repo. ... so you get the failure you have. I've fixed it upstream so that this will work now:

 repoquery --archlist=src --whatrequires  uuid-devel --enablerepo=fedora-source

...until then you should be able to use:

 repoquery --archlist=x86_64,src --whatrequires  uuid-devel --disablerepo='*' --enablerepo=fedora-source
Comment 4 Fedora End Of Life 2012-08-16 16:38:11 EDT
This message is a notice that Fedora 14 is now at end of life. Fedora 
has stopped maintaining and issuing updates for Fedora 14. It is 
Fedora's policy to close all bug reports from releases that are no 
longer maintained.  At this time, all open bugs with a Fedora 'version'
of '14' have been closed as WONTFIX.

(Please note: Our normal process is to give advanced warning of this 
occurring, but we forgot to do that. A thousand apologies.)

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

Bug Reporter: Thank you for reporting this issue and we are sorry that 
we were unable to fix it before Fedora 14 reached 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 to click on 
"Clone This Bug" (top right of this page) and open it against that 
version of Fedora.

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.

The process we are following is described here: 
http://fedoraproject.org/wiki/BugZappers/HouseKeeping

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