Running repoquery on /usr, /var and other directories fails: $ sudo repoquery --whatprovides /usr Loading "installonlyn" plugin Importing additional filelist information $ $ repoquery --whatprovides /bin /var /usr /home /opt /tmp Loading "installonlyn" plugin Importing additional filelist information $ But: $ sudo repoquery --whatprovides /var/run Loading "installonlyn" plugin Importing additional filelist information filesystem-0:2.4.6-1.fc7.i386 $ Expected results: All directories are provided by the "filesystem" package. $ sudo repoquery --whatprovides /var Loading "installonlyn" plugin Importing additional filelist information filesystem-0:2.4.6-1.fc7.i386
Created attachment 161723 [details] Workaround patch This is arguably a bug in yum as repoquery just calls yum methods to look things up. Curiously enough it seems that while returnPackagesByDep() fails to find the / level directories, searchPackageProvides() does find them. Attached patch does that (plus renames a method to avoid naming conflict and recursion to death), seems to fix the issue for me, but it might not be a bad idea to figure why are those two things behaving differently here.
Thanks Pamu, It works for me to, so i have added the patch to upstream.
Yes, this is a bug in yum. It's also been fixed - it had to do with the filesystem package getting one too many '/'s added to its filelist. it's fixed in git.
I remember seeing you mention it's fixed in git but it doesn't look that way (../yum is up-to-date git repo, yum-utils likewise but with the above workaround patch reverted): [pmatilai@turre yum-utils]$ PYTHONPATH=../yum ./repoquery.py --whatprovides /var [pmatilai@turre yum-utils]$
okay then maybe this isn't the same bug. The one I was dealing with was: repoquery -l filesystem didn't list /var it does now, though. So maybe these are not related, though they sure seem like it.
yum-utils-1.1.7-1.fc7 has been pushed to the Fedora 7 testing repository. If problems still persist, please make note of it in this bug report.
yum-utils-1.1.7-1.fc7 has been pushed to the Fedora 7 stable repository. If problems still persist, please make note of it in this bug report.