[Yum-devel] Re: [Yum] repoquery --whatprovides /usr/lib/python2.4 in rawhide

Panu Matilainen pmatilai at laiskiainen.org
Thu Nov 9 12:20:04 UTC 2006


[ yum-users trimmed from replies ]

On Wed, 8 Nov 2006, seth vidal wrote:

> On Wed, 2006-11-08 at 21:55 +0200, Panu Matilainen wrote:
>> On Tue, 2006-11-07 at 16:11 -0800, David Lutterkort wrote:
>>> When I run
>>>         repoquery --whatprovides /usr/lib/python2.4
>>>
>>> against Fedora rawhide, I get
>>>
>>>         kdebindings-0:3.5.5-0.1.fc6.i386
>>>         mailman-3:2.1.9-2.i386
>>>         python-0:2.4.4-1.fc7.i386
>>>
>>> I understand python (expected) and kdebindings (packaging mistake), but
>>> can't find any reason why mailman would provide /usr/lib/python2.4. The
>>> closest I have found is that it owns
>>> '/usr/lib/mailman/pythonlib/lib/python2.4' .. is this a bug in
>>> repoquery ?
>>
>> It's a bug alright, but actually in yum (3.0) itself, repoquery simply
>> calls yum methods here. sqlitesack.searchPrco() uses SQL "LIKE" in the
>> search instead of exact matching (unless the name contains % characters)
>> which seems to be the problem here.
>>
>> To verify, the one-liner below disables using LIKE under any
>> circumstances and then only python and kdebindings (which has a
>> packaging bug) are left. Makes me wonder why is yum doing non-exact
>> matching in file provides? Doesn't seem like a very good idea to me :)
>
> b/c of wildcards, I think. for people doing searches like /usr/bi*/foo
>
> b/c of the way the fileslists tables are made we have to assemble the
> files list then check it against the string. I'm betting that's what it
> is.

Wildcard matching when *asked for* is fine, but that wasn't the case here. 
What package provides '/usr/lib/python2.4' was being asked for, and 
/usr/lib/mailman/pythonlib/lib/python2.4 is NOT a valid match :)

Try 'yum whatprovides /usr/lib/python2.4' for some strange results - 
any package putting stuff under that path is considered a match, plus gems 
like the mailman match. AFAICT depsolving is done using the same matching 
routine which could (well, should) give some truly weird results for 
depsolving, but that doesn't seem to happen for whatever reason (even 
being lucky :)

The whole provides searching appears to have quite a bit of duplicated 
or at least overlapping functionality, eg just grep for 'sendmail' in yum 
sources.

 	- Panu -




More information about the Yum-devel mailing list