git-review broken on Ubuntu+ARM

Bug #1243044 reported by Željko Filipin
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
git-review
Invalid
Undecided
Unassigned
git-review (Ubuntu)
New
Undecided
Unassigned

Bug Description

I have already reported this in Wikimedia bug tracker, but looks like this is the better place to report the problem:

https://bugzilla.wikimedia.org/show_bug.cgi?id=55732

I am following git-review installation instructions for Debian[1]. Everything
works fine until I try to use git-review.

$ sudo apt-get install python-pip
Reading package lists... Done
Building dependency tree
Reading state information... Done
python-pip is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.

$ sudo easy_install pip
Searching for pip
Best match: pip 1.0
Adding pip 1.0 to easy-install.pth file
Installing pip script to /usr/local/bin

Using /usr/lib/python2.7/dist-packages
Processing dependencies for pip
Finished processing dependencies for pip

$ sudo pip install git-review
Requirement already satisfied (use --upgrade to upgrade): git-review in
/usr/local/lib/python2.7/dist-packages
Requirement already satisfied (use --upgrade to upgrade): argparse in
/usr/lib/python2.7 (from git-review)
Cleaning up...

$ which git-review
/usr/local/bin/git-review

$ git remote -v
origin ssh://<email address hidden>:29418/qa/browsertests (fetch)
origin ssh://<email address hidden>:29418/qa/browsertests (push)

$ git review -s
Traceback (most recent call last):
  File "/usr/local/bin/git-review", line 1196, in <module>
    main()
  File "/usr/local/bin/git-review", line 1108, in main
    needs_update = latest_is_newer()
  File "/usr/local/bin/git-review", line 179, in latest_is_newer
    if not configParser.getboolean("updates", "check"):
  File "/usr/lib/python2.7/ConfigParser.py", line 368, in getboolean
    v = self.get(section, option)
  File "/usr/lib/python2.7/ConfigParser.py", line 607, in get
    raise NoSectionError(section)
ConfigParser.NoSectionError: No section: 'updates'

$ git review -vs
Traceback (most recent call last):
  File "/usr/local/bin/git-review", line 1196, in <module>
    main()
  File "/usr/local/bin/git-review", line 1108, in main
    needs_update = latest_is_newer()
  File "/usr/local/bin/git-review", line 179, in latest_is_newer
    if not configParser.getboolean("updates", "check"):
  File "/usr/lib/python2.7/ConfigParser.py", line 368, in getboolean
    v = self.get(section, option)
  File "/usr/lib/python2.7/ConfigParser.py", line 607, in get
    raise NoSectionError(section)
ConfigParser.NoSectionError: No section: 'updates'
(precise)z@localhost:~/project/browsertests$

$ git review -d 74128
Traceback (most recent call last):
  File "/usr/local/bin/git-review", line 1196, in <module>
    main()
  File "/usr/local/bin/git-review", line 1108, in main
    needs_update = latest_is_newer()
  File "/usr/local/bin/git-review", line 179, in latest_is_newer
    if not configParser.getboolean("updates", "check"):
  File "/usr/lib/python2.7/ConfigParser.py", line 368, in getboolean
    v = self.get(section, option)
  File "/usr/lib/python2.7/ConfigParser.py", line 607, in get
    raise NoSectionError(section)
ConfigParser.NoSectionError: No section: 'updates'

Could the problem be that the machine has ARM processor?

Environment:

Samsung Chromebook[2]

$ cat /etc/*-release
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=12.04
DISTRIB_CODENAME=precise
DISTRIB_DESCRIPTION="Ubuntu 12.04.3 LTS"
NAME="Ubuntu"
VERSION="12.04.3 LTS, Precise Pangolin"
ID=ubuntu
ID_LIKE=debian
PRETTY_NAME="Ubuntu precise (12.04.3 LTS)"
VERSION_ID="12.04"

$ uname -a
Linux localhost 3.4.0 #1 SMP Thu Sep 12 16:20:20 PDT 2013 armv7l armv7l armv7l
GNU/Linux

$ git review --version
git-review version 1.23

--

1: http://www.mediawiki.org/wiki/Gerrit/git-review#Debian
2: https://www.google.com/intl/en/chrome/devices/chromebooks.html#ss-cb

Jeremy Stanley (fungi)
Changed in git-review:
assignee: nobody → Jeremy Stanley (fungi)
importance: Undecided → Medium
status: New → Triaged
Revision history for this message
Jeremy Stanley (fungi) wrote :

The line of code where this exception is originating is https://git.openstack.org/cgit/openstack-infra/git-review/tree/git-review?id=1.23#n179 which is saying that you have a /etc/git-review/git-review.conf file with no "updates" section. Normally git-review shouldn't need a global configuration file (not sure how you wound up with one--maybe installing an older distribution package and then using pip to install a newer git-review?). You can try removing or correcting that file, but you might want to make sure that you uninstall and purge any old git-review you may have installed using apt-get as well.

Changed in git-review:
status: Triaged → Incomplete
importance: Medium → Undecided
assignee: Jeremy Stanley (fungi) → nobody
Revision history for this message
Željko Filipin (zeljko-filipin) wrote :

I have created the config file following instructions in this e-mail:

http://lists.wikimedia.org/pipermail/wikitech-l/2013-May/069672.html

Revision history for this message
Željko Filipin (zeljko-filipin) wrote :

Adding something like this to git-review.conf fixes the file:

[updates]
check=off

Revision history for this message
Jeremy Stanley (fungi) wrote :

Good to know. Unfortunately the git-review authors can't directly do much about bad advice someone may have posted to a random mailing ist somewhere. We do try to provide copious documentation along with git-review which describes how to configure and use it in great detail. If the official documentation is lacking to the point where you feel compelled to rely on such unofficial documentation instead, then please open a bug about what you found confusing in our documentation so that we can improve it. Thanks!

Changed in git-review:
status: Incomplete → Invalid
Revision history for this message
Marcin Cieślak (saperski) wrote :

This code has been removed in commit f93a719a100b92f473d1b07a20ed71bb4566e51b (https://github.com/openstack-infra/git-review/commit/f93a719a100b92f473d1b07a20ed71bb4566e51b).

I think this is still a valid bug against Ubuntu package - this exception should simply be caught and appropriate defaults taken. Adding distribution.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.