Bug 465898 - TypeError: 'NoneType' object is unsubscriptable error in sqlitesack.py:94:_read_db_obj (pkgId can't be found)
Summary: TypeError: 'NoneType' object is unsubscriptable error in sqlitesack.py:94:_re...
Keywords:
Status: CLOSED NEXTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: yum
Version: 8
Hardware: i386
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Seth Vidal
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
: 466917 471212 473503 476638 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2008-10-07 01:12 UTC by John
Modified: 2014-01-21 23:06 UTC (History)
10 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2008-11-07 02:57:35 UTC


Attachments (Terms of Use)
'crash dump' automatically saved, as per the dialog box appearing upon failure (2.61 KB, text/plain)
2008-10-07 01:12 UTC, John
no flags Details

Description John 2008-10-07 01:12:55 UTC
Created attachment 319605 [details]
'crash dump' automatically saved, as per the dialog box appearing upon failure

Description of problem:  .


Version-Release number of selected component (if applicable):


How reproducible:  Completely


Steps to Reproduce:
1. When 'automatic' update notice appears, enter the root password and wait.
2.
3.
  
Actual results:
When 'Resolving dependencies for updates' completes (but before the 'Resolving...' status box disappears), an alert is presented with the following text:

'An unhandled exception has occurred.  This is most likely a bug.  Please save the crash dump and file a detailed bug report against pirut at https://bugzilla.redhat.com/bugzilla'

Save the file by clicking the appropriate dialog button.

See attached file (saved per the instructions)


Expected results: 'Resolving dependencies for updates' disappears, and is followed by 'Installing updates'


Additional info:

Comment 1 John 2008-10-07 01:46:08 UTC
On further observation, this bug only occurs on the 'kernel' update (of a list of updates which were offered at the same time).  The detailed description of the 'kernel' update is as follows:

       Title  kernel-2.6.26.5-28.fc8
          ID  FEDORA-2008-8312
        Type  bugfix
      Status  stable
      Issued  2008-10-01 06:01:13
 Description  Update kernel from version 2.6.26.3 to 2.6.26.5:
              http://www.kernel.org/pub/linux/kernel/v2.6/ChangeLog-2.6.26.4
              http://www.kernel.org/pub/linux/kernel/v2.6/ChangeLog-2.6.26.5
              
              Plus additional patches scheduled for inclusion in 2.6.26.6.
              
              Bugs fixed (all reported against Fedora 9):
              
              453023 - e1000/e1000e driver doesn't work with gigabit connection
              459103 - kexec/kdump panics on HP Proliant
              462375 - 2.6.26.3-29.fc9.i686: stacktrace on usb disk plug in
              453257 - Seemingly non-working process is messing with process scheduler.
              461438 - Intel Corporation 82567LM Gigabit Network device not working
              455833 - Marvell 88SE6121 PATA not recognized correctly
              462210 - Macbook Pro stuck on kernel load
              
              
This update will require a reboot.

Comment 2 James Antill 2008-10-07 02:03:11 UTC
 The kernel update isn't the problem, I don't think.

 Can you run:

yum --version
yum repolist

ls -l /var/cache/yum/*

...and then I think you'll fix your problem if you do "yum clean expire-cache", then run pirut or "yum update" again.
 If that doesn't work try: "yum clean all", and then run your normal commands.

Comment 3 James Antill 2008-10-07 02:03:47 UTC
If it wasn't obvious, can you run the first 3 commands, and put the output in this bugzilla?

Comment 4 John 2008-10-07 10:43:10 UTC
<quote>If it wasn't obvious, can you run the first 3 commands, and put the output in this bugzilla?</quote>

The output is:




[root@DHS-NISTnet-JSD jdetwile]# yum --version
3.2.19
  Installed: rpm-4.4.2.2-7.fc8.i386 at 2007-12-02 03:07
  Built    : Fedora Project at 2007-11-12 07:25
  Committed: Panu Matilainen <pmatilai@redhat.com> at 2007-10-24 22:00

  Installed: yum-metadata-parser-1.1.2-1.fc8.i386 at 2007-11-29 02:57
  Built    : Fedora Project at 2007-08-24 14:14
  Committed: Seth Vidal <skvidal at fedoraproject.org> at 2007-08-24 22:00

  Installed: yum-3.2.19-3.fc8.noarch at 2008-09-11 12:32
  Built    : Fedora Project at 2008-09-03 15:19
  Committed: Seth Vidal <skvidal at fedoraproject.org> at 2008-09-03 22:00
[root@DHS-NISTnet-JSD jdetwile]# 
[root@DHS-NISTnet-JSD jdetwile]# 
[root@DHS-NISTnet-JSD jdetwile]# 
[root@DHS-NISTnet-JSD jdetwile]# yum repolist
repo id              repo name                                status  
adobe-linux-i386     Adobe Systems Incorporated               enabled :      17
atrpms               Fedora 8 - i386 - ATrpms                 enabled :     699
fedora               Fedora 8 - i386                          enabled :   8,439
fedora-source        Fedora 8 - Source                        enabled :   4,834
freshrpms            Fedora Core 8 - i386 - Freshrpms         enabled :     156
updates              Fedora 8 - i386 - Updates                enabled :       1
updates-newkey       Fedora 8 - i386 - Updates Newkey         enabled :   5,297
updates-source       Fedora 8 - Updates Source                enabled :       1
repolist: 19,444
[root@DHS-NISTnet-JSD jdetwile]# 
[root@DHS-NISTnet-JSD jdetwile]# 
[root@DHS-NISTnet-JSD jdetwile]# ls -l /var/cache/yum
total 40
drwxr-xr-x 3 root root 4096 2008-10-07 06:38 adobe-linux-i386
drwxr-xr-x 3 root root 4096 2008-10-07 06:38 atrpms
drwxr-xr-x 3 root root 4096 2008-10-07 06:38 fedora
drwxr-xr-x 3 root root 4096 2008-10-07 06:38 fedora-source
drwxr-xr-x 3 root root 4096 2008-10-07 06:38 freshrpms
drwxr-xr-x 3 root root 4096 2007-12-01 19:05 InstallMedia
drwxr-xr-x 3 root root 4096 2008-10-07 06:38 updates
drwxr-xr-x 3 root root 4096 2008-10-07 06:38 updates-newkey
drwxr-xr-x 3 root root 4096 2008-10-07 06:38 updates-source
drwxr-xr-x 3 root root 4096 2008-09-12 17:39 updates-testing
[root@DHS-NISTnet-JSD jdetwile]#

Comment 5 James Antill 2008-10-07 16:20:34 UTC
 Ok, everytime I've seen this bug now it's someone using an atrpms repo.
 It's possible they are doing something weird with multiple packages with the same pkgId, combined with their desire to ship only .xml metadata might produce these kinds of errors.

 I'd recommend just disabling that repo.

Comment 6 salmon.thierry 2008-10-14 14:25:38 UTC
maybe that can help,
I had same kind of message doing command line yum upgrade F8 -> F9

Traceback (most recent call last):
  File "/usr/bin/yum", line 29, in <module>
    yummain.user_main(sys.argv[1:], exit_code=True)
  File "/usr/share/yum-cli/yummain.py", line 229, in user_main
    errcode = main(args)
  File "/usr/share/yum-cli/yummain.py", line 145, in main
    (result, resultmsgs) = base.buildTransaction() 
  File "/usr/lib/python2.5/site-packages/yum/__init__.py", line 641, in buildTransaction
    (rescode, restring) = self.resolveDeps()
  File "/usr/lib/python2.5/site-packages/yum/depsolve.py", line 696, in resolveDeps
    for po, dep in self._checkFileRequires():
  File "/usr/lib/python2.5/site-packages/yum/depsolve.py", line 931, in _checkFileRequires
    if not self.tsInfo.getOldProvides(filename) and not self.tsInfo.getNewProvides(filename):
  File "/usr/lib/python2.5/site-packages/yum/transactioninfo.py", line 414, in getNewProvides
    for pkg, hits in self.pkgSack.getProvides(name, flag, version).iteritems():
  File "/usr/lib/python2.5/site-packages/yum/packageSack.py", line 300, in getProvides
    return self._computeAggregateDictResult("getProvides", name, flags, version)
  File "/usr/lib/python2.5/site-packages/yum/packageSack.py", line 470, in _computeAggregateDictResult
    sackResult = apply(method, args)
  File "/usr/lib/python2.5/site-packages/yum/sqlitesack.py", line 857, in getProvides
    return self._search("provides", name, flags, version)
  File "/usr/lib/python2.5/site-packages/yum/sqlitesack.py", line 43, in newFunc
    return func(*args, **kwargs)
  File "/usr/lib/python2.5/site-packages/yum/sqlitesack.py", line 833, in _search
    for pkg in self.searchFiles(name, strict=True):
  File "/usr/lib/python2.5/site-packages/yum/sqlitesack.py", line 43, in newFunc
    return func(*args, **kwargs)
  File "/usr/lib/python2.5/site-packages/yum/sqlitesack.py", line 584, in searchFiles
    self._sql_pkgKey2po(rep, cur, pkgs)
  File "/usr/lib/python2.5/site-packages/yum/sqlitesack.py", line 468, in _sql_pkgKey2po
    pkg = self._packageByKey(repo, ob['pkgKey'])
  File "/usr/lib/python2.5/site-packages/yum/sqlitesack.py", line 411, in _packageByKey
    po = self.pc(repo, cur.fetchone())
  File "/usr/lib/python2.5/site-packages/yum/sqlitesack.py", line 68, in __init__
    self._read_db_obj(db_obj)
  File "/usr/lib/python2.5/site-packages/yum/sqlitesack.py", line 94, in _read_db_obj
    setattr(self, item, _share_data(db_obj[item]))
TypeError: 'NoneType' object is unsubscriptable


disabling repo updates and keeping only repo update-newkey seen to solve the problem, the upgrade is busy

Comment 7 James Antill 2008-10-14 14:41:06 UTC
*** Bug 466917 has been marked as a duplicate of this bug. ***

Comment 8 James Antill 2008-10-14 14:42:32 UTC
 salmon.thierry and Rex Abert ... do you both have the atrpms repo. installed? If not can you paste the output from "yum repolist"?

Comment 9 salmon.thierry 2008-10-14 15:05:35 UTC
no atrpms repo for me.

this config gives me the problem when I did upgrade

+ yum --exclude=openoffice.org-base --exclude=openoffice.org-calc --exclude=openoffice.org-draw --exclude=openoffice.org-emailmerge --exclude=openoffice.org-graphicfilter --exclude=openoffice.org-impress --exclude=openoffice.org-javafilter --exclude=openoffice.org-math --exclude=openoffice.org-pyuno --exclude=openoffice.org-writer --exclude=openoffice.org-xsltfilter --exclude=openoffice.org-core --exclude=openoffice.org-headless --exclude libX11 --exclude libX11-devel --disablerepo fedora --enablerepo fedoralocal --disablerepo updates --enablerepo updateslocal --disablerepo fedoraEverything --enablerepo fedoraEverythinglocal --disablerepo updates-newkey --enablerepo updateslocal-newkey repolist
repo id              repo name                                status
fedoraEverythingloca Fedora 9 - i386                          enabled :   9,897
fedoralocal          Fedora Core 9 - i386                     enabled :   2,071
updateslocal         Fedora Core 9 - i386 - Updates           enabled :       1
updateslocal-newkey  Fedora Core 9 - i386 - Updates Newkey    enabled :   4,344
repolist: 16,313

this config gives me no problem when I did upgrade (upgrade still busy)

+ yum --exclude=openoffice.org-base --exclude=openoffice.org-calc --exclude=openoffice.org-draw --exclude=openoffice.org-emailmerge --exclude=openoffice.org-graphicfilter --exclude=openoffice.org-impress --exclude=openoffice.org-javafilter --exclude=openoffice.org-math --exclude=openoffice.org-pyuno --exclude=openoffice.org-writer --exclude=openoffice.org-xsltfilter --exclude=openoffice.org-core --exclude=openoffice.org-headless --exclude extragear-plasma --disablerepo fedoraEverything --enablerepo fedoraEverythinglocal --disablerepo updates-newkey --enablerepo updateslocal-newkey --enablerepo livnalocal repolist
repo id              repo name                                status
fedoraEverythingloca Fedora 9 - i386                          enabled :   9,897
livnalocal           Livna for Fedora Core 9 - i386 - Base    enabled :     909
updateslocal-newkey  Fedora Core 9 - i386 - Updates Newkey    enabled :   4,344
repolist: 15,150

*local repo are only local copy of internet repo for personal reason.

Comment 10 James Antill 2008-10-14 15:57:04 UTC
 So AIUI, removing these two repos. solves the problem:

fedoralocal          Fedora Core 9 - i386                     enabled :   2,071
updateslocal         Fedora Core 9 - i386 - Updates           enabled :       1

...can you tar up the files in /var/cache/yum/fedoralocal and /var/cache/yum/updateslocal (don't need the packages directories etc., just the files).

 If not can you show what ls -l is in both directories?

Comment 11 salmon.thierry 2008-10-14 16:23:14 UTC
Sinds last post, I restart my upgrade process because some missing dependencies,
with the new run I added fedoralocal.  Transaction test step is now succeeded, it's busy in Running Transaction stop. 
So removing only repo updateslocal solves the problem for me.

updateslocal         Fedora Core 9 - i386 - Updates           enabled :       1

now ls output

ls -l fedoralocal/ updateslocal
fedoralocal/:
total 33892
-rw-r--r-- 1 root root        0 2008-10-14 17:17 cachecookie
-rw-r--r-- 1 root root  1111171 2007-05-27 16:00 comps-f7.xml
-rw-r--r-- 1 root root 11815936 2008-10-14 14:32 filelists.sqlite
-rw-r--r-- 1 root root  1946449 2007-05-27 16:36 filelists.xml.gz
-rw-r--r-- 1 root root  9593856 2007-06-23 20:52 filelists.xml.gz.sqlite
drwxr-xr-x 2 root root    32768 2007-06-23 20:55 headers
drwxr-xr-x 2 root root    32768 2007-06-30 18:24 packages
-rw-r--r-- 1 root root  5867520 2008-10-14 14:18 primary.sqlite
-rw-r--r-- 1 root root   631597 2007-05-27 16:36 primary.xml.gz
-rw-r--r-- 1 root root  3589120 2007-06-23 20:39 primary.xml.gz.sqlite
-rw-r--r-- 1 root root     2442 2008-05-08 03:42 repomd.xml

updateslocal:
total 46636
-rw-r--r-- 1 root root        0 2008-10-14 14:53 cachecookie
-rw-r--r-- 1 root root  1215803 2008-01-07 07:45 comps-f8.xml
-rw-r--r-- 1 root root 32998400 2008-07-10 18:23 filelists.sqlite
-rw-r--r-- 1 root root  1227691 2007-06-20 21:45 filelists.xml.gz
-rw-r--r-- 1 root root  6631424 2007-06-23 20:52 filelists.xml.gz.sqlite
drwxr-xr-x 2 root root     8192 2007-06-23 20:55 headers
drwxr-xr-x 2 root root    98304 2008-09-30 21:50 packages
-rw-r--r-- 1 root root    20480 2008-09-30 21:47 primary.sqlite
-rw-r--r-- 1 root root   337187 2007-06-20 21:45 primary.xml.gz
-rw-r--r-- 1 root root  5128192 2007-06-23 20:39 primary.xml.gz.sqlite
-rw-r--r-- 1 root root     2659 2008-09-10 18:55 repomd.xml

I have tgz too, but I'm newbie in bugzilla, where can I upload it ?

Comment 12 James Antill 2008-10-14 17:04:00 UTC
 Ok, when you do createrepo on your local repos. ... pass the -d option, and I'm 99% sure your problems will go away.

Comment 13 Rex Abert 2008-10-14 18:11:14 UTC
(In reply to comment #8)
>  salmon.thierry and Rex Abert ... do you both have the atrpms repo. installed?
> If not can you paste the output from "yum repolist"?

[root@localhost ~]# yum repolist

livna                                                    | 2.1 kB     00:00     
fedora                                                   | 2.1 kB     00:00     
adobe-linux-i386                                         |  951 B     00:00     
updates-newkey                                           | 2.3 kB     00:00     
updates                                                  | 2.6 kB     00:00     
repo id              repo name                                status  
adobe-linux-i386     Adobe Systems Incorporated               enabled :      17
fedora               Fedora 8 - i386                          enabled :   8,439
livna                Livna for Fedora Core 8 - i386 - Base    enabled :   2,084
updates              Fedora 8 - i386 - Updates                enabled :       1
updates-newkey       Fedora 8 - i386 - Updates Newkey         enabled :   5,322
repolist: 15,863
[root@localhost ~]#

Comment 14 Rex Abert 2008-10-15 11:32:53 UTC
[root@localhost ~]# ls -l /var/cache/yum/*
/var/cache/yum/adobe-linux-i386:
total 1084
-rw-r--r-- 1 root root      0 2008-10-15 07:20 cachecookie
-rw-r--r-- 1 root root 798720 2008-08-15 11:16 filelists.xml.gz.sqlite
drwxr-xr-x 2 root root   4096 2008-10-15 07:25 packages
-rw-r--r-- 1 root root  10514 2008-10-14 19:57 primary.xml.gz
-rw-r--r-- 1 root root 282624 2008-10-14 21:20 primary.xml.gz.sqlite
-rw-r--r-- 1 root root    972 2008-10-14 19:57 repomd.xml

/var/cache/yum/fedora:
total 67220
-rw-r--r-- 1 root root        0 2008-10-15 07:20 cachecookie
-rw-r--r-- 1 root root  1206417 2007-11-02 10:10 Fedora-8-comps.xml
-rw-rw-r-- 1 root root 45641728 2008-08-11 15:16 filelists.sqlite
-rw-r--r-- 1 root root     2941 2008-10-14 20:20 mirrorlist.txt
drwxr-xr-x 2 root root     4096 2008-09-29 11:17 packages
-rw-r--r-- 1 root root 21885952 2008-08-11 15:09 primary.sqlite
-rw-r--r-- 1 root root     2151 2007-11-02 10:10 repomd.xml

/var/cache/yum/livna:
total 5336
-rw-r--r-- 1 root root       0 2008-10-15 07:20 cachecookie
-rw-r--r-- 1 root root   12207 2008-08-06 01:55 comps.xml
-rw-rw-r-- 1 root root 1928192 2008-08-11 15:31 filelists.sqlite
drwxr-xr-x 2 root root    4096 2008-09-16 11:08 packages
-rw-r--r-- 1 root root 3506176 2008-10-03 09:22 primary.sqlite
-rw-r--r-- 1 root root    2142 2008-10-03 08:21 repomd.xml

/var/cache/yum/updates:
total 35256
-rw-r--r-- 1 root root        0 2008-10-15 07:21 cachecookie
-rw-r--r-- 1 root root  1322338 2008-09-08 19:28 comps-f8.xml
-rw-rw-r-- 1 root root 34663424 2008-08-12 15:26 filelists.sqlite
-rw-r--r-- 1 root root     2034 2008-10-14 18:21 mirrorlist.txt
drwxr-xr-x 2 root root    36864 2008-09-16 10:31 packages
-rw-r--r-- 1 root root    20480 2008-09-10 20:26 primary.sqlite
-rw-r--r-- 1 root root     2659 2008-09-10 10:55 repomd.xml
-rw-r--r-- 1 root root      704 2008-09-10 10:55 updateinfo.xml.gz

/var/cache/yum/updates-newkey:
total 51236
-rw-r--r-- 1 root root        0 2008-10-15 07:20 cachecookie
-rw-r--r-- 1 root root  1342354 2008-10-06 23:46 comps-f8.xml
-rw-r--r-- 1 root root 35982336 2008-10-14 10:14 filelists.sqlite
-rw-r--r-- 1 root root     2187 2008-10-14 19:20 mirrorlist.txt
drwxr-xr-x 2 root root     4096 2008-10-10 07:23 packages
-rw-r--r-- 1 root root 14439424 2008-10-09 22:21 primary.sqlite
-rw-r--r-- 1 root root     2390 2008-10-09 16:51 repomd.xml
-rw-r--r-- 1 root root   610691 2008-10-10 04:21 updateinfo.xml.gz
[root@localhost ~]#

Comment 15 Fedora Update System 2008-10-15 17:51:22 UTC
yum-metadata-parser-1.1.2-9.fc9 has been submitted as an update for Fedora 9.
http://admin.fedoraproject.org/updates/yum-metadata-parser-1.1.2-9.fc9

Comment 16 Fedora Update System 2008-11-07 02:57:31 UTC
yum-metadata-parser-1.1.2-9.fc9 has been pushed to the Fedora 9 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 17 James Antill 2008-12-01 17:17:51 UTC
*** Bug 471212 has been marked as a duplicate of this bug. ***

Comment 18 James Antill 2008-12-01 17:17:56 UTC
*** Bug 473503 has been marked as a duplicate of this bug. ***

Comment 19 seth vidal 2008-12-16 15:09:14 UTC
*** Bug 476638 has been marked as a duplicate of this bug. ***


Note You need to log in before you can comment on or make changes to this bug.