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

James Antill james at fedoraproject.org
Wed Jan 18 15:30:13 UTC 2012


On Wed, 2012-01-18 at 03:31 -0500, Zdenek Pavlas wrote:
> > pkgA: Provides: foo-ABI = 1234
> > pkgB: Provides: foo-ABI = abcd
> 
> A simple 'ver starts with a digit' check in _pkg2prov_version()
> should probably handle most of such cases.

 That will handle some cases, but not all ... and what code path it
takes will be somewhat random (depending on if the first char of the
hash is a number or a-f), which is never a good thing.
 One workaround might be to say if "release is None" then don't use the
version comparison, except of course the BZ that started this used just
a version:

rubygem(activesupport) = 3.0.10
rubygem-activesupport = 1:3.0.10-1.fc17

...*sigh*.
 Of course there is now only a single package providing
rubygem(activesupport) in rawhide anyway (yeh! for BZs against package
problems that only exist for a single day).

> > 1. Do we want to do it after requirements checks, or maybe before
> > where we do it now?
> > 2. Spew all over the API. Is it worth it?
> > 3. Do we want to pass the req. down into the plugin callback?
> 
> I'd rather keep bestPackageFromList() as-is, and patch 
> the return path of searchProvides() (unless there's a catch).

 You mean doing a second "compare_providers" after compare_providers?
Seem like a bad idea, and means we can't make depsolving requires use
the same logic (without copy and pasting it, or creating a
compare_providers2 or something ... urk).



More information about the Yum-devel mailing list