[Yum-devel] [PATCH] Try comparing provides versions, if they all match. BZ 782345.

Zdenek Pavlas zpavlas at redhat.com
Fri Jan 20 14:14:06 UTC 2012


> > I meant that searchProvides() knows the provide name used to find
> > the packages, and if all packages found have a nice version on that
> > provide, it could a) prune the list b) sort the list c) assign
> > some initial score (well, that's an api breakage, probably).
> 
> 1. You can't then use that for other compare_provider() callers,
> without copy&paste or having compare_providers2().

I don't really grasp compare_providers(), there's deep magic :)
Also didn't run that particular test case, so don't know if the
two available packages had exactly the same score, but I assume
they did.

Then sorting the list returned by searchProvides() on the provide 
version and using the position to resolve ties in compare_providers()
could fix this BZ, without breaking any callers.


More information about the Yum-devel mailing list