[Yum] Recursing on repos

pirla the.pirla at gdit.it
Wed Feb 4 13:24:27 UTC 2009


Il giorno mar, 03/02/2009 alle 19.41 -0500, James Antill ha scritto:
> pirla <the.pirla at gdit.it> writes:
>  Here is how I'd probably do it:
> 
> import yum, os, sys
> yb = yum.YumBase()
> yb.repos.setCacheDir(yum.misc.getCacheDir())
> 
> for repo in yb.repos.enableRepo('*'):
>     for pkg in yb.pkgSack.returnPackages(repoid=repo):
>         print pkg.name, pkg.ver, pkg.rel, pkg.arch, pkg.repo
>     yb.pkgSack.dropCachedData()
> 
It also do not work.
The error is the same:
yum.Errors.RepoError: Cannot retrieve repository metadata (repomd.xml)
for repository: kwizart-rawhide-debuginfo. Please verify its path and
try again

I checked for repo definition on 

[kwizart-rawhide-debuginfo]
name=kwizart for Fedora Rawhide - $basearch - Debug
baseurl=http://rpms.kwizart.net/fedora/rawhide/$basearch/debug/
failovermethod=priority
enabled=0
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-kwizart

and the url is available, but empty.

It's not so easy to use python and also API.

Where can I find a **detailed** documentation on modules, classes and so
on, about yum?

-- 
Ciao
        Pirla

Per rispondere in E-mail the (punto) pirla (chiocciola) gdit.it
*** un bacio ai pupi ***

---> Linux user since yesterday <---
--->     Linux User #389536     <---
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: Questa =?ISO-8859-1?Q?=E8?= una parte del messaggio
	firmata digitalmente
Url : http://lists.baseurl.org/pipermail/yum/attachments/20090204/efac9c42/attachment.pgp 


More information about the Yum mailing list