Bug 593654 - mock/yum: IndexError: list index out of range
mock/yum: IndexError: list index out of range
Status: CLOSED ERRATA
Product: Fedora
Classification: Fedora
Component: mock (Show other bugs)
13
All Linux
low Severity high
: ---
: ---
Assigned To: Clark Williams
Fedora Extras Quality Assurance
: Reopened
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2010-05-19 08:21 EDT by Ralf Corsepius
Modified: 2014-01-21 01:18 EST (History)
5 users (show)

See Also:
Fixed In Version: mock-1.1.10-1.el6
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2010-08-12 15:46:49 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:


Attachments (Terms of Use)

  None (edit)
Description Ralf Corsepius 2010-05-19 08:21:42 EDT
Description of problem:

Building any arbitrary package fails in mock on FC13, with this error message:

# mock -r fedora-13-i386 Coin3-3.1.2-0.fc13.src.rpm
INFO: mock.py version 1.1.0 starting...
State Changed: init plugins
State Changed: start
INFO: Start(Coin3-3.1.2-0.fc13.src.rpm)  Config(fedora-13-i386)
State Changed: lock buildroot
State Changed: clean
State Changed: init
State Changed: lock buildroot
Mock Version: 1.1.0
INFO: Mock Version: 1.1.0
INFO: enabled root cache
State Changed: unpacking root cache
INFO: enabled yum cache
State Changed: cleaning yum metadata
INFO: enabled ccache
State Changed: running yum
State Changed: setup
ERROR: Exception(Coin3-3.1.2-0.fc13.src.rpm) Config(fedora-13-i386) 0 minutes 29 seconds
INFO: Results and/or logs in: /var/lib/mock/fedora-13-i386/result
ERROR: Command failed: 
 # /usr/bin/yum --installroot /var/lib/mock/fedora-13-i386/root/  install  ccache  'zlib-devel' 'doxygen' 'bzip2-devel' 'libXext-devel' 'freetype-devel' 'fontconfig-devel' '/usr/bin/rename' 'libGLU-devel'
...
Total size: 54 M
Installed size: 181 M
Warning: RPMDB altered outside of yum.
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 254, in user_main
    errcode = main(args)
  File "/usr/share/yum-cli/yummain.py", line 192, in main
    return_code = base.doTransaction()
  File "/usr/share/yum-cli/cli.py", line 496, in doTransaction
    resultobject = self.runTransaction(cb=cb)
  File "/usr/lib/python2.6/site-packages/yum/__init__.py", line 1182, in runTransaction
    self.rpmdb.transactionResultVersion(self.tsInfo.futureRpmDBVersion())
  File "/usr/lib/python2.6/site-packages/yum/transactioninfo.py", line 580, in futureRpmDBVersion
    self.rpmdb.preloadPackageChecksums()
  File "/usr/lib/python2.6/site-packages/yum/rpmsack.py", line 755, in preloadPackageChecksums
    pkg = self.searchNevra(n, e, v, r, a)[0]
IndexError: list index out of range


Version-Release number of selected component (if applicable):
mock-1.1.0-1.fc13.noarch
yum-3.2.27-4.fc13.noarch


How reproducible:
Deterministic.

Steps to Reproduce:
Run mock several times in a row.
  
Actual results:
The 1st mock run succeeds, subsequent runs fail.

Expected results:
Function.

Additional info:
Manually removing /var/lib/mock/*/root_cache before re-running mock seems to work around this issue.
Comment 1 seth vidal 2010-05-19 09:31:06 EDT
There's a patch to yum to fix this issue by not storing the rpmdb cache in /var/cache/yum - there is also a patch to mock to solve it by having the yumcache plugin that mock includes not copy the installed dir over.

Disabling the yumcache plugin in mock also solves this problem.
Comment 2 Ralf Corsepius 2010-05-19 10:29:17 EDT
Seth, thanks for the answer, but ... 

"FIXED UPSTREAM" or redirecting users of Fedora packages to apply work arounds means NOT FIXED AND IGNORED.

Re-opening, because the bug is not fixed. Appropriate time to close this BZ would be when a fixed package is being released.
Comment 3 Fedora Update System 2010-05-19 13:40:07 EDT
mock-1.0.8-1.fc12 has been submitted as an update for Fedora 12.
http://admin.fedoraproject.org/updates/mock-1.0.8-1.fc12
Comment 4 Fedora Update System 2010-05-19 13:41:32 EDT
mock-1.0.8-1.fc11 has been submitted as an update for Fedora 11.
http://admin.fedoraproject.org/updates/mock-1.0.8-1.fc11
Comment 5 Fedora Update System 2010-05-19 13:42:28 EDT
mock-1.0.8-1.el5 has been submitted as an update for Fedora EPEL 5.
http://admin.fedoraproject.org/updates/mock-1.0.8-1.el5
Comment 6 Fedora Update System 2010-05-20 14:39:29 EDT
mock-1.0.8-1.fc12 has been pushed to the Fedora 12 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update mock'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/mock-1.0.8-1.fc12
Comment 7 Fedora Update System 2010-05-20 14:48:28 EDT
mock-1.0.8-1.fc11 has been pushed to the Fedora 11 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update mock'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/mock-1.0.8-1.fc11
Comment 8 Fedora Update System 2010-05-20 20:32:30 EDT
mock-1.0.8-1.el5 has been pushed to the Fedora EPEL 5 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update mock'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/mock-1.0.8-1.el5
Comment 9 Sergio Pascual 2010-05-21 11:51:18 EDT
Mock is broken in Fedora 13 also.

Mock version mock-1.1.0-1.fc13.noarch
Comment 10 Ralf Corsepius 2010-05-21 12:12:19 EDT
(In reply to comment #9)
> Mock is broken in Fedora 13 also.
My original report was against Fedora 13's mock (mock-1.1.0-1.fc13.noarch)

> Mock version mock-1.1.0-1.fc13.noarch    
A locally rebuilt mock-1.1.1-1.fc13.noarch (currently only in CVS, not in testing) seems to work for me (It at least doesn't crash immediately.
Comment 11 Sergio Pascual 2010-05-21 12:26:27 EDT
Yes, it works for me. We just need the update for F-13 also
Comment 12 Stefan Schulze Frielinghaus 2010-05-27 11:25:59 EDT
I have the same problem here (F13 x86-64). Over the weekend I had to download about 6GB instead of 350MB one time (which drove me crazy ;-)) because I always had to delete the cache (debugging wasn't fun anymore).

Where can I find the patch for yum so I can still use the cache?

Regards,
Stefan
Comment 13 Arkady L. Shane 2010-05-27 11:31:45 EDT
Here it is: http://koji.fedoraproject.org/koji/buildinfo?buildID=173555
Comment 14 Stefan Schulze Frielinghaus 2010-05-27 13:01:14 EDT
Ahh perfect thanks! Works like expected, no re-downloading is necessary.
Comment 15 Fedora Update System 2010-08-03 18:29:09 EDT
mock-1.0.10-1.el5 has been submitted as an update for Fedora EPEL 5.
http://admin.fedoraproject.org/updates/mock-1.0.10-1.el5
Comment 16 Fedora Update System 2010-08-03 18:30:13 EDT
mock-1.0.10-1.fc12 has been submitted as an update for Fedora 12.
http://admin.fedoraproject.org/updates/mock-1.0.10-1.fc12
Comment 17 Fedora Update System 2010-08-04 19:04:44 EDT
mock-1.0.10-1.el5 has been pushed to the Fedora EPEL 5 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update mock'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/mock-1.0.10-1.el5
Comment 18 Fedora Update System 2010-08-05 19:37:45 EDT
mock-1.0.10-1.fc12 has been pushed to the Fedora 12 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update mock'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/mock-1.0.10-1.fc12
Comment 19 Fedora Update System 2010-08-19 13:33:46 EDT
mock-1.0.11-1.fc12 has been submitted as an update for Fedora 12.
http://admin.fedoraproject.org/updates/mock-1.0.11-1.fc12
Comment 20 Fedora Update System 2010-08-19 13:35:01 EDT
mock-1.0.11-1.el5 has been submitted as an update for Fedora EPEL 5.
http://admin.fedoraproject.org/updates/mock-1.0.11-1.el5
Comment 21 Fedora Update System 2010-08-25 21:03:54 EDT
mock-1.0.11-1.fc12 has been pushed to the Fedora 12 stable repository.  If problems still persist, please make note of it in this bug report.
Comment 22 Fedora Update System 2010-09-20 10:43:52 EDT
mock-1.0.12-1.fc12 has been submitted as an update for Fedora 12.
https://admin.fedoraproject.org/updates/mock-1.0.12-1.fc12
Comment 23 Fedora Update System 2010-09-20 10:45:24 EDT
mock-1.0.12-1.el5 has been submitted as an update for Fedora EPEL 5.
https://admin.fedoraproject.org/updates/mock-1.0.12-1.el5
Comment 24 Fedora Update System 2010-10-20 11:45:46 EDT
mock-1.0.13-1.el5 has been submitted as an update for Fedora EPEL 5.
https://admin.fedoraproject.org/updates/mock-1.0.13-1.el5
Comment 25 Fedora Update System 2010-10-20 11:47:55 EDT
mock-1.0.13-1.fc12 has been submitted as an update for Fedora 12.
https://admin.fedoraproject.org/updates/mock-1.0.13-1.fc12
Comment 26 Fedora Update System 2010-12-14 11:15:57 EST
mock-1.0.14-1.el5 has been submitted as an update for Fedora EPEL 5.
https://admin.fedoraproject.org/updates/mock-1.0.14-1.el5
Comment 27 Fedora Update System 2011-01-18 15:06:13 EST
mock-1.0.15-1.el5 has been submitted as an update for Fedora EPEL 5.
https://admin.fedoraproject.org/updates/mock-1.0.15-1.el5
Comment 28 Fedora Update System 2011-02-19 21:28:22 EST
mock-1.1.9-1.fc13 has been submitted as an update for Fedora 13.
https://admin.fedoraproject.org/updates/mock-1.1.9-1.fc13
Comment 29 Fedora Update System 2011-02-19 21:31:20 EST
mock-1.0.16-1.el5 has been submitted as an update for Fedora EPEL 5.
https://admin.fedoraproject.org/updates/mock-1.0.16-1.el5
Comment 30 Fedora Update System 2011-02-19 21:34:07 EST
mock-1.1.9-1.el6 has been submitted as an update for Fedora EPEL 6.
https://admin.fedoraproject.org/updates/mock-1.1.9-1.el6
Comment 31 Fedora Update System 2011-02-19 21:36:56 EST
mock-1.1.9-1.fc14 has been submitted as an update for Fedora 14.
https://admin.fedoraproject.org/updates/mock-1.1.9-1.fc14
Comment 32 Fedora Update System 2011-03-03 03:27:25 EST
mock-1.1.9-1.fc14 has been pushed to the Fedora 14 stable repository.  If problems still persist, please make note of it in this bug report.
Comment 33 Fedora Update System 2011-03-03 03:35:49 EST
mock-1.1.9-1.fc13 has been pushed to the Fedora 13 stable repository.  If problems still persist, please make note of it in this bug report.
Comment 34 Fedora Update System 2011-05-13 16:36:18 EDT
mock-1.1.10-1.fc15 has been submitted as an update for Fedora 15.
https://admin.fedoraproject.org/updates/mock-1.1.10-1.fc15
Comment 35 Fedora Update System 2011-05-13 16:40:32 EDT
mock-1.1.10-1.fc14 has been submitted as an update for Fedora 14.
https://admin.fedoraproject.org/updates/mock-1.1.10-1.fc14
Comment 36 Fedora Update System 2011-05-13 16:44:44 EDT
mock-1.0.17-1.el5 has been submitted as an update for Fedora EPEL 5.
https://admin.fedoraproject.org/updates/mock-1.0.17-1.el5
Comment 37 Fedora Update System 2011-05-13 16:49:02 EDT
mock-1.1.10-1.fc13 has been submitted as an update for Fedora 13.
https://admin.fedoraproject.org/updates/mock-1.1.10-1.fc13
Comment 38 Fedora Update System 2011-05-13 16:53:29 EDT
mock-1.1.10-1.el6 has been submitted as an update for Fedora EPEL 6.
https://admin.fedoraproject.org/updates/mock-1.1.10-1.el6
Comment 39 Fedora Update System 2011-05-19 00:37:40 EDT
mock-1.1.10-1.fc15 has been pushed to the Fedora 15 stable repository.  If problems still persist, please make note of it in this bug report.
Comment 40 Fedora Update System 2011-05-24 22:44:52 EDT
mock-1.1.10-1.fc14 has been pushed to the Fedora 14 stable repository.  If problems still persist, please make note of it in this bug report.
Comment 41 Fedora Update System 2011-05-24 23:19:00 EDT
mock-1.1.10-1.fc13 has been pushed to the Fedora 13 stable repository.  If problems still persist, please make note of it in this bug report.
Comment 42 Fedora Update System 2011-06-02 15:09:01 EDT
mock-1.0.17-1.el5 has been pushed to the Fedora EPEL 5 stable repository.  If problems still persist, please make note of it in this bug report.
Comment 43 Fedora Update System 2011-06-02 15:18:51 EDT
mock-1.1.10-1.el6 has been pushed to the Fedora EPEL 6 stable repository.  If problems still persist, please make note of it in this bug report.

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