Description of problem: A "package-cleanup --problems" fails with following message: Setting up yum Reading local RPM database Processing all local requires Traceback (most recent call last): File "/usr/bin/package-cleanup", line 348, in ? main() File "/usr/bin/package-cleanup", line 345, in main provsomething = buildProviderList(my,pkgs,opts.problems) File "/usr/bin/package-cleanup", line 85, in buildProviderList resolve_sack = my.rpmdb.whatProvides(req,rflags,ver) File "/usr/lib/python2.4/site-packages/yum/rpmsack.py", line 361, in whatProvides pkgs = self.searchProvides(name) File "/usr/lib/python2.4/site-packages/yum/rpmsack.py", line 139, in searchProvides return self.searchPrco(name, 'provides') File "/usr/lib/python2.4/site-packages/yum/rpmsack.py", line 120, in searchPrco if not result.has_key(po.pkgid): TypeError: list objects are unhashable Reinstalling of yum and yum-utils didn't help. Version-Release number of selected component (if applicable): yum-utils-1.0-2.fc6
I have tested package-cleanup --problems with yum 3.0.3 & yum-utils-1.0.1 It like the issue don't exist anymore. Please retest.
Still the same problem: root@work:~# rpm -q yum yum-utils yum-3.0.3-1.fc6 yum-utils-1.0.1-1.fc6 root@work:~# package-cleanup --problems Setting up yum Reading local RPM database Processing all local requires Traceback (most recent call last): File "/usr/bin/package-cleanup", line 349, in ? main() File "/usr/bin/package-cleanup", line 346, in main provsomething = buildProviderList(my,pkgs,opts.problems) File "/usr/bin/package-cleanup", line 85, in buildProviderList resolve_sack = my.rpmdb.whatProvides(req,rflags,ver) File "/usr/lib/python2.4/site-packages/yum/rpmsack.py", line 390, in whatProvides pkgs = self.searchProvides(name) File "/usr/lib/python2.4/site-packages/yum/rpmsack.py", line 141, in searchProvides return self.searchPrco(name, 'provides') File "/usr/lib/python2.4/site-packages/yum/rpmsack.py", line 123, in searchPrco if not result.has_key(po.pkgid): TypeError: list objects are unhashable
Created attachment 146681 [details] package-cleanup with some debug output
I have add at package-cleanup.py with some debug output, to find out what package causing the the problem. run the following. python package-cleanup.py --problems and attach the output just before the TypeError
I did that as I had the same error. THis is the end of the output: req : python rflags : 8 ver : 2.4.4-1.fc6 req : python-popt rflags : 0 ver : None Traceback (most recent call last): [...] So it's a prehistoric package, namely python-popt-0.8.8-7.x.2 installed on April 11, 2002. After removing it, I had the same problem with metamail-2.7-28. It's interesting as metamail-2.7-29.7.x.legacy does not give the problem on another Fedora 6 box I administer. After upgrading (yes, I need it!) the problem stopped. The thing is package-cleanup --problems should not die on prehistoric packages. Or at est it should not die without any debugging output about who killed it.
Also tried the debug version: [...] ver : None req : libXext.so.6 rflags : 0 ver : None req : libXi.so.6 rflags : 0 ver : None req : libcnbpcmcm154.so rflags : 0 ver : None Traceback (most recent call last): File "./package-cleanup.py", line 405, in ? main() File "./package-cleanup.py", line 402, in main provsomething = buildProviderList(my,pkgs,opts.problems) File "./package-cleanup.py", line 88, in buildProviderList resolve_sack = my.rpmdb.whatProvides(req,rflags,ver) File "/usr/lib/python2.4/site-packages/yum/rpmsack.py", line 390, in whatProvides pkgs = self.searchProvides(name) File "/usr/lib/python2.4/site-packages/yum/rpmsack.py", line 141, in searchProvides return self.searchPrco(name, 'provides') File "/usr/lib/python2.4/site-packages/yum/rpmsack.py", line 123, in searchPrco if not result.has_key(po.pkgid): TypeError: list objects are unhashable libcnbpcmcm154.so is provided by bjfilterpixus550i-2.2-1. This is the only available official driver for my canon printer (and not included in fedora). After removing it, the normal version of package-cleanup works fine.
*** Bug 228671 has been marked as a duplicate of this bug. ***
*** Bug 240305 has been marked as a duplicate of this bug. ***
I also have the same problem, so I ran the python attachment: [root@presario /home/Shared]# python package-cleanup.py --problems Setting up yum Excluding Packages in global exclude list Finished Reading local RPM database Processing all local requires [...] req : rtld(GNU_HASH) rflags : 0 ver : None req : libX11.so.6 rflags : 0 ver : None Traceback (most recent call last): File "package-cleanup.py", line 405, in ? main() File "package-cleanup.py", line 402, in main provsomething = buildProviderList(my,pkgs,opts.problems) File "package-cleanup.py", line 88, in buildProviderList resolve_sack = my.rpmdb.whatProvides(req,rflags,ver) File "/usr/lib/python2.4/site-packages/yum/rpmsack.py", line 390, in whatProvides pkgs = self.searchProvides(name) File "/usr/lib/python2.4/site-packages/yum/rpmsack.py", line 141, in searchProvides return self.searchPrco(name, 'provides') File "/usr/lib/python2.4/site-packages/yum/rpmsack.py", line 123, in searchPrco if not result.has_key(po.pkgid): TypeError: list objects are unhashable [root@presario /home/Shared]# locate libX11.so.6 /usr/lib/libX11.so.6 /usr/lib/libX11.so.6.2.0 [...] [root@presario /home/Shared]# rpm -qf /usr/lib/libX11.so.6 libX11-1.0.3-7.fc6 [root@presario /home/Shared]# Since I'm fairly sure that I cannot safely remove libX11 without causing a major meltdown, there is no work-around or quick-fix here like the other guys did. I am wondering if this is a more serious problem with yum itself? uname -a: Linux 2.6.20-1.2952.fc6 #1 SMP Wed May 16 18:59:18 EDT 2007 i686 athlon i386 GNU/Linux
I am running into the problem on FC6, latest kernel-2.6.22.2-42.fc6, yum-utils-1.0.3-1.fc6. Heres my dump: [doctorwhite@localhost ~]$ sudo package-cleanup --problems Setting up yum Reading local RPM database Processing all local requires Traceback (most recent call last): File "/usr/bin/package-cleanup", line 402, in ? main() File "/usr/bin/package-cleanup", line 399, in main provsomething = buildProviderList(my,pkgs,opts.problems) File "/usr/bin/package-cleanup", line 85, in buildProviderList resolve_sack = my.rpmdb.whatProvides(req,rflags,ver) File "/usr/lib/python2.4/site-packages/yum/rpmsack.py", line 390, in whatProvides pkgs = self.searchProvides(name) File "/usr/lib/python2.4/site-packages/yum/rpmsack.py", line 141, in searchProvides return self.searchPrco(name, 'provides') File "/usr/lib/python2.4/site-packages/yum/rpmsack.py", line 123, in searchPrco if not result.has_key(po.pkgid): TypeError: list objects are unhashable
Same problem here: # rpm -q kernel;rpm -qa|grep yum kernel-2.6.20-1.2320.fc5.x86_64 kernel-2.6.22.9-91.fc7.x86_64 yum-metadata-parser-1.1.0-2.fc7.x86_64 yum-utils-1.1.7-1.fc7.noarch yum-kernel-module-1.1.7-1.fc7.noarch yum-3.2.5-1.fc7.noarch # rpm -qf /etc/fedora-release fedora-release-7-3.noarch # yum update fedora 100% |=========================| 2.1 kB 00:00 updates 100% |=========================| 2.3 kB 00:00 Setting up Update Process Resolving Dependencies --> Running transaction check Traceback (most recent call last): File "/usr/bin/yum", line 29, in <module> yummain.main(sys.argv[1:]) File "/usr/share/yum-cli/yummain.py", line 143, in main (result, resultmsgs) = base.buildTransaction() File "/usr/lib/python2.5/site-packages/yum/__init__.py", line 569, in buildTransaction (rescode, restring) = self.resolveDeps() File "/usr/lib/python2.5/site-packages/yum/depsolve.py", line 710, in resolveDeps CheckDeps, checkremoves, checkinstalls, missing = self._resolveRequires(errors) File "/usr/lib/python2.5/site-packages/yum/depsolve.py", line 787, in _resolveRequires thisneeds = self._checkRemove(txmbr) File "/usr/lib/python2.5/site-packages/yum/depsolve.py", line 865, in _checkRemove for pkg, hits in self.tsInfo.getRequires(*prov).iteritems(): File "/usr/lib/python2.5/site-packages/yum/transactioninfo.py", line 427, in getRequires result = self.getOldRequires(name, flag, version) File "/usr/lib/python2.5/site-packages/yum/transactioninfo.py", line 420, in getOldRequires for pkg, hits in self.rpmdb.getRequires(name, flag, version).iteritems(): File "/usr/lib/python2.5/site-packages/yum/rpmsack.py", line 425, in getRequires pkgs = self.searchRequires(name) File "/usr/lib/python2.5/site-packages/yum/rpmsack.py", line 149, in searchRequires return self.searchPrco(name, 'requires') File "/usr/lib/python2.5/site-packages/yum/rpmsack.py", line 128, in searchPrco if not result.has_key(po.pkgid): TypeError: list objects are unhashable
(In reply to comment #11) > Same problem here: > # rpm -q kernel;rpm -qa|grep yum > TypeError: list objects are unhashable I'm still seeing this as well. I found a workaround, see https://devel.linux.duke.edu/bugzilla/show_bug.cgi?id=726#c5
Fixed upstream http://devel.linux.duke.edu/gitweb/?p=yum.git;a=commitdiff;h=2ad0940a196ffb694c03b827fad3f6a7b6816108 will be available in yum 3.2.6
Ah ha. That explains the other 'solution' to the problem I discovered to day. Parse 'rpm -qa' for all package from my previous Fedora version, feed them one at a time into 'yum upgrade'. For each that explodes, 'rpm -e --nodeps;yum -y install' it. Glad to see the fix going in after all this time, and the link to the upstream change is just a one line change in the mean time :-)