Red Hat Bugzilla – Bug 841104
fedora-review: fails to startup with "No mock group"
Last modified: 2012-08-17 21:30:25 EDT
Description of problem:
fedora-review fails to startup with "No mock group - mock not installed?"
error. Setting severity to high as the package is unusable (unless -p is given).
Version-Release number of selected component (if applicable):
Steps to Reproduce:
1. fedora-review -v -b 1
$ fedora-review -v -b 1
Exception down the road...
Traceback (most recent call last):
File "/usr/lib/python2.7/site-packages/FedoraReview/review_helper.py", line 115, in run
File "/usr/lib/python2.7/site-packages/FedoraReview/settings.py", line 188, in init
File "/usr/lib/python2.7/site-packages/FedoraReview/settings.py", line 105, in _check_mock_grp
raise ConfigError('No mock group - mock not installed?')
ConfigError: 'Configuration error: No mock group - mock not installed?'
Exception down the road...
fedora-review can find the mock group.
mock is installed and mock group exists. Also the user fedora-review
was ran as was a member of the mock group.
$ rpm -q mock
$ grep mock /etc/group
I don't know Python, but I tried debugging this a bit.
For me this seems to be the cause of the problem:
Python 2.7.3 (default, Apr 30 2012, 21:18:11)
[GCC 4.7.0 20120416 (Red Hat 4.7.0-2)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import os
mock GID is 996 and it's not on the list returned by os.getgroups().
Full steps to reproduce:
1) install a minimal F17
2) # yum install fedora-review
3) # useradd foo
4) # usermod -a -G mock foo
5) # su foo
6) $ fedora-review -v -b 1
It turns out that the user as which fedora-review is ran must be logged to the mock group. This can be done by running "newgrp mock". The manpage states that this command should be ran as root, while it needs to be ran as the user who will be running fedora review.
The manpage should be corrected, and also the error message should be made more user-friendly (something like "Please log into mock group" instead of "No mock group").
Also note that mock itself doesn't require logging to the mock group, so I think that fedora-review shouldn't require that either.
fedora-review-0.2.2-1.fc16 has been submitted as an update for Fedora 16.
fedora-review-0.2.2-1.fc17 has been submitted as an update for Fedora 17.
* should fix your issue,
* was pushed to the Fedora 16 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing fedora-review-0.2.2-1.fc16'
as soon as you are able to.
Please go to the following url:
then log in and leave karma (feedback).
fedora-review-0.2.2-1.fc16 has been pushed to the Fedora 16 stable repository. If problems still persist, please make note of it in this bug report.
fedora-review-0.2.2-1.fc17 has been pushed to the Fedora 17 stable repository. If problems still persist, please make note of it in this bug report.